-
Notifications
You must be signed in to change notification settings - Fork 155
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement hub callback priorities #2530
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks promising! Just a couple of comments and then if you could look into the tests that'd be great, but if you don't have time, just let me know and I'll see if I can investigate.
I only see the one failed test on Mock called twice; tried with @astrofrog's suggestion and removing the |
Oh good, I was seeing two locally, the second must have been due to something else in my local setup. |
Co-authored-by: Derek Homeier <[email protected]>
I fixed the failing test, the second loop to yield the handlers shouldn't have been inside the loop to populate the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just some corrections to docstrings, otherwise looks good now, thanks!
Co-authored-by: Derek Homeier <[email protected]>
Excellent, thanks! |
This PR allows users to set a priority for the hub callback when subscribing to a hub message, e.g.:
I implemented this with a default priority of 10, where lower integer values are higher priority. I confirmed that this PR (and the code snippet above in Jdaviz) fixes the bug with the Layer not being populated before our data menu processes the
SubsetCreateMessage
.@astrofrog @dhomeier There are two failing tests, I haven't figured out yet why those are now failing, so if you have thoughts on that or the implementation in general let me know.