Add protections against duplicate frames#545
Merged
nden merged 15 commits intospacetelescope:masterfrom Jan 31, 2025
Merged
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #545 +/- ##
==========================================
+ Coverage 85.41% 85.74% +0.32%
==========================================
Files 22 27 +5
Lines 3957 3991 +34
==========================================
+ Hits 3380 3422 +42
+ Misses 577 569 -8 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Collaborator
Author
|
This passes the regression tests: |
WilliamJamieson
commented
Jan 8, 2025
| # Add the frame as an attribute of the pipeline | ||
| super().__setattr__(value.frame.name, value.frame) |
Collaborator
Author
There was a problem hiding this comment.
I tried to use a __getattr__ method instead of this but it broke deep copies in some cases for JWST and Romancal regression tests.
Cadair
added a commit
to Cadair/ndcube
that referenced
this pull request
Jan 14, 2025
3d52018 to
7852bf7
Compare
This will eventually simplify the WCS object and divide the code into areas of responsibility for better organization.
This does two things,
1. updates to using the "new" astropy doc theme
2. properly displays the methods inherited from parents
in the docs.
7852bf7 to
0677ff1
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR refactors GWCS with the goal of fixing issue #178; namely, that adding two frames with the same name causes the gwcs to behave weirdly.
This is accomplished by pulling the "pipeline" management code into a separate object and then adding protections in that object to prevent two frames of the same name to be added. Moreover, it also makes sure the last transform in the pipeline is
Noneas there is nothing for it to transform to.