Skip to content

Commit

Permalink
Fix missing stacklevel keyword in call to warnings.warn().
Browse files Browse the repository at this point in the history
  • Loading branch information
mairanteodoro committed Jan 10, 2025
1 parent 206e85e commit 679f71e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion romancal/resample/resample_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,8 @@ def build_driz_weight(
inv_sky_variance[~np.isfinite(inv_sky_variance)] = 1
else:
warnings.warn(

Check warning on line 177 in romancal/resample/resample_utils.py

View check run for this annotation

Codecov / codecov/patch

romancal/resample/resample_utils.py#L177

Added line #L177 was not covered by tests
"var_rnoise and var_poisson arrays are not available. Setting drizzle weight map to 1"
"var_rnoise and var_poisson arrays are not available. Setting drizzle weight map to 1",
stacklevel=2,
)
inv_sky_variance = 1.0

Check warning on line 181 in romancal/resample/resample_utils.py

View check run for this annotation

Codecov / codecov/patch

romancal/resample/resample_utils.py#L181

Added line #L181 was not covered by tests
result = inv_sky_variance * dqmask
Expand Down

0 comments on commit 679f71e

Please sign in to comment.