-
Notifications
You must be signed in to change notification settings - Fork 192
Unclaimed gas calculation incorrect #1030
Comments
I think failure would make sense if the total gas to claim suggested by I have to let this one sink in for a moment. I've been working on neo3 for a while now that I have to refresh my mind on the |
I think it will be hard for me to debug anything given that it is a claim on your account. My first idea is to compare the neo-python/neo/Core/Blockchain.py Line 441 in f343df6
with what the C# client would say here (make sure to not accidentally relay the transaction on the C# side) Comparing start height, end height and output value. If there is no difference there, then it must be somewhere here neo-python/neo/Core/Blockchain.py Line 487 in f343df6
|
OK, I have tracked the issue down to When I manually run the rest of the GAS calculation with the proper/expected value, it does result in the proper GAS amount, so this is definitely the issue. I'm going to see if I can get a new chain DB to see if it's just my local DB being out-of-whack that's the issue. |
I checked a different fully sync'd neo-python chain, and it has the same issue. @ixje, do you have a neo-python 2.0 chain you can test against? I'm just using the RPC server to quickly test:
With the JSON-RPC call:
Expecting a value of |
I unfortunately have to say no. I used to have a VPS running the latest version for audit reasons but that seems to have died and I've not been able to recover it (yet). The fastest option I can think of is taking a iirc the |
It worked! 🎉 I did a full re-sync, starting from @ixje's bootstrap, syncing with Thanks, @ixje! Glad to hear neo-python had it right; once I saw your confidence that it should work, I was very hopeful that's all it would be 👍 |
Current behavior
Yes, running latest
development
branch.There is one transaction for which gas is unclaimable.
Expected behavior
Gas claim works.
How to reproduce
Trying to claim gas for the address
AZXKdEc2M73qeQMmPj2zmKJFDWmzQf8Gyr
. There is currently only one transaction with unclaimed gas:5a6fd5a783fb1673bc8d7aebb981e6d96c64da1a0f0448e47c65f23e367253f3
neo-python thinks the total GAS to claim is
4.70274012
. Neoscan and Neotracker, on the other hand, both report the total GAS to claim as4.84828396
:https://neoscan.io/address/AZXKdEc2M73qeQMmPj2zmKJFDWmzQf8Gyr
https://neotracker.io/address/AZXKdEc2M73qeQMmPj2zmKJFDWmzQf8Gyr
My suspicion is that something in neo-python's calculation is wrong.
When you try to claim GAS for this transaction, here is the claim transaction that is created:
This transaction gets relayed, but it's never actually processed, presumably because it's not valid.
Note that there were 12 other transactions for which I was able to successfully claim gas (by modifying neo-python to process one claim at a time), so it appears there is something special about the gas calculation for this specific transaction that is causing the problem.
Note also that this is a smart contract address, so I don't know if that has anything to do with it.
I'm happy to help debug/troubleshoot if it's helpful.
Your environment
Let us know in what environment you're running into the issue:
v0.9.2-dev
3.7.4
The text was updated successfully, but these errors were encountered: