Skip to content
This repository has been archived by the owner on Jun 17, 2022. It is now read-only.

opts.keyPath and opts.genesisPath #194

Open
nullart2 opened this issue Feb 19, 2020 · 0 comments
Open

opts.keyPath and opts.genesisPath #194

nullart2 opened this issue Feb 19, 2020 · 0 comments

Comments

@nullart2
Copy link

Hi,

I'm using lotion with coins for the first time using the code below. On initial run, where can I get the keys.json and genesis.json?


let app = lotion({
	initialState: {
		 count: 0
	},
	 keyPath: './keys.json',        // path to keys.json. generates own keys if not specified.
  	genesisPath: './genesis.json', // path to genesis.json. generates new one if not specified.
  	peers: [],
  	logTendermint: true
})

function transactionHandler(state, transaction) {
	if (state.count === transaction.nonce) {
		state.count  
	}
}

app.use(transactionHandler)

app.start().then(appInfo => console.log(appInfo.GCI))

this is the error when specifying a "keys.json" and "genesis.json":

Error: ENOENT: no such file or directory, open './config/genesis.json'
(node:96079) UnhandledPromiseRejectionWarning: Error: no keys file found at ./keys.json

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant