Repository navigation
Record the user behind each peer, with last-writer-wins registration - #4635
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
1 issue found across 13 files
Confidence score: 2/5
registry.rschanges the serialized peer value, so existing v1 Postcard snapshots fail to decode asRegistrywhenopen_inreads them. Add a versioned migration or replay fallback before changing the stored format.
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="document/graph-storage/src/registry.rs">
<violation number="1" location="document/graph-storage/src/registry.rs:13">
P1: This changes the serialized value for each registered peer, so existing v1 Postcard snapshots fail to decode as `Registry`; `open_in` reads them directly without a migration or replay fallback. Add a versioned conversion from legacy `UserId` values before changing this persisted shape.</violation>
</file>
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
| /// Registered by each device's first contribution via `RegistryDelta::RegisterPeer`. | ||
| pub peer_users: HashMap<PeerId, UserId>, | ||
| /// Which person each device is, from `RegistryDelta::RegisterPeer`, so undo and authorship scope by person. | ||
| pub peer_users: HashMap<PeerId, PeerRegistration>, |
Contributor
There was a problem hiding this comment.
P1: This changes the serialized value for each registered peer, so existing v1 Postcard snapshots fail to decode as Registry; open_in reads them directly without a migration or replay fallback. Add a versioned conversion from legacy UserId values before changing this persisted shape.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At document/graph-storage/src/registry.rs, line 13:
<comment>This changes the serialized value for each registered peer, so existing v1 Postcard snapshots fail to decode as `Registry`; `open_in` reads them directly without a migration or replay fallback. Add a versioned conversion from legacy `UserId` values before changing this persisted shape.</comment>
<file context>
@@ -9,12 +9,18 @@ pub struct Registry {
- /// Registered by each device's first contribution via `RegistryDelta::RegisterPeer`.
- pub peer_users: HashMap<PeerId, UserId>,
+ /// Which person each device is, from `RegistryDelta::RegisterPeer`, so undo and authorship scope by person.
+ pub peer_users: HashMap<PeerId, PeerRegistration>,
pub attributes: Attributes,
}
</file context>
TrueDoctor
force-pushed
the
graph-storage-1-users
branch
from
October 2, 2026 21:19
310ff92 to
f983cef
Compare
TrueDoctor
added this pull request to stack #4643
October 3, 2026 14:04
timon-schelling
approved these changes
Oct 4, 2026
timon-schelling
left a comment
Member
There was a problem hiding this comment.
Mostly just inconsistent terms used. And I don't get why we need this but I assume that will make more sense once I look at the rest of the stack.
TrueDoctor
force-pushed
the
graph-storage-1-users
branch
from
October 5, 2026 20:40
f983cef to
c446c74
Compare
This branch was successfully deployed
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.
No description provided.