Closed amimart closed 1 month ago
The changes involve modifications to the DataverseCredential
structure, expanding its metadata to include contextual information such as transaction height, timestamp, and sender address. The functions handling claims have been updated to incorporate these new fields, enhancing how credentials are processed and stored. Additionally, constants used in RDF representation have been reorganized for better clarity.
File Path | Change Summary |
---|---|
contracts/axone-dataverse/src/contract.rs , contracts/axone-dataverse/src/execute.rs |
Updated function signatures to include env parameter for enhanced claims processing and environmental context. |
contracts/axone-dataverse/src/registrar/credential.rs |
Modified DataverseCredential struct to add new fields (height , timestamp , tx_index , sender ) and updated conversion logic. |
contracts/axone-dataverse/src/registrar/rdf.rs |
Reorganized constants for credential attributes into header and body categories, updating associated logic for clarity. |
contracts/axone-dataverse/testdata/vc-unsupported-4.nq |
Changed the predicate for claims in RDF representation to reflect the new structure (dataverse:credential:body#claim ). |
Objective | Addressed | Explanation |
---|---|---|
Store additional context data for claims (e.g., block height, transaction index, sender address) (#[615]) | ✅ | |
Organize credential attributes into header and body categories (#[615]) | ✅ |
🐇 In the meadow, the credentials bloom,
With heights and timestamps, they make room.
From submitter's address to claims anew,
Each change a hop, a leap, a view.
Through the blockchain, they dance and sway,
Celebrating facts in a merry way! 🌼
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?
All modified and coverable lines are covered by tests :white_check_mark:
Files | Coverage Δ | |
---|---|---|
contracts/axone-dataverse/src/contract.rs | 96.27% <100.00%> (+0.04%) |
:arrow_up: |
...tracts/axone-dataverse/src/registrar/credential.rs | 98.00% <100.00%> (+0.10%) |
:arrow_up: |
contracts/axone-dataverse/src/registrar/rdf.rs | 93.56% <100.00%> (+0.58%) |
:arrow_up: |
Path | Size |
---|---|
target/wasm32-unknown-unknown/release/axone_objectarium.wasm | 458.07 KB (0%) |
target/wasm32-unknown-unknown/release/axone_law_stone.wasm | 648.51 KB (0%) |
target/wasm32-unknown-unknown/release/axone_cognitarium.wasm | 831.35 KB (0%) |
target/wasm32-unknown-unknown/release/axone_dataverse.wasm | 672.44 KB (+0.31% 🔺) |
Closes #615
Details
Brings the changes proposed in #615 by making the difference between VC's body and context (i.e. considered as headers in the RDF), and enhance this context with block information (i.e.
height
,timestamp
&tx_index
).Those changes are considered breaking as it breaks the model stored in the cognitarium.
Summary by CodeRabbit
New Features
DataverseCredential
structure to include new fields for better context representation.Bug Fixes
Documentation
Refactor