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

WARNING: The MNEMONIC variable is not set. Defaulting to a blank string. #217

Open
devrajsinghrawat opened this issue Aug 10, 2021 · 6 comments

Comments

@devrajsinghrawat
Copy link

When I am starting the docker-compose then the mnemonic does not picked from .env file as mentioned in comment in docker compose file.

  # This env variable comes from the .env file in the directory in which the
  # docker-compose command is run. Here it will be ./packages/sidetree-ledger-ethereum

Screenshot 2021-08-10 at 13 30 18

and due to that every time, when the container is being restarted a new set of keys are being assigned.

I am starting the container, just by right click on the docker-compose in vscode by selecting "Compose up" option.

@devrajsinghrawat
Copy link
Author

devrajsinghrawat commented Aug 11, 2021

I would like to add here that this only occuers when I start the container directly using docker-compose file .. But when these containers are started using PreTest that time it picks the env variables correctly.

i.e. if I run

npm run test:only @sidetree/element

then it ll internally call pretest "pretest": "docker-compose up -d mongo ganache ipfs",

and picks up correct mnemonics.

@OR13
Copy link
Sponsor Member

OR13 commented Sep 7, 2021

hmm, seems like we probably need to separate the docker compose files so that running a local node is easier.

@devrajsinghrawat
Copy link
Author

I ll let it open so that you can close it, when it done in future releases

@BenjaminMoe
Copy link
Member

I think I've seen this when starting up a server. Want to see if it's happening, and why it's happening, because the seed should be defined in the configuration file.

@BenjaminMoe
Copy link
Member

Taking some notes, it looks like this error can be reproduced by running the test for the cas-ipfs module.

> @sidetree/cas-ipfs@0.3.1-unstable.25 pretest ~/Github/sidetree.js/packages/cas-ipfs
> docker-compose up -d ipfs mongo

WARNING: The MNEMONIC variable is not set. Defaulting to a blank string.
sidetreejs_ipfs_1 is up-to-date
sidetreejs_mongo_1 is up-to-date

> @sidetree/cas-ipfs@0.3.1-unstable.25 test ~/Github/sidetree.js/packages/cas-ipfs
> tsdx test --passWithNoTests

So we need to track down where that warning is coming from, and if it's needed or not.

@OR13
Copy link
Sponsor Member

OR13 commented Jan 19, 2022

This should be defaulted to an example.

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

No branches or pull requests

3 participants