Conversation
Co-authored-by: theg1239 <theg1239@users.noreply.github.com>
Co-authored-by: theg1239 <theg1239@users.noreply.github.com>
fix: update npm configuration and remove unused dependencies
update wasm
Keep the most recent local page-edit save active until server props catch up to that exact serialized value. This prevents a delayed refresh for an earlier save from regressing a moderator's newer consecutive save.
Bump the service-worker cache version to evict previously cached personalized HTML, exclude exact personalized routes such as / and /auth, and honor Cache-Control/Set-Cookie on every cache write path so background refreshes cannot store private responses.
Add the same isClear=true guard used by the rest of the note queries so direct note-detail URLs cannot render moderator-unapproved notes.
Store saved page edits against the current server prop generation so a refresh that returns stale props cannot immediately replace the moderator's just-saved page order or rotations.
fix sw issue
…n-926b fix: protect unpublished notes and saved page edits
Keep main's v6 service-worker policy while preserving cache-control and Set-Cookie guards so stale personalized responses are not written to Cache Storage.
…n-74e6 fix: prevent stale personalized cache and preserve page edits
Keep the current mainline service-worker behavior and retain the PDF viewer guard that prevents stale refreshes from overwriting newly saved page edits.
…n-f100 fix: prevent stale PWA documents and PDF page edits
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Comment on lines
+2069
to
+2074
| if ( | ||
| prev.pendingValueKey && | ||
| prev.pendingValueKey !== normalizedInitialPageEditsKey | ||
| ) { | ||
| return prev; | ||
| } |
Contributor
There was a problem hiding this comment.
When a local save leaves pendingValueKey set and the server later sends a different serialized pageEdits value, this branch keeps returning prev without updating propKey or clearing the pending key. The viewer then keeps rendering savedPageEditsState.value instead of the authoritative prop, so a rejected, normalized, or superseded save can leave the PDF buffer and editor stuck on stale page edits.
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.
spent a lot of water and tokens to review your slop
Greptile Summary
This PR carries saved paper page edits into the PDF viewing flow. The main changes are:
pageEditsto course paper list data and split-view items.Confidence Score: 4/5
The PDF page-edit reconciliation needs attention before merging because stale local edits can continue to override newer server state.
The changed flow is focused and the issue is localized to viewer state reconciliation, while the surrounding data plumbing and service-worker changes appear coherent.
app/components/pdfviewer.tsx
What T-Rex did
Reviews (1): Last reviewed commit: "Merge pull request #438 from ACM-VIT/cur..." | Re-trigger Greptile