Closed antonios988 closed 3 years ago
Hey @antonios988 Did it get stuck while running or it did not start at all?
npm.txt dont start. this is my npm lib
Try the following:
cd to project dir npm install
node Generate_Addresses_From_Seed.js
same problem
Can I see the file path you're passing in line 10?
yes all step done
require('fs').readFileSync('C:/Users/Antonio/Desktop/Script_GenerateMnem_Check_Balance-main/word.txt', 'utf-8').split(/\r
what's your node version?
type node -v
and give me the result
I am setting up a new Linux machine to check there if I am missing something.
i have tried 12.19.0 and 14.13.1
any news?
Install node v10.21.0. https://nodejs.org/dist/v10.21.0/
Let me know
some error
Words successfully imported. internal/crypto/hash.js:58 throw new ERR_INVALID_ARG_TYPE('data', ^
TypeError [ERR_INVALID_ARG_TYPE]: The "data" argument must be one of type string, TypedArray, or DataView. Received type object
at Hmac.update (internal/crypto/hash.js:58:11)
at Function.HDKey.fromMasterSeed (C:\Users\Antonio\Desktop\script\node_modules\ethereum-cryptography\vendor\hdkey-without-crypto.js:188:58)
at Function.EthereumHDKey.fromMasterSeed (C:\Users\Antonio\Desktop\script\node_modules\ethereumjs-wallet\hdkey.js:20:26)
at findBalance (C:\Users\Antonio\Desktop\script\gen.js:30:26)
at generateMnemonic (C:\Users\Antonio\Desktop\script\gen.js:26:3)
at getWordsFromFile (C:\Users\Antonio\Desktop\script\gen.js:13:73)
at Object.
?
I totally forgot about this issue sorry.
Fix it by changing line 30 to const hdwallet = hdkey.fromMasterSeed(bip39.mnemonicToSeedSync(_mnemonic));
throw new ERR_INVALID_ARG_TYPE( ^
TypeError [ERR_INVALID_ARG_TYPE]: The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received an instance of Promise at Hmac.update (internal/crypto/hash.js:84:11) at Function.HDKey.fromMasterSeed (/home/crypto/Scrivania/Script_GenerateMnem_Check_Balance-main/node_modules/hdkey/lib/hdkey.js:181:54) at findBalance (/home/crypto/Scrivania/Script_GenerateMnem_Check_Balance-main/gen.js:30:26) at generateMnemonic (/home/crypto/Scrivania/Script_GenerateMnem_Check_Balance-main/gen.js:26:3) at getWordsFromFile (/home/crypto/Scrivania/Script_GenerateMnem_Check_Balance-main/gen.js:13:73) at Object. (/home/crypto/Scrivania/Script_GenerateMnem_Check_Balance-main/gen.js:55:1)
at Module._compile (internal/modules/cjs/loader.js:1063:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1092:10)
at Module.load (internal/modules/cjs/loader.js:928:32)
at Function.Module._load (internal/modules/cjs/loader.js:769:14)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
at internal/main/run_main_module.js:17:47 {
code: 'ERR_INVALID_ARG_TYPE'