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

create-testnet-data: various enhancements #575

Merged
merged 3 commits into from
Jan 19, 2024

Conversation

smelc
Copy link
Contributor

@smelc smelc commented Jan 18, 2024

Changelog

- description: |
    Improvements to --create-testnet-data
# uncomment types applicable to the change:
  type:
  # - feature        # introduces a new feature
  # - breaking       # the API has changed in a breaking way
  - compatible     # the API has changed but is non-breaking
  # - optimisation   # measurable performance improvements
  # - improvement    # QoL changes e.g. refactoring
  # - bugfix         # fixes a defect
  - test           # fixes/modifies tests
  # - maintenance    # not directly related to the code
  # - release        # related to a new release preparation
  # - documentation  # change in code docs, haddocks...

Context

This PR improves on a number of things, in particuler to make the user experience better (thinking of QA that will use this soon):

  • create-testnet-data: add --drep-keys flag #565 had forgotten to generate the README.md file in the folder of DRep keys. This PR does that.
  • The documentation for --supply and --supply-delegated is made more explicit, something requested many times by @CarlosLopezDeLara Will be done differently in another PR in the end
  • Tests of create-tesnet-data are augmented a bit

Fixes #492

Checklist

  • Commit sequence broadly makes sense and commits have useful messages
  • New tests are added if needed and existing tests are updated. See Running tests for more details
  • Self-reviewed the diff

@smelc smelc mentioned this pull request Jan 18, 2024
6 tasks
@smelc smelc marked this pull request as ready for review January 18, 2024 17:13
Copy link
Contributor

@Jimbo4350 Jimbo4350 left a comment

Choose a reason for hiding this comment

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

One comment

@@ -275,15 +275,19 @@ pGenesisCreateTestNetData envCli =
Opt.optional $ fmap Lovelace $ Opt.option Opt.auto $ mconcat
[ Opt.long "supply"
, Opt.metavar "LOVELACE"
, Opt.help "The initial coin supply in Lovelace which will be evenly distributed across initial, non-delegating stake holders. Defaults to 1 million Ada (i.e. 10^12 Lovelace)."
, Opt.help $ unlines [ "The initial coin supply in Lovelace which will be evenly distributed across initial, non-delegating stake holders. Defaults to 1 million Ada (i.e. 10^12 Lovelace)."
, " The total supply is this amount plus the amount specified with --supply-delegated."
Copy link
Contributor

Choose a reason for hiding this comment

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

This is confusing behaviour. --supply-delegated shouldn't add to the total supply it should delegate a proportion (or all) of whatever was specified by --supply. We should modify this behaviour in create-testnet-data.

Copy link
Contributor Author

@smelc smelc Jan 19, 2024

Choose a reason for hiding this comment

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

Let me do that in another PR 👍 So removing the change to the help from this PR.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

PRed: #581

@smelc smelc force-pushed the smelc/create-testnet-data-details branch from 67f53c9 to b072931 Compare January 19, 2024 14:04
@smelc smelc force-pushed the smelc/create-testnet-data-details branch from b072931 to 9a77245 Compare January 19, 2024 14:14
@smelc smelc force-pushed the smelc/create-testnet-data-details branch from 9a77245 to 15a0fa1 Compare January 19, 2024 14:21
@smelc smelc added this pull request to the merge queue Jan 19, 2024
Merged via the queue into main with commit b228e83 Jan 19, 2024
17 checks passed
@smelc smelc deleted the smelc/create-testnet-data-details branch January 19, 2024 16:34
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.

Add tests for create-staked
3 participants