- Notifications
You must be signed in to change notification settings - Fork 50
Devnet 2.0-rc Deployment #2197
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: dev
Are you sure you want to change the base?
Devnet 2.0-rc Deployment #2197
Conversation
| Important Review skippedReview was skipped as selected files did not have any reviewable changes. 💤 Files selected but had no reviewable changes (18)
⛔ Files ignored due to path filters (2)
You can disable this status message by setting the WalkthroughMass update of Arbitrum Sepolia devnet deployment artifacts: many JSON artifacts were removed or replaced and numerous ABIs, events, errors, addresses, and compiler/metadata were updated (notable surface changes: governor→owner renames, NextRoundSettings, dispute-kit API reshapes, proxy/implementation redeploys). Changes
Sequence Diagram(s)sequenceDiagram participant Deployer participant Proxy as UUPS Proxy participant Impl as Implementation participant Owner rect rgba(52,211,153,0.06) Deployer->>Proxy: deploy(proxy, implementation, initData) Proxy->>Impl: delegatecall initialize(initData) Impl-->>Proxy: initialized end rect rgba(59,130,246,0.06) Owner->>Proxy: executeOwnerProposal(destination, data) Proxy->>Impl: delegatecall executeOwnerProposal(...) alt DisputeKit flow Impl->>DisputeKit: getNextRoundSettings(coreDisputeID, courtIDs, ...) DisputeKit-->>Impl: NextRoundSettings tuple end end Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes
Possibly related PRs
Suggested labels
Suggested reviewers
Poem
Pre-merge checks and finishing touches✅ Passed checks (2 passed)
Comment |
✅ Deploy Preview for kleros-v2-neo ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
✅ Deploy Preview for kleros-v2-testnet ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
❌ Deploy Preview for kleros-v2-testnet-devtools failed. Why did it fail? →
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
contracts/deployments/arbitrumSepoliaDevnet/DisputeResolver.json (1)
46-69: Breaking change — DisputeRequest event now emits (arbitrator, arbitratorDisputeID, templateId); externalDisputeID and templateUri removed.Multiple consumers still expect the old signature DisputeRequest(address,uint256,uint256,uint256,string) and will break — update or revert the ABI. Key affected locations:
- subgraph/core/src/entities/Dispute.ts (uses the old signature and decodes _externalDisputeId/_templateUri)
- web-devtools/src/utils/getDisputeRequestParamsFromTxn.ts (selector "DisputeRequest(address,uint256,uint256,uint256,string)")
- web/src/utils/getDisputeRequestParamsFromTxn.ts (same selector)
- kleros-sdk/src/utils/getDispute.ts and kleros-sdk/config/v2-disputetemplate/** (types expect externalDisputeID/templateUri)
- contracts/test/evidence/index.ts (test unpacks templateUri)
- contracts/scripts/disputeRelayerBot.ts (parses DisputeRequest for relaying)
Action: either restore the previous event shape in the contract ABI or update the listed consumers (subgraph, web/web‑devtools, SDK, tests, scripts) to the new 3‑argument event and reindex/redeploy as required.
🧹 Nitpick comments (4)
contracts/deployments/arbitrumSepoliaDevnet/DisputeTemplateRegistry_Implementation.json (1)
134-138: Harden initializer against zero address.Consider rejecting initialize(address(0)) to avoid a stuck implementation.
If acceptable, add a require(_owner != address(0)) in source before the next redeploy.
contracts/deployments/arbitrumSepoliaDevnet/DisputeKitShutter.json (1)
1633-1639: Deployment wiring: core points to KlerosCore proxy (0x9EfCaeF…).Looks correct. Please add the tx hash for changeCore (if any) to the runbook for traceability.
Also applies to: 1624-1626
contracts/deployments/arbitrumSepoliaDevnet/DisputeKitClassic.json (1)
1018-1070: NextRoundSettings surfaced (event + getter) — update indexers/watchers.ABI adds NextRoundSettingsChanged and a getNextRoundSettings view; subgraph currently does not index them.
- Add a handler for NextRoundSettingsChanged and persist the NextRoundSettings tuple (subgraph/core/src/DisputeKitClassic.ts).
- If you want to record the computed jump/settings, call getNextRoundSettings from your handler or indexing logic and update generated contract types/Graph schema. (See contracts/deployments/arbitrumSepoliaDevnet/DisputeKitClassic.json — NextRoundSettingsChanged ≈ line 318; getNextRoundSettings ≈ line 1018.)
contracts/deployments/arbitrumSepoliaDevnet/DisputeKitGatedShutter.json (1)
1342-1364: Function pairhashJustificationandhashVotediffer in signature and stateability.
hashJustification(line 1342) is declaredpure, taking_saltand_justificationonly.hashVote(line 1366) is declaredview, taking_choice,_salt, and_justification(though no state is read, theviewmodifier is conservative). Verify this discrepancy is intentional; ifhashVotedoes not read state, consider changing it topurefor consistency and gas efficiency.Also applies to: 1366-1393
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (16)
contracts/README.md(1 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeKitClassic.json(20 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeKitClassic_Proxy.json(2 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeKitGated.json(22 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeKitGatedShutter.json(23 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeKitGatedShutter_Proxy.json(2 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeKitGated_Proxy.json(2 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeKitShutter.json(23 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeKitShutter_Proxy.json(2 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeResolver.json(10 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeTemplateRegistry.json(5 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeTemplateRegistry_Implementation.json(7 hunks)contracts/deployments/arbitrumSepoliaDevnet/DisputeTemplateRegistry_Proxy.json(2 hunks)contracts/deployments/arbitrumSepoliaDevnet/EvidenceModule.json(7 hunks)contracts/deployments/arbitrumSepoliaDevnet/EvidenceModule_Proxy.json(2 hunks)contracts/deployments/arbitrumSepoliaDevnet/KlerosCore.json(26 hunks)
✅ Files skipped from review due to trivial changes (1)
- contracts/deployments/arbitrumSepoliaDevnet/DisputeKitClassic_Proxy.json
🧰 Additional context used
🧠 Learnings (7)
📚 Learning: 2025-09-04T23:36:16.415Z
Learnt from: jaybuidl Repo: kleros/kleros-v2 PR: 2126 File: contracts/src/arbitration/KlerosCore.sol:472-489 Timestamp: 2025-09-04T23:36:16.415Z Learning: In this repo, KlerosCore emits AcceptedFeeToken and NewCurrencyRate events that are declared in contracts/src/arbitration/interfaces/IArbitratorV2.sol; implementations don’t need to redeclare these events. Applied to files:
contracts/README.mdcontracts/deployments/arbitrumSepoliaDevnet/KlerosCore.jsoncontracts/deployments/arbitrumSepoliaDevnet/DisputeKitClassic.jsoncontracts/deployments/arbitrumSepoliaDevnet/DisputeResolver.jsoncontracts/deployments/arbitrumSepoliaDevnet/DisputeKitGated.jsoncontracts/deployments/arbitrumSepoliaDevnet/DisputeKitShutter.json
📚 Learning: 2024-10-21T10:32:16.970Z
Learnt from: Harman-singh-waraich Repo: kleros/kleros-v2 PR: 1703 File: kleros-sdk/src/utils/getDispute.ts:38-40 Timestamp: 2024-10-21T10:32:16.970Z Learning: The variables 'arbitrableChainID' and 'externalDisputeID' are required by the context to have uppercase 'ID', so they should remain unchanged even if the corresponding source properties use 'Id'. Applied to files:
contracts/deployments/arbitrumSepoliaDevnet/EvidenceModule.jsoncontracts/deployments/arbitrumSepoliaDevnet/DisputeKitClassic.jsoncontracts/deployments/arbitrumSepoliaDevnet/DisputeKitGated.jsoncontracts/deployments/arbitrumSepoliaDevnet/DisputeKitGatedShutter.jsoncontracts/deployments/arbitrumSepoliaDevnet/DisputeKitShutter.json
📚 Learning: 2024-11-19T16:31:08.965Z
Learnt from: jaybuidl Repo: kleros/kleros-v2 PR: 1746 File: contracts/config/courts.v2.mainnet-neo.json:167-170 Timestamp: 2024-11-19T16:31:08.965Z Learning: In the court hierarchy, child courts' `minStake` must be greater than or equal to their parent court's `minStake`. Applied to files:
contracts/deployments/arbitrumSepoliaDevnet/KlerosCore.json
📚 Learning: 2024-11-19T16:09:41.467Z
Learnt from: jaybuidl Repo: kleros/kleros-v2 PR: 1746 File: contracts/config/courts.v2.mainnet-neo.json:3-17 Timestamp: 2024-11-19T16:09:41.467Z Learning: In `contracts/config/courts.v2.mainnet-neo.json`, the General Court (ID: 1) can have its `parent` ID set to itself (`"parent": 1`), as there is no parent court with ID 0 currently. Applied to files:
contracts/deployments/arbitrumSepoliaDevnet/KlerosCore.json
📚 Learning: 2024-11-19T17:18:39.007Z
Learnt from: jaybuidl Repo: kleros/kleros-v2 PR: 1746 File: contracts/config/courts.v2.mainnet-neo.json:3-5 Timestamp: 2024-11-19T17:18:39.007Z Learning: In `contracts/config/courts.v2.mainnet-neo.json`, the General Court (id: 1) intentionally references itself as its parent (`"parent": 1`). This self-reference is acceptable and should not be flagged as an issue in future reviews. Applied to files:
contracts/deployments/arbitrumSepoliaDevnet/KlerosCore.json
📚 Learning: 2025-01-22T00:55:35.842Z
Learnt from: jaybuidl Repo: kleros/kleros-v2 PR: 1805 File: contracts/src/proxy/UUPSProxiable.sol:127-129 Timestamp: 2025-01-22T00:55:35.842Z Learning: In Solidity, a public state variable automatically implements a corresponding external view function with the same name. For example, `string public constant override version = "0.8.0"` implements the abstract `function version() external view returns (string memory)`. Applied to files:
contracts/deployments/arbitrumSepoliaDevnet/DisputeKitClassic.jsoncontracts/deployments/arbitrumSepoliaDevnet/DisputeKitGated.jsoncontracts/deployments/arbitrumSepoliaDevnet/DisputeKitGatedShutter.jsoncontracts/deployments/arbitrumSepoliaDevnet/DisputeKitShutter.json
📚 Learning: 2025-09-09T13:33:46.896Z
Learnt from: tractorss Repo: kleros/kleros-v2 PR: 2117 File: web/src/components/DisputeFeatures/Features/GatedErc1155.tsx:51-66 Timestamp: 2025-09-09T13:33:46.896Z Learning: The `setDisputeData` function in `NewDisputeContext` at `web/src/context/NewDisputeContext.tsx` has signature `(disputeData: IDisputeData) => void` and only accepts direct state values, not functional updates like standard React state setters. It cannot be used with the pattern `setDisputeData((prev) => ...)`. Applied to files:
contracts/deployments/arbitrumSepoliaDevnet/DisputeResolver.json
🔇 Additional comments (33)
contracts/deployments/arbitrumSepoliaDevnet/EvidenceModule_Proxy.json (1)
2-2: Deployment artifact updates look consistent and properly formatted.The proxy address, transaction metadata, initialization arguments, and compiler settings have been updated coherently for the redeployment. Spot-checking: the implementation address in args[0] (0xEBd4a08A1f02F0661637CA7D1a920F52A52B3487) will need to match the corresponding implementation artifact referenced in related deployment files.
Also applies to: 29-29, 59-61, 63-63
contracts/README.md (1)
81-81: README devnet deployment addresses successfully updated and cross-verified.Spot-checked devnet addresses against their corresponding JSON deployment artifacts:
- Line 90 EvidenceModule proxy: 0x8AAF07ac05E81c92C6FD369aaEdE159E9893508d matches EvidenceModule_Proxy.json ✓
- Line 87 DisputeKitShutter proxy: 0xD143b4FcdCf5699983fF9Ad7e38DE80Aa7Eb9Ce7 matches DisputeKitShutter_Proxy.json ✓
- Line 86 DisputeKitGatedShutter proxy: 0x476EE17A32363aec1D32DB49ab701E70Ec56a8e6 matches DisputeKitGatedShutter_Proxy.json ✓
- Line 89 DisputeTemplateRegistry proxy: 0xa28cA6364B40537B3e73c395cc2B1Bb6de1F1161 matches DisputeTemplateRegistry_Proxy.json ✓
Also applies to: 84-91, 96-98
contracts/deployments/arbitrumSepoliaDevnet/DisputeKitShutter_Proxy.json (1)
2-2: Deployment artifact properly updated with consistent metadata and initialization parameters.Address, transaction data, compiler version (0.8.30), EVM target (Cancun), and optimizer settings (850 runs with viaIR) align with the broader devnet 2.0-rc deployment pattern observed across other proxy artifacts.
Also applies to: 29-29, 59-60, 63-63
contracts/deployments/arbitrumSepoliaDevnet/EvidenceModule.json (1)
38-42: Governance model migration (governor → owner) properly reflected in updated ABI and deployment artifacts.Evidence of consistent API changes across EvidenceModule.json and related contracts:
- New
OwnerOnly()error added (line 38-42) ✓initialize(address _owner)parameter renamed from_governor(line 114) ✓- New
owner()view function added (lines 125-135) ✓- Event parameter renamed:
_arbitratorDisputeIDreplacing_externalDisputeID(line 65) ✓- Implementation address correctly updated (line 259) ✓
Compiler metadata updated to 0.8.30, Cancun EVM, optimizer 850 runs, viaIR enabled—consistent across all devnet 2.0-rc artifacts.
Also applies to: 65-65, 114-114, 125-125, 144-154
contracts/deployments/arbitrumSepoliaDevnet/DisputeKitGated_Proxy.json (1)
2-2: Deployment artifact updated consistently with devnet 2.0-rc redeployment pattern.Address (0x648943Cf73b7fa053942Af576C8327fcEfD314d8), compiler settings (0.8.30, Cancun, 850 runs, viaIR), and transaction metadata align with other proxy artifacts in this devnet redeployment cycle.
Also applies to: 29-29, 59-60, 63-63
contracts/deployments/arbitrumSepoliaDevnet/DisputeKitGatedShutter_Proxy.json (1)
2-2: Deployment artifact updated with consistent redeployment metadata.Address (0x476EE17A32363aec1D32DB49ab701E70Ec56a8e6), compiler, and initialization arguments properly updated. Metadata reflects 0.8.30 compiler, Cancun EVM, and 850 optimizer runs consistent across the redeployment.
Also applies to: 29-29, 59-60, 63-63
contracts/deployments/arbitrumSepoliaDevnet/DisputeTemplateRegistry_Proxy.json (1)
2-2: Proxy artifact properly updated with new address and consistent metadata.Address (0xa28cA6364B40537B3e73c395cc2B1Bb6de1F1161) and implementation reference (0xbD51dae8044B8d418c9F86F601Ec48EABb322e7D) align with DisputeTemplateRegistry.json's updated deployment state. Compiler settings consistent with the broader devnet redeployment (0.8.30, Cancun, 850 runs, viaIR).
Also applies to: 29-29, 59-60, 63-63
contracts/deployments/arbitrumSepoliaDevnet/DisputeTemplateRegistry.json (1)
38-42: Governance model migration (governor → owner) consistently applied across DisputeTemplateRegistry contract.ABI changes align with the pattern established in EvidenceModule.json:
- New
OwnerOnly()error added (line 38-42) ✓- New
changeOwner(address _owner)function added (line 124) ✓- New
owner()view function added (lines 144-154) ✓initialize(address _owner)parameter properly renamed (line 133) ✓- Implementation address updated to 0xbD51dae8044B8d418c9F86F601Ec48EABb322e7D (line 288) ✓
Compiler metadata updates (0.8.30, Cancun EVM, 850 optimizer runs, viaIR enabled) consistent across all devnet 2.0-rc deployment artifacts.
Also applies to: 120-120, 124-127, 144-154
contracts/deployments/arbitrumSepoliaDevnet/DisputeTemplateRegistry_Implementation.json (4)
165-193: Open template registration: confirm intent.setDisputeTemplate is permissionless. If this registry should be curated, gate with onlyByOwner; otherwise, confirm indexers/frontends expect arbitrary submissions.
154-164: proxiableUUID guard looks correct.UUPS proxiableUUID is present and (per library) reverts via delegatecall to avoid self-delegation bricking. LGTM.
271-273: No storage corruption risk — storage layout is compatible across upgrades.The verification confirms that the current storage layout is safe. Prior implementations used
governorat slot 0 (address type) andtemplatesat slot 1 (uint256 type). The current implementation renamed the variable toownerbut preserved the same slots and types, ensuring full compatibility with previous deployments during UUPS upgrades.
114-125: No downstream updates required; governance changes are local implementation details.The review comment incorrectly assumes this change affects callers. Verification shows:
- IDisputeTemplateRegistry interface only exposes
setDisputeTemplate(), not governance functions.- DisputeResolver and ArbitrableExample only interact with the interface, calling
setDisputeTemplate()only (no governance invocations).- The ABI's
changeOwnerandinitializeare implementation details; the interface contract remains unchanged.Since no production contract calls governance functions on DisputeTemplateRegistry, the rename is scoped to the implementation. SDKs and deployment scripts that depend on the interface are unaffected.
Likely an incorrect or invalid review comment.
contracts/deployments/arbitrumSepoliaDevnet/DisputeResolver.json (2)
248-264: Rule path validation is sound.Access restricted to arbitrator, bounds checked (0 allowed as “refuse to decide”), prevents double ruling. LGTM.
295-301: Constructor wiring appears correct; proxy address verified.The deployed templateRegistry address
0xa28cA6364B40537B3e73c395cc2B1Bb6de1F1161in DisputeResolver.json is confirmed to be an active UUPS proxy (not an implementation). The proxy correctly delegates to implementation0xbD51dae8044B8d418c9F86F601Ec48EABb322e7Dand uses proper ERC-1967 storage patterns. Verify frontend configuration separately to ensure this proxy address is also referenced in UI settings.contracts/deployments/arbitrumSepoliaDevnet/KlerosCore.json (5)
1768-1834: Initializer args: jurorNft is configurable but set to zero.ABI exposes jurorNft()/changeJurorNft(). If juror NFTs are required in Devnet 2.0‑rc, add a follow‑up tx to set it; otherwise document that it’s intentionally unset.
Also applies to: 2185-2209
83-86: Guardian surface is properly implemented with intentional access hierarchy.The admin-only flows are guarded as designed:
- pause(): allows guardian or owner (via
onlyByGuardianOrOwner)- unpause(): owner-only by design (per comment: "Can only be done by owner")
- upgrades: owner-only via
_authorizeUpgrade()override (line 373)- executeOwnerProposal(): owner-only (line 393)
- currency rates: owner-only (lines 568, 577)
- guardian rotation: owner-only via
changeGuardian()(line 406)The
GuardianOrOwnerOnlyerror is properly defined at line 1421 and used in theonlyByGuardianOrOwnermodifier. The design gives guardian minimal authority (pause only) while owner retains control of upgrades, currency rates, proposals, and guardian rotation itself.Ops runbooks for guardian address rotation cannot be verified from code review.
27-31: No action required; the arbitrable whitelist gate is disabled by default.The
arbitrableWhitelistEnabledstate variable defaults tofalsein Solidity, so existing arbitrables are not blocked by the new gate unless it's explicitly enabled by the owner. The gate only enforces the whitelist check when botharbitrableWhitelistEnabledistrueAND the caller is not whitelisted. The arbitrumSepoliaDevnet deployment correctly relies on this safe default, and the mainnet deployment shows proper post-deployment setup when the whitelist is explicitly enabled. No existing arbitrables will be broken by this change.Likely an incorrect or invalid review comment.
1531-1568: Update consumers: Round tuple changed + new getCourtAndDisputeKitJumps.ABI now adds getCourtAndDisputeKitJumps and extends Round with drawnJurorFromCourtIDs (uint96[]) and uint256[10] __gap — regenerate ABI bindings / TheGraph codegen and update any decoders that call getRoundInfo (notably subgraph/core/src/{KlerosCore.ts, DisputeKitClassic.ts, entities/Round.ts}, contracts/scripts/{keeperBot.ts, console-init.ts}, contracts/test/{integration/index.ts, arbitration/draw.ts}, and any SDK/typechain clients) so they decode the new tuple shape correctly.
108-118: No changes required — court minStake invariant is properly enforced and validated.Validation confirms:
- All three v2 court configuration files (devnet, mainnet, testnet) comply with the parent ≤ child minStake invariant
- The
MinStakeHigherThanChildCourterror is correctly defined in the ABI- The smart contract enforces this invariant in
changeCourtParameters()by iterating child courts and reverting if any child has a lower minStakecontracts/deployments/arbitrumSepoliaDevnet/DisputeKitShutter.json (4)
672-716: Verified: Access control and event emission already implemented.The review comment's concerns have been confirmed as properly addressed:
The
changeNextRoundSettingsfunction includes theonlyByOwnermodifier, confirming owner-only access control is enforced. Additionally, theNextRoundSettingsChangedevent is defined and properly emitted within the function with the required parameters for indexer tracking.No changes are needed.
226-236: The web search didn't return relevant results. Let me examine the actual code more carefully using the retrieved learning context and my prior findings.Based on my comprehensive verification:
Current Solidity Implementation (
DisputeKitGatedShutter.sollines ~137-145):
- Function:
castCommitShutter(uint256, uint256[], bytes32, bytes32, bytes)- Parameters:
_coreDisputeID,_voteIDs,_commit,_identity,_encryptedVote- Event:
CommitCastShutter(_coreDisputeID, msg.sender, _commit, _identity, _encryptedVote)Deployment JSON (
arbitrumSepoliaDevnet/DisputeKitShutter.jsonlines 226-236):
- Shows different parameter names:
_choiceCommitand_justificationCommit- This does NOT match the current Solidity implementation
Keeper Bot Usage (
keeperBotShutter.tsline 220):
- Filters
CommitCastShutterevents with current event signature- Already handles the correct parameters
Review Comment Claims:
- States "CommitCastShutter now uses _choiceCommit and adds _justificationCommit"
- This claim is incorrect based on actual Solidity code
Conclusion: The review comment contains an inaccurate statement about the API changes. The actual implementation has a single
_commitparameter plus_identityand_encryptedVote, not separate_choiceCommitand_justificationCommit. The JSON file may be outdated or from a different contract version. The keeper bot is already correctly using the current API.Shutter commit API is correctly implemented. The review comment's specific claim about parameter names is incorrect and should be disregarded. No client updates are needed beyond what's already in the codebase.
Likely an incorrect or invalid review comment.
1313-1335: hashJustification helper is defined in ABI but not integrated into test suite.Investigation reveals:
justificationCommitments()is properly used in tests (lines 352, 385) to store/retrieve commitments- However,
hashJustificationis defined in the ABI but never called in the codebase- Tests manually compute hashing logic instead:
ethers.keccak256(ethers.toUtf8Bytes(justification))followed by salt encoding- No frontend code exists in this repository to verify the stated concern about frontend consistency
The main verification concern—"ensure frontends use hashJustification consistently with castVoteShutter"—cannot be validated within this codebase as frontend implementations are not present. Additionally, the test suite appears to bypass the helper function with inline hashing. Clarify whether tests should refactor to use
hashJustification, or if this helper is intended only for external off-chain use.
912-944: Decoders/hooks appear auto-generated from ABIs; verify codegen was run.The draw() function signature changes are complete and consistent across all contracts. However, the review comment references updating "decoders," which likely refers to auto-generated wagmi/viem hooks. The generated hooks directory isn't present in the repository filesystem, suggesting these are build artifacts.
Verify that contract codegen/hook generation has been executed after the ABI changes, as the generated code is not stored in the repository and won't reflect the updated signature until regenerated.
contracts/deployments/arbitrumSepoliaDevnet/DisputeKitClassic.json (3)
839-843: Verify migration completeness for Governor→Owner function names.The migration is incomplete. While new
changeOwnerandexecuteOwnerProposalfunctions are present in DKClassic deployments and Solidity source code, oldchangeGovernorandexecuteGovernorProposalfunctions persist in multiple deployment files including arbitrumSepoliaDevnet.ts. The same file contains both old and new function names (e.g.,changeGovernorat lines 631, 3007, 3540 andchangeOwnerat new lines), indicating an inconsistent state. Verify whether this is intentional dual-support or incomplete migration cleanup.
1456-1461: Verify post-deploy core initialization and clarify changeNextRoundSettings reference.The
changeCorefunction exists in DisputeKitClassicBase with proper access control (onlyByGovernor), confirming the mechanism is in place. However, this review cannot confirm from codebase inspection alone whether the post-deploy transaction that sets core viachangeCore()was actually executed for the arbitrumSepoliaDevnet deployment.Additionally, the mention of "changeNextRoundSettings" in the original comment could not be verified—no such function appears in the current codebase. If this refers to a different mechanism or renamed function, clarification is needed.
Action items:
- Manually verify the deployment logs/scripts to confirm
changeCore()was called post-deployment with the correct core address.- Clarify or remove the reference to
changeNextRoundSettingsif it doesn't apply to current code.- Confirm whether core=0x0 in the JSON is expected (pre-wiring state) or indicates incomplete deployment.
788-820: All draw() signature changes verified and correctly implemented across callers.All dispute kit callers have been updated:
- KlerosCore.sol (line 758): Calls
disputeKit.draw(_disputeID, startIndex + i++, round.nbVotes)and correctly destructures both return values- KlerosCoreUniversity.sol (line 605): Calls with new 3-param signature and dual return destructuring
- DisputeKitGatedArgentinaConsumerProtection.sol (line 95): Calls
super.draw()with all three parameters and returns both valuesNo callers using the old 2-parameter signature remain.
contracts/deployments/arbitrumSepoliaDevnet/DisputeKitGated.json (4)
2-2: Contract address alignment is correct.The root address (line 2), receipt contractAddress (line 1469), and implementation address (line 1511) are appropriately distinct and consistently referenced throughout the artifact.
Also applies to: 1469-1469, 1511-1511
1250-1250: Initialize parameter naming change: governor → owner.Line 1250 reflects a governance model shift from
_governorto_owner. The execute section (lines 1503–1510) provides three address arguments matching the updated function signature: owner, core, and wNative. This is a breaking interface change; verify that all callers of this contract'sinitializefunction are aware of the renamed parameter.Also applies to: 1503-1510
286-331: New eventNextRoundSettingsChangedintroduced with struct fields.Line 329 introduces a new event with an embedded
NextRoundSettingsstruct (lines 296–327). This aligns with new functionschangeNextRoundSettings(line 599) andgetNextRoundSettings(line 1079). Ensure that off-chain indexing and monitoring are aware of this new event structure.
660-689: Output naming and structure updates in dispute query functions.Lines 660–666 and 684–689 update return value naming for
coreDisputeIDToActiveandcoreDisputeIDToLocal. This is a breaking change for callers relying on positional returns; named outputs should make this clearer in type-safe environments but may require upstream updates.contracts/deployments/arbitrumSepoliaDevnet/DisputeKitGatedShutter.json (3)
2-2: Contract address alignment is correct.The root address (line 2), receipt contractAddress (line 1646), and implementation address (line 1688) are appropriately distinct and consistently referenced.
Also applies to: 1646-1646, 1688-1688
221-263: Shutter-variant events and hashing functions introduce encryption-aware structures.Lines 221–263 introduce
CommitCastShutterevent with separate_choiceCommitand_justificationCommitfields. The newhashJustificationfunction (lines 1342–1364) is a pure hash function taking salt + justification (no choice), distinct fromhashVote(lines 1366–1393) which includes the choice. Verify that client implementations using these functions for vote/justification separation are aware of this dual-commit structure.Also applies to: 1342-1364
1466-1493: New state accessorjustificationCommitmentsbreaks encapsulation if not already present.This new function (lines 1466–1493) exposes a mapping of justification commitments keyed by
(localDisputeID, localRoundID, voteID). If this is a new addition, verify that clients querying this state are aware of its availability and structure.
6528829 to a3c9f91 Compare |



PR-Codex overview
This PR focuses on significant updates to the Kleros smart contract system, including the removal of several JSON files, updates to dependencies, and enhancements in contract functionalities, particularly around the
KlerosCoreUniversityand RNG systems.Detailed summary
@reality.eth/reality-eth-libdependency from^3.4.14to^3.4.15.1000to850inhardhat.config.ts.governableAbitoownableAbiinexecution.tsand updated related function calls.RNGWithFallbackin various contract mappings and tests.KlerosCoreUniversitycontract with new events and functions for dispute management.Summary by CodeRabbit