You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-`l` ("left", CID link, optional): link to sub-tree Node on a lower level and with all keys sorting before keys at this node
-`e` ("entries", array of objects, required): ordered list of TreeEntry objects
-`p` ("prefixlen", integer, required): count of bytes shared with previous TreeEntry in this Node (if any)
-`k` ("keysuffix", byte array, required): remainder of key for this TreeEntry, after "prefixlen" have been removed
-`v` ("value", CID Link, required): link to the record data (CBOR) for this entry
-`t` ("tree", CID Link, optional): link to a sub-tree Node at a lower level which has keys sorting after this TreeEntry's key (to the "right"), but before the next TreeEntry's key in this Node (if any)
constsubTreePointer=z.nullable(common.cid)consttreeEntry=z.object({p: z.number(),// prefix count of ascii chars that this key shares with the prev keyk: common.bytes,// the rest of the key outside the shared prefixv: common.cid,// valuet: subTreePointer,// next subtree (to the right of leaf)})constnodeData=z.object({l: subTreePointer,// left-most subtreee: z.array(treeEntry),//entries})
"nullable" is used elsewhere in the same document, and the corresponding implementation in that case matches (although with different syntax that I haven't yet traced):
-`prev` (CID link, nullable): pointer (by hash) to a previous commit object for this repository. Could be used to create a chain of history, but largely unused (included for v2 backwards compatibility). In version `3` repos, this field must exist in the CBOR object, but is virtually always `null`. NOTE: previously specified as nullable and optional, but this caused interoperability issues.
The documentation:
atproto-website/content/specs/repository.md
Lines 87 to 92 in 0a7e942
The implementation:
https://github.com/bluesky-social/atproto/blob/4184a652225eaf2de5f4d4702562e84c2fd3fde7/packages/repo/src/mst/mst.ts#L46-L56
"nullable" is used elsewhere in the same document, and the corresponding implementation in that case matches (although with different syntax that I haven't yet traced):
atproto-website/content/specs/repository.md
Line 52 in 0a7e942
https://github.com/bluesky-social/atproto/blob/4184a652225eaf2de5f4d4702562e84c2fd3fde7/packages/repo/src/types.ts#L17-L18
The text was updated successfully, but these errors were encountered: