You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: conformance/results/mypy/generics_base_class.toml
+6-2Lines changed: 6 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -1,4 +1,7 @@
1
-
conformant = "Pass"
1
+
conformant = "Partial"
2
+
notes = """
3
+
Does not detect inconsistent type variable ordering.
4
+
"""
2
5
output = """
3
6
generics_base_class.py:26: error: Argument 1 to "takes_dict_incorrect" has incompatible type "SymbolTable"; expected "dict[str, list[object]]" [arg-type]
4
7
generics_base_class.py:29: error: Variable "typing.Generic" is not valid as a type [valid-type]
@@ -9,6 +12,7 @@ generics_base_class.py:49: error: "LinkedList" expects 1 type argument, but 2 gi
9
12
generics_base_class.py:61: error: "MyDict" expects 1 type argument, but 2 given [type-arg]
10
13
generics_base_class.py:68: error: Duplicate type variables in Generic[...] or Protocol[...] [misc]
Copy file name to clipboardExpand all lines: conformance/results/pyre/generics_base_class.toml
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -2,6 +2,7 @@ conformant = "Partial"
2
2
notes = """
3
3
Does not reject illegal use of Generic.
4
4
Does not allow using generic in assert_type expression.
5
+
Does not detect inconsistent type variable ordering.
5
6
"""
6
7
output = """
7
8
generics_base_class.py:26:25 Incompatible parameter type [6]: In call `takes_dict_incorrect`, for 1st positional argument, expected `Dict[str, List[object]]` but got `SymbolTable`.
Copy file name to clipboardExpand all lines: conformance/results/pyre/generics_basic.toml
+6-1Lines changed: 6 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -4,6 +4,7 @@ False positives in examples using constrained type variables.
4
4
False negative for constraint parameterized by a type variable.
5
5
False negative in custom map example.
6
6
False positive using `iter`.
7
+
False negative for bad type arguments to Generic/Protocol.
7
8
False negative for generic metaclass.
8
9
"""
9
10
output = """
@@ -16,10 +17,14 @@ generics_basic.py:69:14 Incompatible parameter type [6]: In call `concat`, for 2
16
17
generics_basic.py:121:0 Duplicate type variables [59]: Duplicate type variable `T` in Generic[...].
17
18
generics_basic.py:157:7 Incompatible parameter type [6]: In call `typing.Mapping.__getitem__`, for 1st positional argument, expected `str` but got `int`.
18
19
generics_basic.py:158:7 Incompatible parameter type [6]: In call `typing.Mapping.__getitem__`, for 1st positional argument, expected `str` but got `int`.
20
+
generics_basic.py:171:11 Invalid type variable [34]: The current class isn't generic with respect to the type variable `Variable[T_co]`. To reference the type variable, you can modify the class to inherit from `typing.Generic[T_co]`.
21
+
generics_basic.py:172:11 Invalid type variable [34]: The current class isn't generic with respect to the type variable `Variable[T_co]`. To reference the type variable, you can modify the class to inherit from `typing.Generic[T_co]`.
19
22
"""
20
23
conformance_automated = "Fail"
21
24
errors_diff = """
22
25
Line 55: Expected 1 errors
23
-
Line 191: Expected 1 errors
26
+
Line 162: Expected 1 errors
27
+
Line 163: Expected 1 errors
28
+
Line 208: Expected 1 errors
24
29
Line 34: Unexpected errors ['generics_basic.py:34:4 Incompatible return type [7]: Expected `Variable[AnyStr <: [str, bytes]]` but got `str`.', 'generics_basic.py:34:15 Incompatible parameter type [6]: In call `str.__add__`, for 1st positional argument, expected `str` but got `Variable[AnyStr <: [str, bytes]]`.']
Copy file name to clipboardExpand all lines: conformance/results/pyright/dataclasses_transform_converter.toml
+1-1Lines changed: 1 addition & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -40,5 +40,5 @@ dataclasses_transform_converter.py:130:67 - error: Argument of type "Literal[1]"
40
40
dataclasses_transform_converter.py:133:75 - error: Argument of type "type[int]" cannot be assigned to parameter "default_factory" of type "(() -> S@model_field) | None" in function "model_field"
41
41
Type "type[int]" is not assignable to type "(() -> str) | None"
42
42
No overloaded function matches type "() -> str"
43
-
"type[type]" is not assignable to "type[None]" (reportArgumentType)
43
+
Type is not assignable to "None" (reportArgumentType)
Copy file name to clipboardExpand all lines: conformance/results/pyright/generics_base_class.toml
+2Lines changed: 2 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -10,6 +10,8 @@ generics_base_class.py:30:8 - error: "Generic" is not valid in this context (rep
10
10
generics_base_class.py:49:38 - error: Too many type arguments provided for "LinkedList"; expected 1 but received 2 (reportInvalidTypeArguments)
11
11
generics_base_class.py:61:30 - error: Too many type arguments provided for "MyDict"; expected 1 but received 2 (reportInvalidTypeArguments)
12
12
generics_base_class.py:68:28 - error: Type arguments for "Generic" must be unique (reportInvalidTypeForm)
13
+
generics_base_class.py:98:7 - error: Base classes of BadChild are mutually incompatible
14
+
Base class "Grandparent[T2@BadChild, T1@BadChild]" derives from "Grandparent[T2@BadChild, T1@BadChild]" which is incompatible with type "Grandparent[T1@BadChild, T2@BadChild]" (reportGeneralTypeIssues)
Copy file name to clipboardExpand all lines: conformance/results/pyright/overloads_basic.toml
+2-2Lines changed: 2 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -1,8 +1,8 @@
1
1
conformant = "Pass"
2
2
output = """
3
3
overloads_basic.py:37:1 - error: No overloads for "__getitem__" match the provided arguments (reportCallIssue)
4
-
overloads_basic.py:37:1 - error: Argument of type "Literal['']" cannot be assigned to parameter "__s" of type "slice" in function "__getitem__"
5
-
"Literal['']" is not assignable to "slice" (reportArgumentType)
4
+
overloads_basic.py:37:1 - error: Argument of type "Literal['']" cannot be assigned to parameter "__s" of type "slice[Any, Any, Any]" in function "__getitem__"
5
+
"Literal['']" is not assignable to "slice[Any, Any, Any]" (reportArgumentType)
6
6
overloads_basic.py:63:5 - error: "func1" is marked as overload, but additional overloads are missing (reportInconsistentOverload)
7
7
overloads_basic.py:75:5 - error: "func2" is marked as overload, but no implementation is provided (reportNoOverloadImplementation)
0 commit comments