Skip to content

feat(drive): provide latest core chain lock on init chain#659

Merged
shuplenkov merged 2 commits into
v0.24-devfrom
latest_chainlock
Dec 8, 2022
Merged

feat(drive): provide latest core chain lock on init chain#659
shuplenkov merged 2 commits into
v0.24-devfrom
latest_chainlock

Conversation

@shuplenkov
Copy link
Copy Markdown

@shuplenkov shuplenkov commented Dec 7, 2022

Issue being fixed or feature implemented

Need to return nextCoreChainLockUpdate on init chain.

What was done?

nextCoreChainLockUpdate param added to init chain response.

How Has This Been Tested?

With tests

Breaking Changes

No

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated relevant unit/integration/functional/e2e tests
  • I have made corresponding changes to the documentation

For repository code-owners and collaborators only

  • I have assigned this pull request to a milestone

@shuplenkov shuplenkov added this to the v0.24.0 milestone Dec 7, 2022
@shumkov shumkov changed the title feat(drive): return latest core chain lock on init chain feat(drive): provide latest core chain lock on init chain Dec 7, 2022
Comment thread packages/js-drive/lib/abci/handlers/initChainHandlerFactory.js Outdated
@shuplenkov shuplenkov merged commit 40d2355 into v0.24-dev Dec 8, 2022
@shuplenkov shuplenkov deleted the latest_chainlock branch December 8, 2022 08:26
QuantumExplorer added a commit that referenced this pull request May 10, 2026
The v12 protocol transition was still parenting the main shielded credit
pool under AddressBalances and creating only 4 of the 8 inner subtrees,
which would diverge from a fresh genesis-12 chain (created by v3 init) on
any node that actually migrated from v11. Rewrite it to mirror v3 init:

- Insert RootTree::ShieldedBalances as a top-level SumTree.
- Parent the main pool under [ShieldedBalances] / "M".
- Insert all 8 inner subtrees in BFS order: notes, nullifiers,
  anchors_in_pool, total_balance, anchors_by_height, recent_nullifiers
  (wrapped in NotSummed), compacted_nullifiers, expiration_time.
- Update the two post-condition assertions in the in-file tests.

Also fix CI: the grovedb bump (PR #659/#656) added a new
QueryItem::AggregateCountOnRange variant. wasm-drive-verify wasn't in my
local check set and had a non-exhaustive match in
token_transition.rs that broke the macOS workspace build. Reject the
variant with a clear error message.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants