-
Notifications
You must be signed in to change notification settings - Fork 76
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Debug orientation operations with multiple viewers #2759
Debug orientation operations with multiple viewers #2759
Conversation
else: | ||
self.orientation.selected = "Default orientation" | ||
# Need to manually trigger this here for...reasons | ||
self._change_reference_data() |
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.
If "reasons" is unknown, we have to be sure this won't accidentally break #2751 😬
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.
At worst it will see that the selected orientation and reference data already match, but I'll rebase on top of your PR locally to double check.
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.
I rebased onto your #2751 branch and both our fixes still work.
Is it possible to add test for this case (and that it actually fails on |
I'll try adding a test, should be possible. |
jdaviz/app.py
Outdated
for viewer_id in self._viewer_store: | ||
if orientation_plugin is not None: | ||
orientation_plugin.viewer.selected = viewer_id | ||
orient = orientation_plugin.orientation.selected |
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.
Should have named this branch murder_on_the_orient_express
.
I added one test that fails on |
jdaviz/app.py
Outdated
for viewer_id in self._viewer_store: | ||
if orientation_plugin is not None: | ||
orientation_plugin.viewer.selected = viewer_id |
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.
Won't user see the viewer selection change every iteration when L2045 is run?
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.
Yes...I might be able to do this more elegantly without changing things in the plugin 🤔
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.
Your comment made me realize I didn't need to touch the plugin at all for the fix for bug 3, updated to a much better fix. Getting a fresh pair of eyes on things helps so much sometimes.
Maybe it is a mistake to allow users to change ref data from front-end data menu... |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2759 +/- ##
==========================================
+ Coverage 88.68% 88.70% +0.01%
==========================================
Files 108 108
Lines 16214 16223 +9
==========================================
+ Hits 14379 14390 +11
+ Misses 1835 1833 -2 ☔ View full report in Codecov by Sentry. |
@pllim I added a test that fails on main for the other bug. |
Co-authored-by: P. L. Lim <2090236+pllim@users.noreply.github.com>
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.
Thanks. LGTM!
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 good, thanks.
This fixes a few bugs with adding, changing and deleting orientations when multiple viewers exist. I don't believe there was an issue open for these to close.
Fixes: