Skip to content

Add mypy-plugin extra dependency #1605

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

Merged
merged 2 commits into from
Jun 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
- name: Install dependencies
run: |
poetry config virtualenvs.in-project true
poetry install
poetry install --extras=compatible-mypy

poetry run pip install -U pip

Expand Down
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ You are also required to [configure](https://returns.readthedocs.io/en/latest/pa
`mypy` correctly and install our plugin
to fix [this existing issue](https://github.com/python/mypy/issues/3157):

```bash
pip install returns[compatible-mypy]
```
and

```ini
# In setup.cfg or mypy.ini:
[mypy]
Expand Down
5 changes: 4 additions & 1 deletion poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -48,14 +48,14 @@ _ = "returns.contrib.hypothesis._entrypoint"
python = "^3.7"

typing-extensions = ">=4.0,<5.0"
mypy = { version = "^1.4.0", optional = true }

[tool.poetry.dev-dependencies]
anyio = "^3.7"
trio = "^0.22"
attrs = "^23.1"
httpx = "^0.24"

mypy = "^1.4"
wemake-python-styleguide = "^0.17"
flake8-pytest-style = "^1.6"
flake8-pyi = "^23.4"
Expand All @@ -81,6 +81,9 @@ doc8 = "^1.0"
m2r2 = "^0.3"
tomlkit = "^0.11"

[tool.poetry.extras]
compatible-mypy = ["mypy"]


[build-system]
requires = ["poetry-core>=1.5.0"]
Expand Down