IntersectMBO / cardano-node-emulator

Apache License 2.0
3 stars 4 forks source link

Genesis Files Default to Nothing in Emulator Initialization #35

Open Dr-Mazen-Khaddaj opened 2 weeks ago

Dr-Mazen-Khaddaj commented 2 weeks ago

Description: I've been reviewing how the emulator loads Genesis files upon start and found that it defaults to Nothing. I want to clarify if this is intentional or if there's an option to provide Genesis files explicitly. If not, is there a plan to support this functionality, especially with the upcoming Conway upgrade?

Steps to Reproduce:

Expected Behavior: An explicit genesis file should be required or loaded if available.

Actual Behavior: Defaults to Nothing without indicating the need for a genesis file.

Questions:

Would you happen to know if this is the intended behavior? How does the emulator load Genesis files upon the start?

Additional Information: This could affect configurations when simulating different blockchain states during testing or development.

smelc commented 3 days ago

@Dr-Mazen-Khaddaj> interim maintainer of cardano-node-emulator here :wave:

Indeed as you pointed out, it is not possible actually to specify custom genesis files, as the paths are defaulted to Nothing here and the default value is used in the main.

We could have the main take command-line parameters (using optparse-applicative) and allow the user to give paths to its own genesis files. Would that help with you use case?