-
Notifications
You must be signed in to change notification settings - Fork 25
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
New tooling for comparing the keyword dictionary and data model schemas #337
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #337 +/- ##
==========================================
+ Coverage 66.55% 68.93% +2.38%
==========================================
Files 102 114 +12
Lines 5456 5910 +454
==========================================
+ Hits 3631 4074 +443
- Misses 1825 1836 +11 ☔ View full report in Codecov by Sentry. |
|
||
The "keyword dictionary" is a collection | ||
of json files that describe FITS keywords used in JWST files. | ||
Although the format is similar to jsonschema is is not compatible |
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.
"is is" should be "it is"
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! I applied that fix in b94d57d
Based on discussion with @tapastro there are a few remaining issues to sort out with this PR prior to approval (based on discussion of the currently generated report).
|
@tapastro I think this is ready for final review. See the comment above #337 (comment) for a checklist and linked commits for the items we discussed. I also added a test that fetches the latest "published" keyword dictionary from MAST (using an "unofficial" service since there is no official one) and parses it generating a report as a test of the new tool. I think this is worth expanding by adding a CI job that:
This way we will know when PRs impact keyword dictionary differences (relative the published version, not the latest dev version which is not public). However it makes sense to me to split this work into a separate PR as I'd like to get this one in to also start working on PRs to address the many differences. |
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.
🎉
https://jira.stsci.edu/browse/JP-3783
As it currently stands this PR:
stdatamodels.jwst._kwtool
python -m stdatamodels.jwst._kwtool.cli <keyword dictionary path>
Link to added docs: https://stdatamodels--337.org.readthedocs.build/en/337/jwst/kwtool/index.html
It would be helpful to have feedback on:
Some known issues are:
stdatamodels/src/stdatamodels/jwst/datamodels/schemas/spectracesingle.schema.yaml
Line 8 in 503320f
stdatamodels/src/stdatamodels/jwst/datamodels/schemas/spectrace.schema.yaml
Line 16 in 503320f
meta.items
). At first glance I would say this is a bug as I don't see how having every item in the list overwrite the PRIMARY EXP_TYPE is useful. However this might be a "bug" in the comparison where we don't care about this difference and we'll want some way to ignore it or not flag it as an issue in the first place. @tapastro does this usage look like a schema bug? If so I can open a separate issue.Tasks
docs/
pageno-changelog-entry-needed
)changes/
:echo "changed something" > changes/<PR#>.<changetype>.rst
(see below for change types)jwst
regression tests with this branch installed ("git+https://github.com/<fork>/stdatamodels@<branch>"
)news fragment change types...
changes/<PR#>.feature.rst
: new featurechanges/<PR#>.bugfix.rst
: fixes an issuechanges/<PR#>.doc.rst
: documentation changechanges/<PR#>.removal.rst
: deprecation or removal of public APIchanges/<PR#>.misc.rst
: infrastructure or miscellaneous change