Remove dedicated History page - #28
Conversation
|
Warning Review limit reachedYou’ve reached a temporary PR review limit under our Fair Usage Limits Policy. Next review available in: 32 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (2)
📝 WalkthroughWalkthroughThe dedicated History page, navigation entry, styles, and localization keys are removed. Recent scans now use a singleton service fed by synchronized queue events, retain five deduplicated results, and update the Scan page through change notifications. Tests and documentation reflect the revised workflow. ChangesRecent scans workflow
Estimated code review effort: 3 (Moderate) | ~20 minutes Sequence Diagram(s)sequenceDiagram
participant ItemQueue
participant RecentScansService
participant ScanPage
ItemQueue->>RecentScansService: Publish enqueued scan batch
RecentScansService->>RecentScansService: Deduplicate and retain five results
RecentScansService->>ScanPage: Raise Changed
ScanPage->>ScanPage: Refresh recent scans
Possibly related PRs
Suggested labels: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
🏁 CodeAnt Quality Gate ResultsCommit: ✅ Overall Status: PASSEDQuality Gate Details
|
There was a problem hiding this comment.
1 issue found and verified against the latest diff
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="src/App/Presentation/RecentScansService.cs">
<violation number="1" location="src/App/Presentation/RecentScansService.cs:44">
P2: Clicking an existing recent item leaves its position unchanged, so the promised promote-on-reselect behavior is missing: `SelectRecent` cannot call this now-private `Record` and only changes the displayed result. Exposing a promotion operation or otherwise recording from `SelectRecent` would move the selected snapshot to the front without adding a duplicate.</violation>
</file>
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
| } | ||
|
|
||
| internal void Record(ScanResultViewModel result) | ||
| private void Record(ScanResultViewModel result) |
There was a problem hiding this comment.
P2: Clicking an existing recent item leaves its position unchanged, so the promised promote-on-reselect behavior is missing: SelectRecent cannot call this now-private Record and only changes the displayed result. Exposing a promotion operation or otherwise recording from SelectRecent would move the selected snapshot to the front without adding a duplicate.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At src/App/Presentation/RecentScansService.cs, line 44:
<comment>Clicking an existing recent item leaves its position unchanged, so the promised promote-on-reselect behavior is missing: `SelectRecent` cannot call this now-private `Record` and only changes the displayed result. Exposing a promotion operation or otherwise recording from `SelectRecent` would move the selected snapshot to the front without adding a duplicate.</comment>
<file context>
@@ -21,37 +23,36 @@ internal IReadOnlyList<ScanResultViewModel> Items
}
- internal void Record(ScanResultViewModel result)
+ private void Record(ScanResultViewModel result)
{
lock (_sync)
</file context>
There was a problem hiding this comment.
1 issue found across 2 files (changes from recent commits).
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="src/App/Scan/ItemQueue.cs">
<violation number="1" location="src/App/Scan/ItemQueue.cs:61">
P2: A delayed notification can observe mutations to the caller-owned `items` list, so Recent scans may omit or include the wrong entries when `EnqueueRange` overlaps another notification drain. Copy the batch before queueing the notification to preserve the exact enqueue snapshot.</violation>
</file>
Tip: Review your code locally with the cubic CLI to iterate faster.
Re-trigger cubic
| lock (enqueueSync) | ||
| { | ||
| items.ForEach(queue.Enqueue); | ||
| pendingNotifications.Enqueue(items); |
There was a problem hiding this comment.
P2: A delayed notification can observe mutations to the caller-owned items list, so Recent scans may omit or include the wrong entries when EnqueueRange overlaps another notification drain. Copy the batch before queueing the notification to preserve the exact enqueue snapshot.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At src/App/Scan/ItemQueue.cs, line 61:
<comment>A delayed notification can observe mutations to the caller-owned `items` list, so Recent scans may omit or include the wrong entries when `EnqueueRange` overlaps another notification drain. Copy the batch before queueing the notification to preserve the exact enqueue snapshot.</comment>
<file context>
@@ -36,23 +38,64 @@ internal bool PruneExpired(long now)
{
items.ForEach(queue.Enqueue);
- ItemsEnqueued?.Invoke(items);
+ pendingNotifications.Enqueue(items);
+ shouldDrain = !isDrainingNotifications;
+ isDrainingNotifications = true;
</file context>
| pendingNotifications.Enqueue(items); | |
| pendingNotifications.Enqueue(items.ToArray()); |
Summary
RecentScansServiceand remove page-only localizationRuntime verification
Verified against the real WPF-hosted Blazor application with an isolated WebView2 profile:
/app/historyrenders the application not-found pageValidation
Closes #20