diff --git a/.github/workflows/mypy.yml b/.github/workflows/mypy.yml index 62cf4201..24d9c34b 100644 --- a/.github/workflows/mypy.yml +++ b/.github/workflows/mypy.yml @@ -1,4 +1,4 @@ -name: mypy +name: lint on: pull_request: @@ -6,7 +6,7 @@ on: branches: [main] jobs: - tox: + lint: strategy: matrix: python-version: ["3.8", "3.11"] @@ -30,5 +30,7 @@ jobs: run: python -m pip install --upgrade mypy typing-extensions ruff - name: run mypy run: cd spec/API_specification && mypy dataframe_api && mypy examples - - name: run ruff - run: cd spec/API_specification && ruff format dataframe_api examples && ruff dataframe_api examples + - name: run ruff format + run: cd spec/API_specification && ruff format dataframe_api examples --diff + - name: run ruff check + run: cd spec/API_specification && ruff check dataframe_api examples --no-fix diff --git a/spec/API_specification/dataframe_api/typing.py b/spec/API_specification/dataframe_api/typing.py index 818101ec..39071ca8 100644 --- a/spec/API_specification/dataframe_api/typing.py +++ b/spec/API_specification/dataframe_api/typing.py @@ -69,7 +69,7 @@ class NullType: null: NullType class Datetime: - time_unit: Literal['ms', 'us'] + time_unit: Literal["ms", "us"] time_zone: str | None def __init__( # noqa: ANN204 @@ -80,7 +80,7 @@ def __init__( # noqa: ANN204 ... class Duration: - time_unit: Literal['ms', 'us'] + time_unit: Literal["ms", "us"] def __init__( # noqa: ANN204 self,