Skip to content

Conversation

@dtaghavi
Copy link
Contributor

This PR adds functionality for Node Owners to claim their distribution of $WIRE token.

  • On registration of node owners via sysio.roa an inline action is called adding them to distribution table.

  • When a node owner claims part of their distribution an inline action is made to sysio.token transferring WIRE

  • Initial timestamp of node owner distribution is set via setinittime and stored in singleton.

  • Read only action (viewnodedist) returns useful struct related to a node owners distribution.

- On registration of node owners via sysio.roa inline action is called adding them to distribution table
- When a node owner claims part of their distribution an inline action is made to sysio.token transferring WIRE
- Initial timestamp of node owner distribution is set via setinittime and stored in singleton
- Read only action returning useful struct related to a node owners distribution
@dtaghavi dtaghavi requested a review from heifner December 16, 2025 22:12
- removed TODOs
- Removed liq staking tables to keep PR concise
- Updated abi / wasm for sysio.system contract with new actions / tables
- Update wasm for sysio.roa to account for additional inline action in node owner registration
@heifner heifner requested a review from jglanz December 17, 2025 16:35
@jglanz
Copy link
Collaborator

jglanz commented Dec 17, 2025

@dtaghavi there's no need to merge this PR until it's complete and functionally tested; my reference to completeness is also not a standalone analysis:

When you wrote the authmsg contracts you embedded keccak256.hpp header, as opposed to creating an intrinsic and you chose to embed a uint256.hpp; these create both code bloat and fragmented codebase problems.

Please hold this PR until the intrinsics are made available to you and the contracts are complete from an ecosystem perspective.

J

@jglanz jglanz marked this pull request as draft December 17, 2025 17:09
@jglanz
Copy link
Collaborator

jglanz commented Dec 17, 2025

@dtaghavi In addition to my previous comment, something as critical as the emissions contract should include a link to a final draft of the emissions system design document and the code comments in the contract should reference the design document.

This contract is equivalent to the Fed and should be designed and implemented to strict tolerances.

@dtaghavi
Copy link
Contributor Author

@dtaghavi there's no need to merge this PR until it's complete and functionally tested; my reference to completeness is also not a standalone analysis:

When you wrote the authmsg contracts you embedded keccak256.hpp header, as opposed to creating an intrinsic and you chose to embed a uint256.hpp; these create both code bloat and fragmented codebase problems.

Please hold this PR until the intrinsics are made available to you and the contracts are complete from an ecosystem perspective.

J

Perfect, can just keep it open as a Draft for now, Kevin wanted to have a PR for it. Totally fine keeping it open till it's ready as a whole.

I agree, we talked about keccak on the core call last week, the consensus was as you said have it added as an intrinsic. Same with the uint256, it was suggested to just drop it in for now till we can add it to the CDT properly.

@jglanz
Copy link
Collaborator

jglanz commented Dec 17, 2025

@dtaghavi with regard to any design decision, it must go to a team lead and then that lead will discuss in our new bi-weekly design sessions which are being planned now.

Additionally, ANY system-contracts need to be discussed and reviewed with all engineers working on system contracts which is both @heifner and @jglanz - the potential impact on token/reserves, external yield rewards, etc are integral to depot and interactions with external chains. The emissions was assigned by @jglanz to @heifner, but it should not have been reassigned beyond @heifner and @jglanz due to the reasons mentioned.

Please attach complete final draft documentation prior to updating this PR

- Removed unused temp uint256 implementation
- Adjusted addnodeowner to not require distribution start time to be set, leaving this restriction on claim.
- Removed setinittime from roa test as adding a node owner doesn't need this restriction
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.

3 participants