Selftest: attempt to HTTPS test server should time out and generate an error
Bug #392402 reported by
Martitza
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Bazaar |
Fix Released
|
Medium
|
Vincent Ladeuil |
Bug Description
Vincent and Martin made significant contributions leading to thsi report.
See also: bug #392401 (Packaging Bug: SSL certificates missing from 1.16 PPA)
Tests should not wait forever for test servers to start. Either the servers should time out or the test waiting for the server response should time out. Either way, the results should be a test failure so that testing can continue with the next test. Currently, a nonresponsive test https server results in selftest stalling. I have observed this for https, but similar logic should probably apply to all test servers.
Related branches
lp:~vila/bzr/leaking-tests-catch-them-all
- Robert Collins (community): Needs Fixing
-
Diff: 363 lines (+109/-15)14 files modifiedbzrlib/smart/server.py (+3/-0)
bzrlib/tests/__init__.py (+9/-0)
bzrlib/tests/per_transport.py (+1/-1)
bzrlib/tests/test_http.py (+27/-1)
bzrlib/tests/test_server.py (+7/-1)
bzrlib/tests/test_smart_transport.py (+15/-11)
bzrlib/transport/__init__.py (+13/-0)
bzrlib/transport/ftp/__init__.py (+5/-0)
bzrlib/transport/gio_transport.py (+6/-0)
bzrlib/transport/http/__init__.py (+5/-0)
bzrlib/transport/http/_pycurl.py (+5/-0)
bzrlib/transport/http/_urllib.py (+5/-0)
bzrlib/transport/remote.py (+3/-1)
bzrlib/transport/sftp.py (+5/-0)
Changed in bzr: | |
status: | Confirmed → In Progress |
Changed in bzr: | |
milestone: | none → 2.3b1 |
status: | In Progress → Fix Released |
To post a comment you must log in.
As noted in bug #392401, the culprit is _handle_ request_ noblock in python SocketServer.py, line 268.
Socket exceptions occurring in get_request() (a request in that context is really a connection
and an SSL socket should be initialized by that call) are ignored.