Skip to content

Fix stale diagnostics in Ruff playground #17583

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 23, 2025

Conversation

MichaReiser
Copy link
Member

@MichaReiser MichaReiser commented Apr 23, 2025

Summary

Fix stale diagnostics in the Ruff playground.

It was possible that diagnostics accumulated when two diagnostics had the same code, row, and column because
we used that information as the React key (which has to be unique).

This PR uses a disambiguator if two diagnostics have the same code, row, and column information.

Test Plan

Screen.Recording.2025-04-23.at.15.23.15.mov

@MichaReiser MichaReiser added the playground A playground-specific issue label Apr 23, 2025
@MichaReiser MichaReiser force-pushed the micha/fix-duplicate-key-error branch from 2699e99 to a455a90 Compare April 23, 2025 13:25
@MichaReiser MichaReiser force-pushed the micha/fix-duplicate-key-error branch from a455a90 to 085b182 Compare April 23, 2025 13:30
@MichaReiser MichaReiser merged commit 624f5c6 into main Apr 23, 2025
33 checks passed
@MichaReiser MichaReiser deleted the micha/fix-duplicate-key-error branch April 23, 2025 13:47
dcreager added a commit that referenced this pull request Apr 23, 2025
…tructor

* origin/main:
  [red-knot] Trust module-level undeclared symbols in stubs (#17577)
  [`airflow`] Apply auto fixes to cases where the names have changed in Airflow 3 (`AIR301`) (#17355)
  [`pycodestyle`] Auto-fix redundant boolean comparison (`E712`) (#17090)
  [red-knot] Detect semantic syntax errors (#17463)
  Fix stale diagnostics in Ruff playground (#17583)
  [red-knot] Early return from `project.is_file_open` for vendored files (#17580)
dcreager added a commit that referenced this pull request Apr 23, 2025
…var-instance

* dcreager/generic-constructor:
  Revert FunctionLiteral type
  [red-knot] Trust module-level undeclared symbols in stubs (#17577)
  [`airflow`] Apply auto fixes to cases where the names have changed in Airflow 3 (`AIR301`) (#17355)
  [`pycodestyle`] Auto-fix redundant boolean comparison (`E712`) (#17090)
  Clean this up a bit
  clippy
  [red-knot] Detect semantic syntax errors (#17463)
  Fix stale diagnostics in Ruff playground (#17583)
  [red-knot] Early return from `project.is_file_open` for vendored files (#17580)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
playground A playground-specific issue
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant