[ty] Add caching to CodeGeneratorKind::matches()#19901
Closed
AlexWaygood wants to merge 1 commit intoalex/namedtuple-propertiesfrom
Closed
[ty] Add caching to CodeGeneratorKind::matches()#19901AlexWaygood wants to merge 1 commit intoalex/namedtuple-propertiesfrom
CodeGeneratorKind::matches()#19901AlexWaygood wants to merge 1 commit intoalex/namedtuple-propertiesfrom
Conversation
Contributor
Diagnostic diff on typing conformance testsChanges were detected when running ty on typing conformance tests--- old-output.txt 2025-08-13 21:44:24.067127850 +0000
+++ new-output.txt 2025-08-13 21:44:24.137128742 +0000
@@ -1,5 +1,5 @@
WARN ty is pre-release software and not ready for production use. Expect to encounter bugs, missing features, and fatal errors.
-fatal[panic] Panicked at /home/runner/.cargo/git/checkouts/salsa-e6f3bb7c2a062968/918d35d/src/function/execute.rs:215:25 when checking `/home/runner/work/ruff/ruff/typing/conformance/tests/aliases_typealiastype.py`: `infer_definition_types(Id(4c9d)): execute: too many cycle iterations`
+fatal[panic] Panicked at /home/runner/.cargo/git/checkouts/salsa-e6f3bb7c2a062968/918d35d/src/function/execute.rs:215:25 when checking `/home/runner/work/ruff/ruff/typing/conformance/tests/aliases_typealiastype.py`: `infer_definition_types(Id(acd1)): execute: too many cycle iterations`
_directives_deprecated_library.py:15:31: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `int`
_directives_deprecated_library.py:30:26: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `str`
_directives_deprecated_library.py:36:41: error[invalid-return-type] Function always implicitly returns `None`, which is not assignable to return type `Self@__add__` |
Contributor
|
8a953bc to
cccdaff
Compare
be3e7a2 to
9a70798
Compare
cccdaff to
8253fce
Compare
carljm
approved these changes
Aug 13, 2025
Contributor
carljm
left a comment
There was a problem hiding this comment.
Were cycles observed here, or are you adding the cycle handling pre-emptively?
Member
Author
|
Cycles were indeed observed! See e.g. https://github.com/astral-sh/ruff/actions/runs/16944090646/job/48020592511 |
Member
Author
|
I split this out as a standalone change in #19912 |
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.
Summary
Stacked on top of #19899.
There are some small performance regressions in the Codspeed report for #19899 -- this appears to mitigate that!
Test Plan
Existing tests