Open Keith-CY opened 9 months ago
start block number is same in both mac and windows:11,377,640 sync process is 100% both mac and windows.
The balance between mac and windows is different: mac:10212.94513794 windows:14416.77926062
ckt1qzda0cr08m85hc8jlnfp3zer7xulejywt49kt2rr0vthywaa50xwsqd9grz2p0fy98dq2m2hnaaeugfshrg08fqejjqaz is lost in windows.
and windows has two balance which mac does not have.
After clear cache: The balance between mac and windows is different: mac:10212.94513794 windows:16988.78824545
After clear cache: mac: transactions_1701077538974.csv
windows: transactions_1701077621475.csv
When using light nodes to synchronize data, it was found that neither the input nor the changes in the Nervos dao operation were recognized as this wallet address, only the first output was recognized. It should be that when synchronizing to this transaction, the input and output are not exported. Missing confirmation after export that the transaction has been synchronized. Preliminary confirmation is that when optimizing input and output storage, when deriving addresses, there was a lack of verification of whether there were synchronization exceptions in previous transactions.
I have verified with my local start Neuron. The remote Linux is syncing with https://github.com/nervosnetwork/neuron/pull/2965#issuecomment-1833158839
I have verified the Light client with https://github.com/nervosnetwork/neuron/pull/2965#issuecomment-1835820718. Here are the results: Remote Linux tx table: remote_linux_863.csv Local Virtual Linux tx table: local_virtual_linux_863.csv Local Mac tx table: local_863.csv
And here is the full node result with https://github.com/nervosnetwork/neuron/pull/2965#issuecomment-1835820718: full_local_863.csv
There are two conditions that the light client will miss some tx.
fetch_transaction
to get the input detail, after calling fetch_transaction
with the input's tx, the tx will not return by get_transactions
set_script
with partial
for better performance.So, I will update the light node synchronization from the following two aspects:
partial
to call set_script
when some addresses are derived. And use all
to call set_script
when switching wallets.Verified
Package: https://github.com/nervosnetwork/neuron/actions/runs/6978628219 Wallet: david.json Network: Testnet
Tx: 0x56313e625d978c85636f306e493ec8f25c05173f8238fd2c4e4e5aacc60b9b63![image](https://github.com/Magickbase/neuron-public-issues/assets/7271329/ee034eeb-775b-49f5-8e7b-52a1a84b5544)
The same transaction is treated as an income in Neuron running on Linux and Windows, but as an expense on MacOS. The result is steady after
clear cache
.Thus the balance is incorrect![image](https://github.com/Magickbase/neuron-public-issues/assets/7271329/36334e47-d748-4e51-a014-309b46490da7)
Checking the balance of the change address https://pudge.explorer.nervos.org/address/ckt1qzda0cr08m85hc8jlnfp3zer7xulejywt49kt2rr0vthywaa50xwsq2yuuc0tnwnhytd0e6p8ur63m03an6xa9gq08v25
Obviously, David.json on Linux and Windows lost balance of ckt1qzda0cr08m85hc8jlnfp3zer7xulejywt49kt2rr0vthywaa50xwsq2yuuc0tnwnhytd0e6p8ur63m03an6xa9gq08v25
Search the address in history and get 3 results
It's probably caused by dirty data on Linux and Windows, e.g. synced data of an unpublished neuron that has a known bug. But the data are left for further debugging, and we'd better verify David.json on other platforms.