Merge lp:~barry/lazr.restfulclient/bug-797281 into lp:lazr.restfulclient

Proposed by Barry Warsaw
Status: Merged
Merged at revision: 116
Proposed branch: lp:~barry/lazr.restfulclient/bug-797281
Merge into: lp:lazr.restfulclient
Diff against target: 15 lines (+4/-1)
1 file modified
src/lazr/restfulclient/_browser.py (+4/-1)
To merge this branch: bzr merge lp:~barry/lazr.restfulclient/bug-797281
Reviewer Review Type Date Requested Status
j.c.sackett (community) Approve
Review via email: mp+64894@code.launchpad.net

Description of the change

This works around LP: #797281 which is required in Oneiric. httplib2 0.7.0 added a feature to do SSL certificate validation, enabled by default, but lazr.restfulclient can't handle this. The workaround allows people to continue working with the same validation they had before (i.e. none ;). I'll file a new feature bug to support the cert validation.

To post a comment you must log in.
Revision history for this message
j.c.sackett (jcsackett) wrote :

Barry--

Looks fine, thanks.

=== modified file 'src/lazr/restfulclient/_browser.py'
--- src/lazr/restfulclient/_browser.py 2010-07-19 14:15:11 +0000
+++ src/lazr/restfulclient/_browser.py 2011-06-16 20:11:13 +0000
@@ -106,7 +106,10 @@

     def __init__(self, authorizer=None, cache=None, timeout=None,
                  proxy_info=None):
+ # XXX: Barry Warsaw 2011-06-16 bug=797281 ssl_certification
+ # must be disabled for lazr.restfulclient.
         super(RestfulHttp, self).__init__(
             cache, timeout, proxy_info,
- # LP: #797281
             disable_ssl_certificate_validation=True)
         self.authorizer = authorizer
         if self.authorizer is not None:
             self.authorizer.authorizeSession(self)

review: Approve
Revision history for this message
Barry Warsaw (barry) wrote :

Thanks. I don't believe I have permission to push this change.

Revision history for this message
Robert Collins (lifeless) wrote :

On Fri, Jun 17, 2011 at 2:07 PM, Barry Warsaw <email address hidden> wrote:
> Thanks.  I don't believe I have permission to push this change.

Have you tried?

Revision history for this message
Barry Warsaw (barry) wrote :

On Jun 17, 2011, at 08:48 AM, Robert Collins wrote:

>On Fri, Jun 17, 2011 at 2:07 PM, Barry Warsaw <email address hidden> wrote:
>> Thanks.  I don't believe I have permission to push this change.
>
>Have you tried?

I'm sure I'm doing something stupid, but:

@limelight[~/projects/lazr/lazr.restfulclient:1000]% bzr info
Repository tree (format: unnamed)
Location:
  shared repository: /home/barry/projects/lazr
  repository branch: .

Related branches:
    push branch: bzr+ssh://bazaar.launchpad.net/~lazr-developers/lazr.restfulclient/trunk/
  parent branch: bzr+ssh://bazaar.launchpad.net/~lazr-developers/lazr.restfulclient/trunk/
  submit branch: /home/barry/projects/lazr/bug-797281
@limelight[~/projects/lazr/lazr.restfulclient:1001]% bzr push :parent
bzr: ERROR: Cannot lock LockDir(lp-88074064:///~lazr-developers/lazr.restfulclient/trunk/.bzr/branchlock): Transport operation not possible: readonly transport

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/lazr/restfulclient/_browser.py'
2--- src/lazr/restfulclient/_browser.py 2010-07-19 14:15:11 +0000
3+++ src/lazr/restfulclient/_browser.py 2011-06-16 20:11:13 +0000
4@@ -106,7 +106,10 @@
5
6 def __init__(self, authorizer=None, cache=None, timeout=None,
7 proxy_info=None):
8- super(RestfulHttp, self).__init__(cache, timeout, proxy_info)
9+ super(RestfulHttp, self).__init__(
10+ cache, timeout, proxy_info,
11+ # LP: #797281
12+ disable_ssl_certificate_validation=True)
13 self.authorizer = authorizer
14 if self.authorizer is not None:
15 self.authorizer.authorizeSession(self)

Subscribers

People subscribed via source and target branches