docs(protocol-ref): audit corrections for v3.1 protocol reference#140
docs(protocol-ref): audit corrections for v3.1 protocol reference#140thephez merged 3 commits intodashpay:3.1.0from
Conversation
Fix 15 findings across 8 protocol reference pages: - Fix $version field size 32→16 bits, FeatureVersion = u16 (F-006) - Fix min withdrawal amount ~181,000→190,000 credits, ASSET_UNLOCK_TX_SIZE=190 (F-016) - Fix contract keywords limit "20 at creation; 50 on update"→50 (F-004) - Add missing preProgrammedDistribution to distribution properties table (F-005) - Fix Group Action Info field names to match serde (F-012) - Add minimum group size (2) and member power constraint to group constants (F-010, F-011) - Update DPNS trigger field from records.dashUniqueIdentityId to records.identity (F-014) - Update source links from v1.rs to v3.rs for address transaction limits (F-017) - Fix source link line ranges for token burn/freeze transitions (F-020, F-021) - Add Size column to Data Contract Update table (F-009) - Add batch limit source link (F-008) - Reorder identity publicKeys table to match struct field order (F-022) - Clarify address-system.md Protocol Version 11 wording with source link (F-019) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✅ Files skipped from review due to trivial changes (1)
📝 WalkthroughWalkthroughDocumentation updates across protocol reference files: clarified constraints (keywords, group sizes, field bit widths), introduced token distribution field and parameter aliases, updated fee formulas and source links, reordered identity/publicKeys docs, and corrected trigger/schema notes and transition/table metadata. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related issues
Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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 |
- fix credit transfer fee note to show per-recipient cost (6M credits/recipient) (F-001) - fix $version field size from 32 to 16 bits in data contract Create/Update tables (F-006) - add marketplaceRules to token config full example JSON (F-003) - add signed/unsigned note for distribution function parameters a and m (F-004) - add JSON field name aliases for s and b in Linear/Polynomial/InvertedLogarithmic (F-005) - clarify DPNS trigger ownerId check is a no-op due to schema mismatch (F-002) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@docs/protocol-ref/data-contract.md`:
- Line 83: The docs state a max of 50 keywords but the embedded JSON Schema
limits keywords.maxItems to 20; update the schema snippet so keywords.maxItems
matches the prose (set to 50) or alternatively add an explicit version/caveat
clarifying the two limits; ensure the referenced field name "keywords" and the
schema property "keywords.maxItems" are changed together and any example or
validation rules in the same document are updated to remain consistent.
In `@docs/protocol-ref/data-trigger.md`:
- Line 42: Update the table row for domain `CREATE` to remove the incorrect
claim that `records.dashUniqueIdentityId`/`records.dashAliasIdentityId` are
absent from the v1 schema and instead state the real cause: verify whether the
trigger logic (the CREATE trigger) is checking the wrong field names or running
pre-validation before schema constraints are applied; reference the DPNS v1
schema properties `records.dashUniqueIdentityId` and
`records.dashAliasIdentityId` and clarify that the schema does include these
fields and enforces the one-or-the-other constraint via max/min properties, or
explicitly note a version mismatch or trigger bug if that is the true issue
(e.g., mismatch between trigger code and schema). Also shorten the long table
cell by moving the detailed explanation into a short note or a follow-up
paragraph below the table for readability.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: 1406622d-f6fa-4ab3-9c76-ed9a6c520411
📒 Files selected for processing (8)
docs/protocol-ref/address-system.mddocs/protocol-ref/data-contract-token.mddocs/protocol-ref/data-contract.mddocs/protocol-ref/data-trigger.mddocs/protocol-ref/identity.mddocs/protocol-ref/protocol-constants.mddocs/protocol-ref/state-transition.mddocs/protocol-ref/token.md
Summary
Applies findings from two audit passes of
docs/protocol-ref/against the v3.1-dev platform source, correcting factual errors and omissions across the protocol reference pages. The changes fix incorrect field sizes, outdated constants, missing content, and misleading constraint descriptions.Highlights
Correctness fixes
$versionfield size from 32 to 16 bits in Data Contract Create/Update state transition tables (matchesFeatureVersion = u16)Missing content
marketplaceRulesto token configuration full example JSONpreProgrammedDistributionto distribution properties tableaandmClarifications
ownerIdcheck is currently a no-op due to v1 schema field name mismatchstart_step,starting_amount,start_moment) alongside formula variables in distribution function parameter descriptionsv1.rstov3.rsfor address transaction limitsPreview build: https://dash-docs-platform--140.org.readthedocs.build/en/140/
Summary by CodeRabbit
Documentation