Repository navigation
Fix stale Git diff updates after mode changes and close - #9750
Open
emilianbold wants to merge 2 commits into
Open
emilianbold wants to merge 2 commits into
emilianbold wants to merge 2 commits into
Conversation
Invalidate obsolete refresh generations at EDT publication, cancel the preparation worker as well as its task wrapper, and prevent late views and listeners from being installed after close. Add latch-gated controller regressions for mode changes, queued refresh publication after close, and in-flight diff preparation cancellation. Verified the three regressions plus existing test193781 against the compiled controller using NetBeans 31 dependency jars on JDK 21. Assisted-by: DeepSeek V4.1 Flash Assisted-by: OpenAI GPT-6.1 Sol
Capture the generation at the two preparation call sites and pass it into DiffPrepareTask instead of reading outer controller state in its constructor. Leave the reusable refresh and change workers unchanged. Assisted-by: DeepSeek V4.1 Flash Assisted-by: OpenAI GPT-6.1 Sol
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.
Fixes stale Git Diff updates when a refresh result is published after the comparison mode changes or the window closes. Refresh work now carries a generation that is checked at the EDT publication boundary, close is terminal, and the diff-preparation worker is cancelled directly instead of only cancelling its RequestProcessor task.
Adds three latch-gated regressions covering obsolete-mode publication, publication after close, and in-flight preparation after close.
Verified with the full
ide/git test-unitsuite.Assisted-by: DeepSeek V4.1 Flash
Assisted-by: OpenAI GPT-6.1 Sol