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

Error with latest mypy release (0.750) #236

Closed
anlambert opened this issue Nov 29, 2019 · 1 comment
Closed

Error with latest mypy release (0.750) #236

anlambert opened this issue Nov 29, 2019 · 1 comment
Labels
bug Something isn't working

Comments

@anlambert
Copy link

Due to that recent change in mypy source code, the following error is reported when using django-stubs

mypy run-test: commands[0] | mypy swh
Traceback (most recent call last):
  File "/home/antoine/swh/swh-environment/swh-web/.tox/mypy/bin/mypy", line 8, in <module>
    sys.exit(console_entry())
  File "/home/antoine/swh/swh-environment/swh-web/.tox/mypy/lib/python3.7/site-packages/mypy/__main__.py", line 8, in console_entry
    main(None, sys.stdout, sys.stderr)
  File "mypy/main.py", line 89, in main
  File "mypy/build.py", line 166, in build
  File "mypy/build.py", line 235, in _build
  File "mypy/build.py", line 2567, in dispatch
  File "mypy/build.py", line 2725, in load_graph
  File "mypy/build.py", line 1826, in __init__
  File "mypy/build.py", line 2101, in compute_dependencies
  File "mypy/plugin.py", line 785, in get_additional_deps
  File "mypy/plugin.py", line 711, in get_additional_deps
  File "/home/antoine/swh/swh-environment/swh-web/.tox/mypy/lib/python3.7/site-packages/mypy_django_plugin/main.py", line 124, in get_additional_deps
    if file.fullname() == 'django.conf' and self.django_context.django_settings_module:
TypeError: 'str' object is not callable
ERROR: InvocationError for command /home/antoine/swh/swh-environment/swh-web/.tox/mypy/bin/mypy swh (exited with code 1)
@anlambert anlambert added the bug Something isn't working label Nov 29, 2019
@mkurnikov mkurnikov added this to the 1.3.0 milestone Nov 30, 2019
@mkurnikov
Copy link
Member

Fixed via #238

kalekseev pushed a commit to kalekseev/django-stubs that referenced this issue Jun 19, 2024
…ypeddjango#236)

Closes typeddjango#144

This seems straightforward, but I'm not writing a lot of .pyi files. I have tested it briefly and it seems to work.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Development

No branches or pull requests

2 participants