Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[ty] Avoid AST load for callable description names#25728

Merged
charliermarsh merged 1 commit into
mainfrom
charlie/avoid-call-diagnostic-ast-loads
Jun 7, 2026
Merged

[ty] Avoid AST load for callable description names#25728
charliermarsh merged 1 commit into
mainfrom
charlie/avoid-call-diagnostic-ast-loads

Conversation

@charliermarsh

@charliermarsh charliermarsh commented Jun 7, 2026

Copy link
Copy Markdown
Member

Summary

CallableDescription loaded the parsed module only to read the enclosing class name when formatting Class.method for function and bound-method diagnostics.

This now recovers the enclosing class from the semantic index and formats the name from the original class type metadata, avoiding that direct AST node lookup while preserving the same display text.

@astral-sh-bot astral-sh-bot Bot added the ty Multi-file analysis & type inference label Jun 7, 2026
@astral-sh-bot

astral-sh-bot Bot commented Jun 7, 2026

Copy link
Copy Markdown

Typing conformance results

No changes detected ✅

Current numbers
The percentage of diagnostics emitted that were expected errors held steady at 92.16%. The percentage of expected errors that received a diagnostic held steady at 87.31%. The number of fully passing files held steady at 92/134.

@astral-sh-bot

astral-sh-bot Bot commented Jun 7, 2026

Copy link
Copy Markdown

Memory usage report

Memory usage unchanged ✅

@astral-sh-bot

astral-sh-bot Bot commented Jun 7, 2026

Copy link
Copy Markdown

ecosystem-analyzer results

No diagnostic changes detected ✅

Full report with detailed diff (timing results)

@charliermarsh charliermarsh force-pushed the charlie/avoid-call-diagnostic-ast-loads branch from 6bdd271 to 76d1bdb Compare June 7, 2026 17:45
@charliermarsh charliermarsh changed the title [ty] Avoid direct AST loads in callable diagnostics [ty] Avoid AST load for callable description names Jun 7, 2026
@charliermarsh charliermarsh marked this pull request as ready for review June 7, 2026 17:55
@charliermarsh charliermarsh merged commit 89a2816 into main Jun 7, 2026
59 checks passed
@charliermarsh charliermarsh deleted the charlie/avoid-call-diagnostic-ast-loads branch June 7, 2026 18:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ty Multi-file analysis & type inference

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants