Skip to content

revert(webapp): stale-deploy asset recovery (#4260)#4278

Closed
nicktrn wants to merge 1 commit into
mainfrom
revert/stale-asset-recovery-4260
Closed

revert(webapp): stale-deploy asset recovery (#4260)#4278
nicktrn wants to merge 1 commit into
mainfrom
revert/stale-asset-recovery-4260

Conversation

@nicktrn

@nicktrn nicktrn commented Jul 17, 2026

Copy link
Copy Markdown
Collaborator

Reverts #4260.

The client-side stale-asset recovery it introduced is net-negative during normal deploys:

  • Its fetch interception treats any ?_data= request (Remix loader and action traffic) as a navigation and, on a build-id mismatch, location.assignes the tab to the fetched URL. During a rolling deploy an open dashboard tab can be hard-navigated to a raw data URL (e.g. a /resources/* loader), losing unsaved input.
  • Any transient /build asset error (a network blip, an extension, an unrelated failed dynamic import) blanks the page behind a full-screen overlay for ~60s before offering a manual reload.
  • It serialized form field values to sessionStorage to restore them across the reload.

This returns the webapp to the pre-#4260 baseline as a fast, low-risk step — the diff is an exact inverse of #4260 (nothing else has touched those files since). A simpler reload-only recovery, plus a load-balancer stickiness change that addresses the root cause, will follow as separate PRs.

This reverts #4260 (commit 2aa6420).

The client-side recovery it introduced could navigate a working tab away
during a normal deploy and blank pages behind an overlay on transient asset
errors. Reverting to the pre-#4260 baseline; a simpler replacement will follow.
@nicktrn nicktrn self-assigned this Jul 17, 2026
@changeset-bot

changeset-bot Bot commented Jul 17, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 60f3608

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@coderabbitai

coderabbitai Bot commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Walkthrough

Removed the stale asset recovery component and its integration from the web application. Removed build-version response stamping, the /build-version endpoint, and automatic Cache-Control: no-cache defaults for HTML responses. Updated server change-entry instructions to require short, non-technical release-note text written for dashboard users.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Description check ⚠️ Warning The description is missing the repository template sections for checklist, testing, changelog, and screenshots. Rewrite the PR description in the required template and fill in the checklist, testing steps, changelog summary, and screenshots or N/A.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly signals a revert of the webapp stale-asset recovery change.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch revert/stale-asset-recovery-4260

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.

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 potential issue.

Open in Devin Review

Comment on lines -1 to -6
---
area: webapp
type: fix
---

Fix pages occasionally loading unstyled or failing to load during deploys. The dashboard now detects this and reloads to recover automatically, or prompts you to reload if it can't.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Server-only change ships without a release-notes entry

This change only touches the dashboard server code with no package changes (.server-changes/stale-deploy-asset-recovery.md:1-6 is deleted and none is added to replace it), so the removal of the auto-recovery behavior will not appear in the user-facing release notes.
Impact: Users get a behavior change (automatic reload/recovery during deploys is gone) with no corresponding note in the changelog.

Repository rule requiring a .server-changes file

Both .claude/REVIEW.md ("Server-only changes have .server-changes/*.md. Required for apps/webapp/, apps/supervisor/ edits with no public-package change ... Missing → 🟡.") and CONTRIBUTING.md require a .server-changes/*.md entry for PRs that modify only apps/webapp/ with no packages/ changes. This PR modifies apps/webapp/ exclusively (server.ts, entry.server.tsx, root.tsx, and deletes StaleAssetRecovery.tsx) and deletes the previous note without adding a new one.

Prompt for agents
This PR is a server-only change (only apps/webapp files are touched, no packages/ changes) but it does not include a .server-changes/*.md entry, which REVIEW.md and CONTRIBUTING.md require. The previous note (.server-changes/stale-deploy-asset-recovery.md) is being deleted as part of the revert and nothing replaces it. Add a new .server-changes/*.md file (area: webapp, type: fix) with a 1-2 sentence, non-technical, user-facing description of the behavior change so it appears in release notes. Consider whether the reverted feature was ever released to users when deciding wording.
Open in Devin Review

Was this helpful? React with 👍 or 👎 to provide feedback.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1


ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: fd1b4bcc-5a39-46ee-908e-6380d9dd75dc

📥 Commits

Reviewing files that changed from the base of the PR and between 939c007 and 60f3608.

📒 Files selected for processing (6)
  • .claude/rules/server-apps.md
  • .server-changes/stale-deploy-asset-recovery.md
  • apps/webapp/app/components/StaleAssetRecovery.tsx
  • apps/webapp/app/entry.server.tsx
  • apps/webapp/app/root.tsx
  • apps/webapp/server.ts
💤 Files with no reviewable changes (5)
  • .server-changes/stale-deploy-asset-recovery.md
  • apps/webapp/app/components/StaleAssetRecovery.tsx
  • apps/webapp/server.ts
  • apps/webapp/app/root.tsx
  • apps/webapp/app/entry.server.tsx
📜 Review details
⏰ Context from checks skipped due to timeout. (19)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (10, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (7, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (12, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (11, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (6, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (8, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (5, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (1, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (2, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (9, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (3, 12)
  • GitHub Check: webapp / 🧪 Unit Tests: Webapp (4, 12)
  • GitHub Check: typecheck / typecheck
  • GitHub Check: e2e-webapp / 🧪 E2E Tests: Webapp
  • GitHub Check: code-quality / code-quality
  • GitHub Check: audit
  • GitHub Check: audit
  • GitHub Check: Analyze (javascript-typescript)
  • GitHub Check: Analyze (actions)

---
Fix pages occasionally loading unstyled during deploys. The dashboard now recovers automatically.
Brief description of what changed and why.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

📐 Maintainability & Code Quality | 🟡 Minor | ⚡ Quick win

Document the required user-facing release-note format here.

This placeholder still only asks for a “brief description,” so it does not enforce the PR’s intended 1–2 short, non-technical sentences for dashboard users. Since the body is published verbatim, make the example explicitly state those constraints.

Suggested wording
-Brief description of what changed and why.
+Write 1–2 short, non-technical sentences for dashboard users; this text is copied verbatim into user-facing release notes.
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
Brief description of what changed and why.
Write 1–2 short, non-technical sentences for dashboard users; this text is copied verbatim into user-facing release notes.

@nicktrn

nicktrn commented Jul 17, 2026

Copy link
Copy Markdown
Collaborator Author

Superseded by #4280 — redone as a standard git revert of #4260 (plain git, canonical revert commit) instead of the hand-rolled version here.

@nicktrn nicktrn closed this Jul 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant