librarian.txt fails sometimes
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Launchpad itself |
Fix Released
|
Critical
|
Abel Deuring |
Bug Description
A run of the test suite just failed with this error:
=======
FAILURE: lib/canonical/
-------
_StringException: Text attachment: traceback
------------
Traceback (most recent call last):
File "/usr/lib/
testMethod()
File "/usr/lib/
raise self.failureExc
AssertionError: Failed doctest test for librarian.txt
File "lib/canonical/
-------
File "lib/canonical/
Failed example:
aid = client.
Exception raised:
Traceback (most recent call last):
File "/usr/lib/
File "<doctest librarian.
File "/var/launchpad
File "/var/launchpad
File "/var/launchpad
raise UploadFailed(
UploadFailed: Server said: 200
-------
File "lib/canonical/
Failed example:
f.read()
Differences (ndiff with -expected +actual):
- ''
+ 'This is some data'
------------
devel was passing at the time, and the branch simply upgraded Launchpad to use Twisted 11.0.0, which had been known to work on a previous test run.
Related branches
- Aaron Bentley (community): Approve
-
Diff: 107 lines (+44/-6)2 files modifiedlib/canonical/librarian/client.py (+10/-6)
lib/canonical/librarian/ftests/test_client.py (+34/-0)
Changed in launchpad: | |
status: | In Progress → Fix Committed |
tags: | added: no-qa |
Changed in launchpad: | |
status: | Fix Committed → Fix Released |
tags: |
added: qa-untestable removed: no-qa |
This seems like a genuine bug in the Librarian, and I suspect will be causing uploads to randomly fail on production too. Do we see them in the OOPS reports?
_checkError sees the socket still has data to be read, but when it looks, the data that awaits is a success code. The Librarian is emitting a success code when one is not expected, and normally this passes because the check is made immediately after sending information to the Librarian and the Librarian will have normally not had time yet to process the information and respond.