[fix] bridge grpc and align acropolis inherents - #12
Open
mhounslow wants to merge 8 commits into
Open
Conversation
(cherry picked from commit 95d45af)
…o lowhung/bridge-acropolis-grpc-0.22-pr12-fixes
mhounslow
marked this pull request as ready for review
March 18, 2026 15:58
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Overview
This updates the 0.22 Acropolis gRPC branch to do two things cleanly on top of
node-0.22.0-rc.11-acropolis.First, it keeps the bridge work from the original branch: the node now reads bridge UTXOs from Acropolis gRPC instead of the mock datasource.
Second, it fixes the Acropolis-backed inherent paths that were still diverging from db-sync behavior during guardnet verification. The main issues were that the authority-selection gRPC adapter was decoding Ariadne datums as raw
Bytes(...)instead of full CBORPlutusData, and it was only applying the Cardano epoch offset to Ariadne gating, not to the actual permissioned-candidate / registered-candidate / epoch-nonce queries. That caused the verifier to reconstruct differentAuthoritySelectionInputsthan block authors and led to inherent failures like missing validator data, datum decode failures, andInvalidValidatorsHashMismatch.This PR aligns the Acropolis authority-selection adapter with the db-sync semantics by decoding the full datum payloads correctly and querying the offset data epoch consistently. It also improves cNIGHT inherent mismatch diagnostics so verifier failures surface the first differing UTXO or Cardano position instead of collapsing into a generic
Othererror.🗹 TODO before merging
📌 Submission Checklist
🧪 Testing Evidence
Please describe any additional testing aside from CI:
cargo fmtcargo check -p midnight-node-data-sourcescargo check -p midnight-node-data-sources -p pallet-cnight-observation -p midnight-primitives-cnight-observation -p midnight-primitives-mainchain-followercargo clippy -p midnight-node-data-sources -p pallet-cnight-observation -p midnight-primitives-cnight-observation -p midnight-primitives-mainchain-follower --all-targets -- -D warningsPROTOC=/usr/local/opt/protobuf/bin/protocprotoc, andlitep2p's build script panics before linting completesAdditional tests are provided (if possible)
🔱 Fork Strategy
Links