You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
cardano-testnet seems to make assumptions about where it is run #4194
Hi, I discovered the cardano-testnet executable, I was hoping to run it against a derivation containing the config for a private testnet but apparently I can not run it at all through nix.
━━━ Exception (IOException) ━━━
../dist-newstyle/cache/plan.json: openBinaryFile: does not exist (No such file or directory)
This failure can be reproduced by running:
> recheck (Size 0) (Seed 14417734425994254147 11580250401777982633) <property>
Why is it trying to look for things in dist-newstyle?
This is still an issue (on 238b4c8), reproducible as follows:
# While in cardano-node repository
cabal build cardano-testnet
cabal build cardano-node
export TMP_PATH=$(mktemp -d)
cp $(cabal list-bin cardano-testnet) $(cabal list-bin cardano-node) $TMP_PATH/.
cd $TMP_PATH
./cardano-testnet cardano --num-pool-nodes 3 --testnet-magic 42
... lots of output
━━━ Exception (ErrorCall) ━━━
Could not find plan.json in the path: dist-newstyle/cache/plan.json
CallStack (from HasCallStack):
createSPOGenesisAndFiles, called at src/Testnet/Start/Cardano.hs:199:8 in cardano-testnet-10.0.0-inplace:Testnet.Start.Cardano
cardanoTestnet, called at src/Testnet/Start/Cardano.hs:93:3 in cardano-testnet-10.0.0-inplace:Testnet.Start.Cardano
cardanoTestnetDefault, called at src/Parsers/Run.hs:71:61 in cardano-testnet-10.0.0-inplace:Parsers.Run
This failure can be reproduced by running:
> recheckAt (Seed 9184080727122563869 11195688623784977365) "1:" <property>
As a long-term solution, we should not error out in this function, but rather have the callers handle the different failures. As a short-term solution, we should have a better error message when we fail, indicating that the environment variable can be defined as a workaround. I'm going to do the short-term solution to see how much progress we get regarding running cardano-testnet locally.
Activity
eyeinsky commentedon Sep 29, 2022
I've just run into this as well, @locallycompact did you ever managed to resolve or work around it?
koslambrou commentedon Sep 29, 2022
I fixed it locally by making the following env variables for Nix:
Jimbo4350 commentedon Oct 27, 2022
Closing this. Please reopen if this is still relevant.
gilligan commentedon Nov 22, 2024
I had the same issue outlined here where I get the error with opening
../dist-newstyle/cache/plan.jsonunlessCARDANO_CLIandCARDANO_NODEare set.Setting those solves the issue but this still seems like a workaround to an actual problem to me.
smelc commentedon Dec 9, 2024
This issue has also been reported by @johnalotoski here on Slack.
smelc commentedon Mar 18, 2025
This is still an issue (on 238b4c8), reproducible as follows:
smelc commentedon Mar 18, 2025
We need to change
hedgehog-extras'sbinDistfunction whicherrors here: https://github.com/input-output-hk/hedgehog-extras/blob/a8120b84d1baa4b26c69668fc37f307ba9e942e1/src/Hedgehog/Extras/Test/Process.hs#L302 when 1/ the environment variable for searching the executable isn't defined and 2/ theplan.jsonfile doesn't exist.As a long-term solution, we should not
errorout in this function, but rather have the callers handle the different failures. As a short-term solution, we should have a better error message when we fail, indicating that the environment variable can be defined as a workaround. I'm going to do the short-term solution to see how much progress we get regarding runningcardano-testnetlocally.