-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Import Literal from typing #11247
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
Closed
Closed
Import Literal from typing #11247
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Contributor
|
Diff from mypy_primer, showing the effect of this PR on open source code: python-sop (https://gitlab.com/dkg/python-sop)
- sop/__init__.py:224: error: Missing type parameters for generic type "_SubParsersAction" [type-arg]
- sop/__init__.py:387: error: Missing type parameters for generic type "_SubParsersAction" [type-arg]
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
parso (https://github.com/davidhalter/parso)
- parso/python/prefix.py:17: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- parso/python/tree.py:49: error: Module "collections" does not explicitly export attribute "Mapping" [attr-defined]
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
python-chess (https://github.com/niklasf/python-chess)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
vision (https://github.com/pytorch/vision)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
- torchvision/models/quantization/utils.py:29: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/quantization/utils.py:34: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/quantization/utils.py:39: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/tv_tensors/_tv_tensor.py:106: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/tv_tensors/_tv_tensor.py:111: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/tv_tensors/_tv_tensor.py:116: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/tv_tensors/_tv_tensor.py:121: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/tv_tensors/_tv_tensor.py:132: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/tv_tensors/_video.py:36: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/tv_tensors/_bounding_boxes.py:52: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/tv_tensors/_bounding_boxes.py:102: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/prototype/tv_tensors/_label.py:51: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/_api.py:178: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/transforms/_functional_pil.py:178: error: Argument "border" to "expand" has incompatible type "int | tuple[int, ...]"; expected "int | tuple[int, int] | tuple[int, int, int, int]" [arg-type]
- torchvision/transforms/_functional_pil.py:179: error: Argument 1 to "putpalette" of "Image" has incompatible type "list[int] | None"; expected "ImagePalette | bytes | Iterable[int] | SupportsBytes" [arg-type]
- torchvision/transforms/_functional_pil.py:182: error: Argument "border" to "expand" has incompatible type "int | tuple[int, ...]"; expected "int | tuple[int, int] | tuple[int, int, int, int]" [arg-type]
- torchvision/transforms/_functional_pil.py:209: error: Argument 1 to "putpalette" of "Image" has incompatible type "list[int] | None"; expected "ImagePalette | bytes | Iterable[int] | SupportsBytes" [arg-type]
- torchvision/transforms/_functional_pil.py:214: error: "Image" has no attribute "shape" [attr-defined]
- torchvision/transforms/_functional_pil.py:217: error: "Image" has no attribute "shape" [attr-defined]
- torchvision/transforms/_functional_pil.py:250: error: Argument 1 to "resize" of "Image" has incompatible type "tuple[int, ...]"; expected "tuple[int, int]" [arg-type]
- torchvision/transforms/_functional_pil.py:250: error: Argument 2 to "resize" of "Image" has incompatible type "int"; expected "Resampling | Literal[0, 1, 2, 3, 4, 5] | None" [arg-type]
- torchvision/transforms/_functional_pil.py:297: error: Argument 4 to "transform" of "Image" has incompatible type "int"; expected "Resampling | Literal[0, 1, 2, 3, 4, 5]" [arg-type]
- torchvision/transforms/_functional_pil.py:314: error: Argument 2 to "rotate" of "Image" has incompatible type "int"; expected "Resampling | Literal[0, 1, 2, 3, 4, 5]" [arg-type]
- torchvision/transforms/_functional_pil.py:330: error: Argument 4 to "transform" of "Image" has incompatible type "int"; expected "Resampling | Literal[0, 1, 2, 3, 4, 5]" [arg-type]
- torchvision/models/_utils.py:174: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/utils.py:119: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/utils.py:227: error: Incompatible types in assignment (expression has type "FreeTypeFont", variable has type "ImageFont") [assignment]
- torchvision/utils.py:560: error: Item "int" of "tuple[int, int, int] | tuple[int, int, int, int] | Any | int" has no attribute "__iter__" (not iterable) [union-attr]
- torchvision/utils.py:561: error: Incompatible return value type (got "list[tuple[int, int, int] | tuple[int, int, int, int] | Any | int]", expected "list[tuple[int, int, int]]") [return-value]
- torchvision/models/detection/generalized_rcnn.py:106: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/datasets/utils.py:145: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/swin_transformer.py:53: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/swin_transformer.py:288: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/swin_transformer.py:370: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/resnet.py:221: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/resnet.py:223: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/maxvit.py:87: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/maxvit.py:90: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/maxvit.py:96: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/maxvit.py:98: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/maxvit.py:178: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/maxvit.py:179: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/inception.py:89: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/inception.py:162: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/inception.py:376: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/inception.py:378: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/googlenet.py:87: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/googlenet.py:88: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/googlenet.py:170: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/googlenet.py:338: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/googlenet.py:339: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/resnet.py:248: error: Unused "type: ignore[arg-type, union-attr]" comment [unused-ignore]
- torchvision/models/video/resnet.py:447: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/datasets/widerface.py:89: error: Argument 1 to "open" has incompatible type "str | dict[str, Any]"; expected "str | bytes | Path | SupportsRead[bytes]" [arg-type]
- torchvision/datasets/cityscapes.py:190: error: Incompatible types in assignment (expression has type "Image", variable has type "dict[str, Any]") [assignment]
- torchvision/datasets/_stereo_matching.py:565: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/swin_transformer.py:53: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/swin_transformer.py:292: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/quantization/googlenet.py:203: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/quantization/googlenet.py:204: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/detection/backbone_utils.py:243: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/datasets/folder.py:76: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/datasets/video_utils.py:146: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/datasets/video_utils.py:386: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/mvit.py:234: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/mvit.py:235: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/mvit.py:236: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/mvit.py:251: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/mvit.py:252: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/mvit.py:253: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/mvit.py:263: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/mvit.py:264: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/mvit.py:265: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/video/mvit.py:344: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/detection/rpn.py:38: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/detection/rpn.py:40: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/detection/_utils.py:382: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/models/detection/_utils.py:486: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/tv_tensors/_image.py:52: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/transforms/v2/functional/_geometry.py:116: error: Module "PIL.Image" is not valid as a type [valid-type]
- torchvision/transforms/v2/functional/_geometry.py:116: note: Perhaps you meant to use a protocol matching the module structure?
- torchvision/transforms/v2/functional/_geometry.py:297: error: Argument "resample" to "resize" of "Image" has incompatible type "int"; expected "Resampling | Literal[0, 1, 2, 3, 4, 5] | None" [arg-type]
- torchvision/transforms/v2/functional/_color.py:703: error: Module "PIL.Image" is not valid as a type [valid-type]
- torchvision/transforms/v2/functional/_color.py:703: note: Perhaps you meant to use a protocol matching the module structure?
- torchvision/transforms/v2/_transform.py:113: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/transforms/v2/_augment.py:114: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/transforms/v2/_augment.py:115: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/transforms/v2/_augment.py:234: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/transforms/v2/_augment.py:282: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/transforms/v2/_misc.py:378: error: "bool" has no attribute "all" [attr-defined]
- torchvision/transforms/v2/_meta.py:25: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/transforms/v2/_meta.py:38: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/transforms/v2/_geometry.py:265: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/transforms/v2/_geometry.py:266: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/transforms/v2/_geometry.py:473: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/prototype/models/depth/stereo/raft_stereo.py:456: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/prototype/models/depth/stereo/crestereo.py:335: error: Unused "type: ignore" comment [unused-ignore]
- torchvision/prototype/models/depth/stereo/crestereo.py:481: error: Unused "type: ignore" comment [unused-ignore]
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
attrs (https://github.com/python-attrs/attrs)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
paroxython (https://github.com/laowantong/paroxython)
- paroxython/goodies.py:10: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/flatten_ast.py:319: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/preprocess_source.py:32: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/normalize_predicate.py:5: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/list_programs.py:6: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/list_programs.py:51: error: Incompatible default for argument "relative_path" (default has type "None", argument has type "Path") [assignment]
- paroxython/list_programs.py:51: note: PEP 484 prohibits implicit Optional. Accordingly, mypy has changed its default to no_implicit_optional=True
- paroxython/list_programs.py:51: note: Use https://github.com/hauntsaninja/no_implicit_optional to automatically upgrade your codebase
- paroxython/filter_programs.py:20: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/derived_labels_db.py:84: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/recommend_programs.py:36: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/recommend_programs.py:160: error: Incompatible types in assignment (expression has type "str", variable has type "Operation") [assignment]
- paroxython/parse_program.py:9: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/parse_program.py:240: error: Incompatible types in assignment (expression has type "Callable[[str, int, int, bool, bool | None, float | None], Scanner[str]]", target has type "Pattern[Any]") [assignment]
- paroxython/parse_program.py:288: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/parse_program.py:297: error: "Pattern[Any]" not callable [operator]
- paroxython/label_programs.py:6: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/cli_recommend.py:83: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/map_taxonomy.py:113: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/map_taxonomy.py:178: error: Argument 1 to "append" of "list" has incompatible type "tuple[regex.regex.Pattern[str], TaxonPattern]"; expected "tuple[re.Pattern[Any], TaxonPattern]" [arg-type]
- paroxython/make_db.py:12: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/cli.py:24: error: Unused "type: ignore" comment [unused-ignore]
- paroxython/cli.py:25: error: Unused "type: ignore" comment [unused-ignore]
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
porcupine (https://github.com/Akuli/porcupine)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
- porcupine/__init__.py:28: error: Unused "type: ignore" comment [unused-ignore]
- porcupine/settings.py:82: error: Unused "type: ignore" comment [unused-ignore]
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
bidict (https://github.com/jab/bidict)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
pyp (https://github.com/hauntsaninja/pyp)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
itsdangerous (https://github.com/pallets/itsdangerous)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
pip (https://github.com/pypa/pip)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
- src/pip/_internal/metadata/_json.py:82: error: Incompatible types in assignment (expression has type "Message | Any | str | list[Message | str]", target has type "str | list[str]") [assignment]
- src/pip/_internal/metadata/pkg_resources.py:162: error: Item "EmptyProvider" of "Any | EmptyProvider" has no attribute "path" [union-attr]
- src/pip/_internal/metadata/pkg_resources.py:236: error: Argument 1 to "Environment" has incompatible type "None"; expected "WorkingSet" [arg-type]
- src/pip/_internal/req/req_uninstall.py:176: error: Unused "type: ignore" comment [unused-ignore]
- src/pip/_internal/network/utils.py:41: error: Incompatible types in assignment (expression has type "Any | None", variable has type "str") [assignment]
- src/pip/_internal/network/utils.py:43: error: Unsupported operand types for <= ("int" and "None") [operator]
- src/pip/_internal/network/utils.py:43: note: Right operand is of type "Any | None"
- src/pip/_internal/network/utils.py:43: error: Unsupported operand types for > ("int" and "None") [operator]
- src/pip/_internal/network/utils.py:43: note: Left operand is of type "Any | None"
- src/pip/_internal/network/utils.py:48: error: Unsupported operand types for <= ("int" and "None") [operator]
- src/pip/_internal/network/utils.py:48: note: Right operand is of type "Any | None"
- src/pip/_internal/network/utils.py:48: error: Unsupported operand types for > ("int" and "None") [operator]
- src/pip/_internal/network/utils.py:48: note: Left operand is of type "Any | None"
- src/pip/_internal/network/utils.py:63: error: Item "None" of "Any | None" has no attribute "stream" [union-attr]
- src/pip/_internal/network/utils.py:93: error: Item "None" of "Any | None" has no attribute "read" [union-attr]
- src/pip/_internal/network/auth.py:486: error: Argument 1 to "_get_new_credentials" of "MultiDomainBasicAuth" has incompatible type "Any | None"; expected "str" [arg-type]
- src/pip/_internal/network/auth.py:500: error: Argument 1 to "_prompt_for_password" of "MultiDomainBasicAuth" has incompatible type "bytes"; expected "str" [arg-type]
- src/pip/_internal/network/auth.py:505: error: Invalid index type "bytes" for "dict[str, tuple[str | None, str | None]]"; expected type "str" [index]
- src/pip/_internal/network/auth.py:510: error: Argument "url" to "Credentials" has incompatible type "bytes"; expected "str" [arg-type]
- src/pip/_internal/network/auth.py:520: error: Item "None" of "Any | None" has no attribute "release_conn" [union-attr]
- src/pip/_internal/network/auth.py:533: error: "Response" has no attribute "connection" [attr-defined]
- src/pip/_internal/network/auth.py:543: error: Item "None" of "Any | None" has no attribute "url" [union-attr]
- src/pip/_internal/network/auth.py:554: error: Unsupported operand types for > ("int" and "None") [operator]
- src/pip/_internal/network/auth.py:554: note: Left operand is of type "Any | None"
- src/pip/_internal/network/session.py:220: error: Argument 1 to "url_to_path" has incompatible type "Any | None"; expected "str" [arg-type]
- src/pip/_internal/network/session.py:246: error: Cannot assign to a method [method-assign]
- src/pip/_internal/network/session.py:388: error: Incompatible types in assignment (expression has type "HTTPAdapter", variable has type "CacheControlAdapter") [assignment]
- src/pip/_internal/network/session.py:389: error: Incompatible types in assignment (expression has type "InsecureHTTPAdapter", variable has type "InsecureCacheControlAdapter") [assignment]
- src/pip/_internal/network/session.py:405: error: Item "None" of "Any | None" has no attribute "index_urls" [union-attr]
- src/pip/_internal/index/collector.py:92: error: Item "None" of "Any | None" has no attribute "method" [union-attr]
- src/pip/_internal/index/collector.py:331: error: Argument "url" to "IndexContent" has incompatible type "Any | None"; expected "str" [arg-type]
- src/pip/_internal/network/download.py:109: error: Argument 1 to "splitext" has incompatible type "Any | None"; expected "PathLike[Any]" [arg-type]
- src/pip/_internal/cli/req_command.py:150: error: Item "None" of "Any | None" has no attribute "prompting" [union-attr]
- src/pip/_internal/cli/req_command.py:151: error: Item "None" of "Any | None" has no attribute "keyring_provider" [union-attr]
stone (https://github.com/dropbox/stone)
- stone/ir/data_types.py:1653: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- test/test_python_type_stubs.py:13: error: Unused "type: ignore" comment [unused-ignore]
- stone/backends/python_rsrc/stone_serializers.py:324: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- stone/backends/python_rsrc/stone_serializers.py:420: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
cloud-init (https://github.com/canonical/cloud-init)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
- tests/hypothesis_jsonschema.py:8: error: Unused "type: ignore" comment [unused-ignore]
- cloudinit/net/netops/__init__.py:38: error: Missing return statement [empty-body]
- cloudinit/distros/parsers/ifconfig.py:30: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/distros/parsers/ifconfig.py:37: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/distros/parsers/ifconfig.py:38: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/distros/parsers/ifconfig.py:40: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/distros/parsers/ifconfig.py:41: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/distros/parsers/ifconfig.py:42: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/distros/parsers/ifconfig.py:43: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- tests/hypothesis.py:10: error: Unused "type: ignore" comment [unused-ignore]
- cloudinit/safeyaml.py:146: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/util.py:3264: error: Unused "type: ignore" comment [unused-ignore]
- cloudinit/reporting/__init__.py:37: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/reporting/__init__.py:46: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/net/sysconfig.py:956: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/distros/package_management/apt.py:117: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/reporting/events.py:124: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/distros/__init__.py:156: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/distros/__init__.py:164: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/distros/debian.py:60: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/sources/DataSourceAzure.py:1842: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/config/schema.py:852: error: Incompatible default for argument "instance_data_path" (default has type "None", argument has type "str") [assignment]
- cloudinit/config/schema.py:852: note: PEP 484 prohibits implicit Optional. Accordingly, mypy has changed its default to no_implicit_optional=True
- cloudinit/config/schema.py:852: note: Use https://github.com/hauntsaninja/no_implicit_optional to automatically upgrade your codebase
- cloudinit/config/schema.py:923: error: Incompatible default for argument "instance_data_path" (default has type "None", argument has type "str") [assignment]
- cloudinit/config/schema.py:923: note: PEP 484 prohibits implicit Optional. Accordingly, mypy has changed its default to no_implicit_optional=True
- cloudinit/config/schema.py:923: note: Use https://github.com/hauntsaninja/no_implicit_optional to automatically upgrade your codebase
- cloudinit/config/cc_ubuntu_advantage.py:337: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/config/cc_ubuntu_advantage.py:345: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/config/cc_growpart.py:402: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/config/cc_apt_configure.py:715: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/config/cc_apt_configure.py:716: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- cloudinit/cmd/devel/hotplug_hook.py:77: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- tests/unittests/test_templating.py:268: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
- tests/unittests/sources/test_akamai.py:20: error: Incompatible default for argument "ds_cfg" (default has type "None", argument has type "dict[str, Any]") [assignment]
- tests/unittests/sources/test_akamai.py:20: note: PEP 484 prohibits implicit Optional. Accordingly, mypy has changed its default to no_implicit_optional=True
- tests/unittests/sources/test_akamai.py:20: note: Use https://github.com/hauntsaninja/no_implicit_optional to automatically upgrade your codebase
- tests/unittests/config/test_cc_ubuntu_drivers.py:84: note: By default the bodies of untyped functions are not checked, consider using --check-untyped-defs [annotation-unchecked]
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
CPython (peg_generator) (https://github.com/python/cpython)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
steam.py (https://github.com/Gobot1234/steam.py)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/builtins.pyi:211: error: INTERNAL ERROR -- Please try using mypy master on GitHub:
+ https://mypy.readthedocs.io/en/stable/common_issues.html#using-a-development-mypy-build
+ Please report a bug at https://github.com/python/mypy/issues
+ version: 1.8.0
+ note: use --pdb to drop into pdb
+ Traceback (most recent call last):
+ File "mypy/semanal.py", line 6539, in accept
+ File "mypy/nodes.py", line 1310, in accept
+ File "mypy/semanal.py", line 2855, in visit_assignment_stmt
+ File "mypy/semanal.py", line 3612, in check_and_set_up_type_alias
+ File "mypy/semanal.py", line 3501, in analyze_alias
+ File "mypy/typeanal.py", line 156, in analyze_type_alias
+ File "mypy/types.py", line 2858, in accept
+ File "mypy/typeanal.py", line 1185, in visit_union_type
+ File "mypy/typeanal.py", line 1659, in anal_array
+ File "mypy/typeanal.py", line 1684, in anal_type
+ File "mypy/types.py", line 955, in accept
+ File "mypy/typeanal.py", line 259, in visit_unbound_type
+ File "mypy/typeanal.py", line 399, in visit_unbound_type_nonoptional
+ File "mypy/typeanal.py", line 624, in try_analyze_special_unbound_type
+ File "mypy/typeanal.py", line 1470, in analyze_literal_type
+ File "mypy/typeanal.py", line 1536, in analyze_literal_param
+ File "mypy/typeanal.py", line 1738, in named_type
+ File "mypy/typeanal.py", line 256, in lookup_fully_qualified
+ File "mypy/semanal.py", line 5852, in lookup_fully_qualified
+ AssertionError: builtins.int
- steam/types/trade.py:69: error: Overwriting TypedDict field "instanceid" while merging [misc]
- steam/types/trade.py:69: error: Overwriting TypedDict field "classid" while merging [misc]
- steam/types/trade.py:112: error: Overwriting TypedDict field "assetid" while merging [misc]
- steam/types/trade.py:112: error: Overwriting TypedDict field "amount" while merging [misc]
- steam/types/trade.py:112: error: Overwriting TypedDict field "appid" while merging [misc]
- steam/types/trade.py:112: error: Overwriting TypedDict field "contextid" while merging [misc]
- steam/types/trade.py:112: error: Overwriting TypedDict field "instanceid" while merging [misc]
- steam/types/trade.py:112: error: Overwriting TypedDict field "classid" while merging [misc]
- steam/types/trade.py:112: error: Overwriting TypedDict field "missing" while merging [misc]
- steam/types/vdf.py:31: error: Incompatible return value type (implicitly returns "None", expected "NoReturn") [empty-body]
- steam/types/vdf.py:34: error: Incompatible return value type (implicitly returns "None", expected "NoReturn") [empty-body]
- steam/types/app.py:171: error: Unsupported dynamic base class "TypedDict" [misc]
- steam/types/app.py:173: error: NotRequired[] can be only used in a TypedDict definition [valid-type]
- steam/types/app.py:177: error: NotRequired[] can be only used in a TypedDict definition [valid-type]
- steam/types/app.py:178: error: NotRequired[] can be only used in a TypedDict definition [valid-type]
- steam/types/manifest.py:66: error: Duplicate TypedDict key "review_percentage" [misc]
- steam/types/manifest.py:67: error: Duplicate TypedDict key "review_score" [misc]
- steam/types/manifest.py:70: error: Duplicate TypedDict key "steam_release_date" [misc]
- steam/types/manifest.py:72: error: Duplicate TypedDict key "store_tags" [misc]
- steam/_const.py:29: error: Module "steam.clan" has no attribute "Clan" [attr-defined]
- steam/_const.py:30: error: Module "steam.group" has no attribute "Group" [attr-defined]
- steam/_const.py:37: error: Unused "type: ignore" comment [unused-ignore]
- steam/_const.py:57: error: Unused "type: ignore" comment [unused-ignore]
- steam/_const.py:69: error: Unused "type: ignore" comment [unused-ignore]
- steam/_const.py:73: error: Function is missing a return type annotation [no-untyped-def]
- steam/_const.py:73: error: Function is missing a type annotation for one or more arguments [no-untyped-def]
- steam/_const.py:75: error: Unused "type: ignore" comment [unused-ignore]
- steam/_const.py:90: error: Unused "type: ignore" comment [unused-ignore]
- steam/_const.py:100: error: Unused "type: ignore" comment [unused-ignore]
- steam/_const.py:109: error: Unused "type: ignore" comment [unused-ignore]
- steam/_const.py:110: error: Unused "type: ignore" comment [unused-ignore]
- steam/_const.py:118: error: Unused "type: ignore" comment [unused-ignore]
- steam/_const.py:146: error: Invalid base class [misc]
- steam/_const.py:195: error: Cannot assign to a method [method-assign]
- steam/_const.py:195: error: Incompatible types in assignment (expression has type "Callable[[_IDComparable, object], bool]", variable has type "Callable[[object, object], bool]") [assignment]
- steam/_const.py:196: error: Cannot assign to a method [method-assign]
- steam/_const.py:196: error: Incompatible types in assignment (expression has type "Callable[[_IDComparable], int]", variable has type "Callable[[object], int]") [assignment]
- steam/types/user.py:16: error: Module "steam.user" has no attribute "User" [attr-defined]
- steam/types/user.py:139: error: Cannot resolve name "Author" (possible cyclic definition) [misc]
- steam/types/user.py:143: error: Parameter 1 of Literal[...] is invalid [valid-type]
- steam/invite.py:16: error: Module "steam.clan" has no attribute "Clan" [attr-defined]
- steam/invite.py:19: error: Module "steam.group" has no attribute "Group" [attr-defined]
- steam/invite.py:21: error: Module "steam.user" has no attribute "User" [attr-defined]
- steam/invite.py:90: error: Attributes without a default cannot follow attributes with one [misc]
- steam/invite.py:109: error: Attributes without a default cannot follow attributes with one [misc]
- steam/invite.py:118: error: Cannot resolve name "ChatGroupInvite" (possible cyclic definition) [misc]
- steam/invite.py:134: error: Call to abstract method "accept" of "_Invite" with trivial body via super() is unsafe [safe-super]
- steam/enums.py:98: error: Function is missing a return type annotation [no-untyped-def]
- steam/enums.py:98: note: Use "-> None" if function does not return a value
- steam/enums.py:106: error: Invalid base class [misc]
- steam/enums.py:108: error: Unused "type: ignore" comment [unused-ignore]
- steam/enums.py:111: error: Unused "type: ignore" comment [unused-ignore]
- steam/enums.py:124: error: Unused "type: ignore" comment [unused-ignore]
- steam/enums.py:181: error: Invalid base class [misc]
- steam/enums.py:198: error: Unused "type: ignore" comment [unused-ignore]
- steam/enums.py:249: error: Unused "type: ignore" comment [unused-ignore]
- steam/enums.py:637: error: Unused "type: ignore" comment [unused-ignore]
- steam/enums.py:640: error: Dict entry 0 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:641: error: Dict entry 1 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:642: error: Dict entry 2 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:643: error: Dict entry 3 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:644: error: Dict entry 4 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:645: error: Dict entry 5 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:646: error: Dict entry 6 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:647: error: Dict entry 7 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:648: error: Dict entry 8 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:649: error: Dict entry 9 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:650: error: Dict entry 10 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:651: error: Dict entry 11 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:652: error: Dict entry 12 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:653: error: Dict entry 13 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:654: error: Dict entry 14 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:655: error: Dict entry 15 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:656: error: Dict entry 16 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:657: error: Dict entry 17 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:658: error: Dict entry 18 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:659: error: Dict entry 19 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:660: error: Dict entry 20 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:661: error: Dict entry 21 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:662: error: Dict entry 22 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:663: error: Dict entry 23 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:664: error: Dict entry 24 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:665: error: Dict entry 25 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:666: error: Dict entry 26 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:667: error: Dict entry 27 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:668: error: Dict entry 28 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:672: error: Unused "type: ignore" comment [unused-ignore]
- steam/enums.py:675: error: Dict entry 0 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:676: error: Dict entry 1 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:677: error: Dict entry 2 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:678: error: Dict entry 3 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:679: error: Dict entry 4 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:680: error: Dict entry 5 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:681: error: Dict entry 6 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:682: error: Dict entry 7 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:683: error: Dict entry 8 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:684: error: Dict entry 9 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:685: error: Dict entry 10 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:686: error: Dict entry 11 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:687: error: Dict entry 12 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:688: error: Dict entry 13 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:689: error: Dict entry 14 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:690: error: Dict entry 15 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:691: error: Dict entry 16 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:692: error: Dict entry 17 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:693: error: Dict entry 18 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:694: error: Dict entry 19 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:695: error: Dict entry 20 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:696: error: Dict entry 21 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:697: error: Dict entry 22 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:698: error: Dict entry 23 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:699: error: Dict entry 24 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:700: error: Dict entry 25 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:701: error: Dict entry 26 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:702: error: Dict entry 27 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:703: error: Dict entry 28 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:707: error: Unused "type: ignore" comment [unused-ignore]
- steam/enums.py:710: error: Dict entry 0 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:711: error: Dict entry 1 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:712: error: Dict entry 2 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:713: error: Dict entry 3 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:714: error: Dict entry 4 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:715: error: Dict entry 5 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:716: error: Dict entry 6 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:717: error: Dict entry 7 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:718: error: Dict entry 8 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:719: error: Dict entry 9 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:720: error: Dict entry 10 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:721: error: Dict entry 11 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:722: error: Dict entry 12 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:723: error: Dict entry 13 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:724: error: Dict entry 14 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:725: error: Dict entry 15 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:726: error: Dict entry 16 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:727: error: Dict entry 17 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:728: error: Dict entry 18 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:729: error: Dict entry 19 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:730: error: Dict entry 20 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:731: error: Dict entry 21 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:732: error: Dict entry 22 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:733: error: Dict entry 23 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:734: error: Dict entry 24 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:735: error: Dict entry 25 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:736: error: Dict entry 26 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:737: error: Dict entry 27 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:738: error: Dict entry 28 has incompatible type "int": "str"; expected "Language": "str" [dict-item]
- steam/enums.py:2146: error: Incompatible return value type (got "int", expected "UserNewsType") [return-value]
- steam/enums.py:2159: error: Incompatible return value type (got "int", expected "UserNewsType") [return-value]
- steam/errors.py:93: error: Unused "type: ignore" comment [unused-ignore]
- steam/protobufs/headers.py:71: error: Function is missing a return type annotation [no-untyped-def]
- steam/protobufs/headers.py:71: note: Use "-> None" if function does not return a value
- steam/protobufs/headers.py:120: error: Need type argument for Final[...] with non-literal default in dataclass [misc]
- steam/protobufs/headers.py:124: error: Unused "type: ignore" comment [unused-ignore]
- steam/protobufs/headers.py:146: error: Function is missing a return type annotation [no-untyped-d
... (truncated 20493 lines) ... |
Collaborator
Author
|
I have the memory of a goldfish. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.