Skip to content
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

feat: network token enforcement #45

Merged
merged 3 commits into from
Mar 23, 2024
Merged

feat: network token enforcement #45

merged 3 commits into from
Mar 23, 2024

Conversation

evilrobot-01
Copy link
Collaborator

Network now launches with zero total issuance, requiring a reserve transfer from the relay to get started. This will be automated with a pop up feature, but for now one can reserve transfer from relay to Pop with the following encoded calls:

  • Send 100 UNIT to Alice on Pop
    0x630804000100098e0400010100d43593c715fdd31c61141abd04a99fd6822c8558854ccde39a5684e7a56da27d04040000000b00407a10f35a0000000000
  • Send 100 UNIT to Bob on Pop
    0x630804000100098e04000101008eaf04151687736326c9fea17e25fc5287613693c912909cb226aa4794f26a4804040000000b00407a10f35a0000000000

Commits:

  • filter balances::force* calls to prevent minting of native token, ensuring network can only be funded from relay token
  • removes endowments from chainspec
  • removes endowments from genesis within integration tests, updating tests accordingly

Copy link
Collaborator

@Daanvdplas Daanvdplas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice!

Should we add testing the integrations in the CI or is that too much?

Copy link
Collaborator

@peterwht peterwht left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. We will probably want to introduce some tests later on for allowing users to withdraw tokens back to the relay chain

@peterwht
Copy link
Collaborator

peterwht commented Mar 22, 2024

Reserve transfer to Pop Network script tracker: #47

@evilrobot-01
Copy link
Collaborator Author

LGTM. We will probably want to introduce some tests later on for allowing users to withdraw tokens back to the relay chain

Already exists:

fn reserve_transfer_native_asset_from_para_to_relay() {

@peterwht
Copy link
Collaborator

LGTM. We will probably want to introduce some tests later on for allowing users to withdraw tokens back to the relay chain

Already exists:

fn reserve_transfer_native_asset_from_para_to_relay() {

Ah nice. Missed that one and thought we were testing transfer to SA account.

@evilrobot-01
Copy link
Collaborator Author

Should we add testing the integrations in the CI or is that too much?

Already included - see https://github.com/r0gue-io/pop-node/actions/runs/8383155297/job/22958325605:
image

@al3mart al3mart merged commit 74943ec into main Mar 23, 2024
5 checks passed
@al3mart al3mart deleted the frank/feat-network-token branch March 23, 2024 07:55
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.

4 participants