bzrlib.tests.blackbox.test_serve.TestBzrServe.test_server_exception_with_hook is fragile
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Bazaar |
Fix Released
|
Critical
|
Vincent Ladeuil |
Bug Description
This just failed for me on PQM while trying to submit something unrelated.
=======
FAIL: bzrlib.
bzrlib.
-------
_StringException: Text attachment: log
------------
226.218 creating config directory: '/tmp/testbzr-
226.220 run bzr: ['serve']
226.220 bazaar version: 2.4.0dev4
226.220 bzr arguments: [u'serve']
226.236 encoding stdout as sys.stdout encoding 'UTF-8'
INFO catching exception
226.237 errors:
'catching exception\n'
226.260 opening working tree '/tmp/testbzr-
------------
Text attachment: traceback
------------
Traceback (most recent call last):
File "/usr/lib/
return fn(*args)
File "/usr/lib/
testMethod()
File "/home/
self.
AssertionError: not equal:
a = 'listening on port: 4155\ncatching exception\n'
b = 'catching exception\n'
Note that it got the exception before it started listening on the port. I think the fix is that the test should wait until it sees "listening on port" before it triggers the exception.
Either that, or it is a simple stdout/stderr buffering issue. Depending on when the listening line gets flushed, it can not be written before the exception occurs.
Marking this critical because it will cause bouncing from the PQM for things that aren't otherwise broken.
Related branches
- John A Meinel: Approve
-
Diff: 118 lines (+33/-15)2 files modifiedbzrlib/tests/blackbox/test_serve.py (+30/-15)
doc/en/release-notes/bzr-2.4.txt (+3/-0)
Changed in bzr: | |
status: | Confirmed → In Progress |
Changed in bzr: | |
milestone: | none → 2.4b4 |
status: | In Progress → Fix Released |
Hmm, it also listens on port4155 instead of using a random port which should be fixed too.