From 6709b4658c887c83685e5482ed27f8613d044455 Mon Sep 17 00:00:00 2001 From: Jelle Zijlstra Date: Thu, 27 Aug 2026 11:19:32 -0700 Subject: [PATCH] Update pycroscope to 0.5.0 and refresh conformance results --- .../results/pycroscope/aliases_implicit.toml | 4 - .../pycroscope/aliases_type_statement.toml | 3 + .../pycroscope/aliases_typealiastype.toml | 8 +- .../pycroscope/callables_annotation.toml | 13 +- .../pycroscope/callables_protocol.toml | 9 +- .../pycroscope/callables_subtyping.toml | 11 +- .../results/pycroscope/classes_classvar.toml | 8 +- .../results/pycroscope/classes_override.toml | 11 +- .../pycroscope/directives_disjoint_base.toml | 22 ++- .../results/pycroscope/enums_definition.toml | 8 +- .../results/pycroscope/generics_defaults.toml | 43 +----- .../generics_defaults_referential.toml | 20 +-- .../generics_mixed_variance_inference.toml | 20 +-- .../generics_paramspec_semantics.toml | 6 +- .../generics_paramspec_variance.toml | 68 +++------ .../generics_syntax_infer_variance.toml | 4 +- .../pycroscope/generics_syntax_scoping.toml | 23 +-- .../generics_typevartuple_basic.toml | 8 +- .../generics_typevartuple_variance.toml | 47 ++---- .../pycroscope/namedtuples_define_class.toml | 10 +- .../pycroscope/protocols_definition.toml | 8 +- .../results/pycroscope/protocols_generic.toml | 3 +- .../typeddicts_type_consistency.toml | 12 +- conformance/results/pycroscope/version.toml | 2 +- conformance/results/results.html | 136 ++++-------------- conformance/uv.lock | 6 +- 26 files changed, 129 insertions(+), 384 deletions(-) diff --git a/conformance/results/pycroscope/aliases_implicit.toml b/conformance/results/pycroscope/aliases_implicit.toml index 51e2e303d..9bdc116fc 100644 --- a/conformance/results/pycroscope/aliases_implicit.toml +++ b/conformance/results/pycroscope/aliases_implicit.toml @@ -13,16 +13,12 @@ Line 113: Expected 1 errors Line 117: Expected 1 errors Line 118: Expected 1 errors Line 119: Expected 1 errors -Line 68: Unexpected errors ['./aliases_implicit.py:68:16: .GoodTypeAlias9[, None] = (int, /, ****P) -> ~R is not equivalent to (int, str, str, /) -> None'] Line 70: Unexpected errors ['./aliases_implicit.py:70:16: Any[from_another] is not equivalent to int | str | list[list[int]] | None'] -Line 72: Unexpected errors ['./aliases_implicit.py:72:16: .GoodTypeAlias13 = (**__P: **P) -> None is not equivalent to (...) -> None'] Line 95: Unexpected errors ["./aliases_implicit.py:95:16: Cannot resolve subscripted annotation: [invalid_annotation]"] Line 100: Unexpected errors ["./aliases_implicit.py:100:17: Annotated[type 'list', (<+list is_truthy None> == NullConstraint())] is always True because it does not provide __bool__ [type_always_true]"] """ output = """ -./aliases_implicit.py:68:16: .GoodTypeAlias9[, None] = (int, /, ****P) -> ~R is not equivalent to (int, str, str, /) -> None ./aliases_implicit.py:70:16: Any[from_another] is not equivalent to int | str | list[list[int]] | None -./aliases_implicit.py:72:16: .GoodTypeAlias13 = (**__P: **P) -> None is not equivalent to (...) -> None ./aliases_implicit.py:77:8: Unrecognized annotation types.GenericAlias [invalid_annotation] ./aliases_implicit.py:78:8: Expected 1 type arguments for type alias, got 2 [invalid_specialization] ./aliases_implicit.py:79:8: Expected 1 type arguments for type alias, got 2 [invalid_specialization] diff --git a/conformance/results/pycroscope/aliases_type_statement.toml b/conformance/results/pycroscope/aliases_type_statement.toml index 9961849bc..d22c1deb9 100644 --- a/conformance/results/pycroscope/aliases_type_statement.toml +++ b/conformance/results/pycroscope/aliases_type_statement.toml @@ -1,6 +1,7 @@ conformant = "Partial" notes = """ Fails to reject various weird annotations. +Rejects a valid recursive generic type alias. """ conformance_automated = "Fail" errors_diff = """ @@ -16,6 +17,7 @@ Line 45: Expected 1 errors Line 46: Expected 1 errors Line 47: Expected 1 errors Line 49: Expected 1 errors +Line 61: Unexpected errors ['./aliases_type_statement.py:61:0: Unrecognized annotation typing._SpecialForm [invalid_annotation]'] """ output = """ ./aliases_type_statement.py:17:0: typing.TypeAliasType has no attribute 'bit_count' [undefined_attribute] @@ -26,6 +28,7 @@ output = """ ./aliases_type_statement.py:48:22: Annotated[type 'list', (<+list is_truthy None> == NullConstraint())] is always True because it does not provide __bool__ [type_always_true] ./aliases_type_statement.py:53:22: Type alias cannot combine old-style TypeVar declarations with type statement parameters [invalid_type_alias] ./aliases_type_statement.py:58:16: Type alias must declare type parameters in the type statement [invalid_type_alias] +./aliases_type_statement.py:61:0: Unrecognized annotation typing._SpecialForm [invalid_annotation] ./aliases_type_statement.py:68:6: Type argument str is not compatible with ~S@./aliases_type_statement.py.RecursiveTypeAlias2 [invalid_specialization] ./aliases_type_statement.py:70:6: Type argument int is not compatible with ~T@./aliases_type_statement.py.RecursiveTypeAlias2 [invalid_specialization] ./aliases_type_statement.py:73:0: Type alias RecursiveTypeAlias3 has a circular definition [invalid_type_alias] diff --git a/conformance/results/pycroscope/aliases_typealiastype.toml b/conformance/results/pycroscope/aliases_typealiastype.toml index 09556fcfd..9aae0a048 100644 --- a/conformance/results/pycroscope/aliases_typealiastype.toml +++ b/conformance/results/pycroscope/aliases_typealiastype.toml @@ -1,14 +1,8 @@ -conformant = "Partial" -notes = """ -Rejects valid `ParamSpec` specialization. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 39: Unexpected errors ["./aliases_typealiastype.py:39:4: Unrecognized annotation [invalid_annotation]"] """ output = """ ./aliases_typealiastype.py:32:6: typing.TypeAliasType has no attribute 'other_attrib' [undefined_attribute] -./aliases_typealiastype.py:39:4: Unrecognized annotation [invalid_annotation] ./aliases_typealiastype.py:40:4: Type argument int is not compatible with ~TStr@./aliases_typealiastype.py.GoodAlias5 [invalid_specialization] ./aliases_typealiastype.py:43:44: Type alias cannot combine old-style TypeVar declarations with type statement parameters [invalid_type_alias] ./aliases_typealiastype.py:44:44: Type alias must declare type parameters in the type statement [invalid_type_alias] diff --git a/conformance/results/pycroscope/callables_annotation.toml b/conformance/results/pycroscope/callables_annotation.toml index 4eac45be1..d74b67611 100644 --- a/conformance/results/pycroscope/callables_annotation.toml +++ b/conformance/results/pycroscope/callables_annotation.toml @@ -1,10 +1,5 @@ -conformant = "Partial" -notes = """ -Does not support callback protocols with PEP 695 ParamSpec type parameters. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 115: Unexpected errors ['./callables_annotation.py:115:38: Traceback (most recent call last):', './callables_annotation.py:115:4: Traceback (most recent call last):'] """ output = """ ./callables_annotation.py:25:4: Missing required positional argument at position 1 [incompatible_call] @@ -19,10 +14,8 @@ output = """ ./callables_annotation.py:59:4: Ellipsis must be used directly in Callable[..., T], not in Callable[[...], T] [invalid_annotation] ./callables_annotation.py:91:0: Incompatible assignment: expected (int, /, **Any[explicit]) -> str, got () -> str [incompatible_assignment] ./callables_annotation.py:93:0: Incompatible assignment: expected (int, /, **Any[explicit]) -> str, got (*, a: int) -> str [incompatible_assignment] -./callables_annotation.py:115:38: Traceback (most recent call last): -./callables_annotation.py:115:4: Traceback (most recent call last): ./callables_annotation.py:159:4: Incompatible assignment: expected ./callables_annotation.py.Proto5[Any[explicit]], got ./callables_annotation.py.Proto8 [incompatible_assignment] -./callables_annotation.py:172:4: Incompatible assignment: expected .Callback2[Any[ellipsis_callable]] = (int, /, ****P) -> str, got () -> str [incompatible_assignment] +./callables_annotation.py:172:4: Incompatible assignment: expected .Callback2[AnySig()] = (int, /, ****P) -> str, got () -> str [incompatible_assignment] ./callables_annotation.py:187:4: Incompatible assignment: expected (str, /, **Any[explicit]) -> str, got (int, str, /) -> str [incompatible_assignment] -./callables_annotation.py:189:4: Incompatible assignment: expected .CallbackWithStr[Any[ellipsis_callable]] = (str, /, ****P) -> str, got (int, str, /) -> str [incompatible_assignment] +./callables_annotation.py:189:4: Incompatible assignment: expected .CallbackWithStr[AnySig()] = (str, /, ****P) -> str, got (int, str, /) -> str [incompatible_assignment] """ diff --git a/conformance/results/pycroscope/callables_protocol.toml b/conformance/results/pycroscope/callables_protocol.toml index 8bc4c7dff..658e045ad 100644 --- a/conformance/results/pycroscope/callables_protocol.toml +++ b/conformance/results/pycroscope/callables_protocol.toml @@ -1,10 +1,5 @@ -conformant = "Partial" -notes = """ -Does not support callback protocols with PEP 695 ParamSpec type parameters. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 179: Unexpected errors ['./callables_protocol.py:179:30: Traceback (most recent call last):', './callables_protocol.py:179:4: Traceback (most recent call last):'] """ output = """ ./callables_protocol.py:35:0: Incompatible assignment: expected ./callables_protocol.py.Proto1, got (*vals: tuple[bytes, ...], max_items: int | None) -> list[bytes] [incompatible_assignment] @@ -17,8 +12,6 @@ output = """ ./callables_protocol.py:97:0: Incompatible assignment: expected ./callables_protocol.py.Proto4, got (x: int) -> None [incompatible_assignment] ./callables_protocol.py:121:0: Incompatible assignment: expected ./callables_protocol.py.NotProto6, got (*vals: tuple[bytes, ...], max_len: int | None = None) -> list[bytes] [incompatible_assignment] ./callables_protocol.py:169:0: Incompatible assignment: expected ./callables_protocol.py.Proto8, got (x: int) -> Any[explicit] [incompatible_assignment] -./callables_protocol.py:179:30: Traceback (most recent call last): -./callables_protocol.py:179:4: Traceback (most recent call last): ./callables_protocol.py:186:4: Incompatible types in assignment to attribute 'other_attribute': expected int, got Literal['str'] [incompatible_assignment] ./callables_protocol.py:187:4: ./callables_protocol.py.Proto9[**P@./callables_protocol.py.decorator1..decorator1, +R@./callables_protocol.py.decorator1..decorator1] has no attribute 'xxx' [undefined_attribute] ./callables_protocol.py:197:6: ./callables_protocol.py.Proto9[(x: int) -> Any[unannotated], str] has no attribute 'other_attribute2' [undefined_attribute] diff --git a/conformance/results/pycroscope/callables_subtyping.toml b/conformance/results/pycroscope/callables_subtyping.toml index ad3adb9b2..548cae50e 100644 --- a/conformance/results/pycroscope/callables_subtyping.toml +++ b/conformance/results/pycroscope/callables_subtyping.toml @@ -1,11 +1,5 @@ -conformant = "Partial" -notes = """ -Does not support callback protocols with PEP 695 ParamSpec type parameters. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 205: Unexpected errors ['./callables_subtyping.py:205:30: Traceback (most recent call last):', './callables_subtyping.py:205:4: Traceback (most recent call last):'] -Line 214: Unexpected errors ['./callables_subtyping.py:214:4: Incompatible assignment: expected callables_subtyping.ProtocolWithP[**P@callables_subtyping.func7..func7], got callables_subtyping.TypeAliasWithP[**P@callables_subtyping.func7..func7] = (**__P: **P) -> None [incompatible_assignment]'] """ output = """ ./callables_subtyping.py:26:4: Incompatible assignment: expected (float | int, /) -> float | int, got (int, /) -> int [incompatible_assignment] @@ -34,9 +28,6 @@ output = """ ./callables_subtyping.py:195:4: Incompatible assignment: expected callables_subtyping.IntKwargs6, got callables_subtyping.StrKwargs6 [incompatible_assignment] ./callables_subtyping.py:196:4: Incompatible assignment: expected callables_subtyping.Standard6, got callables_subtyping.IntStrKwargs6 [incompatible_assignment] ./callables_subtyping.py:197:4: Incompatible assignment: expected callables_subtyping.Standard6, got callables_subtyping.StrKwargs6 [incompatible_assignment] -./callables_subtyping.py:205:30: Traceback (most recent call last): -./callables_subtyping.py:205:4: Traceback (most recent call last): -./callables_subtyping.py:214:4: Incompatible assignment: expected callables_subtyping.ProtocolWithP[**P@callables_subtyping.func7..func7], got callables_subtyping.TypeAliasWithP[**P@callables_subtyping.func7..func7] = (**__P: **P) -> None [incompatible_assignment] ./callables_subtyping.py:236:4: Incompatible assignment: expected callables_subtyping.DefaultArg8, got callables_subtyping.NoDefaultArg8 [incompatible_assignment] ./callables_subtyping.py:237:4: Incompatible assignment: expected callables_subtyping.DefaultArg8, got callables_subtyping.NoX8 [incompatible_assignment] ./callables_subtyping.py:240:4: Incompatible assignment: expected callables_subtyping.NoDefaultArg8, got callables_subtyping.NoX8 [incompatible_assignment] diff --git a/conformance/results/pycroscope/classes_classvar.toml b/conformance/results/pycroscope/classes_classvar.toml index 23479ff47..4d3f0e1dd 100644 --- a/conformance/results/pycroscope/classes_classvar.toml +++ b/conformance/results/pycroscope/classes_classvar.toml @@ -1,10 +1,5 @@ -conformant = "Partial" -notes = """ -Does not reject use of `ClassVar` as a qualifier for a NamedTuple field. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 94: Expected 1 errors """ output = """ ./classes_classvar.py:40:10: Invalid type annotation (, ) [invalid_annotation] @@ -23,6 +18,7 @@ output = """ ./classes_classvar.py:79:7: ClassVar can only be used for assignments in class body [invalid_qualifier] ./classes_classvar.py:80:19: ClassVar cannot be used in type aliases [invalid_qualifier] ./classes_classvar.py:89:7: Unexpected ClassVar annotation [invalid_qualifier] +./classes_classvar.py:94:7: ClassVar cannot be used for NamedTuple fields [invalid_qualifier] ./classes_classvar.py:127:0: Cannot assign to class variable 'stats' via instance [incompatible_assignment] ./classes_classvar.py:156:0: Incompatible assignment: expected ./classes_classvar.py.ProtoA, got ./classes_classvar.py.ProtoAImpl [incompatible_assignment] """ diff --git a/conformance/results/pycroscope/classes_override.toml b/conformance/results/pycroscope/classes_override.toml index b5c0ee4fe..b140ec840 100644 --- a/conformance/results/pycroscope/classes_override.toml +++ b/conformance/results/pycroscope/classes_override.toml @@ -1,12 +1,5 @@ -conformant = "Partial" -notes = """ -Does not honor `@override` compatibility checks for `__init__` and `__new__`: -the incompatible constructor overrides in `ChildC2` are not flagged. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Lines 134, 135: Expected error (tag 'init') -Lines 137, 138: Expected error (tag 'new') """ output = """ ./classes_override.py:53:4: Method does not override any base method [override_does_not_override] @@ -14,4 +7,6 @@ output = """ ./classes_override.py:79:4: Method does not override any base method [override_does_not_override] ./classes_override.py:84:4: Method does not override any base method [override_does_not_override] ./classes_override.py:89:4: Method does not override any base method [override_does_not_override] +./classes_override.py:135:4: Value of __init__ incompatible with base class classes_override.ParentC [incompatible_override] +./classes_override.py:138:4: Value of __new__ incompatible with base class classes_override.ParentC [incompatible_override] """ diff --git a/conformance/results/pycroscope/directives_disjoint_base.toml b/conformance/results/pycroscope/directives_disjoint_base.toml index 96a30b849..f58404656 100644 --- a/conformance/results/pycroscope/directives_disjoint_base.toml +++ b/conformance/results/pycroscope/directives_disjoint_base.toml @@ -1,17 +1,13 @@ -conformant = "Partial" -notes = """ -Does not reject invalid class definitions due to disjoint bases, but uses disjoint base information in type narrowing. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 69: Expected 1 errors -Line 73: Expected 1 errors -Line 77: Expected 1 errors -Line 81: Expected 1 errors -Line 105: Expected 1 errors -Line 118: Expected 1 errors -Line 123: Expected 1 errors """ output = """ -./directives_disjoint_base.py:113:1: Incompatible argument type for cls: expected ~_TC but got () -> None [incompatible_argument] +./directives_disjoint_base.py:69:0: Class has incompatible disjoint bases [invalid_base] +./directives_disjoint_base.py:73:0: Class has incompatible disjoint bases [invalid_base] +./directives_disjoint_base.py:77:0: Class has incompatible disjoint bases [invalid_base] +./directives_disjoint_base.py:81:0: Class has incompatible disjoint bases [invalid_base] +./directives_disjoint_base.py:105:0: Class has incompatible disjoint bases [invalid_base] +./directives_disjoint_base.py:113:1: disjoint_base cannot be applied to a function [invalid_disjoint_base] +./directives_disjoint_base.py:118:1: disjoint_base cannot be applied to a TypedDict [invalid_disjoint_base] +./directives_disjoint_base.py:123:1: disjoint_base cannot be applied to a Protocol [invalid_disjoint_base] """ diff --git a/conformance/results/pycroscope/enums_definition.toml b/conformance/results/pycroscope/enums_definition.toml index 896d77db6..622573cae 100644 --- a/conformance/results/pycroscope/enums_definition.toml +++ b/conformance/results/pycroscope/enums_definition.toml @@ -1,10 +1,5 @@ -conformant = "Partial" -notes = """ -Does not allow enum members to be conditional on version/platform checks. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 91: Unexpected errors ['./enums_definition.py:91:12: ./enums_definition.py.Color12 is not equivalent to Any[unannotated]'] """ output = """ ./enums_definition.py:34:12: enum.Enum has no attribute 'RED' [undefined_attribute] @@ -23,6 +18,5 @@ output = """ ./enums_definition.py:40:32: type[enum.Enum] has no attribute 'RED' [undefined_attribute] ./enums_definition.py:41:12: type[enum.Enum] has no attribute 'RED' [undefined_attribute] ./enums_definition.py:41:32: type[enum.Enum] has no attribute 'RED' [undefined_attribute] -./enums_definition.py:91:12: ./enums_definition.py.Color12 is not equivalent to Any[unannotated] ./enums_definition.py:92:0: has no attribute 'BLUE' [undefined_attribute] """ diff --git a/conformance/results/pycroscope/generics_defaults.toml b/conformance/results/pycroscope/generics_defaults.toml index 3e3cc4f3a..70c20747d 100644 --- a/conformance/results/pycroscope/generics_defaults.toml +++ b/conformance/results/pycroscope/generics_defaults.toml @@ -1,44 +1,11 @@ -conformant = "Partial" -notes = """ -Numerous issues; does not support `TypeVarTuple` and `ParamSpec` defaults. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 33: Unexpected errors ['./generics_defaults.py:33:16: ~DefaultStrT@./generics_defaults.py.NoNonDefaults is not equivalent to str'] -Line 34: Unexpected errors ['./generics_defaults.py:34:16: ~DefaultIntT@./generics_defaults.py.NoNonDefaults is not equivalent to int'] -Line 73: Unexpected errors ['./generics_defaults.py:73:16: ~T1@./generics_defaults.py.AllTheDefaults is not equivalent to Any[explicit]'] -Line 74: Unexpected errors ['./generics_defaults.py:74:16: ~T2@./generics_defaults.py.AllTheDefaults is not equivalent to Any[explicit]'] -Line 75: Unexpected errors ['./generics_defaults.py:75:16: ~DefaultStrT@./generics_defaults.py.NoNonDefaults is not equivalent to str'] -Line 76: Unexpected errors ['./generics_defaults.py:76:16: ~DefaultIntT@./generics_defaults.py.NoNonDefaults is not equivalent to int'] -Line 77: Unexpected errors ['./generics_defaults.py:77:16: ~DefaultBoolT@./generics_defaults.py.AllTheDefaults is not equivalent to bool'] -Line 122: Unexpected errors ['./generics_defaults.py:122:16: (**__P: **DefaultP@./generics_defaults.py.Class_ParamSpec) -> None is not equivalent to (str, int, /) -> None'] -Line 124: Unexpected errors ['./generics_defaults.py:124:16: ./generics_defaults.py.Class_ParamSpec[AnySig()] is not equivalent to ./generics_defaults.py.Class_ParamSpec[tuple[bool, bool]]'] -Line 144: Unexpected errors ['./generics_defaults.py:144:60: Incompatible argument type for default: expected TypeForm[object] but got Literal[typing.Unpack[DefaultTs]] [incompatible_argument]'] -Line 203: Unexpected errors ["./generics_defaults.py:203:36: Invalid type annotation [] [invalid_annotation]", './generics_defaults.py:203:17: ParamSpec specialization must use list form, Concatenate[..., P], P, or ... [invalid_annotation]'] -Line 204: Unexpected errors ['./generics_defaults.py:204:16: tuple[int] is not equivalent to tuple[int, str]'] -Line 205: Unexpected errors ['./generics_defaults.py:205:16: (...) -> None is not equivalent to (float | int, bool, /) -> None'] -Line 208: Unexpected errors ['./generics_defaults.py:208:16: (...) -> None is not equivalent to (bytes, /) -> None'] """ output = """ -./generics_defaults.py:24:0: non-default TypeVars cannot follow ones with defaults [invalid_type_parameter] -./generics_defaults.py:33:16: ~DefaultStrT@./generics_defaults.py.NoNonDefaults is not equivalent to str -./generics_defaults.py:34:16: ~DefaultIntT@./generics_defaults.py.NoNonDefaults is not equivalent to int +./generics_defaults.py:24:0: non-default TypeVars cannot follow ones with defaults [invalid_type_parameter_default] ./generics_defaults.py:66:7: Expected at least 2 type arguments for ./generics_defaults.py.AllTheDefaults [invalid_specialization] -./generics_defaults.py:73:16: ~T1@./generics_defaults.py.AllTheDefaults is not equivalent to Any[explicit] -./generics_defaults.py:74:16: ~T2@./generics_defaults.py.AllTheDefaults is not equivalent to Any[explicit] -./generics_defaults.py:75:16: ~DefaultStrT@./generics_defaults.py.NoNonDefaults is not equivalent to str -./generics_defaults.py:76:16: ~DefaultIntT@./generics_defaults.py.NoNonDefaults is not equivalent to int -./generics_defaults.py:77:16: ~DefaultBoolT@./generics_defaults.py.AllTheDefaults is not equivalent to bool -./generics_defaults.py:122:16: (**__P: **DefaultP@./generics_defaults.py.Class_ParamSpec) -> None is not equivalent to (str, int, /) -> None -./generics_defaults.py:124:16: ./generics_defaults.py.Class_ParamSpec[AnySig()] is not equivalent to ./generics_defaults.py.Class_ParamSpec[tuple[bool, bool]] -./generics_defaults.py:144:60: Incompatible argument type for default: expected TypeForm[object] but got Literal[typing.Unpack[DefaultTs]] [incompatible_argument] -./generics_defaults.py:152:50: TypeVar default must be assignable to its bound [incompatible_call] -./generics_defaults.py:159:51: TypeVar default must be one of its constraints [incompatible_call] +./generics_defaults.py:152:50: TypeVar default must be assignable to its bound [invalid_type_parameter_default] +./generics_defaults.py:159:51: TypeVar default must be one of its constraints [invalid_type_parameter_default] ./generics_defaults.py:176:12: Any[generic_argument] is not equivalent to int -./generics_defaults.py:188:0: TypeVars with defaults cannot follow TypeVarTuples [invalid_type_parameter] -./generics_defaults.py:203:36: Invalid type annotation [] [invalid_annotation] -./generics_defaults.py:203:17: ParamSpec specialization must use list form, Concatenate[..., P], P, or ... [invalid_annotation] -./generics_defaults.py:204:16: tuple[int] is not equivalent to tuple[int, str] -./generics_defaults.py:205:16: (...) -> None is not equivalent to (float | int, bool, /) -> None -./generics_defaults.py:208:16: (...) -> None is not equivalent to (bytes, /) -> None +./generics_defaults.py:188:0: TypeVars with defaults cannot follow TypeVarTuples [invalid_type_parameter_default] """ diff --git a/conformance/results/pycroscope/generics_defaults_referential.toml b/conformance/results/pycroscope/generics_defaults_referential.toml index 9bde8f604..d6d2e1b4e 100644 --- a/conformance/results/pycroscope/generics_defaults_referential.toml +++ b/conformance/results/pycroscope/generics_defaults_referential.toml @@ -1,20 +1,12 @@ -conformant = "Partial" -notes = """ -Fails to apply default specializations in some cases. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 97: Unexpected errors ['./generics_defaults_referential.py:97:16: ~Z1@generics_defaults_referential.Bar is not equivalent to Any[explicit]'] -Line 98: Unexpected errors ['./generics_defaults_referential.py:98:16: ~ListDefaultT@generics_defaults_referential.Bar is not equivalent to list[Any[explicit]]'] """ output = """ ./generics_defaults_referential.py:36:16: Incompatible argument type for b: expected int but got str [incompatible_argument] ./generics_defaults_referential.py:37:13: Incompatible argument type for a: expected int but got str [incompatible_argument] -./generics_defaults_referential.py:53:0: Type parameter defaults can reference only earlier type parameters from the same class [invalid_type_parameter] -./generics_defaults_referential.py:60:4: Type parameter defaults can reference only earlier type parameters from the same class [invalid_type_parameter] -./generics_defaults_referential.py:68:39: TypeVar default must be assignable to its bound [incompatible_call] -./generics_defaults_referential.py:74:51: TypeVar default must be one of its constraints [incompatible_call] -./generics_defaults_referential.py:78:62: TypeVar default must be one of its constraints [incompatible_call] -./generics_defaults_referential.py:97:16: ~Z1@generics_defaults_referential.Bar is not equivalent to Any[explicit] -./generics_defaults_referential.py:98:16: ~ListDefaultT@generics_defaults_referential.Bar is not equivalent to list[Any[explicit]] +./generics_defaults_referential.py:53:0: Type parameter defaults can reference only earlier type parameters from the same class [invalid_type_parameter_default] +./generics_defaults_referential.py:60:4: Type parameter defaults can reference only earlier type parameters from the same class [invalid_type_parameter_default] +./generics_defaults_referential.py:68:39: TypeVar default must be assignable to its bound [invalid_type_parameter_default] +./generics_defaults_referential.py:74:51: TypeVar default must be one of its constraints [invalid_type_parameter_default] +./generics_defaults_referential.py:78:62: TypeVar default must be one of its constraints [invalid_type_parameter_default] """ diff --git a/conformance/results/pycroscope/generics_mixed_variance_inference.toml b/conformance/results/pycroscope/generics_mixed_variance_inference.toml index 6aa55eb89..679f6f667 100644 --- a/conformance/results/pycroscope/generics_mixed_variance_inference.toml +++ b/conformance/results/pycroscope/generics_mixed_variance_inference.toml @@ -1,20 +1,8 @@ -conformant = "Unsupported" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 8: Unexpected errors ['./generics_mixed_variance_inference.py:8:32: Traceback (most recent call last):', './generics_mixed_variance_inference.py:8:4: Traceback (most recent call last):'] -Line 12: Unexpected errors ['./generics_mixed_variance_inference.py:12:0: Incompatible assignment: expected generics_mixed_variance_inference.Mixed[int, Any[error]], got generics_mixed_variance_inference.Mixed[object, AnySig()] [incompatible_assignment]', './generics_mixed_variance_inference.py:12:4: Invalid type annotation [] [invalid_annotation]'] -Line 17: Unexpected errors ['./generics_mixed_variance_inference.py:17:0: Incompatible assignment: expected generics_mixed_variance_inference.Mixed[int, int, ], got generics_mixed_variance_inference.Mixed[int, bool, AnySig()] [incompatible_assignment]'] -Line 20: Unexpected errors ["./generics_mixed_variance_inference.py:20:4: Invalid type annotation [] [invalid_annotation]"] """ output = """ -./generics_mixed_variance_inference.py:8:32: Traceback (most recent call last): -./generics_mixed_variance_inference.py:8:4: Traceback (most recent call last): -./generics_mixed_variance_inference.py:12:0: Incompatible assignment: expected generics_mixed_variance_inference.Mixed[int, Any[error]], got generics_mixed_variance_inference.Mixed[object, AnySig()] [incompatible_assignment] -./generics_mixed_variance_inference.py:12:4: Invalid type annotation [] [invalid_annotation] -./generics_mixed_variance_inference.py:13:0: Incompatible assignment: expected generics_mixed_variance_inference.Mixed[int, Any[error]], got generics_mixed_variance_inference.Mixed[bool, AnySig()] [incompatible_assignment] -./generics_mixed_variance_inference.py:13:4: Invalid type annotation [] [invalid_annotation] -./generics_mixed_variance_inference.py:16:0: Incompatible assignment: expected generics_mixed_variance_inference.Mixed[int, int, ], got generics_mixed_variance_inference.Mixed[int, object, AnySig()] [incompatible_assignment] -./generics_mixed_variance_inference.py:17:0: Incompatible assignment: expected generics_mixed_variance_inference.Mixed[int, int, ], got generics_mixed_variance_inference.Mixed[int, bool, AnySig()] [incompatible_assignment] -./generics_mixed_variance_inference.py:20:4: Invalid type annotation [] [invalid_annotation] -./generics_mixed_variance_inference.py:21:4: Invalid type annotation [] [invalid_annotation] +./generics_mixed_variance_inference.py:13:0: Incompatible assignment: expected generics_mixed_variance_inference.Mixed[int, tuple[()], () -> Any[generic_argument]], got generics_mixed_variance_inference.Mixed[bool, () -> Any[generic_argument]] [incompatible_assignment] +./generics_mixed_variance_inference.py:16:0: Incompatible assignment: expected generics_mixed_variance_inference.Mixed[int, int, () -> Any[generic_argument]], got generics_mixed_variance_inference.Mixed[int, object, () -> Any[generic_argument]] [incompatible_assignment] +./generics_mixed_variance_inference.py:21:0: Incompatible assignment: expected generics_mixed_variance_inference.Mixed[int, tuple[()], (int, /) -> Any[generic_argument]], got generics_mixed_variance_inference.Mixed[int, (bool, /) -> Any[generic_argument]] [incompatible_assignment] """ diff --git a/conformance/results/pycroscope/generics_paramspec_semantics.toml b/conformance/results/pycroscope/generics_paramspec_semantics.toml index dfaf3a3c1..c332d805f 100644 --- a/conformance/results/pycroscope/generics_paramspec_semantics.toml +++ b/conformance/results/pycroscope/generics_paramspec_semantics.toml @@ -9,7 +9,7 @@ output = """ ./generics_paramspec_semantics.py:98:3: Incompatible argument type for @0: expected str but got Literal[1] [incompatible_argument] ./generics_paramspec_semantics.py:108:0: Incompatible argument type for args: expected tuple[bool, ...] but got tuple[Literal[1]] [incompatible_argument] ./generics_paramspec_semantics.py:120:3: Incompatible argument type for @0: expected str but got Literal[1] [incompatible_argument] -./generics_paramspec_semantics.py:127:1: Incompatible argument type for x: expected (int, /, ****P@./generics_paramspec_semantics.py.expects_int_first..expects_int_first) -> int but got (x: str) -> int [incompatible_argument] -./generics_paramspec_semantics.py:132:1: Incompatible argument type for x: expected (int, /, ****P@./generics_paramspec_semantics.py.expects_int_first..expects_int_first) -> int but got (*, x: int) -> int [incompatible_argument] -./generics_paramspec_semantics.py:137:1: Incompatible argument type for x: expected (int, /, ****P@./generics_paramspec_semantics.py.expects_int_first..expects_int_first) -> int but got (**kwargs: dict[str, int]) -> int [incompatible_argument] +./generics_paramspec_semantics.py:127:1: Incompatible argument type for x: expected (int, /, ****P) -> int but got (x: str) -> int [incompatible_argument] +./generics_paramspec_semantics.py:132:1: Incompatible argument type for x: expected (int, /, ****P) -> int but got (*, x: int) -> int [incompatible_argument] +./generics_paramspec_semantics.py:137:1: Incompatible argument type for x: expected (int, /, ****P) -> int but got (**kwargs: dict[str, int]) -> int [incompatible_argument] """ diff --git a/conformance/results/pycroscope/generics_paramspec_variance.toml b/conformance/results/pycroscope/generics_paramspec_variance.toml index 9a83d5184..edfa0a813 100644 --- a/conformance/results/pycroscope/generics_paramspec_variance.toml +++ b/conformance/results/pycroscope/generics_paramspec_variance.toml @@ -1,49 +1,27 @@ -conformant = "Unsupported" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 90: Expected 1 errors -Line 117: Expected 1 errors -Line 126: Expected 1 errors -Line 19: Unexpected errors ['./generics_paramspec_variance.py:19:23: Traceback (most recent call last):', './generics_paramspec_variance.py:19:4: Traceback (most recent call last):'] -Line 22: Unexpected errors ['./generics_paramspec_variance.py:22:38: Traceback (most recent call last):'] -Line 31: Unexpected errors ['./generics_paramspec_variance.py:31:38: Traceback (most recent call last):'] -Line 84: Unexpected errors ["./generics_paramspec_variance.py:84:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.OutitP~[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.OutitP~[(*, a: int) -> Any[unannotated]] [incompatible_assignment]"] -Line 86: Unexpected errors ["./generics_paramspec_variance.py:86:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.OutitP~[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.OutitP~[(a: int, /) -> Any[unannotated]] [incompatible_assignment]"] -Line 109: Unexpected errors ['./generics_paramspec_variance.py:109:13: Traceback (most recent call last):'] -Line 122: Unexpected errors ['./generics_paramspec_variance.py:122:45: Traceback (most recent call last):'] -Line 133: Unexpected errors ['./generics_paramspec_variance.py:133:45: Traceback (most recent call last):'] -Line 143: Unexpected errors ['./generics_paramspec_variance.py:143:59: Traceback (most recent call last):'] -Line 152: Unexpected errors ['./generics_paramspec_variance.py:152:59: Traceback (most recent call last):'] """ output = """ -./generics_paramspec_variance.py:14:41: Traceback (most recent call last): -./generics_paramspec_variance.py:15:38: Traceback (most recent call last): -./generics_paramspec_variance.py:19:23: Traceback (most recent call last): -./generics_paramspec_variance.py:19:4: Traceback (most recent call last): -./generics_paramspec_variance.py:21:41: Traceback (most recent call last): -./generics_paramspec_variance.py:22:38: Traceback (most recent call last): -./generics_paramspec_variance.py:30:35: Traceback (most recent call last): -./generics_paramspec_variance.py:31:38: Traceback (most recent call last): -./generics_paramspec_variance.py:61:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.InitP~[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.InitP~[(*, a: int) -> Any[unannotated]] [incompatible_assignment] -./generics_paramspec_variance.py:63:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.InitP~[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.InitP~[(a: int, /) -> Any[unannotated]] [incompatible_assignment] -./generics_paramspec_variance.py:65:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.InitP~[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.InitP~[(b: int) -> Any[unannotated]] [incompatible_assignment] -./generics_paramspec_variance.py:69:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.InitP~[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.InitP~[(a: int, b: str) -> Any[unannotated]] [incompatible_assignment] -./generics_paramspec_variance.py:84:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.OutitP~[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.OutitP~[(*, a: int) -> Any[unannotated]] [incompatible_assignment] -./generics_paramspec_variance.py:86:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.OutitP~[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.OutitP~[(a: int, /) -> Any[unannotated]] [incompatible_assignment] -./generics_paramspec_variance.py:88:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.OutitP~[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.OutitP~[(b: int) -> Any[unannotated]] [incompatible_assignment] -./generics_paramspec_variance.py:92:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.OutitP~[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.OutitP~[(a: int, b: str) -> Any[unannotated]] [incompatible_assignment] -./generics_paramspec_variance.py:100:8: Error calling (name: str, /, *, bound: object = no argument given, covariant: bool = Literal[False], contravariant: bool = Literal[False], infer_variance: bool = Literal[False], default: object = no argument given) -> typing.ParamSpec (with impl): Bivariant types are not supported. [incompatible_call] -./generics_paramspec_variance.py:101:8: Error calling (name: str, /, *, bound: object = no argument given, covariant: bool = Literal[False], contravariant: bool = Literal[False], infer_variance: bool = Literal[False], default: object = no argument given) -> typing.ParamSpec (with impl): Variance cannot be specified with infer_variance. [incompatible_call] -./generics_paramspec_variance.py:102:8: Error calling (name: str, /, *, bound: object = no argument given, covariant: bool = Literal[False], contravariant: bool = Literal[False], infer_variance: bool = Literal[False], default: object = no argument given) -> typing.ParamSpec (with impl): Variance cannot be specified with infer_variance. [incompatible_call] -./generics_paramspec_variance.py:109:13: Traceback (most recent call last): -./generics_paramspec_variance.py:110:13: Traceback (most recent call last): -./generics_paramspec_variance.py:111:13: Traceback (most recent call last): -./generics_paramspec_variance.py:121:48: Traceback (most recent call last): -./generics_paramspec_variance.py:122:45: Traceback (most recent call last): -./generics_paramspec_variance.py:132:42: Traceback (most recent call last): -./generics_paramspec_variance.py:133:45: Traceback (most recent call last): -./generics_paramspec_variance.py:142:62: Traceback (most recent call last): -./generics_paramspec_variance.py:143:59: Traceback (most recent call last): -./generics_paramspec_variance.py:151:56: Traceback (most recent call last): -./generics_paramspec_variance.py:152:59: Traceback (most recent call last): +./generics_paramspec_variance.py:14:0: Incompatible assignment: expected ./generics_paramspec_variance.py.InvariantParamSpec[(object, /) -> Any[generic_argument]], got ./generics_paramspec_variance.py.InvariantParamSpec[(int, /) -> Any[generic_argument]] [incompatible_assignment] +./generics_paramspec_variance.py:15:0: Incompatible assignment: expected ./generics_paramspec_variance.py.InvariantParamSpec[(int, /) -> Any[generic_argument]], got ./generics_paramspec_variance.py.InvariantParamSpec[(object, /) -> Any[generic_argument]] [incompatible_assignment] +./generics_paramspec_variance.py:21:0: Incompatible assignment: expected ./generics_paramspec_variance.py.ContravariantParamSpec[(object, /) -> Any[generic_argument]], got ./generics_paramspec_variance.py.ContravariantParamSpec[(int, /) -> Any[generic_argument]] [incompatible_assignment] +./generics_paramspec_variance.py:30:0: Incompatible assignment: expected ./generics_paramspec_variance.py.CovariantParamSpec[(int, /) -> Any[generic_argument]], got ./generics_paramspec_variance.py.CovariantParamSpec[(object, /) -> Any[generic_argument]] [incompatible_assignment] +./generics_paramspec_variance.py:61:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.InitP[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.InitP[(*, a: int) -> Any[unannotated]] [incompatible_assignment] +./generics_paramspec_variance.py:63:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.InitP[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.InitP[(a: int, /) -> Any[unannotated]] [incompatible_assignment] +./generics_paramspec_variance.py:65:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.InitP[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.InitP[(b: int) -> Any[unannotated]] [incompatible_assignment] +./generics_paramspec_variance.py:69:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.InitP[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.InitP[(a: int, b: str) -> Any[unannotated]] [incompatible_assignment] +./generics_paramspec_variance.py:88:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.OutitP[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.OutitP[(b: int) -> Any[unannotated]] [incompatible_assignment] +./generics_paramspec_variance.py:90:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.OutitP[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.OutitP[(a: int = Literal[1]) -> Any[unannotated]] [incompatible_assignment] +./generics_paramspec_variance.py:92:0: Incompatible types in assignment to attribute 't': expected ./generics_paramspec_variance.py.OutitP[(a: int) -> Any[unannotated]], got ./generics_paramspec_variance.py.OutitP[(a: int, b: str) -> Any[unannotated]] [incompatible_assignment] +./generics_paramspec_variance.py:100:8: Bivariant types are not supported [incompatible_call] +./generics_paramspec_variance.py:101:8: Type parameter cannot combine infer_variance with explicit variance [incompatible_call] +./generics_paramspec_variance.py:102:8: Type parameter cannot combine infer_variance with explicit variance [incompatible_call] +./generics_paramspec_variance.py:110:0: Incompatible assignment: expected ./generics_paramspec_variance.py.InvariantParamSpecOld[(int, /) -> Any[generic_argument]], got ./generics_paramspec_variance.py.InvariantParamSpecOld[(bool, /) -> Any[generic_argument]] [incompatible_assignment] +./generics_paramspec_variance.py:111:0: Incompatible assignment: expected ./generics_paramspec_variance.py.InvariantParamSpecOld[(int, /) -> Any[generic_argument]], got ./generics_paramspec_variance.py.InvariantParamSpecOld[(object, /) -> Any[generic_argument]] [incompatible_assignment] +./generics_paramspec_variance.py:117:4: InP has incompatible variance in method [invalid_annotation] +./generics_paramspec_variance.py:121:0: Incompatible assignment: expected ./generics_paramspec_variance.py.ContravariantParamSpecOld[(object, /) -> Any[generic_argument]], got ./generics_paramspec_variance.py.ContravariantParamSpecOld[(int, /) -> Any[generic_argument]] [incompatible_assignment] +./generics_paramspec_variance.py:126:4: OutP has incompatible variance in method [invalid_annotation] +./generics_paramspec_variance.py:132:0: Incompatible assignment: expected ./generics_paramspec_variance.py.CovariantParamSpecOld[(int, /) -> Any[generic_argument]], got ./generics_paramspec_variance.py.CovariantParamSpecOld[(object, /) -> Any[generic_argument]] [incompatible_assignment] +./generics_paramspec_variance.py:142:0: Incompatible assignment: expected ./generics_paramspec_variance.py.InferredContravariantParamSpecOld[(object, /) -> Any[generic_argument]], got ./generics_paramspec_variance.py.InferredContravariantParamSpecOld[(int, /) -> Any[generic_argument]] [incompatible_assignment] +./generics_paramspec_variance.py:151:0: Incompatible assignment: expected ./generics_paramspec_variance.py.InferredCovariantParamSpecOld[(int, /) -> Any[generic_argument]], got ./generics_paramspec_variance.py.InferredCovariantParamSpecOld[(object, /) -> Any[generic_argument]] [incompatible_assignment] """ diff --git a/conformance/results/pycroscope/generics_syntax_infer_variance.toml b/conformance/results/pycroscope/generics_syntax_infer_variance.toml index fdae01c6a..df6ccefcf 100644 --- a/conformance/results/pycroscope/generics_syntax_infer_variance.toml +++ b/conformance/results/pycroscope/generics_syntax_infer_variance.toml @@ -2,8 +2,8 @@ conformance_automated = "Pass" errors_diff = """ """ output = """ -./generics_syntax_infer_variance.py:15:5: TypeVar cannot combine infer_variance with explicit variance [incompatible_call] -./generics_syntax_infer_variance.py:17:5: TypeVar cannot combine infer_variance with explicit variance [incompatible_call] +./generics_syntax_infer_variance.py:15:5: Type parameter cannot combine infer_variance with explicit variance [incompatible_call] +./generics_syntax_infer_variance.py:17:5: Type parameter cannot combine infer_variance with explicit variance [incompatible_call] ./generics_syntax_infer_variance.py:29:0: Incompatible assignment: expected ./generics_syntax_infer_variance.py.ShouldBeCovariant1[int], got ./generics_syntax_infer_variance.py.ShouldBeCovariant1[float | int] [incompatible_assignment] ./generics_syntax_infer_variance.py:47:0: Incompatible assignment: expected ./generics_syntax_infer_variance.py.ShouldBeCovariant2[int], got ./generics_syntax_infer_variance.py.ShouldBeCovariant2[float | int] [incompatible_assignment] ./generics_syntax_infer_variance.py:56:0: Incompatible assignment: expected ./generics_syntax_infer_variance.py.ShouldBeCovariant3[int], got ./generics_syntax_infer_variance.py.ShouldBeCovariant3[float | int] [incompatible_assignment] diff --git a/conformance/results/pycroscope/generics_syntax_scoping.toml b/conformance/results/pycroscope/generics_syntax_scoping.toml index 3bff89f05..6aa30d4d5 100644 --- a/conformance/results/pycroscope/generics_syntax_scoping.toml +++ b/conformance/results/pycroscope/generics_syntax_scoping.toml @@ -1,24 +1,13 @@ -conformant = "Partial" -notes = """ -Misses some details of scoping rules. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 18: Expected 1 errors -Line 92: Expected 1 errors -Line 95: Expected 1 errors -Line 98: Expected 1 errors -Line 74: Unexpected errors ['./generics_syntax_scoping.py:74:19: Undefined name: Private [undefined_name]'] -Line 88: Unexpected errors ['./generics_syntax_scoping.py:88:1: Undefined name: decorator2 [undefined_name]'] -Line 117: Unexpected errors ['./generics_syntax_scoping.py:117:28: ~T@./generics_syntax_scoping.py.f..Outer2 is not equivalent to typing.TypeVar', './generics_syntax_scoping.py:117:28: Type parameter is not valid in this annotation context [invalid_annotation]'] """ output = """ ./generics_syntax_scoping.py:14:19: TypeVar bound cannot be parameterized by type variables [invalid_annotation] +./generics_syntax_scoping.py:18:13: Type parameter bound cannot reference a later type parameter [invalid_type_parameter] ./generics_syntax_scoping.py:35:6: Undefined name: T [undefined_name] +./generics_syntax_scoping.py:44:12: Incompatible argument type for x: expected type[./generics_syntax_scoping.py.Foo[~T@./generics_syntax_scoping.py.decorator1..decorator1]] but got types.GenericAlias (partial from [Any[error]]) [incompatible_argument] ./generics_syntax_scoping.py:44:16: Undefined name: T [undefined_name] -./generics_syntax_scoping.py:44:1: Undefined name: decorator1 [undefined_name] -./generics_syntax_scoping.py:74:19: Undefined name: Private [undefined_name] -./generics_syntax_scoping.py:88:1: Undefined name: decorator2 [undefined_name] -./generics_syntax_scoping.py:117:28: ~T@./generics_syntax_scoping.py.f..Outer2 is not equivalent to typing.TypeVar -./generics_syntax_scoping.py:117:28: Type parameter is not valid in this annotation context [invalid_annotation] +./generics_syntax_scoping.py:92:16: Type parameter 'T' is already in use by an outer scope [invalid_type_parameter] +./generics_syntax_scoping.py:95:16: Type parameter 'T' is already in use by an outer scope [invalid_type_parameter] +./generics_syntax_scoping.py:98:16: Type parameter 'T' is already in use by an outer scope [invalid_type_parameter] """ diff --git a/conformance/results/pycroscope/generics_typevartuple_basic.toml b/conformance/results/pycroscope/generics_typevartuple_basic.toml index 6685db31f..482d88b8c 100644 --- a/conformance/results/pycroscope/generics_typevartuple_basic.toml +++ b/conformance/results/pycroscope/generics_typevartuple_basic.toml @@ -1,10 +1,5 @@ -conformant = "Partial" -conformance_automated = "Fail" -notes = """ -Doesn't error when multiple type variable tuples appear in a PEP 695 type parameter list; only detects the `Generic[...]` form. -""" +conformance_automated = "Pass" errors_diff = """ -Line 111: Expected 1 errors """ output = """ ./generics_typevartuple_basic.py:43:33: Incompatible argument type for shape: expected tuple[*tuple[Shape, ...]] but got NewType('Height', int) [incompatible_argument] @@ -20,4 +15,5 @@ output = """ ./generics_typevartuple_basic.py:100:4: Cannot resolve type variables [incompatible_call] ./generics_typevartuple_basic.py:101:4: Cannot resolve type variables [incompatible_call] ./generics_typevartuple_basic.py:107:21: Only one TypeVarTuple can be used in a type parameter list [invalid_base] +./generics_typevartuple_basic.py:111:19: Only one TypeVarTuple may appear in a type parameter list [invalid_type_parameter] """ diff --git a/conformance/results/pycroscope/generics_typevartuple_variance.toml b/conformance/results/pycroscope/generics_typevartuple_variance.toml index f53bb15ad..74e9e79f4 100644 --- a/conformance/results/pycroscope/generics_typevartuple_variance.toml +++ b/conformance/results/pycroscope/generics_typevartuple_variance.toml @@ -1,54 +1,31 @@ -conformant = "Unsupported" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 56: Expected 1 errors -Line 57: Expected 1 errors -Line 58: Expected 1 errors -Line 79: Expected 1 errors -Line 90: Expected 1 errors -Line 29: Unexpected errors ['./generics_typevartuple_variance.py:29:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTuple[int], got generics_typevartuple_variance.ContravariantTypeVarTuple[object] [incompatible_assignment]'] -Line 30: Unexpected errors ['./generics_typevartuple_variance.py:30:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTuple[*tuple[int, ...]], got generics_typevartuple_variance.ContravariantTypeVarTuple[tuple[object, ...]] [incompatible_assignment]'] -Line 33: Unexpected errors ['./generics_typevartuple_variance.py:33:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTuple[int], got generics_typevartuple_variance.ContravariantTypeVarTuple[tuple[int, ...]] [incompatible_assignment]'] -Line 43: Unexpected errors ['./generics_typevartuple_variance.py:43:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[object], got generics_typevartuple_variance.CovariantTypeVarTuple[int] [incompatible_assignment]'] -Line 44: Unexpected errors ['./generics_typevartuple_variance.py:44:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[int, int], got generics_typevartuple_variance.CovariantTypeVarTuple[bool, bool] [incompatible_assignment]'] -Line 49: Unexpected errors ['./generics_typevartuple_variance.py:49:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[*tuple[object, ...]], got generics_typevartuple_variance.CovariantTypeVarTuple[tuple[int, ...]] [incompatible_assignment]'] -Line 52: Unexpected errors ['./generics_typevartuple_variance.py:52:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[*tuple[int, ...]], got generics_typevartuple_variance.CovariantTypeVarTuple[int] [incompatible_assignment]'] -Line 84: Unexpected errors ['./generics_typevartuple_variance.py:84:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTupleOld[int], got generics_typevartuple_variance.ContravariantTypeVarTupleOld[object] [incompatible_assignment]'] -Line 98: Unexpected errors ['./generics_typevartuple_variance.py:98:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTupleOld[object], got generics_typevartuple_variance.CovariantTypeVarTupleOld[int] [incompatible_assignment]'] -Line 108: Unexpected errors ['./generics_typevartuple_variance.py:108:0: Incompatible assignment: expected generics_typevartuple_variance.InferredContravariantTypeVarTupleOld[int], got generics_typevartuple_variance.InferredContravariantTypeVarTupleOld[object] [incompatible_assignment]'] -Line 117: Unexpected errors ['./generics_typevartuple_variance.py:117:0: Incompatible assignment: expected generics_typevartuple_variance.InferredCovariantTypeVarTupleOld[object], got generics_typevartuple_variance.InferredCovariantTypeVarTupleOld[int] [incompatible_assignment]'] """ output = """ ./generics_typevartuple_variance.py:14:0: Incompatible assignment: expected generics_typevartuple_variance.InvariantTypeVarTuple[object], got generics_typevartuple_variance.InvariantTypeVarTuple[int] [incompatible_assignment] ./generics_typevartuple_variance.py:15:0: Incompatible assignment: expected generics_typevartuple_variance.InvariantTypeVarTuple[int], got generics_typevartuple_variance.InvariantTypeVarTuple[object] [incompatible_assignment] -./generics_typevartuple_variance.py:17:0: Incompatible assignment: expected generics_typevartuple_variance.InvariantTypeVarTuple[*tuple[int, ...]], got generics_typevartuple_variance.InvariantTypeVarTuple[tuple[object, ...]] [incompatible_assignment] -./generics_typevartuple_variance.py:18:0: Incompatible assignment: expected generics_typevartuple_variance.InvariantTypeVarTuple[*tuple[object, ...]], got generics_typevartuple_variance.InvariantTypeVarTuple[tuple[int, ...]] [incompatible_assignment] -./generics_typevartuple_variance.py:20:0: Incompatible assignment: expected generics_typevartuple_variance.InvariantTypeVarTuple[int], got generics_typevartuple_variance.InvariantTypeVarTuple[tuple[int, ...]] [incompatible_assignment] +./generics_typevartuple_variance.py:17:0: Incompatible assignment: expected generics_typevartuple_variance.InvariantTypeVarTuple[*tuple[int, ...]], got generics_typevartuple_variance.InvariantTypeVarTuple[*tuple[object, ...]] [incompatible_assignment] +./generics_typevartuple_variance.py:18:0: Incompatible assignment: expected generics_typevartuple_variance.InvariantTypeVarTuple[*tuple[object, ...]], got generics_typevartuple_variance.InvariantTypeVarTuple[*tuple[int, ...]] [incompatible_assignment] +./generics_typevartuple_variance.py:20:0: Incompatible assignment: expected generics_typevartuple_variance.InvariantTypeVarTuple[int], got generics_typevartuple_variance.InvariantTypeVarTuple[*tuple[int, ...]] [incompatible_assignment] ./generics_typevartuple_variance.py:21:0: Incompatible assignment: expected generics_typevartuple_variance.InvariantTypeVarTuple[*tuple[int, ...]], got generics_typevartuple_variance.InvariantTypeVarTuple[int] [incompatible_assignment] ./generics_typevartuple_variance.py:28:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTuple[object, object], got generics_typevartuple_variance.ContravariantTypeVarTuple[object, int] [incompatible_assignment] -./generics_typevartuple_variance.py:29:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTuple[int], got generics_typevartuple_variance.ContravariantTypeVarTuple[object] [incompatible_assignment] -./generics_typevartuple_variance.py:30:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTuple[*tuple[int, ...]], got generics_typevartuple_variance.ContravariantTypeVarTuple[tuple[object, ...]] [incompatible_assignment] -./generics_typevartuple_variance.py:31:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTuple[*tuple[object, ...]], got generics_typevartuple_variance.ContravariantTypeVarTuple[tuple[int, ...]] [incompatible_assignment] -./generics_typevartuple_variance.py:33:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTuple[int], got generics_typevartuple_variance.ContravariantTypeVarTuple[tuple[int, ...]] [incompatible_assignment] +./generics_typevartuple_variance.py:31:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTuple[*tuple[object, ...]], got generics_typevartuple_variance.ContravariantTypeVarTuple[*tuple[int, ...]] [incompatible_assignment] ./generics_typevartuple_variance.py:34:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTuple[*tuple[int, ...]], got generics_typevartuple_variance.ContravariantTypeVarTuple[int] [incompatible_assignment] ./generics_typevartuple_variance.py:42:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[int], got generics_typevartuple_variance.CovariantTypeVarTuple[object] [incompatible_assignment] -./generics_typevartuple_variance.py:43:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[object], got generics_typevartuple_variance.CovariantTypeVarTuple[int] [incompatible_assignment] -./generics_typevartuple_variance.py:44:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[int, int], got generics_typevartuple_variance.CovariantTypeVarTuple[bool, bool] [incompatible_assignment] ./generics_typevartuple_variance.py:45:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[int, int], got generics_typevartuple_variance.CovariantTypeVarTuple[bool, object] [incompatible_assignment] ./generics_typevartuple_variance.py:46:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[int, int], got generics_typevartuple_variance.CovariantTypeVarTuple[object, bool] [incompatible_assignment] ./generics_typevartuple_variance.py:47:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[int, int], got generics_typevartuple_variance.CovariantTypeVarTuple[object, object] [incompatible_assignment] -./generics_typevartuple_variance.py:48:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[*tuple[int, ...]], got generics_typevartuple_variance.CovariantTypeVarTuple[tuple[object, ...]] [incompatible_assignment] -./generics_typevartuple_variance.py:49:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[*tuple[object, ...]], got generics_typevartuple_variance.CovariantTypeVarTuple[tuple[int, ...]] [incompatible_assignment] -./generics_typevartuple_variance.py:51:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[int], got generics_typevartuple_variance.CovariantTypeVarTuple[tuple[int, ...]] [incompatible_assignment] -./generics_typevartuple_variance.py:52:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[*tuple[int, ...]], got generics_typevartuple_variance.CovariantTypeVarTuple[int] [incompatible_assignment] +./generics_typevartuple_variance.py:48:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[*tuple[int, ...]], got generics_typevartuple_variance.CovariantTypeVarTuple[*tuple[object, ...]] [incompatible_assignment] +./generics_typevartuple_variance.py:51:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTuple[int], got generics_typevartuple_variance.CovariantTypeVarTuple[*tuple[int, ...]] [incompatible_assignment] +./generics_typevartuple_variance.py:56:9: Bivariant types are not supported [incompatible_call] +./generics_typevartuple_variance.py:57:9: Type parameter cannot combine infer_variance with explicit variance [incompatible_call] +./generics_typevartuple_variance.py:58:9: Type parameter cannot combine infer_variance with explicit variance [incompatible_call] ./generics_typevartuple_variance.py:68:0: Incompatible assignment: expected generics_typevartuple_variance.InvariantTypeVarTupleOld[object], got generics_typevartuple_variance.InvariantTypeVarTupleOld[int] [incompatible_assignment] ./generics_typevartuple_variance.py:69:0: Incompatible assignment: expected generics_typevartuple_variance.InvariantTypeVarTupleOld[int], got generics_typevartuple_variance.InvariantTypeVarTupleOld[object] [incompatible_assignment] +./generics_typevartuple_variance.py:79:4: InTs has incompatible variance in method [invalid_annotation] ./generics_typevartuple_variance.py:83:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTupleOld[object], got generics_typevartuple_variance.ContravariantTypeVarTupleOld[int] [incompatible_assignment] -./generics_typevartuple_variance.py:84:0: Incompatible assignment: expected generics_typevartuple_variance.ContravariantTypeVarTupleOld[int], got generics_typevartuple_variance.ContravariantTypeVarTupleOld[object] [incompatible_assignment] +./generics_typevartuple_variance.py:90:4: OutTs has incompatible variance in method [invalid_annotation] ./generics_typevartuple_variance.py:97:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTupleOld[int], got generics_typevartuple_variance.CovariantTypeVarTupleOld[object] [incompatible_assignment] -./generics_typevartuple_variance.py:98:0: Incompatible assignment: expected generics_typevartuple_variance.CovariantTypeVarTupleOld[object], got generics_typevartuple_variance.CovariantTypeVarTupleOld[int] [incompatible_assignment] ./generics_typevartuple_variance.py:107:0: Incompatible assignment: expected generics_typevartuple_variance.InferredContravariantTypeVarTupleOld[object], got generics_typevartuple_variance.InferredContravariantTypeVarTupleOld[int] [incompatible_assignment] -./generics_typevartuple_variance.py:108:0: Incompatible assignment: expected generics_typevartuple_variance.InferredContravariantTypeVarTupleOld[int], got generics_typevartuple_variance.InferredContravariantTypeVarTupleOld[object] [incompatible_assignment] ./generics_typevartuple_variance.py:116:0: Incompatible assignment: expected generics_typevartuple_variance.InferredCovariantTypeVarTupleOld[int], got generics_typevartuple_variance.InferredCovariantTypeVarTupleOld[object] [incompatible_assignment] -./generics_typevartuple_variance.py:117:0: Incompatible assignment: expected generics_typevartuple_variance.InferredCovariantTypeVarTupleOld[object], got generics_typevartuple_variance.InferredCovariantTypeVarTupleOld[int] [incompatible_assignment] """ diff --git a/conformance/results/pycroscope/namedtuples_define_class.toml b/conformance/results/pycroscope/namedtuples_define_class.toml index 8cd3f9ab2..b09002fc2 100644 --- a/conformance/results/pycroscope/namedtuples_define_class.toml +++ b/conformance/results/pycroscope/namedtuples_define_class.toml @@ -1,15 +1,7 @@ -conformant = "Partial" -notes = """ -Does not support precise type inference for slices over namedtuples. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 30: Unexpected errors ['./namedtuples_define_class.py:30:12: tuple is not equivalent to tuple[int, int]'] -Line 31: Unexpected errors ['./namedtuples_define_class.py:31:12: tuple is not equivalent to tuple[int, int, str]'] """ output = """ -./namedtuples_define_class.py:30:12: tuple is not equivalent to tuple[int, int] -./namedtuples_define_class.py:31:12: tuple is not equivalent to tuple[int, int, str] ./namedtuples_define_class.py:33:6: Tuple index out of range: Literal[3] [incompatible_call] ./namedtuples_define_class.py:34:6: Tuple index out of range: Literal[-4] [incompatible_call] ./namedtuples_define_class.py:45:5: Missing required argument 'y' [incompatible_call] diff --git a/conformance/results/pycroscope/protocols_definition.toml b/conformance/results/pycroscope/protocols_definition.toml index d5e5f2dc7..ee40e33ff 100644 --- a/conformance/results/pycroscope/protocols_definition.toml +++ b/conformance/results/pycroscope/protocols_definition.toml @@ -1,10 +1,5 @@ -conformance_automated = "Fail" -conformant = "Partial" -notes = """ -Incorrectly accepts an instance-only attribute as satisfying a `ClassVar` protocol member. -""" +conformance_automated = "Pass" errors_diff = """ -Line 369: Expected 1 errors """ output = """ ./protocols_definition.py:30:10: Incompatible argument type for things: expected collections.abc.Iterable[./protocols_definition.py.SupportsClose] but got Literal[[1]] [incompatible_argument] @@ -28,5 +23,6 @@ output = """ ./protocols_definition.py:339:0: Incompatible assignment: expected ./protocols_definition.py.Template6, got ./protocols_definition.py.Concrete6_Bad1 [incompatible_assignment] ./protocols_definition.py:340:0: Incompatible assignment: expected ./protocols_definition.py.Template6, got ./protocols_definition.py.Concrete6_Bad2 [incompatible_assignment] ./protocols_definition.py:341:0: Incompatible assignment: expected ./protocols_definition.py.Template6, got ./protocols_definition.py.Concrete6_Bad3 [incompatible_assignment] +./protocols_definition.py:369:0: Incompatible assignment: expected ./protocols_definition.py.Template7, got ./protocols_definition.py.Concrete7_Bad1 [incompatible_assignment] ./protocols_definition.py:370:0: Incompatible assignment: expected ./protocols_definition.py.Template7, got ./protocols_definition.py.Concrete7_Bad2 [incompatible_assignment] """ diff --git a/conformance/results/pycroscope/protocols_generic.toml b/conformance/results/pycroscope/protocols_generic.toml index 9882a5578..be06306c6 100644 --- a/conformance/results/pycroscope/protocols_generic.toml +++ b/conformance/results/pycroscope/protocols_generic.toml @@ -1,15 +1,14 @@ conformant = "Partial" notes = """ -Fails to reject duplicate generic/protocol bases. Treats global object as a literal. """ conformance_automated = "Fail" errors_diff = """ -Line 44: Expected 1 errors Line 96: Unexpected errors ['./protocols_generic.py:96:12: Literal[] is not equivalent to protocols_generic.ConcreteHasParent'] """ output = """ ./protocols_generic.py:40:0: Incompatible assignment: expected protocols_generic.Proto1[int, str], got protocols_generic.Concrete1 [incompatible_assignment] +./protocols_generic.py:44:0: Protocol type parameter shorthand cannot be combined with Generic [invalid_base] ./protocols_generic.py:56:4: Incompatible assignment: expected protocols_generic.Box[int], got protocols_generic.Box[float | int] [incompatible_assignment] ./protocols_generic.py:66:4: Incompatible assignment: expected protocols_generic.Sender[float | int], got protocols_generic.Sender[int] [incompatible_assignment] ./protocols_generic.py:74:4: Incompatible assignment: expected protocols_generic.AttrProto[float | int], got protocols_generic.AttrProto[int] [incompatible_assignment] diff --git a/conformance/results/pycroscope/typeddicts_type_consistency.toml b/conformance/results/pycroscope/typeddicts_type_consistency.toml index cf2aaa072..06f5d3185 100644 --- a/conformance/results/pycroscope/typeddicts_type_consistency.toml +++ b/conformance/results/pycroscope/typeddicts_type_consistency.toml @@ -1,18 +1,14 @@ -conformant = "Partial" -notes = """ -Considers `TypedDict`s to be assignable to plain `dict` types. -""" -conformance_automated = "Fail" +conformance_automated = "Pass" errors_diff = """ -Line 76: Expected 1 errors -Line 78: Expected 1 errors -Line 82: Expected 1 errors """ output = """ ./typeddicts_type_consistency.py:21:0: Incompatible assignment: expected TypedDict({"x": int | None}), got TypedDict({"x": int}) [incompatible_assignment] ./typeddicts_type_consistency.py:38:0: Incompatible assignment: expected TypedDict({"x": NotRequired[int]}), got TypedDict({"x": int}) [incompatible_assignment] ./typeddicts_type_consistency.py:65:0: Incompatible assignment: expected TypedDict({"x": int, "y": int}), got TypedDict({"x": int}) [incompatible_assignment] ./typeddicts_type_consistency.py:69:0: Incompatible assignment: expected TypedDict({"x": int}), got Literal[{'x': 0, 'y': 0}] [incompatible_assignment] +./typeddicts_type_consistency.py:76:0: Incompatible assignment: expected dict[str, int], got TypedDict({"x": int, "y": int}) [incompatible_assignment] ./typeddicts_type_consistency.py:77:0: Incompatible assignment: expected dict[str, object], got TypedDict({"x": int, "y": int}) [incompatible_assignment] +./typeddicts_type_consistency.py:78:0: Incompatible assignment: expected dict[Any[explicit], Any[explicit]], got TypedDict({"x": int, "y": int}) [incompatible_assignment] +./typeddicts_type_consistency.py:82:0: Incompatible assignment: expected collections.abc.Mapping[str, int], got TypedDict({"x": int, "y": int}) [incompatible_assignment] ./typeddicts_type_consistency.py:126:0: Incompatible assignment: expected TypedDict({"outer_key": TypedDict({"inner_key": TypedDict({"inner_key": str})})}), got Literal[{'outer_key': {'inner_key': {'inner_key': 1}}}] [incompatible_assignment] """ diff --git a/conformance/results/pycroscope/version.toml b/conformance/results/pycroscope/version.toml index 8060c0669..e5d8a823f 100644 --- a/conformance/results/pycroscope/version.toml +++ b/conformance/results/pycroscope/version.toml @@ -1 +1 @@ -version = "pycroscope 0.4.0" +version = "pycroscope 0.5.0" diff --git a/conformance/results/results.html b/conformance/results/results.html index 0d37f6225..7915147fd 100644 --- a/conformance/results/results.html +++ b/conformance/results/results.html @@ -265,7 +265,7 @@

Python Type System Conformance Test Results

mypy 2.1.0 - pycroscope 0.4.0 + pycroscope 0.5.0 pyrefly 1.3.0-dev.1 pyright 1.1.410 ty 0.0.75 @@ -554,12 +554,7 @@

Python Type System Conformance Test Results

  • Does not fully support defaults on TypeVarTuple and ParamSpec.
  • - - Partial -
      -
    • Numerous issues; does not support TypeVarTuple and ParamSpec defaults.
    • -
    - + Pass Pass Pass @@ -580,12 +575,7 @@

    Python Type System Conformance Test Results

  • Does not correctly handle defaults referencing other TypeVars.
  • - - Partial -
      -
    • Fails to apply default specializations in some cases.
    • -
    - + Pass Pass Pass Pass @@ -613,7 +603,7 @@

    Python Type System Conformance Test Results

    generics_mixed_variance_inference Pass - Unsupported + Pass Unsupported Unsupported Pass @@ -663,7 +653,7 @@

    Python Type System Conformance Test Results

    generics_paramspec_variance Unsupported - Unsupported + Pass Unsupported Unsupported @@ -787,12 +777,7 @@

    Python Type System Conformance Test Results

  • Does not following runtime scoping rules for type parameters in all cases.
  • - - Partial -
      -
    • Misses some details of scoping rules.
    • -
    - + Pass Pass Pass Pass @@ -844,12 +829,7 @@

    Python Type System Conformance Test Results

  • Does not enforce that tuples captured by TypeVarTuple are same length.
  • - - Partial -
      -
    • Doesn't error when multiple type variable tuples appear in a PEP 695 type parameter list; only detects the Generic[...] form.
    • -
    - + Pass Pass Partial @@ -914,7 +894,7 @@

    Python Type System Conformance Test Results

    generics_typevartuple_variance Unsupported - Unsupported + Pass Unsupported Unsupported @@ -972,7 +952,7 @@

    Python Type System Conformance Test Results

    23.5 / 33 • 71.2% - 28 / 33 • 84.8% + 33 / 33 • 100.0% 30 / 33 • 90.9% 28.5 / 33 • 86.4% 30 / 33 • 90.9% @@ -1062,12 +1042,7 @@

    Python Type System Conformance Test Results

  • Does not reject use of ClassVar in TypeAlias definition.
  • - - Partial -
      -
    • Does not reject use of ClassVar as a qualifier for a NamedTuple field.
    • -
    - + Pass Pass Pass Pass @@ -1082,13 +1057,7 @@

    Python Type System Conformance Test Results

  • the incompatible constructor overrides in ChildC2 are not flagged.
  • - - Partial -
      -
    • Does not honor @override compatibility checks for __init__ and __new__:
    • -
    • the incompatible constructor overrides in ChildC2 are not flagged.
    • -
    - + Pass Pass Partial @@ -1109,7 +1078,7 @@

    Python Type System Conformance Test Results

    1 / 2 • 50.0% - 1 / 2 • 50.0% + 2 / 2 • 100.0% 2 / 2 • 100.0% 1.5 / 2 • 75.0% 1.5 / 2 • 75.0% @@ -1192,6 +1161,7 @@

    Python Type System Conformance Test Results

    Partial
    • Fails to reject various weird annotations.
    • +
    • Rejects a valid recursive generic type alias.
    Pass @@ -1213,12 +1183,7 @@

    Python Type System Conformance Test Results

  • Incorrectly rejects the use of a class-scoped TypeVar in a TypeAliasType definition.
  • - - Partial -
      -
    • Rejects valid ParamSpec specialization.
    • -
    - + Pass Pass Pass @@ -1241,7 +1206,7 @@

    Python Type System Conformance Test Results

    5.5 / 7 • 78.6% - 5.5 / 7 • 78.6% + 6 / 7 • 85.7% 7 / 7 • 100.0% 7 / 7 • 100.0% 4 / 7 • 57.1% @@ -1355,12 +1320,7 @@

    Python Type System Conformance Test Results

  • Does not detect protocol mismatch if concrete method's parameters are position-only.
  • - - Partial -
      -
    • Incorrectly accepts an instance-only attribute as satisfying a ClassVar protocol member.
    • -
    - + Pass Pass Pass Pass @@ -1392,7 +1352,6 @@

    Python Type System Conformance Test Results

    Partial
      -
    • Fails to reject duplicate generic/protocol bases.
    • Treats global object as a literal.
    @@ -1507,7 +1466,7 @@

    Python Type System Conformance Test Results

    9.5 / 11 • 86.4% - 9.5 / 11 • 86.4% + 10 / 11 • 90.9% 10.5 / 11 • 95.5% 10.5 / 11 • 95.5% 7.5 / 11 • 68.2% @@ -1529,12 +1488,7 @@

    Python Type System Conformance Test Results

  • Does not treat *args: Any, **kargs: Any as ... when separated by keyword parameter.
  • - - Partial -
      -
    • Does not support callback protocols with PEP 695 ParamSpec type parameters.
    • -
    - + Pass Pass Pass Pass @@ -1557,12 +1511,7 @@

    Python Type System Conformance Test Results

    callables_protocol Pass - - Partial -
      -
    • Does not support callback protocols with PEP 695 ParamSpec type parameters.
    • -
    - + Pass Pass Pass Pass @@ -1571,12 +1520,7 @@

    Python Type System Conformance Test Results

    callables_subtyping Pass - - Partial -
      -
    • Does not support callback protocols with PEP 695 ParamSpec type parameters.
    • -
    - + Pass Pass Pass Pass @@ -1585,7 +1529,7 @@

    Python Type System Conformance Test Results

    3 / 4 • 75.0% - 2.5 / 4 • 62.5% + 4 / 4 • 100.0% 4 / 4 • 100.0% 4 / 4 • 100.0% 4 / 4 • 100.0% @@ -2197,12 +2141,7 @@

    Python Type System Conformance Test Results

    typeddicts_type_consistency Pass - - Partial -
      -
    • Considers TypedDicts to be assignable to plain dict types.
    • -
    - + Pass Pass Pass Pass @@ -2220,7 +2159,7 @@

    Python Type System Conformance Test Results

    11.5 / 14 • 82.1% - 13.5 / 14 • 96.4% + 14 / 14 • 100.0% 14 / 14 • 100.0% 13.5 / 14 • 96.4% 14 / 14 • 100.0% @@ -2296,12 +2235,7 @@

    Python Type System Conformance Test Results

  • Does not support version-conditional fields.
  • - - Partial -
      -
    • Does not support precise type inference for slices over namedtuples.
    • -
    - + Pass Pass Pass Pass @@ -2342,7 +2276,7 @@

    Python Type System Conformance Test Results

    3 / 4 • 75.0% - 3.5 / 4 • 87.5% + 4 / 4 • 100.0% 4 / 4 • 100.0% 4 / 4 • 100.0% 4 / 4 • 100.0% @@ -2367,12 +2301,7 @@

    Python Type System Conformance Test Results

    enums_definition Pass - - Partial -
      -
    • Does not allow enum members to be conditional on version/platform checks.
    • -
    - + Pass Pass Pass Pass @@ -2453,7 +2382,7 @@

    Python Type System Conformance Test Results

    4.5 / 6 • 75.0% - 5.5 / 6 • 91.7% + 6 / 6 • 100.0% 6 / 6 • 100.0% 5.5 / 6 • 91.7% 6 / 6 • 100.0% @@ -2537,12 +2466,7 @@

    Python Type System Conformance Test Results

    directives_disjoint_base Pass - - Partial -
      -
    • Does not reject invalid class definitions due to disjoint bases, but uses disjoint base information in type narrowing.
    • -
    - + Pass Pass Unsupported @@ -2641,7 +2565,7 @@

    Python Type System Conformance Test Results

    10 / 11 • 90.9% - 10.5 / 11 • 95.5% + 11 / 11 • 100.0% 11 / 11 • 100.0% 10 / 11 • 90.9% 10.5 / 11 • 95.5% @@ -2684,7 +2608,7 @@

    Python Type System Conformance Test Results

    108.5 / 145 • 74.8% - 127.5 / 145 • 87.9% + 138 / 145 • 95.2% 140.5 / 145 • 96.9% 135.5 / 145 • 93.4% 132 / 145 • 91.0% diff --git a/conformance/uv.lock b/conformance/uv.lock index f638ac45a..dcf5fc26d 100644 --- a/conformance/uv.lock +++ b/conformance/uv.lock @@ -148,15 +148,15 @@ wheels = [ [[package]] name = "pycroscope" -version = "0.4.0" +version = "0.5.0" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "typeshed-client" }, { name = "typing-extensions" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/7c/8e/284fdc4027bf9a7c92f8256ff07006a50456ccd2ce5506d040e6ed2f2f1b/pycroscope-0.4.0.tar.gz", hash = "sha256:14b40e36f6186dd2eff712c8da91d02eb89a263a257472b49f4c59153ff380fb", size = 662901, upload-time = "2026-05-02T14:00:43.775Z" } +sdist = { url = "https://files.pythonhosted.org/packages/9d/67/c5cb4c78c1f50f905902fb8f5ff7dcd5c321b75f1ee123354ae9f26b364f/pycroscope-0.5.0.tar.gz", hash = "sha256:573eb605f49b97e6ff5d85af115de0406b475a239d9cb3db00ccec2ef97a62ba", size = 696137, upload-time = "2026-08-27T18:13:38.707Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/50/5f/c172c08b69e29d4094e1466b63260d8daf61a3ed3c689de7936f952f1663/pycroscope-0.4.0-py3-none-any.whl", hash = "sha256:cb7440b44ed16ed927995c33867cab22503f4bff7efe504964b81fb967183223", size = 714256, upload-time = "2026-05-02T14:00:41.891Z" }, + { url = "https://files.pythonhosted.org/packages/4c/d1/873dac15d2a9f059b5dfb2fdae56d57378023f137d73d61bea5d085e0835/pycroscope-0.5.0-py3-none-any.whl", hash = "sha256:effc2fc347c2b6175bacdd5aad8e242392eba075d22832b441c0c6ecbc7f6517", size = 747967, upload-time = "2026-08-27T18:13:37.043Z" }, ] [[package]]