diff --git a/.github/workflows/dependabot.yml b/.github/workflows/dependabot.yml index dc4ae98..647d055 100644 --- a/.github/workflows/dependabot.yml +++ b/.github/workflows/dependabot.yml @@ -25,7 +25,7 @@ jobs: - name: Fetch tags run: git fetch --all --tags - name: Python setup - uses: actions/setup-python@v6 + uses: actions/setup-python@v7 with: python-version: "3.11" - name: Install the latest version of uv diff --git a/.github/workflows/publish-docs.yml b/.github/workflows/publish-docs.yml index b0bf094..9e1b7ed 100644 --- a/.github/workflows/publish-docs.yml +++ b/.github/workflows/publish-docs.yml @@ -20,7 +20,7 @@ jobs: uses: actions/checkout@v7 with: fetch-depth: 0 - - uses: actions/setup-python@v6 + - uses: actions/setup-python@v7 with: python-version: "3.11" - name: Install the latest version of uv diff --git a/.github/workflows/publish-pypi.yml b/.github/workflows/publish-pypi.yml index 207e07f..d9406b8 100644 --- a/.github/workflows/publish-pypi.yml +++ b/.github/workflows/publish-pypi.yml @@ -20,7 +20,7 @@ jobs: with: fetch-depth: 0 - name: Python setup - uses: actions/setup-python@v6 + uses: actions/setup-python@v7 with: python-version: "3.11" - name: Install the latest version of uv diff --git a/.github/workflows/run-tests.yml b/.github/workflows/run-tests.yml index 504f583..200f4e8 100644 --- a/.github/workflows/run-tests.yml +++ b/.github/workflows/run-tests.yml @@ -18,7 +18,7 @@ jobs: # checks out the repo - uses: actions/checkout@v7 - name: Python setup - uses: actions/setup-python@v6 + uses: actions/setup-python@v7 with: python-version: "3.11" - name: Install the latest version of uv @@ -41,7 +41,7 @@ jobs: - name: Checkout uses: actions/checkout@v7 - name: Python setup - uses: actions/setup-python@v6 + uses: actions/setup-python@v7 with: python-version: ${{ matrix.python_version }} - name: Install the latest version of uv diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c4297f4..89a00e9 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,11 +15,11 @@ repos: - id: check-yaml - id: detect-private-key - repo: https://github.com/tox-dev/pyproject-fmt - rev: "v2.25.1" + rev: "v2.26.0" hooks: - id: pyproject-fmt - repo: https://github.com/codespell-project/codespell - rev: v2.4.2 + rev: v2.4.3 hooks: - id: codespell exclude: | @@ -50,7 +50,7 @@ repos: hooks: - id: actionlint - repo: https://github.com/astral-sh/ruff-pre-commit - rev: "v0.15.20" + rev: "v0.16.1" hooks: - id: ruff-format - id: ruff-check diff --git a/src/cytodataframe/frame.py b/src/cytodataframe/frame.py index 92c46f5..6cd5249 100644 --- a/src/cytodataframe/frame.py +++ b/src/cytodataframe/frame.py @@ -112,7 +112,7 @@ class CytoDataFrame(pd.DataFrame): # while avoiding oversized outputs in typical Jupyter viewports. _DEFAULT_TABLE_MAX_HEIGHT: ClassVar[str] = "700px" - def __init__( # noqa: PLR0913 + def __init__( # noqa: PLR0913, PLR0917 self: CytoDataFrame_type, data: Union[CytoDataFrame_type, pd.DataFrame, str, pathlib.Path], data_context_dir: Optional[str] = None, @@ -840,7 +840,7 @@ def _slider_relative_position(value: float, slider_domain: np.ndarray) -> float: return position @staticmethod - def _build_filter_distribution_html( # noqa: C901, PLR0912, PLR0913, PLR0915 + def _build_filter_distribution_html( # noqa: C901, PLR0912, PLR0913, PLR0915, PLR0917 values: pd.Series, selected_range: Tuple[float, float], threshold_x: Optional[float] = None, @@ -2035,7 +2035,7 @@ def find_image_path_columns( and str(col).replace("FileName", "PathName") in all_cols } - def search_for_mask_or_outline( # noqa: PLR0913, PLR0911, C901 + def search_for_mask_or_outline( # noqa: PLR0913, PLR0911, PLR0917, C901 self: CytoDataFrame_type, data_value: str, pattern_map: dict, @@ -2644,7 +2644,7 @@ def _load_enhanced_image_for_display( # noqa: C901 return orig_image_array - def _prepare_cropped_image_layers( # noqa: C901, PLR0915, PLR0912, PLR0913 + def _prepare_cropped_image_layers( # noqa: C901, PLR0915, PLR0912, PLR0913, PLR0917 self: CytoDataFrame_type, data_value: Any, bounding_box: Tuple[int, int, int, int], @@ -3630,7 +3630,7 @@ def _find_3d_columns_for_display( return columns_3d - def _add_label_overlay_to_plotter( # noqa: PLR0913 + def _add_label_overlay_to_plotter( # noqa: PLR0913, PLR0917 self: CytoDataFrame_type, plotter: Any, volume: np.ndarray, @@ -3969,7 +3969,7 @@ def _toggle_overlay_actors_visibility( with contextlib.suppress(Exception): plotter.render() - def _build_pyvista_viewer( # noqa: C901, PLR0912, PLR0913, PLR0915 + def _build_pyvista_viewer( # noqa: C901, PLR0912, PLR0913, PLR0915, PLR0917 self: CytoDataFrame_type, volume: np.ndarray, backend: str, diff --git a/src/cytodataframe/volume.py b/src/cytodataframe/volume.py index b7e588c..4227931 100644 --- a/src/cytodataframe/volume.py +++ b/src/cytodataframe/volume.py @@ -82,7 +82,7 @@ def _resolve_vtk_js_url(display_options: Optional[dict]) -> str: return str(configured) if configured else VTK_JS_CDN_URL -def build_3d_image_html_view( # noqa: C901, PLR0912, PLR0913, PLR0915 +def build_3d_image_html_view( # noqa: C901, PLR0912, PLR0913, PLR0915, PLR0917 volume: np.ndarray, dims: Tuple[int, int, int], data_value: str, @@ -443,7 +443,7 @@ def extract_volume_from_ome_arrow( # noqa: C901, PLR0912 return None -def build_3d_html_from_path( # noqa: PLR0913 +def build_3d_html_from_path( # noqa: PLR0913, PLR0917 data_value: str, candidate_path: pathlib.Path, display_options: Optional[dict], diff --git a/tests/test_frame.py b/tests/test_frame.py index fb613ad..b907fd9 100644 --- a/tests/test_frame.py +++ b/tests/test_frame.py @@ -530,7 +530,7 @@ def test_find_matching_segmentation_path_prefers_candidate_parent_tree( assert matched.parent.name == "plate_a" -def test_cytodataframe_input( +def test_cytodataframe_input( # noqa: PLR0917 tmp_path: pathlib.Path, basic_outlier_dataframe: pd.DataFrame, basic_outlier_csv: str,