Skip to content

Commit

Permalink
fixed failing unit tests
Browse files Browse the repository at this point in the history
  • Loading branch information
emolter committed Oct 16, 2024
1 parent 2d548ad commit 9f8f682
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/stcal/alignment/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,8 @@ def _calculate_new_wcs(wcs: gwcs.wcs.WCS,
transform: astmodels.Model | None = None,
) -> gwcs.wcs.WCS:
"""
Calculates a new WCS object based on the combined WCS objects provided.
Calculates a new WCS object based on the combined footprints
and reference WCS provided.
Parameters
----------
Expand Down Expand Up @@ -560,7 +561,10 @@ def wcs_from_footprints(
The WCS object corresponding to the combined input footprints.
"""
footprints = [_sregion_to_footprint(s_region) for s_region in footprints if isinstance(s_region, str)]

footprints = [_sregion_to_footprint(s_region)
if isinstance(s_region, str) else s_region
for s_region in footprints]
fiducial = _calculate_fiducial(footprints, crval=crval)

transform = _generate_tranform(
Expand Down

0 comments on commit 9f8f682

Please sign in to comment.