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

Updated conformance test results for mypy 1.11.0 and pyright 1.1.372 #1812

Merged
merged 1 commit into from
Jul 19, 2024
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
8 changes: 3 additions & 5 deletions conformance/results/mypy/aliases_explicit.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ aliases_explicit.py:67: error: Bad number of arguments for type alias, expected
aliases_explicit.py:68: error: Bad number of arguments for type alias, expected 0, given 1 [type-arg]
aliases_explicit.py:69: error: Bad number of arguments for type alias, expected 1, given 2 [type-arg]
aliases_explicit.py:70: error: Bad number of arguments for type alias, expected 1, given 2 [type-arg]
aliases_explicit.py:71: error: Can only replace ParamSpec with a parameter types list or another ParamSpec, got "int" [misc]
aliases_explicit.py:71: error: Can only replace ParamSpec with a parameter types list or another ParamSpec, got "int" [valid-type]
aliases_explicit.py:79: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_explicit.py:80: error: Bracketed expression "[...]" is not valid as a type [valid-type]
aliases_explicit.py:81: error: Invalid type alias: expression is not a valid type [valid-type]
Expand All @@ -23,13 +23,11 @@ aliases_explicit.py:89: error: Invalid type: try using Literal[1] instead? [val
aliases_explicit.py:90: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_explicit.py:90: error: Function "list" could always be true in boolean context [truthy-function]
aliases_explicit.py:91: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_explicit.py:101: error: "<typing special form>" not callable [operator]
aliases_explicit.py:101: error: "UnionType[list[Any], set[Any]]" not callable [operator]
aliases_explicit.py:102: error: Bad number of arguments for type alias, expected 0, given 1 [type-arg]
"""
conformance_automated = "Fail"
errors_diff = """
Line 100: Expected 1 errors
"""
ignore_errors = [
'Function "list" could always be true in boolean context',
]
ignore_errors = ["Function \"list\" could always be true in boolean context"]
4 changes: 2 additions & 2 deletions conformance/results/mypy/aliases_implicit.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ aliases_implicit.py:76: error: Bad number of arguments for type alias, expected
aliases_implicit.py:77: error: Bad number of arguments for type alias, expected 0, given 1 [type-arg]
aliases_implicit.py:78: error: Bad number of arguments for type alias, expected 1, given 2 [type-arg]
aliases_implicit.py:79: error: Bad number of arguments for type alias, expected 1, given 2 [type-arg]
aliases_implicit.py:80: error: Can only replace ParamSpec with a parameter types list or another ParamSpec, got "int" [misc]
aliases_implicit.py:80: error: Can only replace ParamSpec with a parameter types list or another ParamSpec, got "int" [valid-type]
aliases_implicit.py:81: error: Type argument "str" of "GoodTypeAlias12" must be a subtype of "float" [type-var]
aliases_implicit.py:100: error: Function "list" could always be true in boolean context [truthy-function]
aliases_implicit.py:106: error: Variable "aliases_implicit.BadTypeAlias1" is not valid as a type [valid-type]
Expand Down Expand Up @@ -35,7 +35,7 @@ aliases_implicit.py:118: error: Variable "aliases_implicit.BadTypeAlias13" is no
aliases_implicit.py:118: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_implicit.py:119: error: Variable "aliases_implicit.BadTypeAlias14" is not valid as a type [valid-type]
aliases_implicit.py:119: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_implicit.py:133: error: "<typing special form>" not callable [operator]
aliases_implicit.py:133: error: "UnionType[list[Any], set[Any]]" not callable [operator]
aliases_implicit.py:135: error: Bad number of arguments for type alias, expected 0, given 1 [type-arg]
"""
conformance_automated = "Pass"
Expand Down
125 changes: 37 additions & 88 deletions conformance/results/mypy/aliases_type_statement.toml
Original file line number Diff line number Diff line change
@@ -1,97 +1,46 @@
conformant = "Unsupported"
conformant = "Partial"
notes = """
Does not support `type` statement.
Does not reject use of TypeAliasType as base class.
Does not reject redefinition of type alias defined with type statement.
Does not reject type alias defined in function scope.
Does not reject type alias with circular definition.
"""
output = """
aliases_type_statement.py: error: Cannot assign multiple types to name "BadTypeAlias14" without an explicit "Type[...]" annotation [misc]
aliases_type_statement.py:8: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:9: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:9: error: Name "S3" is not defined [name-defined]
aliases_type_statement.py:9: error: Name "S1" is not defined [name-defined]
aliases_type_statement.py:9: error: Name "S2" is not defined [name-defined]
aliases_type_statement.py:10: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:10: error: Value of type "UnionType" is not indexable [index]
aliases_type_statement.py:14: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:21: error: "type[int]" has no attribute "__value__" [attr-defined]
aliases_type_statement.py:23: error: "type[int]" has no attribute "other_attrib" [attr-defined]
aliases_type_statement.py:37: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:38: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:39: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:40: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:41: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:42: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:43: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:44: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:45: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:46: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:47: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:48: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:48: error: Function "list" could always be true in boolean context [truthy-function]
aliases_type_statement.py:49: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:52: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:54: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:58: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:64: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:64: error: Name "K" is not defined [name-defined]
aliases_type_statement.py:69: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:72: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:72: error: Name "T" is not defined [name-defined]
aliases_type_statement.py:72: error: Variable "aliases_type_statement.RecursiveTypeAlias1" is not valid as a type [valid-type]
aliases_type_statement.py:72: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_type_statement.py:74: error: Variable "aliases_type_statement.RecursiveTypeAlias1" is not valid as a type [valid-type]
aliases_type_statement.py:74: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_type_statement.py:75: error: Variable "aliases_type_statement.RecursiveTypeAlias1" is not valid as a type [valid-type]
aliases_type_statement.py:75: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_type_statement.py:77: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:77: error: Name "P" is not defined [name-defined]
aliases_type_statement.py:77: error: Name "T" is not defined [name-defined]
aliases_type_statement.py:77: error: Name "S" is not defined [name-defined]
aliases_type_statement.py:77: error: Variable "aliases_type_statement.RecursiveTypeAlias2" is not valid as a type [valid-type]
aliases_type_statement.py:77: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_type_statement.py:79: error: Unexpected "..." [misc]
aliases_type_statement.py:79: error: Variable "aliases_type_statement.RecursiveTypeAlias2" is not valid as a type [valid-type]
aliases_type_statement.py:79: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_type_statement.py:80: error: Unexpected "..." [misc]
aliases_type_statement.py:80: error: Variable "aliases_type_statement.RecursiveTypeAlias2" is not valid as a type [valid-type]
aliases_type_statement.py:80: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_type_statement.py:81: error: Unexpected "..." [misc]
aliases_type_statement.py:81: error: Variable "aliases_type_statement.RecursiveTypeAlias2" is not valid as a type [valid-type]
aliases_type_statement.py:81: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_type_statement.py:82: error: Bracketed expression "[...]" is not valid as a type [valid-type]
aliases_type_statement.py:82: error: Variable "aliases_type_statement.RecursiveTypeAlias2" is not valid as a type [valid-type]
aliases_type_statement.py:82: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_type_statement.py:84: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:84: error: Name "RecursiveTypeAlias3" is not defined [name-defined]
aliases_type_statement.py:86: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:86: error: Name "T" is not defined [name-defined]
aliases_type_statement.py:86: error: Cannot determine type of "RecursiveTypeAlias4" [has-type]
aliases_type_statement.py:88: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:88: error: Name "T" is not defined [name-defined]
aliases_type_statement.py:88: error: Variable "aliases_type_statement.RecursiveTypeAlias5" is not valid as a type [valid-type]
aliases_type_statement.py:88: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_type_statement.py:90: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:17: error: "TypeAliasType" has no attribute "bit_count" [attr-defined]
aliases_type_statement.py:19: error: "TypeAliasType" not callable [operator]
aliases_type_statement.py:23: error: "TypeAliasType" has no attribute "other_attrib" [attr-defined]
aliases_type_statement.py:31: error: Parameterized generics cannot be used with class or instance checks [misc]
aliases_type_statement.py:31: error: Argument 2 to "isinstance" has incompatible type "TypeAliasType"; expected "_ClassInfo" [arg-type]
aliases_type_statement.py:37: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_type_statement.py:38: error: Bracketed expression "[...]" is not valid as a type [valid-type]
aliases_type_statement.py:39: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_type_statement.py:40: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_type_statement.py:41: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_type_statement.py:42: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_type_statement.py:43: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_type_statement.py:44: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_type_statement.py:45: error: Variable "aliases_type_statement.var1" is not valid as a type [valid-type]
aliases_type_statement.py:45: note: See https://mypy.readthedocs.io/en/stable/common_issues.html#variables-vs-type-aliases
aliases_type_statement.py:46: error: Invalid type: try using Literal[True] instead? [valid-type]
aliases_type_statement.py:47: error: Invalid type: try using Literal[1] instead? [valid-type]
aliases_type_statement.py:48: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_type_statement.py:49: error: Invalid type alias: expression is not a valid type [valid-type]
aliases_type_statement.py:54: error: Name "BadTypeAlias14" already defined on line 52 [no-redef]
aliases_type_statement.py:64: error: All type parameters should be declared ("V" not declared) [valid-type]
aliases_type_statement.py:69: error: All type parameters should be declared ("T1" not declared) [valid-type]
aliases_type_statement.py:79: error: Type argument "str" of "RecursiveTypeAlias2" must be a subtype of "int" [type-var]
aliases_type_statement.py:81: error: Type argument "int" of "RecursiveTypeAlias2" must be a subtype of "str" [type-var]
aliases_type_statement.py:84: error: Cannot resolve name "RecursiveTypeAlias3" (possible cyclic definition) [misc]
aliases_type_statement.py:86: error: Invalid recursive alias: a union item of itself [misc]
aliases_type_statement.py:90: error: Cannot resolve name "RecursiveTypeAlias6" (possible cyclic definition) [misc]
aliases_type_statement.py:90: error: Cannot resolve name "RecursiveTypeAlias7" (possible cyclic definition) [misc]
aliases_type_statement.py:90: error: Name "RecursiveTypeAlias7" is used before definition [used-before-def]
aliases_type_statement.py:91: error: PEP 695 type aliases are not yet supported [valid-type]
aliases_type_statement.py:91: error: Cannot resolve name "RecursiveTypeAlias7" (possible cyclic definition) [misc]
"""
conformance_automated = "Fail"
errors_diff = """
Line 17: Expected 1 errors
Line 19: Expected 1 errors
Line 26: Expected 1 errors
Line 31: Expected 1 errors
Line 8: Unexpected errors ['aliases_type_statement.py:8: error: PEP 695 type aliases are not yet supported [valid-type]']
Line 9: Unexpected errors ['aliases_type_statement.py:9: error: PEP 695 type aliases are not yet supported [valid-type]', 'aliases_type_statement.py:9: error: Name "S3" is not defined [name-defined]', 'aliases_type_statement.py:9: error: Name "S1" is not defined [name-defined]', 'aliases_type_statement.py:9: error: Name "S2" is not defined [name-defined]']
Line 10: Unexpected errors ['aliases_type_statement.py:10: error: PEP 695 type aliases are not yet supported [valid-type]', 'aliases_type_statement.py:10: error: Value of type "UnionType" is not indexable [index]']
Line 14: Unexpected errors ['aliases_type_statement.py:14: error: PEP 695 type aliases are not yet supported [valid-type]']
Line 21: Unexpected errors ['aliases_type_statement.py:21: error: "type[int]" has no attribute "__value__" [attr-defined]']
Line 54: Unexpected errors ['aliases_type_statement.py:54: error: PEP 695 type aliases are not yet supported [valid-type]']
Line 72: Unexpected errors ['aliases_type_statement.py:72: error: PEP 695 type aliases are not yet supported [valid-type]', 'aliases_type_statement.py:72: error: Name "T" is not defined [name-defined]', 'aliases_type_statement.py:72: error: Variable "aliases_type_statement.RecursiveTypeAlias1" is not valid as a type [valid-type]']
Line 74: Unexpected errors ['aliases_type_statement.py:74: error: Variable "aliases_type_statement.RecursiveTypeAlias1" is not valid as a type [valid-type]']
Line 75: Unexpected errors ['aliases_type_statement.py:75: error: Variable "aliases_type_statement.RecursiveTypeAlias1" is not valid as a type [valid-type]']
Line 77: Unexpected errors ['aliases_type_statement.py:77: error: PEP 695 type aliases are not yet supported [valid-type]', 'aliases_type_statement.py:77: error: Name "P" is not defined [name-defined]', 'aliases_type_statement.py:77: error: Name "T" is not defined [name-defined]', 'aliases_type_statement.py:77: error: Name "S" is not defined [name-defined]', 'aliases_type_statement.py:77: error: Variable "aliases_type_statement.RecursiveTypeAlias2" is not valid as a type [valid-type]']
Line 80: Unexpected errors ['aliases_type_statement.py:80: error: Unexpected "..." [misc]', 'aliases_type_statement.py:80: error: Variable "aliases_type_statement.RecursiveTypeAlias2" is not valid as a type [valid-type]']
Line 82: Unexpected errors ['aliases_type_statement.py:82: error: Bracketed expression "[...]" is not valid as a type [valid-type]', 'aliases_type_statement.py:82: error: Variable "aliases_type_statement.RecursiveTypeAlias2" is not valid as a type [valid-type]']
Line 88: Unexpected errors ['aliases_type_statement.py:88: error: PEP 695 type aliases are not yet supported [valid-type]', 'aliases_type_statement.py:88: error: Name "T" is not defined [name-defined]', 'aliases_type_statement.py:88: error: Variable "aliases_type_statement.RecursiveTypeAlias5" is not valid as a type [valid-type]']
Line 91: Unexpected errors ['aliases_type_statement.py:91: error: PEP 695 type aliases are not yet supported [valid-type]']
Line 52: Expected 1 errors
Line 58: Expected 1 errors
Line 54: Unexpected errors ['aliases_type_statement.py:54: error: Name "BadTypeAlias14" already defined on line 52 [no-redef]']
Line 91: Unexpected errors ['aliases_type_statement.py:91: error: Cannot resolve name "RecursiveTypeAlias7" (possible cyclic definition) [misc]']
"""
5 changes: 1 addition & 4 deletions conformance/results/mypy/aliases_typealiastype.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,13 @@ conformant = "Partial"
notes = """
Incorrectly rejects some recursive type aliases using TypeAliasType.
Incorrectly rejects the use of a class-scoped TypeVar in a TypeAliasType definition.
Generates error when accessing `__value__` attribute of TypeAliasType.
"""
output = """
aliases_typealiastype.py:19: error: Cannot resolve name "GoodAlias4" (possible cyclic definition) [misc]
aliases_typealiastype.py:20: error: Cannot resolve name "GoodAlias5" (possible cyclic definition) [misc]
aliases_typealiastype.py:22: error: Cannot resolve name "GoodAlias5" (possible cyclic definition) [misc]
aliases_typealiastype.py:27: error: Type variable "T" is not included in type_params [valid-type]
aliases_typealiastype.py:30: error: "type[int]" has no attribute "__value__" [attr-defined]
aliases_typealiastype.py:32: error: "type[int]" has no attribute "other_attrib" [attr-defined]
aliases_typealiastype.py:32: error: "TypeAliasType" has no attribute "other_attrib" [attr-defined]
aliases_typealiastype.py:40: error: Type argument "int" of "GoodAlias5" must be a subtype of "str" [type-var]
aliases_typealiastype.py:43: error: Type variable "S" is not included in type_params [valid-type]
aliases_typealiastype.py:44: error: Type variable "S" is not included in type_params [valid-type]
Expand Down Expand Up @@ -43,5 +41,4 @@ Line 19: Unexpected errors ['aliases_typealiastype.py:19: error: Cannot resolve
Line 20: Unexpected errors ['aliases_typealiastype.py:20: error: Cannot resolve name "GoodAlias5" (possible cyclic definition) [misc]']
Line 22: Unexpected errors ['aliases_typealiastype.py:22: error: Cannot resolve name "GoodAlias5" (possible cyclic definition) [misc]']
Line 27: Unexpected errors ['aliases_typealiastype.py:27: error: Type variable "T" is not included in type_params [valid-type]']
Line 30: Unexpected errors ['aliases_typealiastype.py:30: error: "type[int]" has no attribute "__value__" [attr-defined]']
"""
Loading