Skip to content

Commit

Permalink
Updated conformance test results for mypy 1.15 and pyright 1.1.393. (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
erictraut authored Feb 5, 2025
1 parent b76a853 commit b97d71b
Show file tree
Hide file tree
Showing 18 changed files with 76 additions and 85 deletions.
40 changes: 20 additions & 20 deletions conformance/results/mypy/generics_defaults.toml
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
conformant = "Partial"
output = """
generics_defaults.py:24: error: "T" cannot appear after "DefaultStrT" in type parameter list because it has no default type [misc]
generics_defaults.py:30: error: Expression is of type "type[NoNonDefaults[Any, Any]]", not "type[NoNonDefaults[str, int]]" [assert-type]
generics_defaults.py:31: error: Expression is of type "type[NoNonDefaults[Any, Any]]", not "type[NoNonDefaults[str, int]]" [assert-type]
generics_defaults.py:38: error: Expression is of type "type[OneDefault[Any, Any]]", not "type[OneDefault[float, bool]]" [assert-type]
generics_defaults.py:45: error: Expression is of type "type[AllTheDefaults[Any, Any, Any, Any, Any]]", not "type[AllTheDefaults[Any, Any, str, int, bool]]" [assert-type]
generics_defaults.py:46: error: Expression is of type "type[AllTheDefaults[Any, Any, Any, Any, Any]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]
generics_defaults.py:30: error: Expression is of type "type[NoNonDefaults[DefaultStrT, DefaultIntT]]", not "type[NoNonDefaults[str, int]]" [assert-type]
generics_defaults.py:31: error: Expression is of type "type[NoNonDefaults[str, DefaultIntT]]", not "type[NoNonDefaults[str, int]]" [assert-type]
generics_defaults.py:38: error: Expression is of type "type[OneDefault[float, DefaultBoolT]]", not "type[OneDefault[float, bool]]" [assert-type]
generics_defaults.py:45: error: Expression is of type "type[AllTheDefaults[T1, T2, DefaultStrT, DefaultIntT, DefaultBoolT]]", not "type[AllTheDefaults[Any, Any, str, int, bool]]" [assert-type]
generics_defaults.py:46: error: Expression is of type "type[AllTheDefaults[int, complex, DefaultStrT, DefaultIntT, DefaultBoolT]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]
generics_defaults.py:50: error: Type application has too few types (expected between 2 and 5) [misc]
generics_defaults.py:52: error: Expression is of type "type[AllTheDefaults[Any, Any, Any, Any, Any]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]
generics_defaults.py:55: error: Expression is of type "type[AllTheDefaults[Any, Any, Any, Any, Any]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]
generics_defaults.py:59: error: Expression is of type "type[AllTheDefaults[Any, Any, Any, Any, Any]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]
generics_defaults.py:79: error: Expression is of type "type[Class_ParamSpec[Any]]", not "type[Class_ParamSpec[[str, int]]]" [assert-type]
generics_defaults.py:94: error: Expression is of type "type[Class_TypeVarTuple[*tuple[Any, ...]]]", not "type[Class_TypeVarTuple[str, int]]" [assert-type]
generics_defaults.py:52: error: Expression is of type "type[AllTheDefaults[int, complex, DefaultStrT, DefaultIntT, DefaultBoolT]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]
generics_defaults.py:55: error: Expression is of type "type[AllTheDefaults[int, complex, str, DefaultIntT, DefaultBoolT]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]
generics_defaults.py:59: error: Expression is of type "type[AllTheDefaults[int, complex, str, int, DefaultBoolT]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]
generics_defaults.py:79: error: Expression is of type "type[Class_ParamSpec[DefaultP]]", not "type[Class_ParamSpec[[str, int]]]" [assert-type]
generics_defaults.py:94: error: Expression is of type "type[Class_TypeVarTuple[*DefaultTs]]", not "type[Class_TypeVarTuple[str, int]]" [assert-type]
generics_defaults.py:151: error: Expression is of type "type[Foo6[*tuple[Any, ...], Any]]", not "type[Foo6[int, str, [float, bool]]]" [assert-type]
generics_defaults.py:151: error: Can only replace ParamSpec with a parameter types list or another ParamSpec, got "str" [misc]
generics_defaults.py:152: error: Expression is of type "type[Foo6[*tuple[Any, ...], Any]]", not "type[Foo6[int, str, [bytes]]]" [assert-type]
Expand All @@ -25,16 +25,16 @@ errors_diff = """
Line 104: Expected 1 errors
Line 111: Expected 1 errors
Line 138: Expected 1 errors
Line 30: Unexpected errors ['generics_defaults.py:30: error: Expression is of type "type[NoNonDefaults[Any, Any]]", not "type[NoNonDefaults[str, int]]" [assert-type]']
Line 31: Unexpected errors ['generics_defaults.py:31: error: Expression is of type "type[NoNonDefaults[Any, Any]]", not "type[NoNonDefaults[str, int]]" [assert-type]']
Line 38: Unexpected errors ['generics_defaults.py:38: error: Expression is of type "type[OneDefault[Any, Any]]", not "type[OneDefault[float, bool]]" [assert-type]']
Line 45: Unexpected errors ['generics_defaults.py:45: error: Expression is of type "type[AllTheDefaults[Any, Any, Any, Any, Any]]", not "type[AllTheDefaults[Any, Any, str, int, bool]]" [assert-type]']
Line 46: Unexpected errors ['generics_defaults.py:46: error: Expression is of type "type[AllTheDefaults[Any, Any, Any, Any, Any]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]']
Line 52: Unexpected errors ['generics_defaults.py:52: error: Expression is of type "type[AllTheDefaults[Any, Any, Any, Any, Any]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]']
Line 55: Unexpected errors ['generics_defaults.py:55: error: Expression is of type "type[AllTheDefaults[Any, Any, Any, Any, Any]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]']
Line 59: Unexpected errors ['generics_defaults.py:59: error: Expression is of type "type[AllTheDefaults[Any, Any, Any, Any, Any]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]']
Line 79: Unexpected errors ['generics_defaults.py:79: error: Expression is of type "type[Class_ParamSpec[Any]]", not "type[Class_ParamSpec[[str, int]]]" [assert-type]']
Line 94: Unexpected errors ['generics_defaults.py:94: error: Expression is of type "type[Class_TypeVarTuple[*tuple[Any, ...]]]", not "type[Class_TypeVarTuple[str, int]]" [assert-type]']
Line 30: Unexpected errors ['generics_defaults.py:30: error: Expression is of type "type[NoNonDefaults[DefaultStrT, DefaultIntT]]", not "type[NoNonDefaults[str, int]]" [assert-type]']
Line 31: Unexpected errors ['generics_defaults.py:31: error: Expression is of type "type[NoNonDefaults[str, DefaultIntT]]", not "type[NoNonDefaults[str, int]]" [assert-type]']
Line 38: Unexpected errors ['generics_defaults.py:38: error: Expression is of type "type[OneDefault[float, DefaultBoolT]]", not "type[OneDefault[float, bool]]" [assert-type]']
Line 45: Unexpected errors ['generics_defaults.py:45: error: Expression is of type "type[AllTheDefaults[T1, T2, DefaultStrT, DefaultIntT, DefaultBoolT]]", not "type[AllTheDefaults[Any, Any, str, int, bool]]" [assert-type]']
Line 46: Unexpected errors ['generics_defaults.py:46: error: Expression is of type "type[AllTheDefaults[int, complex, DefaultStrT, DefaultIntT, DefaultBoolT]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]']
Line 52: Unexpected errors ['generics_defaults.py:52: error: Expression is of type "type[AllTheDefaults[int, complex, DefaultStrT, DefaultIntT, DefaultBoolT]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]']
Line 55: Unexpected errors ['generics_defaults.py:55: error: Expression is of type "type[AllTheDefaults[int, complex, str, DefaultIntT, DefaultBoolT]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]']
Line 59: Unexpected errors ['generics_defaults.py:59: error: Expression is of type "type[AllTheDefaults[int, complex, str, int, DefaultBoolT]]", not "type[AllTheDefaults[int, complex, str, int, bool]]" [assert-type]']
Line 79: Unexpected errors ['generics_defaults.py:79: error: Expression is of type "type[Class_ParamSpec[DefaultP]]", not "type[Class_ParamSpec[[str, int]]]" [assert-type]']
Line 94: Unexpected errors ['generics_defaults.py:94: error: Expression is of type "type[Class_TypeVarTuple[*DefaultTs]]", not "type[Class_TypeVarTuple[str, int]]" [assert-type]']
Line 151: Unexpected errors ['generics_defaults.py:151: error: Expression is of type "type[Foo6[*tuple[Any, ...], Any]]", not "type[Foo6[int, str, [float, bool]]]" [assert-type]', 'generics_defaults.py:151: error: Can only replace ParamSpec with a parameter types list or another ParamSpec, got "str" [misc]']
Line 152: Unexpected errors ['generics_defaults.py:152: error: Expression is of type "type[Foo6[*tuple[Any, ...], Any]]", not "type[Foo6[int, str, [bytes]]]" [assert-type]', 'generics_defaults.py:152: error: Can only replace ParamSpec with a parameter types list or another ParamSpec, got "str" [misc]']
Line 166: Unexpected errors ['generics_defaults.py:166: error: Expression is of type "Callable[[Self], Self]", not "Callable[[Foo7[int]], Foo7[int]]" [assert-type]']
Expand Down
12 changes: 6 additions & 6 deletions conformance/results/mypy/generics_defaults_referential.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
conformant = "Partial"
output = """
generics_defaults_referential.py:23: error: Expression is of type "type[slice[Any, Any, Any]]", not "type[slice[int, int, int | None]]" [assert-type]
generics_defaults_referential.py:23: error: Expression is of type "type[slice[StartT, StopT, StepT]]", not "type[slice[int, int, int | None]]" [assert-type]
generics_defaults_referential.py:37: error: Argument 1 to "Foo" has incompatible type "str"; expected "int" [arg-type]
generics_defaults_referential.py:53: error: Type parameter "Start2T" has a default type that refers to one or more type variables that are out of scope [misc]
generics_defaults_referential.py:94: error: Expression is of type "type[Bar[Any, Any]]", not "type[Bar[Any, list[Any]]]" [assert-type]
generics_defaults_referential.py:95: error: Expression is of type "type[Bar[Any, Any]]", not "type[Bar[int, list[int]]]" [assert-type]
generics_defaults_referential.py:94: error: Expression is of type "type[Bar[Z1, ListDefaultT]]", not "type[Bar[Any, list[Any]]]" [assert-type]
generics_defaults_referential.py:95: error: Expression is of type "type[Bar[int, ListDefaultT]]", not "type[Bar[int, list[int]]]" [assert-type]
generics_defaults_referential.py:96: error: Expression is of type "Bar[int, list[Never]]", not "Bar[int, list[int]]" [assert-type]
"""
conformance_automated = "Fail"
Expand All @@ -14,8 +14,8 @@ Line 60: Expected 1 errors
Line 68: Expected 1 errors
Line 74: Expected 1 errors
Line 78: Expected 1 errors
Line 23: Unexpected errors ['generics_defaults_referential.py:23: error: Expression is of type "type[slice[Any, Any, Any]]", not "type[slice[int, int, int | None]]" [assert-type]']
Line 94: Unexpected errors ['generics_defaults_referential.py:94: error: Expression is of type "type[Bar[Any, Any]]", not "type[Bar[Any, list[Any]]]" [assert-type]']
Line 95: Unexpected errors ['generics_defaults_referential.py:95: error: Expression is of type "type[Bar[Any, Any]]", not "type[Bar[int, list[int]]]" [assert-type]']
Line 23: Unexpected errors ['generics_defaults_referential.py:23: error: Expression is of type "type[slice[StartT, StopT, StepT]]", not "type[slice[int, int, int | None]]" [assert-type]']
Line 94: Unexpected errors ['generics_defaults_referential.py:94: error: Expression is of type "type[Bar[Z1, ListDefaultT]]", not "type[Bar[Any, list[Any]]]" [assert-type]']
Line 95: Unexpected errors ['generics_defaults_referential.py:95: error: Expression is of type "type[Bar[int, ListDefaultT]]", not "type[Bar[int, list[int]]]" [assert-type]']
Line 96: Unexpected errors ['generics_defaults_referential.py:96: error: Expression is of type "Bar[int, list[Never]]", not "Bar[int, list[int]]" [assert-type]']
"""
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
conformant = "Partial"
output = """
generics_defaults_specialization.py:30: error: Bad number of arguments for type alias, expected between 0 and 1, given 2 [type-arg]
generics_defaults_specialization.py:45: error: Expression is of type "type[Bar[Any]]", not "type[Bar[str]]" [assert-type]
generics_defaults_specialization.py:45: error: Expression is of type "type[Bar[DefaultStrT]]", not "type[Bar[str]]" [assert-type]
generics_defaults_specialization.py:55: error: The type "type[Foo]" is not generic and not indexable [misc]
"""
conformance_automated = "Fail"
errors_diff = """
Line 45: Unexpected errors ['generics_defaults_specialization.py:45: error: Expression is of type "type[Bar[Any]]", not "type[Bar[str]]" [assert-type]']
Line 45: Unexpected errors ['generics_defaults_specialization.py:45: error: Expression is of type "type[Bar[DefaultStrT]]", not "type[Bar[str]]" [assert-type]']
"""
26 changes: 10 additions & 16 deletions conformance/results/mypy/generics_paramspec_components.toml
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
conformant = "Partial"
notes = """
Does not report illegal use of "P.args" on normal parameter.
Does not report error when P.args is specified but P.kwargs is missing.
Does not report error when P is out of scope and P.args and P.kwargs is used.
Does not report error when keyword argument is specified between P.args and P.kwargs.
"""
conformant = "Pass"
output = """
generics_paramspec_components.py:17: error: Use "P.args" for variadic "*" parameter [valid-type]
generics_paramspec_components.py:17: error: Use "P.kwargs" for variadic "**" parameter [valid-type]
generics_paramspec_components.py:20: error: ParamSpec components are not allowed here [valid-type]
generics_paramspec_components.py:23: error: Use "P.kwargs" for variadic "**" parameter [valid-type]
generics_paramspec_components.py:26: error: ParamSpec must have "*args" typed as "P.args" and "**kwargs" typed as "P.kwargs" [valid-type]
generics_paramspec_components.py:30: error: ParamSpec "P" is unbound [valid-type]
generics_paramspec_components.py:35: error: ParamSpec components are not allowed here [valid-type]
generics_paramspec_components.py:36: error: ParamSpec components are not allowed here [valid-type]
generics_paramspec_components.py:38: error: ParamSpec must have "*args" typed as "P.args" and "**kwargs" typed as "P.kwargs" [valid-type]
generics_paramspec_components.py:41: error: ParamSpec must have "*args" typed as "P.args" and "**kwargs" typed as "P.kwargs" [valid-type]
generics_paramspec_components.py:49: error: Argument 1 has incompatible type "*P.kwargs"; expected "P.args" [arg-type]
generics_paramspec_components.py:49: error: Argument 2 has incompatible type "**P.args"; expected "P.kwargs" [arg-type]
generics_paramspec_components.py:51: error: Argument 1 has incompatible type "int"; expected "P.args" [arg-type]
generics_paramspec_components.py:60: error: Arguments not allowed after ParamSpec.args [valid-type]
generics_paramspec_components.py:70: error: Argument 1 has incompatible type "*P.args"; expected "int" [arg-type]
generics_paramspec_components.py:70: error: Argument 2 has incompatible type "int"; expected "P.args" [arg-type]
generics_paramspec_components.py:72: error: Argument 1 has incompatible type "*P.args"; expected "int" [arg-type]
Expand All @@ -21,14 +23,6 @@ generics_paramspec_components.py:83: error: Argument 3 to "foo" has incompatible
generics_paramspec_components.py:98: error: Argument 2 to "twice" has incompatible type "str"; expected "int" [arg-type]
generics_paramspec_components.py:98: error: Argument 3 to "twice" has incompatible type "int"; expected "str" [arg-type]
"""
conformance_automated = "Fail"
conformance_automated = "Pass"
errors_diff = """
Line 20: Expected 1 errors
Line 26: Expected 1 errors
Line 30: Expected 1 errors
Line 35: Expected 1 errors
Line 36: Expected 1 errors
Line 38: Expected 1 errors
Line 41: Expected 1 errors
Line 60: Expected 1 errors
"""
4 changes: 2 additions & 2 deletions conformance/results/mypy/version.toml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
version = "mypy 1.14.0"
test_duration = 1.6
version = "mypy 1.15.0"
test_duration = 2.0
2 changes: 1 addition & 1 deletion conformance/results/pyre/version.toml
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
version = "pyre 0.9.23"
test_duration = 7.3
test_duration = 6.5
10 changes: 5 additions & 5 deletions conformance/results/pyright/aliases_explicit.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,25 +10,25 @@ aliases_explicit.py:79:21 - error: Invalid expression form for type alias defini
aliases_explicit.py:79:21 - error: Call expression not allowed in type expression (reportInvalidTypeForm)
aliases_explicit.py:80:21 - error: Invalid expression form for type alias definition (reportInvalidTypeForm)
aliases_explicit.py:80:21 - error: List expression not allowed in type expression
  Use List[T] to indicate a list type or Union[T1, T2] to indicate a union type (reportInvalidTypeForm)
  Use list[T] to indicate a list type or T1 | T2 to indicate a union type (reportInvalidTypeForm)
aliases_explicit.py:80:21 - error: Expected class but received "list[Unknown]" (reportGeneralTypeIssues)
aliases_explicit.py:81:21 - error: Invalid expression form for type alias definition (reportInvalidTypeForm)
aliases_explicit.py:81:21 - error: Tuple expression not allowed in type expression
  Use tuple[T1, ..., Tn] to indicate a tuple type or Union[T1, T2] to indicate a union type (reportInvalidTypeForm)
  Use tuple[T1, ..., Tn] to indicate a tuple type or T1 | T2 to indicate a union type (reportInvalidTypeForm)
aliases_explicit.py:82:21 - error: Invalid expression form for type alias definition (reportInvalidTypeForm)
aliases_explicit.py:82:21 - error: List expression not allowed in type expression
  Use List[T] to indicate a list type or Union[T1, T2] to indicate a union type (reportInvalidTypeForm)
  Use list[T] to indicate a list type or T1 | T2 to indicate a union type (reportInvalidTypeForm)
aliases_explicit.py:82:21 - error: Expected class but received "list[type[int]]" (reportGeneralTypeIssues)
aliases_explicit.py:83:21 - error: Invalid expression form for type alias definition (reportInvalidTypeForm)
aliases_explicit.py:83:21 - error: Dictionary expression not allowed in type expression
  Use Dict[T1, T2] to indicate a dictionary type (reportInvalidTypeForm)
  Use dict[T1, T2] to indicate a dictionary type (reportInvalidTypeForm)
aliases_explicit.py:83:21 - error: Expected class but received "dict[str, Unknown]" (reportGeneralTypeIssues)
aliases_explicit.py:83:28 - error: "b" is not defined (reportUndefinedVariable)
aliases_explicit.py:84:21 - error: Invalid expression form for type alias definition (reportInvalidTypeForm)
aliases_explicit.py:84:21 - error: Call expression not allowed in type expression (reportInvalidTypeForm)
aliases_explicit.py:85:21 - error: Invalid expression form for type alias definition (reportInvalidTypeForm)
aliases_explicit.py:85:21 - error: List expression not allowed in type expression
  Use List[T] to indicate a list type or Union[T1, T2] to indicate a union type (reportInvalidTypeForm)
  Use list[T] to indicate a list type or T1 | T2 to indicate a union type (reportInvalidTypeForm)
aliases_explicit.py:85:21 - error: Expected class but received "list[type[int]]" (reportGeneralTypeIssues)
aliases_explicit.py:85:27 - error: Expected class but received "Literal[0]" (reportGeneralTypeIssues)
aliases_explicit.py:86:21 - error: Invalid expression form for type alias definition (reportInvalidTypeForm)
Expand Down
Loading

0 comments on commit b97d71b

Please sign in to comment.