thorswap / SwapKit

SwapKit SDK - Integrate blockchains easily. Docs - https://docs.thorswap.finance/swapkit-docs
https://swapkit.dev
Apache License 2.0
48 stars 25 forks source link

Error submitting deposits on Maya #682

Closed mattgabriel closed 2 months ago

mattgabriel commented 5 months ago

Current behavior

All deposit transactions on the Maya chain are currently failing with the error below:

Error: Broadcasting transaction failed with code 6 (codespace: sdk). Log: all coins must be native to BASEChain: unknown request
at GA.broadcastTxSync
at async GA.broadcastTx
at async BA
at async Je$1.eval [as deposit]

How to reproduce:

const client = createSwapKit();
await client.connectKeystore(Chain.Maya, phrase);
const hash = await client.deposit({
    assetValue: new AssetValue({
      value: 1,
      decimal: 10,
      chain: Chain.Maya,
      symbol: 'CACAO',
    }),
    memo: test,
    recipient: '',
});

Also fails when registering a MayaName since it also a deposit:

const hash = await client.registerMayaname({
  name: 'test1',
  chain: Chain.Maya,
  assetValue: new AssetValue({
    value: getMAYANameCost(1),
    decimal: 10,
    chain: Chain.Maya,
    symbol: 'CACAO',
  }),
  address: 'maya1.....',
});

Expected behavior

It should work like it does for THORChain.

Functionality

Packages

Details

Package versions:

# Paste the output of `<npm|yarn|pnpm|bun pm> ls --depth=0 | grep @swapkit` here
ice-chillios commented 4 months ago

@mattgabriel could you try with newest version? We currently testing Maya and it seems working fine for actions 🤔