chore(deps): update dependency ty to >=0.0.39#128
Open
renovate[bot] wants to merge 1 commit into
Open
Conversation
7fd4be5 to
87a8021
Compare
87a8021 to
1e7cf0d
Compare
1e7cf0d to
b42710f
Compare
cab86d6 to
201c531
Compare
201c531 to
6e11d65
Compare
6e11d65 to
9c089c7
Compare
9c089c7 to
73a08bf
Compare
73a08bf to
72ab8f0
Compare
72ab8f0 to
c0b2d52
Compare
c0b2d52 to
726f5ca
Compare
726f5ca to
8262302
Compare
8262302 to
ecf847c
Compare
ecf847c to
f1fab9b
Compare
f1fab9b to
8a0fe03
Compare
8a0fe03 to
cb29317
Compare
cb29317 to
ba66250
Compare
ba66250 to
d9bc56f
Compare
d9bc56f to
287166b
Compare
287166b to
7a051a2
Compare
7a051a2 to
cf70eba
Compare
cf70eba to
27ace02
Compare
27ace02 to
fb7850d
Compare
fb7850d to
93858d0
Compare
93858d0 to
4149036
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
>=0.0.13→>=0.0.39Release Notes
astral-sh/ty (ty)
v0.0.39Compare Source
Released on 2026-05-22.
This release removes the Python 3.9 branches from our vendored standard library stubs. ty now only has "full" support for
Python 3.10 and later, but will still report version-specific syntax errors and other diagnostics when
--python-version 3.9is provided via the CLI.
Bug fixes
__new__assignments to classes (#25282)dict-compatible fallbacks in TypedDict unions (#25242)LSP server
Diagnostics
Performance
Core type checking
self(#25077)order=True(#21704)dict(TypedDict)asdict[str, object](#24852)Contributors
v0.0.38Compare Source
Released on 2026-05-19.
Bug fixes
NewTypebase expansion during cycle recovery (#25234)_generate_next_value_with custom construction hooks (#25210)LSP server
excepthandlers (#25231).gitignorechanges (#25183)Core type checking
_generate_next_value_methods in enums (#25196)Contributors
v0.0.37Compare Source
Released on 2026-05-16.
Bug fixes
not innarrowing (#25161)__new__(#25185)reveal_protocol,reveal_mro, etc. with keyword arguments (#25179)LSP server
Core type checking
__new__with custom metaclasses (#25180)Contributors
v0.0.36Compare Source
Released on 2026-05-14.
Bug fixes
ClassVar[Self]assignment checks for class objects (#24657)Callable-bounded TypeVars (#24793)Selffields (#25094)args[0]forstatic_assert(#25149)TypeOfrecursion in generic callables (#24668)LSP server
includeDeclarationrequest parameter (#24960)Performance
Core type checking
__new__values as dynamic (#25136)Contributors
v0.0.35Compare Source
Released on 2026-05-10.
Bug fixes
LSP server
CLI
Core type checking
__class__checks (#24997)Diagnostics
Performance
Contributors
v0.0.34Compare Source
Released on 2026-05-01.
Bug fixes
LSP server
Annotatedmetadata in semantic tokens (#24890)Core type checking
functools.partial(#24582)TypeIsassignability with gradual types (#24928)dict(**TypedDict)inTypedDictcontext (#24709)infer_variancefor legacyTypeVar(#24930)ParamSpec(#24927)UnionofTypedDictin various sites (#24958)Diagnostics
Performance
Contributors
v0.0.33Compare Source
Released on 2026-04-28.
Notable changes
ty now prefers the declared type of an annotated assignment in more situations (#24802).
Consider this example:
ty previously favored the inferred type of the right hand side expression when
thresholdandresultwere used. This is useful forthreshold, as it allows something likethreshold += 1to work without an error: we know thatthresholdcould later becomeNone, but right now, we see that it is anint. However, forresult, the inferred type isUnknown. This is not a useful type and it can lead to false negatives. Starting with this release, ty will therefore preferthe declared type if the inferred and declared types are mutually assignable. In the above example,
thresholdwill still be inferred asint(or ratherLiteral[1]), butresultwill now be inferred asstr. If you previously addedcasts to work around this behavior, you should be able to remove them after upgrading.Bug fixes
LSP server
Core type checking
finallyblocks where alltry/exceptblocks are terminal (#24882)ClassVarvs instance-attribute overrides (#24767)Unpack[...](#24868)Callabletype context (#24317)**unpacking ofTypedDictin dict-literal assignments (#24703)Unpack[TypedDict]in**kwargssignatures (#24653)[*xs]as an irrefutable pattern when matching onSequence(#24787)Diagnostics
invalid-return-typediagnostics,invalid-yielddiagnostics, attribute assignment diagnostics (#24770, #24771)dictassignment error diagnostics (#24768)invalid-keydiagnostics for unions of TypedDicts (#24693)invalid-type-formdiagnostics for PEP-613 type alias values (#24760)Performance
Other changes
Contributors
v0.0.32Compare Source
Released on 2026-04-20.
Bug fixes
__get__usesConcatenateself-type and wraps a__call__(#24692)Callabletype context (#24661)LSP server
@overload-decorated function has no docstring (#23920)Core type checking
ifstatements in TypedDict bodies (#24702)@disjoint_baseon TypedDicts and Protocols (#24671)@dataclass_transform-decorated class to have dataclass-like semantics if it hastypein its MRO (#24679)Neversetters or deleters (#24510)Diagnostics
Performance
Contributors
v0.0.31Compare Source
Released on 2026-04-15.
Bug fixes
namedtuple(typename=T, field_names=x, **{})(#24641)Enum(...)names (#24638)Enum(value=...)(#24639)invalid-keyfix doesn't converge, andoverride-of-final-methodproduces invalid syntax (#24649)ty:ignorecomments inserted by--add-ignorefor diagnostics starting on the same line (#24651)CLI
--fixmode to enable auto-fix for diagnostics (#24097)Performance
Core type checking
NamedTuplefield conflicts (#24542)EnumMeta.__call__for enum constructor signatures (#24513)Contributors
v0.0.30Compare Source
Released on 2026-04-13.
As of v0.0.30, ty no longer unions
Unknowninto most inferred types of unannotated attributes. For example:In previous versions,
reveal_type(Foo().value)would have includedUnknown, so the assignment to"x"would not have been flagged. Since this can affect inferred attribute types throughout a codebase, upgrading may lead to both new and resolved diagnostics. Initializers ofNoneand other non-literal singleton types remain exceptions. See #24531 for details.Bug fixes
ParamSpecinConcatenateprefixes (#24474)Callabletypes (#24497)TYPE_CHECKINGstate from outer blocks (#24470)__init_subclass__calls (#24541)type[T]to a metaclass (#24515)ParamSpec-specialized class calls (#24399)TypedDictfield types as type context to inform the inference of arguments passed toTypedDictconstructors (#24422)LSP server
typingandcollectionshigher than third party re-exports (#23643)TypedDictconstructor support in the LSP by synthesizing__init__(#24476, #24522, #24535)infosubdiagnostics in LSP diagnostic messages (#24328)Diagnostics
Core type checking
Enum(...)syntax (#23602, #24570, #24571)Finalvariable assignments in__post_init__(#24529)type[...]annotations, e.g.type["MyClass"](#24518)__init_subclass__ = None(#24543)TypeGuardandTypeIsnarrowing for unbound method calls (#24612)list[int][0]leads to 1 diagnostic, rather than 2 (#24354)dataclass_transformmetadata from metaclass bases (#24615)Noneaccessors in manual property construction (#24492)Finalattributes (#24508)TypedDictunpacking (#24446)strconstructor (#24514)Unknowninto types of un-annotated attributes (#24531)super()in metaclass methods (#24483)Concatenatetype-expression parsing (#24172)if TYPE_CHECKINGblock (#24394)Contributors
v0.0.29Compare Source
Released on 2026-04-05.
Bug fixes
dataclasses.fieldif it's not infield_specifiers(#24397)environment.python-versionvalues in configuration files (#24402)requires-python(#24401)Core type checking
types.new_class(#23144)withstatement (#24395)__new__and metaclass__call__return types (#24357)Contributors
v0.0.28Compare Source
Released on 2026-04-02.
Bug fixes
LSP server
Core type checking
extra_itemskeyword argument to class-based TypedDicts as an annotation expression (#24362)x: list[int | None] = [None] * 2(#24197)infer_type_expressionfor parsing parameter annotations and return-type annotations (#24353)infer_type_expressionfor validating PEP-613 type aliases (#24370)extra_itemskeyword to functional TypedDicts (#24360)TypedDicts (#24345)Contributors
v0.0.27Compare Source
Released on 2026-03-31.
Bug fixes
list[int]<CURSOR>()(#24167)list[Annotated[()]](#24303)type A = TypeIs[Callable[[], A]](#24245)_clsas the name of the first argument for synthesizedcollections.namedtupleconstructor methods (#24333)LSP server
Core type checking
get()defaults (#24231)pop()defaults (#24229)Finalattribute assignment rules for annotated and augmented writes (#23880)Callabletype context (#23888)Callabletype context (#22633)awaitexpressions (#24256)Finalwhen emitting a diagnostic about aFinalvariable being reassigned (#24194)Contributors
v0.0.26Compare Source
Released on 2026-03-26.
Bug fixes
Core type checking
typing.Concatenate(#23689)converters (#23088)Selfin metaclass and static methods (#23231)dict()(#24103)dataclass_transformparams (#24170)Performance
Literaltype(#24185)Contributors
v0.0.25Compare Source
Released on 2026-03-24.
Breaking changes
type:ignore[ty:code]suppressions (#24096)Bug fixes
TypedDict | dictunions (#24151)NewTypes of unions vs. unions (#24087)N & ~TtoNeverifB & ~Twould simplify toNever, whereBis the concrete base type of aNewTypeN(#24086)LSP
Type checking
TypedDictupdate (#24101)TypedDictupdates (#24128)reveal_typediagnostics in unreachable code (#24070)isinstance()reachability analysis (#24077)yieldexpression types (#23796)invalid-metaclass(#24145)Never(#24056)Contributors
v0.0.24Compare Source
Released on 2026-03-19.
Bug fixes
TypedDictsubscripts for unknown keys returnUnknown(#23926)TypeIs(#23784)LSP server
Core type checking
/usr/local/libdist-packages on Debian/Ubuntu (#23797)v0.0.23Compare Source
Released on 2026-03-13.
Bug fixes
from __future__ import annotationsis active (#23915)dataclass_transform: Respectkw_onlyoverwrites in dataclasses (#23930)Literaltypes (#23875)Server
#(#23831)Configuration
📅 Schedule: (UTC)
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.