I should have synced https://github.com/pyodide/pyodide/pull/2177 with main before merging it, as there were a few extra commits on main where this version of pre-commit configuration wasn't yet applied.

This should fix CI.
Fix pre-commit CI. I should have synced https://github.com/pyodide/pyodide/pull/2177 with main before merging it, as there were a few extra commits on main where this version of pre-commit configuration wasn't yet applied.

This should fix CI.
exclude: '^.*patches|.*\.cgi$'
default_language_version:
  python: "3.9"
repos:
  - repo: https://github.com/pre-commit/pre-commit-hooks
    rev: "v4.1.0"
    hooks:
      - id: check-yaml
        exclude: .clang-format
      - id: end-of-file-fixer
      - id: trailing-whitespace

  - repo: https://github.com/psf/black
    rev: "22.1.0"
    hooks:
      - id: black

  - repo: https://gitlab.com/pycqa/flake8
    rev: 3.9.2
    hooks:
      - id: flake8
        types: [file, python]
        # only check for unused imports, as the rest is done by black
        args: [--select=F401]

  - repo: https://github.com/pre-commit/mirrors-mypy
    rev: v0.931
    hooks:
      - id: mypy
        args:
          - --show-error-codes
          - --ignore-missing-imports
        files: ^(src/|packages/.*/test|conftest.py|docs/)
        additional_dependencies: &mypy-deps
          - packaging
          - types-docutils
          - types-pyyaml
          - types-setuptools
      - id: mypy
        name: mypy-micropip
        files: ^packages/micropip/src/
        args: &mypy-args
          - --show-error-codes
        additional_dependencies: *mypy-deps
      - id: mypy
        name: mypy-pyodide-build
        files: ^pyodide-build/pyodide_build/
        args: *mypy-args
        additional_dependencies: *mypy-deps

  - repo: https://github.com/pre-commit/mirrors-clang-format
    rev: "v13.0.0"
    hooks:
      - id: clang-format

  - repo: https://github.com/pre-commit/mirrors-prettier
    rev: "v2.5.1"
    hooks:
      - id: prettier

exclude: '^.*patches|.*\.cgi$'
default_language_version:
  python: "3.9"
repos:
  - repo: https://github.com/pre-commit/pre-commit-hooks
    rev: "v4.1.0"
    hooks:
      - id: check-yaml
        exclude: .clang-format
      - id: end-of-file-fixer
      - id: trailing-whitespace

  - repo: https://github.com/psf/black
    rev: "22.1.0"
    hooks:
      - id: black

  - repo: https://gitlab.com/pycqa/flake8
    rev: 3.9.2
    hooks:
      - id: flake8
        types: [file, python]
        # only check for unused imports, as the rest is done by black
        args: [--select=F401]

  - repo: https://github.com/pre-commit/mirrors-mypy
    rev: v0.931
    hooks:
      - id: mypy
        args:
          - --show-error-codes
          - --ignore-missing-imports
        files: ^(src/|packages/.*/test|conftest.py|docs/)
        additional_dependencies: &mypy-deps
          - packaging
          - types-docutils
          - types-pyyaml
          - types-setuptools
      - id: mypy
        name: mypy-micropip
        files: ^packages/micropip/src/
        args: &mypy-args
          - --show-error-codes
        additional_dependencies: *mypy-deps
      - id: mypy
        name: mypy-pyodide-build
        files: ^pyodide-build/pyodide_build/
        args: *mypy-args
        additional_dependencies: *mypy-deps

  - repo: https://github.com/pre-commit/mirrors-clang-format
    rev: "v13.0.0"
    hooks:
      - id: clang-format

  - repo: https://github.com/pre-commit/mirrors-prettier
    rev: "v2.5.1"
    hooks:
      - id: prettier
