Repository navigation
Comments: no false load error after a write; steady signing notice - #93
Merged
Merged
Conversation
The collection watch reports a write before it confirms, and the panel reloads comments 50 ms later. The comment body read required a confirmed record, so it refused the pending record the write had just made and showed "Writer's selected record changed or is protected". Display reads of comment and annotation bodies now accept a pending record and refuse only a hold or an unresolved conflict; writes and readbacks stay strict. The signing notice took its people state from whichever account check finished last, so a slow, older check could replace a newer one (a tab showed "not linked" while signing). Checks now apply in start order, and a transient `unavailable` people-directory failure is retried once before the notice says the account could not be checked. Refs #91
Contributor
Author
|
Supervisor: this is live. writer.mdbase.dev serves 3d3ff44, published by App CD run 43240570517 at about 14:52Z. Ready for the testing rotation's retest. |
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.
Refs #91
A. "Comments could not be loaded" after each write
Cause (Writer integration, not the shared
@mdbase-dev/uipackage): the collection watch reports a write while it is stillpending, and the workspace reloads comments 50 ms later.NativeWriterBackend's body read (bodies(), andcontractRecordunder it) requiredstate: "confirmed". It therefore refused the pending record that the write had just made, with "Writer's selected record changed or is protected." No later change arrives when the write confirms, so the error stayed until Try again.Fix: display reads of comment and annotation bodies accept a pending record and still refuse a hold or an unresolved conflict. Writes, write readbacks and
readBodykeep requiring a confirmed record. A rejected write is rolled back and arrives as another change.B. Signing notice flips while identity succeeds
Cause (deterministic part):
peoplein the workspace snapshot was written by bothloadComments()andrefreshPeople()(on focus or Check again), whichever finished last. A slow, older check could replace a newer one. A tab could then say "not linked" while new comments were signed with the fresh state. Fix: checks apply in the order they started.Likely contributor (not reproduced against production): the SDK people directory throws
unavailablewhen its read session is replaced mid-check (people_fenced) or the person inventory is briefly incomplete. Writer turned that straight into "could not check the account's person record" although/identityreturned 200. It now retries once after 250 ms.Tests
native.test.ts: with confirmations stalled onMemoryReplica, a reload after a resolve and after a reply returns the comments without an error. This test fails onmainwith the production message. A held or conflicted body is still refused. A transient directory failure is retried once.workspace.test.ts: an older account check that finishes last doesn't replace a newerlinkedstate.pnpm checkpasses (i18n, typecheck, 369 app tests, 51 core tests).No persisted comment format or public API change. Issue 92 (withdrawing a thread root after replies) is untouched.