liquality / atomicagent

💥 Atomic Agent
https://www.npmjs.com/package/atomicagent
MIT License
23 stars 35 forks source link

Fail to swap ETH to NEAR #362

Open think-in-universe opened 3 years ago

think-in-universe commented 3 years ago

Description

When running atomic agent and wallet locally. we met the below error in wallet when swap ETH to NEAR.

Error: Can not sign transactions for account 77edf44c33b222feb3a31b2ac7a002d528334c31b06653cdc335182c19773431 on network testnet, no matching key pair found in InMemorySigner(InMemoryKeyStore).

Retry doesn't work.

Screenshots:

image image image

think-in-universe commented 3 years ago

the failure is because the account https://explorer.testnet.near.org/accounts/77edf44c33b222feb3a31b2ac7a002d528334c31b06653cdc335182c19773431 was not created when I initiated the swap from ETH to NEAR on testnet.

The retry works now after I send 10 NEAR from another account to 77edf44c33b222feb3a31b2ac7a002d528334c31b06653cdc335182c19773431, and then click Retry again.

monokh commented 3 years ago

This is somewhat expected behaviour in the environment you are running.

We have a separate service (not built in the agent) that funds a NEAR account if it is conducting a swap with no NEAR. This service is setup pointing at the live mainnet and testnet agent only. Since this is not available to you, you should have just a tiny amount of NEAR in your account before doing swaps to NEAR.

think-in-universe commented 3 years ago

@monokh thanks.

will this be an issue, if we set up our own atomic agents, or ask other market makers to set up their own atomic agents?