From dd847ccd57f4cc97601c4ec5a89800200eff04e1 Mon Sep 17 00:00:00 2001 From: Brett Date: Tue, 5 Nov 2024 17:12:02 -0500 Subject: [PATCH] add F841 noqas --- src/stcal/alignment/util.py | 2 +- tests/test_alignment.py | 6 +++--- tests/test_infrastructure.py | 7 ++++--- tests/test_ramp_fitting.py | 3 ++- 4 files changed, 10 insertions(+), 8 deletions(-) diff --git a/src/stcal/alignment/util.py b/src/stcal/alignment/util.py index 90eb9420..e3aade7a 100644 --- a/src/stcal/alignment/util.py +++ b/src/stcal/alignment/util.py @@ -4,8 +4,8 @@ import functools import logging import re -from typing import TYPE_CHECKING import warnings +from typing import TYPE_CHECKING if TYPE_CHECKING: from collections.abc import Callable, Sequence diff --git a/tests/test_alignment.py b/tests/test_alignment.py index 6868985f..94633642 100644 --- a/tests/test_alignment.py +++ b/tests/test_alignment.py @@ -10,17 +10,17 @@ from stcal.alignment import resample_utils from stcal.alignment.util import ( + _compute_fiducial_from_footprints, + _sregion_to_footprint, _validate_wcs_list, compute_fiducial, - _compute_fiducial_from_footprints, compute_s_region_imaging, compute_s_region_keyword, compute_scale, reproject, - _sregion_to_footprint, wcs_bbox_from_shape, wcs_from_footprints, - wcs_from_sregions + wcs_from_sregions, ) diff --git a/tests/test_infrastructure.py b/tests/test_infrastructure.py index 37e68482..b09c37ac 100644 --- a/tests/test_infrastructure.py +++ b/tests/test_infrastructure.py @@ -1,16 +1,17 @@ """Tests of custom testing infrastructure""" -import pytest import numpy as np +import pytest + from stcal.testing_helpers import MemoryThreshold, MemoryThresholdExceeded def test_memory_threshold(): with MemoryThreshold("10 KB"): - buff = np.ones(1000, dtype=np.uint8) + buff = np.ones(1000, dtype=np.uint8) # noqa: F841 def test_memory_threshold_exceeded(): with pytest.raises(MemoryThresholdExceeded): with MemoryThreshold("500. B"): - buff = np.ones(10000, dtype=np.uint8) \ No newline at end of file + buff = np.ones(10000, dtype=np.uint8) # noqa: F841 diff --git a/tests/test_ramp_fitting.py b/tests/test_ramp_fitting.py index b6cd65d8..6a333976 100644 --- a/tests/test_ramp_fitting.py +++ b/tests/test_ramp_fitting.py @@ -1792,7 +1792,8 @@ def dbg_print(string): """ Print string with line number and filename. """ - import inspect, os + import inspect + import os cf = inspect.currentframe() line_number = cf.f_back.f_lineno finfo = inspect.getframeinfo(cf.f_back)