Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add dmypy status file setting #332

Open
joecox opened this issue Nov 23, 2024 · 2 comments
Open

Add dmypy status file setting #332

joecox opened this issue Nov 23, 2024 · 2 comments
Labels
feature-request Request for new features or functionality good first issue Good for newcomers needs community feedback

Comments

@joecox
Copy link

joecox commented Nov 23, 2024

Hello! When developing, I like to use mypy 2 ways:

  • A mypy VSCode extension such as this one to see problems inline in my editor
  • Run mypy as a pre-commit hook to ensure type errors are not committed

When using preferDaemon, I find that I cannot easily have both share the same daemon process.

  • the extension generates a /tmp/.vscode.dmypy_status/status-<uuid>.json status file
  • I can set --status-file in my pre-commit hook, but I can't know which file the extension is using

The impact of this is that running the pre-commit hook is slow as it cannot make use of the already running daemon.

I have also tried setting path to:

    "mypy-type-checker.path": [
      "${workspaceFolder}/.venv/bin/python",
      "-m",
      "mypy.dmypy",
      "--status-file",
      ".dmypy.json"
    ]

but the extension overrides that CLI option with its own.

Proposal

Add an optional daemonStatusFile setting which vscode-mypy uses as the status file.

@karthiknadig karthiknadig added feature-request Request for new features or functionality good first issue Good for newcomers needs community feedback and removed triage-needed labels Nov 23, 2024
@karthiknadig
Copy link
Member

Thanks for the feature request! We are going to give the community 60 days from when this issue was created to provide 7 👍 upvotes on the opening comment to gauge general interest in this idea. If there's enough upvotes then we will consider this feature request in our future planning. If there's unfortunately not enough upvotes then we will close this issue.

We are also open for PR on this, seems like a useful feature to add.

@eleanorjboyd eleanorjboyd closed this as not planned Won't fix, can't repro, duplicate, stale Dec 10, 2024
@eleanorjboyd eleanorjboyd reopened this Dec 10, 2024
@eleanorjboyd
Copy link
Member

oops sorry- got the timing wrong, this still have a month and a half to get upvotes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request Request for new features or functionality good first issue Good for newcomers needs community feedback
Projects
None yet
Development

No branches or pull requests

3 participants