signum-network / signum-node

Signum Node
https://signum.network
GNU General Public License v3.0
194 stars 77 forks source link

Request `getTransaction` does not read `Token mint` transactions executed by a smart contract #825

Open ipr0310 opened 4 months ago

ipr0310 commented 4 months ago

Is your feature request related to a problem? Please describe. The node api getTransaction request is not able to get information of a Token mint transaction executed by an smart contract

https://europe2.signum.network/api?requestType=getTransaction&transaction=3826764388524773347

Response example:

{
  "errorCode": 5,
  "errorDescription": "Unknown transaction",
  "requestProcessingTime": 1
}

The explorer has it saved: https://explorer.signum.network/tx/3826764388524773347

Describe the solution you'd like The request should also show information about that transaction

Additional context I also found out the getAccountTransactions does not find that ID https://europe2.signum.network/api?requestType=getAccountTransactions&account=18339269626061634110

Is it an issue with the explorer?

ipr0310 commented 4 months ago

If i try to read a Token mint transaction executed by an user, not a smart contract It will appear normally

Explorer URL https://testnet.explorer.signum.network/tx/9351127744969003209

Request URL https://europe3.testnet.signum.network/api?requestType=getTransaction&transaction=9351127744969003209

Response:

{
  "type": 2,
  "subtype": 6,
  "timestamp": 245523389,
  "deadline": 20,
  "senderPublicKey": "4d6c56919197e341dd6a0253471e16bfbe223ad0076937c466d8aff56b21dd7b",
  "amountNQT": "0",
  "feeNQT": "1000000",
  "signature": "4f2eaae84d1828b9b8d492378234a10eb39ff10b3cbbe3e677a134821f595a0e8785f316c4e095bb621db3e9fd9a9f9c6f3ff875db714aa1780a9bba91ccb203",
  "signatureHash": "f92f44e6ce67fb3cf22f8ed585f7ffa16663ea556477ccc58c15cc06c6488896",
  "fullHash": "c9502dc023e1c5811ebde2bdf8a10d130ad6bd339ea40c95f0bf413ea187bffd",
  "transaction": "9351127744969003209",
  "attachment": {
    "version.AssetMint": 1,
    "asset": "15734729270853801993",
    "quantityQNT": "50000"
  },
  "attachmentBytes": "0109982edae7fc5cda50c3000000000000",
  "sender": "10657861381637251164",
  "senderRS": "TS-HA4W-GPUX-QPWD-BN4U9",
  "height": 419250,
  "version": 2,
  "ecBlockId": "16630564921237585775",
  "ecBlockHeight": 419238,
  "cashBackId": "8952122635653861124",
  "block": "11160572799194675873",
  "confirmations": 262125,
  "blockTimestamp": 245523641,
  "requestProcessingTime": 3
}
ipr0310 commented 4 months ago

Something weird is going on:

The transaction is found even tough it is executed by a smart contract.

Explorer URL https://testnet.explorer.signum.network/tx/11249404957632442290

Request URL https://europe3.testnet.signum.network/api?requestType=getTransaction&transaction=11249404957632442290

{
  "type": 2,
  "subtype": 6,
  "timestamp": 308764866,
  "deadline": 1440,
  "senderPublicKey": "d771c0789e79cb79000000000000000000000000000000000000000000000000",
  "amountNQT": "0",
  "feeNQT": "0",
  "transaction": "11249404957632442290",
  "attachment": {
    "version.AssetMint": 1,
    "asset": "4650261435909806",
    "quantityQNT": "120"
  },
  "attachmentBytes": "01ae06005d638510007800000000000000",
  "sender": "8776242020399215063",
  "senderRS": "TS-2WGR-MTWE-54M8-9TVLM",
  "height": 680719,
  "version": 1,
  "ecBlockId": "0",
  "ecBlockHeight": 0,
  "cashBackId": "0",
  "block": "2482729759072095452",
  "confirmations": 657,
  "blockTimestamp": 308764866,
  "requestProcessingTime": 3
}

Looks like the explorer maybe the issue