Skip to content

Conversation

intricate
Copy link
Contributor

No description provided.

@intricate intricate self-assigned this May 8, 2020
@intricate intricate force-pushed the intricate/20200508-deps branch from 958ccf4 to d6e1f93 Compare May 8, 2020 23:12
@intricate intricate requested review from dcoutts, Jimbo4350 and erikd May 8, 2020 23:12
@intricate
Copy link
Contributor Author

@dcoutts: If you prefer that I keep all of the keys in PascalCase, I can drop that change and update the PParams keys to be PascalCase.

@intricate intricate marked this pull request as ready for review May 8, 2020 23:12
Comment on lines +20 to +22
"extraEntropy": {
"tag": "NeutralNonce"
},
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@erikd @dcoutts: Any suggestions as to how this value should be formatted? Right now, I'm just deriving the JSON instances for this type, Nonce.

Copy link
Contributor

Choose a reason for hiding this comment

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

Morally it's a Maybe, and a leaf one at that. So it could easily be empty/null or a hash string (as hex, which is probably already the default for that).

@dcoutts
Copy link
Contributor

dcoutts commented May 8, 2020

I don't really care provided it's consistent. We'll have to update the examples in the docs anyway.

@intricate
Copy link
Contributor Author

We'll have to update the examples in the docs anyway.

Right, I'll do that now.

@dcoutts
Copy link
Contributor

dcoutts commented May 8, 2020

Right, I'll do that now.

If you're doing that, you can also make the story simpler: if the genesis.spec.json is missing, use the shelleyGenesisDefaults and perhaps even write those defaults out to genesis.spec.json so people can edit them. That will make the instructions much nicer.

That also gives us a cheap and cheerful way to print the defaults.

Copy link
Contributor

@dcoutts dcoutts left a comment

Choose a reason for hiding this comment

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

LGTM.

Using the defaults and writing out a genesis.spec.json in the create-genesis command would be an excellent bonus.

@erikd erikd force-pushed the intricate/20200508-deps branch from 21352cb to d0db4c8 Compare May 9, 2020 05:11
genUnitInterval :: Gen UnitInterval
genUnitInterval =
UnsafeUnitInterval
<$> Gen.realFrac_ (Range.linearFrac 0 1)
Copy link
Contributor

Choose a reason for hiding this comment

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

According to the hedgehog docs realFrac_ does not shrink. Should we use the double generator here instead?

Copy link
Contributor

Choose a reason for hiding this comment

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

Shrinking not too important here.

@erikd
Copy link
Contributor

erikd commented May 9, 2020

bors r+

@iohk-bors
Copy link
Contributor

iohk-bors bot commented May 9, 2020

@iohk-bors iohk-bors bot merged commit fbb0358 into master May 9, 2020
@iohk-bors iohk-bors bot deleted the intricate/20200508-deps branch May 9, 2020 05:52
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