Skip to content

Conversation

@MichaReiser
Copy link
Member

@MichaReiser MichaReiser commented Dec 8, 2025

Summary

Addresses the 'too many "Python 3.7 was assumed" diagnostics issue raised in this comment

We already skip the primary annotation when creating related diagnostics for the main diagnostic, but we failed to do so for sub-diagnostics, which results in duplicated related information diagnostics.

We need to skip the primary annotation because we already use that range when generating related information for the subdiagnostic.

Test Plan

Screenshot 2025-12-08 at 14 48 57

@MichaReiser MichaReiser added the server Related to the LSP server label Dec 8, 2025
@MichaReiser MichaReiser requested a review from dcreager as a code owner December 8, 2025 13:48
@MichaReiser MichaReiser added the ty Multi-file analysis & type inference label Dec 8, 2025
@astral-sh-bot
Copy link

astral-sh-bot bot commented Dec 8, 2025

Diagnostic diff on typing conformance tests

No changes detected when running ty on typing conformance tests ✅

@astral-sh-bot

This comment was marked as off-topic.

@astral-sh-bot
Copy link

astral-sh-bot bot commented Dec 8, 2025

ruff-ecosystem results

Linter (stable)

✅ ecosystem check detected no linter changes.

Linter (preview)

✅ ecosystem check detected no linter changes.

Copy link
Member

@AlexWaygood AlexWaygood left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!!

@MichaReiser MichaReiser merged commit 4364ffb into main Dec 8, 2025
43 checks passed
@MichaReiser MichaReiser deleted the micha/filter-primary-annotations branch December 8, 2025 14:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

server Related to the LSP server ty Multi-file analysis & type inference

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants