Setting --shadow-file makes dmypy reload daemon(perf issue)
Offen
Dieses Issue hat noch niemand übernommen.
performance
topic-daemon
- Vorherrschende Sprache
- Python
- Sterne
- 20.6k
- Forks
- 3.3k
- PR-Merge-Kennzahlen
- PR-Kennzahlen ausstehend
Beschreibung
This is a bug report.
- Minimal repro
$ touch test.py
$ cp test.py /tmp/test.py
$ dmypy run test.py
Daemon started
Success: no issues found in 22 source files
$ dmypy run test.py
Success: no issues found in 1 source file
$ dmypy run -- --shadow-file test.py /tmp/test.py test.py
Restarting: configuration changed
Daemon stopped
Daemon started
Success: no issues found in 22 source files
- What is the actual behavior/output?
dmypyinterprets setting--shadow-fileas a "configuration change" and reloads the mypy daemon. This effectively counteracts the whole point of having a daemon since it takes a long time to reload the daemon. - What is the behavior/output you expect?
dmypyshould not interpret--shadow-filechanges as configuration changes. It should use the existing daemon instead of reloading. - What are the versions of mypy and Python you are using?
Python 3.8.2.
mypy 0.790+dev.2e9afec83a5214f4a0eaf57a96034230b8460379
The mypy install is from Github master as of thirty minutes ago. - What are the mypy flags you are using? (For example --strict-optional)
The repro above describes this. There are nomypy.ini(or friends) files in the directory.
Beitragsleitfaden
Erste Schritte
- Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
- Forke das Repository und arbeite in einem Branch.
- Öffne einen Pull Request, der die Issue-Nummer nennt.
Rechercherichtung
Beginne damit, nachzuverfolgen, wie dmypy die Option --shadow-file verarbeitet und entscheidet, dass sich die Konfiguration geändert hat. Verwende die minimale Reproduktion, um zu überprüfen, dass das Ändern der Shadow-Datei den Daemon weder stoppt noch neu startet, während die Typprüfung mit der erwarteten Anzahl an Quelldateien weiterhin erfolgreich ist.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- python
- Bereich
- cli, tooling
- Issue-Typ
- Bug
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Klar beschrieben
- Anfängerfreundlichkeit
- 35/100