Skip to content

Instantly share code, notes, and snippets.

@terrycojones
Created March 24, 2012 02:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save terrycojones/2177560 to your computer and use it in GitHub Desktop.
Save terrycojones/2177560 to your computer and use it in GitHub Desktop.
[2012-03-24 01:28] <terrycojones> exarkun: thanks for fielding the question in stackoverflow related to txRDQ. i'm trying to figure out what's going wrong.
[2012-03-24 01:30] <terrycojones> exarkun: i've been putting in print stmts for about 30 mins and everything seems fine, but trial for some reason is printing [ERROR].
[2012-03-24 01:32] <idnar> terrycojones: the usual cause of an [ERROR] when there's apparently no exception being raised is that an exception was *logged* and not flushed
[2012-03-24 01:32] <idnar> (at least, in my experience)
[2012-03-24 01:32] <idnar> (I have absolutely no context here though, so that's just a wild guess)
[2012-03-24 01:33] <terrycojones> idnar: that sounds plausible / in line with exarkun's ticket suggestion, thanks. you just caused me to go read what exarkun wrote a bit more closely :-)
[2012-03-24 01:54] <terrycojones> idnar: well, i still don't see what the error is. idnar context is at http://stackoverflow.com/questions/9728781/testing-a-failing-job-in-resizabledispatchqueue-with-trial if you feel like looking.
[2012-03-24 01:55] <terrycojones> idnar: the self.queue.put(...) call returns a deferred. if i addBoth to it with something that flushes logged errors, there are no logged errors. even though the deferred has fired & failed.
[2012-03-24 01:56] <terrycojones> idnar: and i'm returning the deferred from the test case, to make sure trial gets it.
[2012-03-24 01:59] <terrycojones> idnar: i guess what i'm seeing would make sense if trial gave an [ERROR] after the test returns even if the test returns a deferred. so it gets the test result back, complains about the logged error, and sometime later the deferred fires & the flush finds no errors because trial has complained and cleared the logged errors.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment