Skip to content
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

DM-42636: Add ObservationInfo.observing_day_offset #71

Merged
merged 23 commits into from Feb 29, 2024
Merged

Conversation

timj
Copy link
Member

@timj timj commented Feb 20, 2024

No description provided.

Copy link

codecov bot commented Feb 20, 2024

Codecov Report

Attention: Patch coverage is 93.93939% with 4 lines in your changes are missing coverage. Please review.

Project coverage is 79.60%. Comparing base (b8aeb2f) to head (5c1496b).

Files Patch % Lines
...hon/astro_metadata_translator/cli/astrometadata.py 0.00% 3 Missing ⚠️
...ython/astro_metadata_translator/observationInfo.py 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #71      +/-   ##
==========================================
+ Coverage   78.59%   79.60%   +1.00%     
==========================================
  Files          36       36              
  Lines        3140     3133       -7     
  Branches      670      670              
==========================================
+ Hits         2468     2494      +26     
+ Misses        549      508      -41     
- Partials      123      131       +8     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@timj timj force-pushed the tickets/DM-42636 branch 5 times, most recently from 7eb96f4 to 11dc953 Compare February 22, 2024 17:27
@timj timj marked this pull request as ready for review February 25, 2024 20:08
@timj
Copy link
Member Author

timj commented Feb 27, 2024

@TallJimbo this is ready for review. There are many cleanup commits that you can ignore. There is only one commit that adds ObservationInfo.day_obs_offset.

This offset is what is used to calculate an observing day
from an observation date. There is also a class method allowing
the offset to be calculated from the observation date. Each
translator must declare an explicit value -- the default is
None and is equivalent to applying 0 offset when converting
a date time to an observing day.
I do not think the warning about switching to HIERARCH should
exist at all. The purpose of the Header class is to transparently
store the information in FITS in such a form that when we read
the header we get the information back. HIERARCH is an internal
implementation detail.
This also resulted in the astrometadata translate script
implementation getting a new name.
Sometimes this test fails with 4 conversion failurs instead of
3 and we do not know why because there is no useful output.
This change adds the output from the conversions on failure
and adjusts the test to compare the okay and failed count
at the same time by using a tuple.
@timj timj merged commit 6935484 into main Feb 29, 2024
15 checks passed
@timj timj deleted the tickets/DM-42636 branch February 29, 2024 21:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants