Closed hanakannzashi closed 6 months ago
This also happen when using near-api-js
Facing same issue. I do have the key pair in the near-credentials folder.
❯ near send not-this-account.testnet garbage-account.testnet 10
Sending 10 NEAR to garbage-account.testnet from not-this-account.testnet
An error occured
Error: Can not sign transactions for account not-this-account.testnet on network testnet, no matching key pair found in InMemorySigner(MergeKeyStore(UnencryptedFileSystemKeyStore(/Users/---/.near-credentials), UnencryptedFileSystemKeyStore(/Users/---/.near-credentials/testnet/neardev))).
at Account.signTransaction (/Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/node_modules/near-api-js/lib/account.js:93:19)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async /Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/node_modules/near-api-js/lib/account.js:118:34
at async Object.exponentialBackoff [as default] (/Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/node_modules/near-api-js/lib/utils/exponential-backoff.js:7:24)
at async Account.signAndSendTransactionV2 (/Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/node_modules/near-api-js/lib/account.js:117:24)
at async exports.sendMoney (/Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/index.js:263:20)
at async Object.handler (/Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/utils/exit-on-error.js:52:9)
TypedError: Can not sign transactions for account not-this-account.testnet on network testnet, no matching key pair found in InMemorySigner(MergeKeyStore(UnencryptedFileSystemKeyStore(/Users/---/.near-credentials), UnencryptedFileSystemKeyStore(/Users/---/.near-credentials/testnet/neardev))).
at Account.signTransaction (/Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/node_modules/near-api-js/lib/account.js:93:19)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async /Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/node_modules/near-api-js/lib/account.js:118:34
at async Object.exponentialBackoff [as default] (/Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/node_modules/near-api-js/lib/utils/exponential-backoff.js:7:24)
at async Account.signAndSendTransactionV2 (/Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/node_modules/near-api-js/lib/account.js:117:24)
at async exports.sendMoney (/Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/index.js:263:20)
at async Object.handler (/Users/---/.config/nvm/versions/node/v18.12.1/lib/node_modules/near-cli/utils/exit-on-error.js:52:9) {
type: 'KeyNotFound',
context: undefined
}
Key pair present in folder:
~/.near-credentials/testnet
❯ ls | grep not-this
not-this-account.testnet.json
A new version has been released, let us know if the error persists
Describe the bug I do have keypair file in
~/.near-credentials/testnet
, but sometimesnear call
does't work. It showsKeyNotFound
. This often happens when I operate frequently. My cli version is3.4.2