Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 11 additions & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ jobs:
matrix:
os: [windows-latest, ubuntu-latest, macos-latest]
python-version: ['3.10', '3.11', '3.12', '3.13', '3.14']
env:
# External test data is only downloaded (and cached) on this one runner
USE_EXTERNAL_DATA: ${{ contains(matrix.os, 'ubuntu') && matrix.python-version == '3.10' }}
defaults:
run:
shell: bash
Expand Down Expand Up @@ -44,7 +47,7 @@ jobs:
uses: actions/cache@v6
# We only download data on this runner, so only cache data from this run
# so we don't get an empty cache on other runners overriding that data
if: ${{ contains(matrix.os, 'ubuntu') && matrix.python-version == '3.10' }}
if: env.USE_EXTERNAL_DATA == 'true'
with:
path: |
**/data/
Expand All @@ -53,10 +56,15 @@ jobs:
restore-keys: |
cdf-data-

- name: Restore tracked files overwritten by the cache
# A fallback restore via restore-keys can bring back stale copies of
# git-tracked files under data/ and test_data/; reset them to the
# checked-out versions while keeping the untracked downloaded data.
if: env.USE_EXTERNAL_DATA == 'true'
run: git checkout -- .

- name: Testing
id: test
env:
USE_EXTERNAL_DATA: ${{ contains(matrix.os, 'ubuntu') && matrix.python-version == '3.10' }}
run: |
# Ignore the network marks from the remote test environment
if [ "$USE_EXTERNAL_DATA" = "true" ]; then
Expand Down
6 changes: 4 additions & 2 deletions imap_processing/glows/l1b/glows_l1b_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -995,7 +995,7 @@ def update_spice_parameters(self, spin_offset_correction: float = 0.0) -> None:

# Calculate spin period
# ---------------------
spin_data = get_spin_data()
spin_data = get_spin_data(use_corrected_spin_start=False)
# select spin data within the range from data start time to end time
spin_data = spin_data[
(spin_data["spin_start_met"] >= data_start_met)
Expand All @@ -1009,7 +1009,9 @@ def update_spice_parameters(self, spin_offset_correction: float = 0.0) -> None:
# --------------------------------
angle_offset = 360 - get_spin_angle(
get_instrument_spin_phase(
self.imap_start_time, instrument=geometry.SpiceFrame.IMAP_GLOWS
self.imap_start_time,
instrument=geometry.SpiceFrame.IMAP_GLOWS,
use_corrected_spin_start=False,
),
degrees=True,
)
Expand Down
Loading
Loading