Skip to content

fix: cancel offscreen media downloads#476

Merged
mubarakcoded merged 2 commits into
masterfrom
pip/whitenoise-mac-468
Jul 13, 2026
Merged

fix: cancel offscreen media downloads#476
mubarakcoded merged 2 commits into
masterfrom
pip/whitenoise-mac-468

Conversation

@agent-p1p

@agent-p1p agent-p1p commented Jul 12, 2026

Copy link
Copy Markdown
Contributor

Summary

  • retain each tile's automatic media download task
  • cancel queued or in-flight work when the tile scrolls out, disappears, or changes attachment
  • add a regression check for the SwiftUI cancellation wiring

Test plan

  • source contract regression check passes
  • git diff --check
  • macOS build/tests deferred to GitHub CI (Xcode unavailable on Linux)

Fixes #468


Open in Stage

Retain each tile's automatic download task and cancel it when the tile leaves the viewport, disappears, or changes attachment identity. This removes cancelled waiters from the download limiter so visible media is not stuck behind scrolled-past work.

Fixes #468
@coderabbitai

coderabbitai Bot commented Jul 12, 2026

Copy link
Copy Markdown

Warning

Review limit reached

@mubarakcoded, you've reached your PR review limit, so we couldn't start this review.

Next review available in: 50 minutes

Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available.
You're only billed for reviews past your plan's rate limits ($0.25/file).

How can I continue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

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 configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: b1b6c775-6e75-4183-ac37-8057457fbd8c

📥 Commits

Reviewing files that changed from the base of the PR and between 490ca5b and 04948d8.

📒 Files selected for processing (2)
  • whitenoise-mac/Views/MessageMediaViews.swift
  • whitenoise-macTests/whitenoise_macTests.swift
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch pip/whitenoise-mac-468

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@stage-review

stage-review Bot commented Jul 12, 2026

Copy link
Copy Markdown

Ready to review this PR? Stage has broken it down into 2 individual chapters for you:

Title
1 Manage media download task lifecycle
2 Verify download cancellation via source contract test
Open in Stage

Chapters generated by Stage for commit 04948d8 on Jul 13, 2026 12:41pm UTC.

@mubarakcoded
mubarakcoded marked this pull request as ready for review July 13, 2026 14:28
@mubarakcoded
mubarakcoded merged commit 60ca4e7 into master Jul 13, 2026
4 of 5 checks passed
@mubarakcoded
mubarakcoded deleted the pip/whitenoise-mac-468 branch July 13, 2026 15:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

2 participants