Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/utybo/mypy-issue-89-repro
https://github.com/utybo/mypy-issue-89-repro
Last synced: 11 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/utybo/mypy-issue-89-repro
- Owner: utybo
- Created: 2024-03-23T21:03:00.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2024-03-23T21:03:37.000Z (8 months ago)
- Last Synced: 2024-10-11T11:22:08.060Z (about 1 month ago)
- Language: Python
- Size: 25.4 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# `mypy-vscode` [#89](https://github.com/matangover/mypy-vscode/issues/89) repro
Installation: `poetry install`, then open the repository in VS Code.
## Expected
When opening the VS Code repository from the root, the Mypy extension should display the same errors as running `mypy` in the `my-python-project` folder:
```sh
$ poetry run mypy .
my_python_project/reportme.py:2: error: Incompatible return value type (got "int", expected "str") [return-value]
Found 1 error in 1 file (checked 3 source files)
```## Actual
The mypy extension shows two problems:
![Example](image.png)
It _does_ correctly take the `mypy.ini` file into account as the error in `example.py` did disappear.
As I understand it, the main issue is that the `exclude` rules don't work as they're probably being interpreted relative to the root of the opened workspace, not the Python project's root.