8000 adding smart contracts for kgp-6 implementation by 0xxlegolas · Pull Request #1803 · klaytn/klaytn · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Aug 19, 2024. It is now read-only.

adding smart contracts for kgp-6 implementation #1803

Merged
merged 14 commits into from
Mar 14, 2023
Merged

Conversation

0xxlegolas
Copy link
Contributor

Proposed changes

This PR is a part of KGP-6 implementation to record treasury fund rebalancing in smart contract.

Types of changes

Please put an x in the boxes related to your change.

  • Bugfix
  • New feature or enhancement
  • Others

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I have read the CONTRIBUTING GUIDELINES doc
  • I have signed the CLA
  • Lint and unit tests pass locally with my changes ($ make test)
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)
  • Any dependent changes have been merged and published in downstream modules

Related issues

  • Please leave the issue numbers or links related to this PR here.

Further comments

If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc...

@blukat29
Copy link
Contributor
blukat29 commented Mar 2, 2023

If I understand correctly, only some Status is set by the setStatus function despite its name.

flowchart LR
  Start-->|constructor|Initialized
  Initialized-->|"{register,remove}{Sender,Receiver}"|Initialized
  Initialized-->|setStatus|Registered
  Registered-->|approve|Registered
  Registered-->|setStatus,with validations|Approved
  Approved-->|finalizeContract|Finalized
  Registered-->|reset|Initialized
  Approved-->|reset|Initialized
Loading

Can we split the setStatus() function into two functions, each with a descriptive name and an atStatus modifier?

For instance finalizeRegistration() moves Initialized -> Registered, finalizeApproval() moves Registered -> Approval.

@0xxlegolas
Copy link
Contributor Author

@blukat29 Thanks for the suggestions. Modified accordingly.

@aidan-kwon
Copy link
Member

This is the smart contract implementation of klaytn/kips#104

@0xxlegolas 0xxlegolas added the need to merge Need to merge for the next time label Mar 2, 2023
Co-authored-by: Donghwan Aidan Kwon <aidan.kwon@klaytn.foundation>
aidan-kwon
aidan-kwon previously approved these changes Mar 14, 2023
ian0371
ian0371 previously approved these changes Mar 14, 2023
blukat29
blukat29 previously approved these changes Mar 14, 2023
@0xxlegolas 0xxlegolas dismissed stale reviews from blukat29, ian0371, and aidan-kwon via 0698b31 March 14, 2023 10:02
@aidan-kwon aidan-kwon requested review from blukat29 and ian0371 March 14, 2023 10:03
@0xxlegolas 0xxlegolas merged commit 86676ab into klaytn:dev Mar 14, 2023
@ian0371 ian0371 mentioned this pull request Mar 17, 2023
9 tasks
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
need to merge Need to merge for the next time
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants
0