Repository navigation
Fix Pro-sync pill resolution, conflict-toast churn, collaboration roster, and add create-collection UI - #1693
Merged
Merged
Conversation
The daemon serializes DatabaseSettingsNode with sync_enabled/auth_status directly on `properties`, but activeDatabaseSettings() read them from a nested `['database-settings']` sub-object that never exists at runtime. `enabled` was therefore always false and the pill could never resolve to `connected`. Read `properties` flat, and update the pill/settings test fixtures to seed the same flat shape the daemon emits. Co-Authored-By: Claude Opus 4.8 <[email protected]>
…ewer decideRemoteUpdate() raised a conflict notification for any database broadcast to an actively-edited node that wasn't a content-matched own-echo. During rapid typing our own earlier keystrokes echo back with a version that is not ahead of our optimistic local version but whose content no longer matches lastSentContent, producing a phantom conflict on every keystroke. Gate notifyConflict on the incoming version being strictly newer than the local one (or uncomparable); a stale self-echo is now dropped silently. Add a regression case for the not-ahead differing-content echo. Co-Authored-By: Claude Opus 4.8 <[email protected]>
listMembers() could return the same person_id on more than one member_of
edge, crashing the keyed roster {#each} on a duplicate key and wedging the
Collaboration panel on "Loading members…". Collapse duplicates to one row
per person at the highest permission. displayFor() now resolves a person's
name/email from their locally-synced person node (flat properties, cached
in personNames, id fallback) instead of showing the raw id.
Co-Authored-By: Claude Opus 4.8 <[email protected]>
The collections store gains createCollection(), a ROOT_COLLECTION_ID so collections that are only member_of the root render top-level rather than nested under Default, and a NON_CONTENT_NODE_TYPES filter for selectedCollectionMembers. The sidebar gets a "+ New collection" inline input, and the sub-panel filters to content nodes with "Untitled …" labels, type tags, and per-type icons. Co-Authored-By: Claude Opus 4.8 <[email protected]>
…nnel Thrown exceptions and unhandled rejections (e.g. a Svelte keyed-each duplicate-key crash) never pass through the logger methods, so they were visible only in the webview devtools console. Add window error/ unhandledrejection listeners that forward to the same NDJSON file channel, gated on window presence and non-test, so normal builds pay nothing. Co-Authored-By: Claude Opus 4.8 <[email protected]>
malibio
added a commit
that referenced
this pull request
Jul 18, 2026
…t fix PR #1693 landed on main while this branch was in review and independently re-added a version-comparison guard (incomingIsNewer) to decideRemoteUpdate to fix "conflict toast on every keystroke" — but via a different, still- needed mechanism than this PR's daemon-side fix: #1693's guard protects against stale echoes from the sync service (nodespace-sync writes in-process via NodeService::with_client("sync-service"), a path this PR's x-ns-client-id gRPC header does not cover), while this PR's daemon-side suppression eliminates same-gRPC-connection echoes entirely. Resolution: kept the incomingIsNewer version guard (still needed for sync-service stale replays) but dropped the content-based isPlausibleOwnEcho/stashVersion machinery it was paired with (unreachable now that same-connection echoes never arrive at all). Updated remote-update-policy.ts's doc comment and tests to describe both mechanisms and why each is still necessary post-merge. Co-Authored-By: Claude <[email protected]>
This was referenced Jul 18, 2026
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.
Frontend fixes surfaced during live dev-mode validation of Pro sync. Five focused commits.
What's fixed
activeDatabaseSettings()read theDatabaseSettingsNodeproperties from a nested['database-settings']sub-object, but the daemon serializes them FLAT (properties.sync_enabled/.auth_status, per the Core schema). The read now matches the daemon's shape, so the pill can actually resolve toconnected.decideRemoteUpdatenow only setsnotifyConflictwhen the incoming db-broadcast version is strictly newer than the local version. A device's own echo (version not ahead) is no longer surfaced as a conflict. (Pairs with the daemon-side self-echo drop in sync#335.)listMembersdedupes rows bypersonId(keeping the highest permission), and the membership store resolves display names from the locally-synced person node (FLATname/email), falling back to the id.member_ofthe root render top-level (not nested under Default); non-content node types are filtered out of the member list, with human-readable type tags / "Untitled …" labels.window.onerror/unhandledrejectionnow forward into the debug-log channel (NDJSON), so frontend crashes are captured in dev-mode logs.Scope note
The patch was originally authored atop the unmerged
issue-1672-channel-wedge-recoverbranch (#1672/#1685) and has been rebased onto cleanmain. ThemarkSyncEnabledLocally()FLAT-write correction was omitted here because that method lives only on the unmerged #1685 branch — it belongs with #1685. Onmainthe pill resolves correctly via the FLAT read plus the existingrefreshDatabaseSettings()re-pull.Verification
bun run test— 166 files, 4106 tests pass (+2 new: stale-self-echo gate, roster dedupe); zero failuresbun run quality:check— eslint 0/0, svelte-check 0 errorsui-extensions.test.ts,pro-sync-pill.test.ts,pro-sync-settings-refresh.test.ts🤖 Generated with Claude Code