[Buildbot] #2951: AttributeError: 'NoneType' object has no attribute 'append'
Buildbot trac
trac at buildbot.net
Mon Oct 20 19:42:30 UTC 2014
#2951: AttributeError: 'NoneType' object has no attribute 'append'
-------------------+--------------------
Reporter: Ben | Owner:
Type: defect | Status: new
Priority: major | Milestone: 0.9.0
Version: 0.8.9 | Resolution:
Keywords: |
-------------------+--------------------
Comment (by dustin):
It looks like some newly-asynchronous method is being called *after* the
`run` method finishes. `run` has:
{{{
#!python
@defer.inlineCallbacks
def run(self):
self._start_deferred = defer.Deferred()
unhandled = self._start_unhandled_deferreds = []
try:
..
finally:
self._start_deferred = None
unhandled = self._start_unhandled_deferreds
self._start_unhandled_deferreds = None
}}}
The issue is that both `addLog` and `log.addStdout` are now asynchronous,
so a call to `log.addStdout` needs to wait until `addLog`'s deferred
fires, and *then* queue up a call to its `addStdout` method. If
`addLog`'s deferred doesn't fire until after the "finally" block above
runs, then `_catchup` has nowhere to put the deferred returned by
`addStdout`.
So probably the better approach is to iteratively wait for Deferreds in
`_start_unhandled_deferreds` until the list is empty.
--
Ticket URL: <http://trac.buildbot.net/ticket/2951#comment:2>
Buildbot <http://buildbot.net/>
Buildbot: build/test automation
More information about the bugs
mailing list