Skip to content

KIP-227/286/290: sync permissionless implementation#118

Merged
hyunsooda merged 5 commits into
kaiachain:mainfrom
hyunsooda:feat/permissionless-spec-sync
May 21, 2026
Merged

KIP-227/286/290: sync permissionless implementation#118
hyunsooda merged 5 commits into
kaiachain:mainfrom
hyunsooda:feat/permissionless-spec-sync

Conversation

@hyunsooda
Copy link
Copy Markdown
Contributor

@hyunsooda hyunsooda commented May 21, 2026

Proposed changes

Synchronizes KIP-227, KIP-286, and KIP-290 specifications with the permissionless implementation. Changes were derived by cross-referencing the Go/Solidity implementation against the spec.

KIP-227

  • Fix terminology: candidates(N-1)CandTesting(N-1) for consistency with definition
  • Add rule: if block N+1 is epoch-start, proposer carries CandTesting(N+1) instead of cfReport

KIP-286

  • Rewrite epoch transition pseudo-code as a single-pass loop matching the Go implementation (T1, T4, T2, T3b/pool in one pass); update ordering rationale
  • Fix ValActive description: remove incorrect "= committee"
  • Add Committee section: defines committee(N) = {ValActive} - {Suspended} with safety fallback, and documents post-HF consensus rules (header.Extra, proposer verification, seal verification, quorum)
  • Add Derived Node Sets section: documents all 6 node sets (Council, Committee, HeaderGovVoters, CNPeers, RewardEligible, EpochCompetitors) with formulas and API visibility note

KIP-290

  • Add missing errors: NotInitializable, OnlyManager, OnlyNodeId
  • Add missing events: ManagerUpdated, RewardAddressUpdated, VoterAddressUpdated, MetadataUpdated
  • Add GovernanceInfo struct, getAllGovernanceInfo(), getAllNodesLength()
  • Add fund address functions: updateKefAddress, updateKifAddress, updateKpfAddress, getFundAddresses(), isUsedAddress()
  • Clarify config update functions are called by configurator, not owner
  • Add Governance Parameter Deprecation section: governance.addvalidator, governance.removevalidator, istanbul.committeesize deprecated after FORK_BLOCK

Types of changes

  • Bugfix
  • KIP Proposal
  • KIP Improvement

Checklist

  • Used the suggested template: https://github.com/kaiachain/KIPs/blob/main/kip-template.md
  • I have read the CLA and signed by comment I have read the CLA Document and I hereby sign the CLA in first time contribution
  • I have added necessary documentation (if appropriate)
  • Any dependent changes have been merged and published in downstream modules

Related issues

Further comments

All changes are implementation-driven: the Go/Solidity code is the ground truth, and these commits bring the spec documents into alignment.

hyunsooda and others added 4 commits May 21, 2026 12:53
kip-227:
- Enforce header.VRank empty before FORK_BLOCK
- Epoch-start decoded list must preserve valset order
- Non-epoch: cfReport must be sorted ascending, empty payload permitted

kip-286:
- Rewrite epoch transition pseudo-code as single-pass loop matching
  the implementation (T1, T4, T2, T3b/pool all in one iteration)
- Move T4 (CandReady transitions) into the main loop before top-50
  sorting; update ordering rationale accordingly

kip-290:
- Add missing errors: NotInitializable, OnlyManager, OnlyNodeId
- Add missing events: ManagerUpdated, RewardAddressUpdated,
  VoterAddressUpdated, MetadataUpdated
- Add GovernanceInfo struct and getAllGovernanceInfo()/getAllNodesLength()
- Clarify config update functions are called by configurator, not owner

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ixes

kip-227:
- Fix terminology: candidates(N-1) → CandTesting(N-1) for consistency
- Add rule 4 to Proposer section: if N+1 is epoch-start, omit cfReport
  and carry CandTesting(N+1) instead

kip-286:
- Remove incorrect "= committee" from ValActive description
- Add Qualified Validators section: defines committee = {ValActive} -
  {Suspended}, documents post-HF consensus rules (header.Extra, proposer
  verification, seal verification against qualified set, quorum from
  len(qualified), istanbul.committeesize deprecated)

kip-290:
- Add Governance Parameter Deprecation section: governance.addvalidator,
  governance.removevalidator, istanbul.committeesize deprecated after
  FORK_BLOCK

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Documents all node set definitions with formulas and descriptions:
Council, Committee, HeaderGovVoters, CNPeers, RewardEligible,
EpochCompetitors. Notes that only Council and Committee are external
APIs; all other sets are internal to the core client.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Add missing admin and getter functions present in IAddressBookV2:
- updateKefAddress/updateKifAddress/updateKpfAddress (owner)
- isUsedAddress() and getFundAddresses() (view)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@hyunsooda hyunsooda self-assigned this May 21, 2026
@hyunsooda hyunsooda changed the title Feat/permissionless spec sync spec: align KIP-227/286/290 with permissionless implementation May 21, 2026
@hyunsooda hyunsooda changed the title spec: align KIP-227/286/290 with permissionless implementation KIP-227/286/290: sync permissionless implementation May 21, 2026
Comment thread KIPs/kip-290.md Outdated
Governance parameter deprecation (addvalidator, removevalidator,
istanbul.committeesize) is a validator lifecycle/consensus rule change,
not a smart contract spec change. Move to KIP-286 per review feedback.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@hyunsooda hyunsooda merged commit 04d7f98 into kaiachain:main May 21, 2026
2 checks passed
@github-actions github-actions Bot locked and limited conversation to collaborators May 21, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants