-
Notifications
You must be signed in to change notification settings - Fork 76
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
Assign Row to NIRISS-parsed 1D Spectra #1836
Conversation
Codecov ReportBase: 88.15% // Head: 88.15% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## main #1836 +/- ##
=======================================
Coverage 88.15% 88.15%
=======================================
Files 95 95
Lines 10279 10280 +1
=======================================
+ Hits 9061 9062 +1
Misses 1218 1218
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
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.
👍 for test clean-up. Thanks!
assert spec1d.label == f"1D Spectrum {i}" | ||
spec2d = mosviz_helper.app.data_collection[i+11] | ||
assert spec2d.label == f"2D Spectrum {i}" | ||
assert int(spec1d.meta['SOURCEID']) == int(spec2d.meta['SOURCEID']) |
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.
Why is the int
casting necessary?
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.
So the reasoning here was that I wanted to make sure to avoid situation of None == None
. We know the source ids in this dataset are numbers, so I wanted to make sure we were getting back actual values rather than the same, nonsensical thing
Co-authored-by: P. L. Lim <[email protected]>
Co-authored-by: P. L. Lim <[email protected]>
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.
Code LGTM. Thanks!
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.
Awesome, thanks!
Oops, something went wrong applying the patch ... Please have a look at my logs. |
Hmm, auto backport failed. Do we really need to backport this? If so, @duytnguyendtn will need to manually do it. |
(I alerted the backport bot dev on how it is no longer applying follow-up label and proper manual backport message on failed backport.) |
I'm not particularly tied to this being backport @pllim. This bug has been in mosviz for quite some time (over a year) so I can't imagine anyone's desperate to get this fixed ASAP. It doesn't impact mosviz's core functionality. What should we do with the existing milestones? How do we switch this back to 3.2 AFTER the merge? is it just as simple as changing the milestone and removing the |
It is! I did that for you. 😸 |
I guess we also need to move the changelog entry. Should I make a PR for that? |
@@ -110,6 +110,8 @@ Mosviz | |||
|
|||
- Data unassigned a row is hidden under the subdropdown in the data dropdown. [#1798, #1808] | |||
|
|||
- Missing mosviz_row metadata in NIRISS-parsed 1D spectra now added. [#1836] |
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.
@duytnguyendtn , do you want to open a follow-up PR to move the change log to the 3.2 section instead?
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.
Will do!
Thanks Pey-Lian! I'll have a followup PR ready soon! |
Just testing the bot, please ignore. @meeseeksdev backport to v3.1.x |
Oops, something went wrong applying the patch ... Please have a look at my logs. |
@meeseeksdev backport to v3.1.x |
Awww, sorry blink1073 you do not seem to be allowed to do that, please ask a repository maintainer. |
Just testing the bot, please ignore. (Round 2) @meeseeksdev backport to v3.1.x |
Owee, I'm MrMeeseeks, Look at me. There seem to be a conflict, please backport manually. Here are approximate instructions:
And apply the correct labels and milestones. Congratulations — you did some good work! Hopefully your backport PR will be tested by the continuous integration and merged soon! Remember to remove the If these instructions are inaccurate, feel free to suggest an improvement. |
Description
This PR adds a 1 line fix to the NIRISS parser to assign the
mosviz_row
meta to the 1D spectra.Because this was such a quick fix, I also took the liberty of cleaning up the niriss and nirspec tests. This was so that I could add a test line to check for this bug in both our NIRISS and NIRspec tests
Fixes #1805
Change log entry
CHANGES.rst
? If you want to avoid merge conflicts,list the proposed change log here for review and add to
CHANGES.rst
before merge. If no, maintainershould add a
no-changelog-entry-needed
label.Checklist for package maintainer(s)
This checklist is meant to remind the package maintainer(s) who will review this pull request of some common things to look for. This list is not exhaustive.
trivial
label.