Skip to content

lint: silence deprecated flake8-mypy noise and bump mypy.ini to py3.1…#2369

Open
WatchTree-19 wants to merge 1 commit intopixie-io:mainfrom
WatchTree-19:fix/mypy-linting-noble
Open

lint: silence deprecated flake8-mypy noise and bump mypy.ini to py3.1…#2369
WatchTree-19 wants to merge 1 commit intopixie-io:mainfrom
WatchTree-19:fix/mypy-linting-noble

Conversation

@WatchTree-19
Copy link
Copy Markdown

Fixes #1955.

Two surgical config fixes for the mypy / flake8 linting setup under the Ubuntu noble linter image.

Root cause

The T499 errors are emitted by flake8-mypy, a flake8 plugin that wraps mypy with its own outdated args. The plugin has been deprecated since 2020 and is stuck on a Python 3.6 interpreter under noble. The plugin gets auto-loaded by flake8 because it's installed in the linter docker image.

.arclint already declares a separate, dedicated mypy linter that runs mypy --config-file=mypy.ini against the proper interpreter, so real mypy linting is happening regardless of flake8-mypy.

Changes

  • .flake8rc: add T499 to the ignore list with an explanatory comment matching the style of the existing N802 / E999 notes. Silences the broken plugin without touching the linter image.
    • mypy.ini: bump python_version from 3.8 to 3.12 to match the project's actual Python target (WORKSPACE declares python_version = "3.12").
      This intentionally does not block on or imply the broader linter-replacement work tracked in Replace arcanist with a support linting tool #1896.

Tested

Walked through the diff against the issue body's repro. Have not run arc lint locally - Pixie's Bazel + linter docker setup isn't in my dev env. Happy for a maintainer to confirm the noise stops on a real run.

pixie-io#1955)

Signed-off-by: WatchTree-19 <119982314+WatchTree-19@users.noreply.github.com>
@WatchTree-19 WatchTree-19 requested a review from a team as a code owner May 7, 2026 18:29
@WatchTree-19 WatchTree-19 requested a deployment to pr-actions-approval May 7, 2026 18:30 — with GitHub Actions Waiting
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Python/mypy linting broken with Ubuntu noble linter image

1 participant