mirror of
https://github.com/davidhalter/django-stubs.git
synced 2025-12-15 08:17:08 +08:00
Fix mypy==0.710 errors (#97)
* error -> note for revealed type for tests * fixes for latest mypy
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
[env MYPY_DJANGO_CONFIG=${MYPY_CWD}/mypy_django.ini]
|
||||
[disable_cache]
|
||||
from django.conf import settings
|
||||
reveal_type(settings.NO_SUCH_SETTING) # E: Revealed type is 'Any'
|
||||
reveal_type(settings.NO_SUCH_SETTING) # N: Revealed type is 'Any'
|
||||
|
||||
[file mypy_django.ini]
|
||||
[[mypy_django_plugin]
|
||||
@@ -13,7 +13,7 @@ ignore_missing_settings = True
|
||||
[env MYPY_DJANGO_CONFIG=${MYPY_CWD}/mypy_django.ini]
|
||||
[disable_cache]
|
||||
from django.conf import settings
|
||||
reveal_type(settings.MY_SETTING) # E: Revealed type is 'builtins.int'
|
||||
reveal_type(settings.MY_SETTING) # N: Revealed type is 'builtins.int'
|
||||
|
||||
[file mypy_django.ini]
|
||||
[[mypy_django_plugin]
|
||||
@@ -26,7 +26,7 @@ MY_SETTING: int = 1
|
||||
[CASE mypy_django_ini_in_current_directory_is_a_default]
|
||||
[disable_cache]
|
||||
from django.conf import settings
|
||||
reveal_type(settings.MY_SETTING) # E: Revealed type is 'builtins.int'
|
||||
reveal_type(settings.MY_SETTING) # N: Revealed type is 'builtins.int'
|
||||
|
||||
[file mypy_django.ini]
|
||||
[[mypy_django_plugin]
|
||||
|
||||
Reference in New Issue
Block a user