Skip to content

Conversation

@avnik
Copy link
Contributor

@avnik avnik commented Oct 23, 2023

No description provided.

@avnik avnik marked this pull request as draft October 23, 2023 18:34
Copy link
Member

@aciceri aciceri left a comment

Choose a reason for hiding this comment

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

In my head we should have a modules directory that contains a default.nix file (which is a flake.parts module) and other subdirectories. Each subdirectory contains at least a default.nix (which is a NixOS module) which imports interface.nix and implementation.nixand potentially other files (if the module need other files, also non Nix files). It would be nice if the flake.parts module was able to automatically expose as flake.nixosModules by scanning the modules directory.

For tests I was imagining exactly the same structure but with the top level folder named tests.

Signed-off-by: Alexander V. Nikolaev <avn@avnik.info>
Comment on lines 32 to 33
mainnet = 0;
private = 42;
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
mainnet = 0;
private = 42;
mainnet = 764824073;
preprod = 1;
preview = 2;
sanchonet = 4;

Not sure about mainnet, usually you never use it because you pass --mainnet or --testnet-magic <n>.

Copy link
Member

Choose a reason for hiding this comment

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

Also I would rename the option to protocolMagic for consistency different networks genesis files.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I disagree about protocolMagic, because it a high-level option regarding decide network to use. I extract values from iohk-lib.nix, so it can differ from protocol magic numbers. Anyway, we can rename it later,if needed

Copy link
Member

Choose a reason for hiding this comment

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

Where have you extracted those values exactly?
I got them from https://github.com/input-output-hk/cardano-configurations/blob/master/network/mainnet/genesis/byron.json (you can change mainnet to other network names), look for the protocolMagic key in the JSONs.

For now let's ignore this, I'm merging it.

Copy link
Contributor Author

@avnik avnik left a comment

Choose a reason for hiding this comment

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

Looks like I fixed everything

@aciceri
Copy link
Member

aciceri commented Oct 30, 2023

@avnik Did some dumb polishing before merging, nothing worth to be discussed, just FYY:

  • renamed your commits that weren't using conventional names (still unsure if it's a thing that we want though)
  • realized that we weren't importing the shell module
  • wrote a minimal README
  • enable CI for x86_64-darwin (I don't know if you knew that we have an HCI agent for that architecture)

@zmrocze now this repo has a skeleton if you to take a look. Anyway #2 and #3 (which should be implemented in mlabs-haskell/devops) still have the priority.

@aciceri aciceri marked this pull request as ready for review October 30, 2023 21:00
@aciceri aciceri merged commit 2d064d7 into master Oct 30, 2023
@aciceri aciceri deleted the avnik/scaffolding branch October 30, 2023 21:00
@aciceri
Copy link
Member

aciceri commented Oct 30, 2023

@zmrocze since perhaps the CI thing it's a big confusing. Currently this repo has a working CI but it's still using the MLabs agent. Instead it has to use an ad hoc agent that pushes to an ad hoc cache.

@aciceri
Copy link
Member

aciceri commented Oct 30, 2023

Closes #1

Edit: hasn't worked automatically :(
I'm (manually) closing #1

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