superhero-com / superhero-wallet

Superhero Wallet – More than just a way to receive, store & send tokens on the æternity blockchain
https://wallet.superhero.com
ISC License
39 stars 38 forks source link

Wrong TXs on token #3053

Closed nikita-fuchs closed 3 months ago

nikita-fuchs commented 4 months ago

Hey, I just received one bridged USDT token ;)

Why is the transaction log in the wallet showing confusing things though?

https://github.com/superhero-com/superhero-wallet/assets/11761828/b1d9b281-546c-48ce-9368-6da5fe16214c

nikita-fuchs commented 4 months ago

FYI the token address is ct_2AiMceYFXnUdA6A9Lu2ZQ2tr2TpfbGVfkxLfBnceoWgHTKZYvc and my account address is ak_uTWegpfN6UjA4yz8X4ZVRi9xKEYeXHJDRZcRryTsRHAFoBpLa

CedrikNikita commented 4 months ago

It seems that this type of transactions are not listed in the mdw https://mainnet.aeternity.io/mdw/v3/aex9/ct_2AiMceYFXnUdA6A9Lu2ZQ2tr2TpfbGVfkxLfBnceoWgHTKZYvc/transfers?account=ak_uTWegpfN6UjA4yz8X4ZVRi9xKEYeXHJDRZcRryTsRHAFoBpLa

This is the only transaction related to this contract we have managed to get from mdw, using this endpont.

https://mainnet.aeternity.io/mdw/v2/accounts/ak_uTWegpfN6UjA4yz8X4ZVRi9xKEYeXHJDRZcRryTsRHAFoBpLa/activities

{
      "type": "ContractCallTxEvent",
      "height": 948377,
      "block_hash": "mh_2pDPja17d8s9wbNXW4CpRgDsE3ueGaKHzxbLH4ZjShJMfywH1A",
      "payload": {
        "block_hash": "mh_2pDPja17d8s9wbNXW4CpRgDsE3ueGaKHzxbLH4ZjShJMfywH1A",
        "block_height": 948377,
        "encoded_tx": "tx_+NcLAfhCuEChT03iTcuCicVPgT0j4/gvAGqxglbCR4ira10Qq+XMMwCoAhPn012N4bzvuVOGmUryoKKtJKUHv1YWvRlOySgKuI/4jSsBoQF3HDimaXVPjyhNjk1H78cNW6xmYoc24cvQ9B28s5M0c4HtoQWZwC5BRsMejDEbHpUkBwsFjZAjxY8XEU962oV5E6Ic0wOGpk9pV/gAgw54nACCGdKEO5rKAK8rEe/MWOErnwCg4p7nIz2hDixqNe5TdyE80zAksQug/ePzXsWaAab6iodvgw9CAJcvXjU=",
        "hash": "th_CJemh2nFtMnfHojh9spMJNk7fsnY8xwUkBZN87UH2WVh2dL1Q",
        "micro_index": 34,
        "micro_time": 1716293178417,
        "signatures": [
          "sg_N72ZXnmWgqNpTozLzXs5TYzAFaBg3mhyE122AFhuWfzUx8WYT66X1azRqERZC41x3peEmZ8grKRvph13BwQrhkzHsW7HG"
        ],
        "tx": {
          "abi_version": 3,
          "aexn_type": "aex9",
          "amount": 0,
          "arguments": [
            {
              "type": "address",
              "value": "ak_2ioisnF4reEMxWz4hkX5DhR4D6h83oW9ShHfAvs89E6PKqphA9"
            },
            {
              "type": "int",
              "value": 1000000
            }
          ],
          "call_data": "cb_KxHvzFjhK58AoOKe5yM9oQ4sajXuU3chPNMwJLELoP3j817FmgGm+oqHb4MPQgBotanh",
          "caller_id": "ak_uTWegpfN6UjA4yz8X4ZVRi9xKEYeXHJDRZcRryTsRHAFoBpLa",
          "contract_id": "ct_2AiMceYFXnUdA6A9Lu2ZQ2tr2TpfbGVfkxLfBnceoWgHTKZYvc",
          "fee": 182860000000000,
          "function": "create_allowance",
          "gas": 6610,
          "gas_price": 1000000000,
          "gas_used": 5288,
          "log": [
            {
              "address": "ct_2AiMceYFXnUdA6A9Lu2ZQ2tr2TpfbGVfkxLfBnceoWgHTKZYvc",
              "data": "cb_Xfbg4g==",
              "topics": [
                "6675387653529534352993899574763440621350730065146058041830673378811230846814",
                "53875091683475111476451629676645823991858014834876290127600872463679999915123",
                "102503460869547734593096252361841109291585426008369033344117281444812455316103",
                "1000000"
              ]
            }
          ],
          "nonce": 237,
          "result": "ok",
          "return": {
            "type": "unit",
            "value": ""
          },
          "return_type": "ok",
          "ttl": 948380,
          "type": "ContractCallTx",
          "version": 1
        }
      },

Do you have a transaction hash in order to check if it is event presented in the mdw?

nikita-fuchs commented 4 months ago

Is what you are missing somehow related to this? https://github.com/aeternity/aescan/issues/798

When looking at the call transactions there, things seem to be missing. When looking at the events, there is a minting happening: https://aescan.io/transactions/th_9hsJzzrx67y17ue7vKK7kyyi9hoYgCvaYqBe9sZBe998hR5pq may it be that there are issues because there is no transfer event fired... ?

CedrikNikita commented 4 months ago

I think generally it is a ae_mdw issue with indexing.

CedrikNikita commented 4 months ago

Should be resolved when this issue will be fixed and released. https://github.com/aeternity/ae_mdw/issues/1780

CedrikNikita commented 3 months ago

The issue was fixed on mdw side https://github.com/aeternity/ae_mdw/issues/1780.

nikita-fuchs commented 3 months ago

thanks guys !