Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

why always listens to erc20 ABI and usdterc20 address events #186

Open
vnxz opened this issue Sep 5, 2023 · 1 comment
Open

why always listens to erc20 ABI and usdterc20 address events #186

vnxz opened this issue Sep 5, 2023 · 1 comment

Comments

@vnxz
Copy link

vnxz commented Sep 5, 2023

This package make me confuse.when i try to listen events by using this package, it show events are ERC20 events with erc20 address ,
even I use TRC20 Contract address , events are as follow

  "caller_contract_address" => "TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t"
    "result" => array:6 [▼
      0 => "0x7b64f080b919f781892d88446f4948befa8274a3"
      1 => "0x5aba65d4f38d98bbae846ad902e6ea7201c32202"
      2 => "113213150"
      "from" => "0x7b64f080b919f781892d88446f4948befa8274a3"
      "to" => "0x5aba65d4f38d98bbae846ad902e6ea7201c32202"
      "value" => "113213150"
    ]
    "transaction_id" => "eb652c70149ea79ffc80763ed95605f202742beff176701ce00ef7bf645dc086"
    "result_type" => array:3 [▶]
    "_unconfirmed" => true
    "block_timestamp" => 1693940001000
    "block_number" => 54436546
    "event_name" => "Transfer"
    "contract_address" => "TR7NHqjeKQxGTCi8q8ZY4pL8otSzgjLj6t"
    "event" => "Transfer(address indexed from, address indexed to, uint256 value)"
    "_fingerprint" => "3EHwYj8Z1CjpX8dohWQYgWzRgV8wxxvsCfo5Ljg6BKaAXWemRTqgHdR7puwmRvaNaBdX7UoyXL6vTbZSXkG3hxfBrUiN4RRBVS5JdPTDwSzxNLpnqCjb6knniKCPrAB6pj9vWYGGN9abvunpcgqgfNKHDAT8zxtx ▶"
    "event_index" => 0
  ]

from , to address are not TRC20 address, Lol , what the hell is going on,
ABI Json error?
do you have same issue?

@ygcool
Copy link

ygcool commented Oct 23, 2023

1: Replace 0x with 41

0x7b64f080b919f781892d88446f4948befa8274a3 => 417b64f080b919f781892d88446f4948befa8274a3

2: $tron->fromHex("417b64f080b919f781892d88446f4948befa8274a3");

// TMDf33v2phNDQ2gFPYZgswF78sZsJN6Fnx

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants