cncli icon indicating copy to clipboard operation
cncli copied to clipboard

InvalidCbor error when running cncli-sync on SanchoNet

Open happystaking opened this issue 3 months ago • 0 comments

Describe the bug The cncli sync service does not fully sync when running on a SanchoNet node. Instead it fails around 86-88% with ERROR cncli::nodeclient::sync > InvalidCbor("unexpected type u8 at position 263: expected array"). The error does not always occur at the same block.

Removing the cncli db and starting from scratch yields the same result.

To Reproduce

  1. Spin up a SanchoNet node and let it sync with the SanchoNet chain
  2. Start a fresh cncli instance with an empty database
  3. Let it sync and wait for the error to show up in the journal

Expected behavior It will sync to 100% and keep it there.

Additional context Last lines from the journal:

INFO  cncli::nodeclient::sync > block 1016212 of 1163604:  87.33% sync'd  
INFO  cncli::nodeclient::sync > block 1032098 of 1163604:  88.69% sync'd  
ERROR cncli::nodeclient::sync > InvalidCbor("unexpected type u8 at position 263: expected array")  
cncli-sync.service: Main process exited, code=exited, status=1/FAILURE 
systemd[1]: cncli-sync.service: Failed with result 'exit-code'.

The service is started with the following command and runs as a systemd service: cncli sync --host [redacted] --port 3004 --db /var/local/cncli/db.sqlite --network-magic 4

Tested with precompiled versions 6.0.1 and 6.1.0.

happystaking avatar Mar 21 '24 14:03 happystaking