python / python/mypy

dmypy fails to see errors after changing path

Open
#16,705 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug topic-daemon
Dominant language
Python
Stars
20.6k
Forks
3.3k
PR merge metrics
PR metrics pending

Description

Bug Report

It seems dmypy stops seeing errors when you give it exact paths.

To Reproduce

I have created a repository here with a command that creates a virtualenv and instructions on commands to run

https://github.com/delfick/mypy-daemon-bug

Expected Behavior

I expect to be able to run dmypy against different files in my project and have it still be able to see errors in files.

Actual Behavior

It appears that when dmypy is run with a different path in my project it loses the ability to see errors until the next time it is restarted

Your Environment

  • Mypy version used: 1.8.0
  • Mypy command-line flags: dmypy run -- <path>
  • Mypy configuration options from mypy.ini (and other config files): no configuration files
  • Python version used: 3.11.1

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked reproduction repository and run its documented commands using dmypy 1.8.0 and Python 3.11.1. Trace how dmypy run -- <path> handles successive exact paths; done means errors in project files remain visible after changing the path without restarting the daemon.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli, tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.