Repository navigation
ci: link the GroveDB structure viewer on pull requests that change structure - #4846
Conversation
…ructure A pull request that adds GroveDB structure now gets a comment with a link that opens the structure viewer on the difference between its merge base and its head: new nodes glow, removed ones stay as ghosts, and a tour walks through each change. The viewer compares the two grovedb-structure.json files itself, so the link works before the merge and for forks. - `grovedb-structure-preview.yml` runs when the exported structure file changes. It needs no checkout: it finds the merge base, reads both files through the API, lists the added, changed and removed nodes, and posts or updates one comment (the job summary carries the same text, which is what fork pull requests get). Identifiers from the pull request's file are only printed when they have the expected shape. - New book chapter "The GroveDB Structure": the description as code, the tests that keep it true, why the shape of a layer matters, and the pull request link. It embeds the viewer. - Coding conventions gain an "Adding GroveDB structure" checklist, and the pull request template a line for it. Co-Authored-By: Claude Fable 5.1 <[email protected]>
|
Warning Review limit reachedNext included review available in 13 minutes. View limit detailsLimit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: Repository: dashpay/platform/.coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (5)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
🌳 GroveDB structure No node of the described GroveDB structure was added, changed or removed. Open the structure viewer on this pull request's version. Compared |
PR HygieneState: waiting-bots · commit
Self-review is an author attestation that you have read the diff: This check passes when the policy is satisfied; the repository decides whether merging requires it. |
|
📖 Book Preview built successfully. Download the preview from the workflow artifacts. Updated at 2026-09-20T04:10:54.676Z |
Issue being fixed or feature implemented
#4845 described Drive's complete GroveDB structure as code and exports it to
packages/rs-drive/grovedb-structure.json. The structure viewer reads that file by git ref and can compare two refs. What is missing is the link between the two: a pull request that adds structure should show, without anyone asking, what it adds.What was done?
.github/workflows/grovedb-structure-preview.ymlruns on pull requests that changegrovedb-structure.json. It needs no checkout: it finds the merge base through the compare API (the base branch tip would show structure merged since the branch point as removed), reads both files through the contents API, and posts or updates one comment (marker<!-- grovedb-structure-preview -->, same pattern asbook-preview.yml) with?base=<merge base>&head=<owner>/<repo>@<head sha>. New nodes glow, removed ones stay as ghosts, every ancestor of a change carries a count, and a tour walks through each change. The viewer fetches and compares the two files itself, so the link works before the merge and for forks;The same text goes to the job summary. Fork pull requests run with a read-only token that cannot comment, so they get the summary and a notice with the link. The structure file comes from the pull request and is not trusted: node identifiers are only printed when they have the expected shape, as code.
New book chapter "The GroveDB Structure" (
book/src/drive/grovedb-structure.md, first in the Drive section): the description as code, the tests that keep it true (lint, conformance against a real GroveDB for every protocol version and populated fixtures, the coverage gate, the exported file), why the shape of a layer matters and how it is recorded, and the pull request link. It embeds the viewer.Coding conventions gain an "Adding GroveDB structure" checklist: constants and paths, one builder shared by genesis and the protocol upgrade, the node in the sibling
structure.rswithsince, regenerating the file, fixtures or theUNVERIFIEDlist, checking the posted link.Pull request template: one checklist line for structure changes.
How Has This Been Tested?
?head=dashpay/platform@<sha>.mdbook build booksucceeds.Breaking Changes
None.
Checklist:
For repository code-owners and collaborators only
🤖 Generated with Claude Code