Closed dwf closed 8 years ago
@rizar Please review and merge at will.
Can you provide a bit more explanation about this issue? I tried googling, but unsuccessfully.
Also, I don't like that the tests pass: https://travis-ci.org/mila-udem/blocks-extras/builds/90059416
PushThread
stores (int, ColumnDataSource)
tuples in a PriorityQueue
list. Python3 raises an exception because ColumnDataSource
objects are unorderable. PriorityQueue Notes (2nd bullet), warned about it :(.
I just successfully re-ran the same example with this fix in both Python2 and Python3 environments.
could Travis have ignored the exception because it was raised from a non-main Thread?
Okay, thanks for the explanation. Regarding the Travis, I don't think we would see such a nice a log as in https://travis-ci.org/mila-udem/blocks-extras/jobs/90059420 if we had an exception, even if it was in a secondary thread. Thus, I am still puzzled.
This is going to be an annoying thing to test, and not that useful as the Bokeh server has been entirely rewritten (for the better, thankfully) and so this is going to probably go away anyway. I'd rather just merge the fix for the interim.
All right, all right, let's merge this.
A recent pull request introduced an issue involving the comparison of unorderable types, which is noly an issue on Python 3. This fixes it by wrapping work items in a namedtuple-derived dummy class.
@johnarevalo