Repository navigation
Keep a macro filter from being replaced by an earlier list reload - #1326
Merged
AgreeDK merged 1 commit intoNov 17, 2026
Merged
Conversation
A macro calling opensak.clear_filter() and then opensak.filter{} showed
the filtered list at once. The full list that clear_filter() had started
loading in the background then arrived and replaced it. The grid showed
every cache while the filter, and the red clear button, stayed active.
It happened only sometimes: opensak.progress lets queued events run, so
a load that finished during the macro's loop arrived early and did no
harm. On large databases the load often finished later.
The background reload result is discarded only when a newer reload has
been requested. Showing a filter result, or reloading the table after an
import, filled the grid directly without making the running reload
stale. Both now do, through the new _discard_pending_refreshes().
fixes OpenSAK-Org#1325
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.
Keep a macro filter from being replaced by an earlier list reload
A macro calling opensak.clear_filter() and then opensak.filter{} showed
the filtered list at once. The full list that clear_filter() had started
loading in the background then arrived and replaced it. The grid showed
every cache while the filter, and the red clear button, stayed active.
It happened only sometimes: opensak.progress lets queued events run, so
a load that finished during the macro's loop arrived early and did no
harm. On large databases the load often finished later.
The background reload result is discarded only when a newer reload has
been requested. Showing a filter result, or reloading the table after an
import, filled the grid directly without making the running reload
stale. Both now do, through the new _discard_pending_refreshes().
fixes #1325