diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 090fce9..6dc97ec 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -24,7 +24,7 @@ jobs: - name: Install Python tools run: | - pip install black==22.10.0 flake8==5.0.4 isort==5.11.5 + pip install black==26.5.1 flake8==7.3.0 isort==5.11.5 - name: Run black run: black --check . diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index b109223..ed15ad7 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/psf/black - rev: 22.10.0 + rev: 26.5.1 hooks: - id: black files: '^.*\.py' diff --git a/contributing/requirements.txt b/contributing/requirements.txt index 1337533..7b2f1fe 100644 --- a/contributing/requirements.txt +++ b/contributing/requirements.txt @@ -1,6 +1,6 @@ -black==22.10.0 -flake8==5.0.4 -isort==5.10.1 +black==26.5.1 +flake8==7.3.0 +isort==5.11.5 pre-commit==2.20.0 pytest==7.2.0 pytest-dotenv==0.5.2 diff --git a/fastlabel/utils/mask_image_util.py b/fastlabel/utils/mask_image_util.py index b48f6e6..7001ede 100644 --- a/fastlabel/utils/mask_image_util.py +++ b/fastlabel/utils/mask_image_util.py @@ -67,7 +67,10 @@ def __detect_segmentation_list( segmentation_list.append(segmentation) for separate_place_hierarchy_index in separate_place_hierarchy_indexes: - (segmentation, _,) = __detect_segmentation( + ( + segmentation, + _, + ) = __detect_segmentation( separate_place_hierarchy_index, hierarchy, contours ) segmentation_list.append(segmentation) diff --git a/tests/test_lerobot_v3_parquet.py b/tests/test_lerobot_v3_parquet.py index 417808a..d8e9a7d 100644 --- a/tests/test_lerobot_v3_parquet.py +++ b/tests/test_lerobot_v3_parquet.py @@ -4,6 +4,7 @@ check_dependencies so that pandas/pyarrow major-version bumps surface breakage in CI. """ + import pytest pd = pytest.importorskip("pandas") diff --git a/tests/test_pillow_exports.py b/tests/test_pillow_exports.py index b0f35bc..6352472 100644 --- a/tests/test_pillow_exports.py +++ b/tests/test_pillow_exports.py @@ -4,6 +4,7 @@ save, ImageDraw, and ImageColor calls inside fastlabel/__init__.py so that Pillow major-version bumps surface API breakage in CI. """ + import os import numpy as np diff --git a/tests/test_workspace_user.py b/tests/test_workspace_user.py index 9d3bc8a..e7729ee 100644 --- a/tests/test_workspace_user.py +++ b/tests/test_workspace_user.py @@ -4,6 +4,7 @@ endpoint, query params and payload. The HTTP layer (client.api.*_request) is stubbed so no real request is made. """ + import pytest import fastlabel