Context
rollups-node uses CGO bindings to libcartesi (emulator C API), currently pinned to v0.19.0. The Machine team provided a v0.20.0 preview/test release and asked us to validate it in the node before they cut the final release.
This task is not about adopting new emulator features in the node. The goal is to bump to the preview build, ensure the node still works end-to-end, and add minimal bindings for two newly introduced C APIs so we can exercise them in tests/prototypes.
Relevant binding location:
pkg/emulator (CGO binding to libcartesi / libcartesi_jsonrpc)
Proposed change
-
Update the pinned libcartesi version from 0.19.0 → 0.20.0 (preview) in all build/install paths used by CI/dev (Docker images, scripts, docs, etc. as applicable).
-
Extend the CGO bindings to expose the newly added APIs:
CM_API cm_error cm_collect_mcycle_root_hashes(
cm_machine *m,
uint64_t mcycle_end,
uint64_t mcycle_period,
uint64_t mcycle_phase,
int32_t log2_bundle_mcycle_count,
const char *previous_back_tree,
const char **result
);
CM_API cm_error cm_collect_uarch_cycle_root_hashes(
cm_machine *m,
uint64_t mcycle_end,
int32_t log2_bundle_uarch_cycle_count,
const char **result
);
Notes:
- Keep the scope minimal: expose the functions + basic error handling + memory management for returned strings.
- Do not refactor the emulator package unless required by the bump.
- Update the Rust prototype node to use the same preview version and run its test flow, so we can compare resulting machine hashes and the computation hashes (hash parity).
Deliverables
Acceptance criteria
Out of scope
- Implementing or exposing all new emulator features introduced in 0.20.x.
- Changing CLI/JSON-RPC surfaces unless strictly required for compatibility.
Follow-up (after Machine team releases 0.20.0)
Context
rollups-nodeuses CGO bindings tolibcartesi(emulator C API), currently pinned to v0.19.0. The Machine team provided a v0.20.0 preview/test release and asked us to validate it in the node before they cut the final release.This task is not about adopting new emulator features in the node. The goal is to bump to the preview build, ensure the node still works end-to-end, and add minimal bindings for two newly introduced C APIs so we can exercise them in tests/prototypes.
Relevant binding location:
pkg/emulator(CGO binding tolibcartesi/libcartesi_jsonrpc)Proposed change
Update the pinned
libcartesiversion from 0.19.0 → 0.20.0 (preview) in all build/install paths used by CI/dev (Docker images, scripts, docs, etc. as applicable).Extend the CGO bindings to expose the newly added APIs:
Notes:
Deliverables
libcartesito v0.20.0 preview (exact preview identifier/commit as provided by Machine team)pkg/emulatorfor the new APIsrollups-nodetest suite against the preview build (CI + local as needed)libcartesito the same preview version in the Rust prototype nodeAcceptance criteria
rollups-nodebuilds and links successfully against libcartesi v0.20.0 preview on CI-supported platforms.Out of scope
Follow-up (after Machine team releases 0.20.0)