Tentative fix for usehttp2=true

Augie Fackler durin42 at gmail.com
Thu May 12 12:12:09 CDT 2011


For anyone experiencing the ssl defect, I've got a proposed fix out
for review at http://codereview.appspot.com/4532054/. If that works,
I'll push it to py-nonblocking-http and mail the corresponding change
for Mercurial. I'd like someone to test this that was experiencing the
defect, since I can't reproduce it myself (but I think I got unit
tests that are about right).

On Wed, May 11, 2011 at 7:34 AM, Peter Arrenbrecht
<peter.arrenbrecht at gmail.com> wrote:
> On Wed, May 11, 2011 at 2:20 PM, Peter Arrenbrecht
> <peter.arrenbrecht at gmail.com> wrote:
>> On Wed, May 11, 2011 at 2:19 PM, Peter Arrenbrecht
>> <peter.arrenbrecht at gmail.com> wrote:
>>> On Wed, May 11, 2011 at 2:17 PM, Augie Fackler <durin42 at gmail.com> wrote:
>>>>
>>>> On May 11, 2011, at 7:16 AM, Peter Arrenbrecht wrote:
>>>>
>>>>> On Wed, May 11, 2011 at 2:13 PM, Augie Fackler <durin42 at gmail.com> wrote:
>>>>>> Wow, I'm dumb. I'll get a test and fix (probably what you posted) into the upstream library and then get it imported back into hg.
>>>>>
>>>>> Please also look into the read error I mentioned on IRC:
>>>>> http://paste.pocoo.org/show/386790/
>>>>> -parren
>>>>
>>>> Was this repeatable consistently?
>>>
>>> Was and still is. ;)
>>> -parren
>>
>> Saw this with pull/incoming from Bitbucket and on a fresh clone of
>> oplop from Google Code.
>
> Better stack trace here:
>
> using https://bitbucket.org/tortoisehg/thg
> sending capabilities command
> warning: bitbucket.org certificate with fingerprint
> 81:2b:08:90:dc:d3:71:ee:e0:7c:b4:75:ce:9b:6c:48:94:56:a1:fe not
> verified (check hostfingerprints or web.cacerts config setting)
> comparing with https://bitbucket.org/tortoisehg/thg
> sending changegroupsubset command
> Traceback (most recent call last):
>  File "/home/peo/dev/hg/dev-crew/mercurial/dispatch.py", line 58, in _runcatch
>    return _dispatch(ui, args)
>  File "/home/peo/dev/hg/dev-crew/mercurial/dispatch.py", line 613, in _dispatch
>    cmdpats, cmdoptions)
>  File "/home/peo/dev/hg/dev-crew/mercurial/dispatch.py", line 418, in
> runcommand
>    ret = _runcommand(ui, options, cmd, d)
>  File "/home/peo/dev/hg/dev-crew/mercurial/dispatch.py", line 667, in
> _runcommand
>    return checkargs()
>  File "/home/peo/dev/hg/dev-crew/mercurial/dispatch.py", line 621, in checkargs
>    return cmdfunc()
>  File "/home/peo/dev/hg/dev-crew/mercurial/dispatch.py", line 610, in <lambda>
>    d = lambda: util.checksignature(func)(ui, *args, **cmdoptions)
>  File "/home/peo/dev/hg/dev-crew/mercurial/util.py", line 385, in check
>    return func(*args, **kwargs)
>  File "/home/peo/dev/hg/dev-crew/mercurial/commands.py", line 2717, in incoming
>    ret = hg.incoming(ui, repo, source, opts)
>  File "/home/peo/dev/hg/dev-crew/mercurial/hg.py", line 472, in incoming
>    return _incoming(display, subreporecurse, ui, repo, source, opts)
>  File "/home/peo/dev/hg/dev-crew/mercurial/hg.py", line 431, in _incoming
>    revs, opts["bundle"], opts["force"])
>  File "/home/peo/dev/hg/dev-crew/mercurial/bundlerepo.py", line 333,
> in getremotechanges
>    cg = other.changegroupsubset(incoming, onlyheads, 'incoming')
>  File "/home/peo/dev/hg/dev-crew/mercurial/wireproto.py", line 123,
> in changegroupsubset
>    bases=bases, heads=heads)
>  File "/home/peo/dev/hg/dev-crew/mercurial/httprepo.py", line 113, in
> _callstream
>    resp = self.urlopener.open(req)
>  File "/usr/lib/python2.6/urllib2.py", line 391, in open
>    response = self._open(req, data)
>  File "/usr/lib/python2.6/urllib2.py", line 409, in _open
>    '_open', req)
>  File "/usr/lib/python2.6/urllib2.py", line 369, in _call_chain
>    result = func(*args)
>  File "/home/peo/dev/hg/dev-crew/mercurial/httpconnection.py", line
> 232, in https_open
>    return self.do_open(self._makesslconnection, req)
>  File "/home/peo/dev/hg/dev-crew/mercurial/httpconnection.py", line
> 201, in do_open
>    r = h.getresponse()
>  File "/home/peo/dev/hg/dev-crew/mercurial/httpclient/__init__.py",
> line 631, in getresponse
>    r._select()
>  File "/home/peo/dev/hg/dev-crew/mercurial/httpclient/__init__.py",
> line 168, in _select
>    data = self.sock.recv(INCOMING_BUFFER_SIZE)
>  File "/usr/lib/python2.6/ssl.py", line 215, in recv
>    return self.read(buflen)
>  File "/usr/lib/python2.6/ssl.py", line 136, in read
>    return self._sslobj.read(len)
> SSLError: [Errno 2] _ssl.c:1331: The operation did not complete (read)
> abort: _ssl.c:1331: The operation did not complete (read)
>


More information about the Mercurial-devel mailing list