8000 opts.keyPath and opts.genesisPath · Issue #194 · keppel/lotion · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Jun 17, 2022. It is now read-only.
This repository was archived by the owner on Jun 17, 2022. It is now read-only.
opts.keyPath and opts.genesisPath #194
Open
@nullart2

Description

@nullart2

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0