[codex] Fix duplicate timeline placeholder cards#145
Merged
utopiafar merged 1 commit intoMay 18, 2026
Conversation
PR Preflight Summary / PR 预检汇总中文
English
PR Policy Preflight / PR 规则预检PR Policy Preflight / PR 规则预检中文
未发现确定性规则问题。 English
No deterministic policy findings. PR Flutter Quality / Flutter 质量预检PR Flutter Quality / Flutter 质量预检中文
English
Flutter Analyzer Baseline
No new analyzer issues introduced by this PR. Flutter Test Baseline
No new Flutter test failures introduced by this PR. |
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.
Summary
TimelineCardModel.id.Root Cause
A newly submitted card can enter the TimelineViewModel from more than one local UI/update path while it is still in
processingstate.addCard()always inserted at index 0, so two copies of the same fact id could be visible until a later refresh or completed card update rebuilt the list from storage.Validation
dart pub get --offline --no-exampleflutter test --no-pub test/ui/timelinedart analyze lib/ui/timeline/view_models/timeline_viewmodel.dart lib/ui/timeline/widgets/timeline_screen.dart test/ui/timeline/view_models/timeline_viewmodel_test.dart test/ui/timeline/widgets/timeline_entry_dedupe_test.dart(passes with existing info-leveltimeline_screen.dartwarnings for deprecatedwithOpacityand one existing async-context lint)git diff --cached --check