-
Notifications
You must be signed in to change notification settings - Fork 75
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
Fix units JSON units error in notebook #3206
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3206 +/- ##
==========================================
+ Coverage 88.46% 88.49% +0.02%
==========================================
Files 125 125
Lines 18668 18671 +3
==========================================
+ Hits 16514 16522 +8
+ Misses 2154 2149 -5 ☔ View full report in Codecov by Sentry. |
jdaviz/configs/cubeviz/plugins/tests/test_cubeviz_unit_conversion.py
Outdated
Show resolved
Hide resolved
jdaviz/configs/specviz/plugins/unit_conversion/tests/test_unit_conversion.py
Outdated
Show resolved
Hide resolved
jdaviz/configs/specviz/plugins/unit_conversion/tests/test_unit_conversion.py
Outdated
Show resolved
Hide resolved
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 for the cleanup and added test-coverage - just a few small questions/comments
jdaviz/configs/cubeviz/plugins/tests/test_cubeviz_unit_conversion.py
Outdated
Show resolved
Hide resolved
jdaviz/configs/specviz/plugins/unit_conversion/unit_conversion.py
Outdated
Show resolved
Hide resolved
Looks like you are still pushing changes, let me know when all the changes are done. So far I like the simplification. Thanks! |
@pllim just responding to review comments - i've responded to all as of now so feel free to keep reviewing |
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.
Except the typo I introduce, code LGTM. Thanks!
This PR fixes the issue described in JDAT-4817
Some code cleanup in the unit conversion plugin is also in this PR. Setting available flux units for unit conversion based on the loaded dataset was able to be simplified. This includes:
Test coverage for unit conversion in cubeviz and specviz is added - the new tests test that for a cube loaded in a given unit, the dropdown items for available flux units to convert to in the unit conversion plugin are as expected.