ord icon indicating copy to clipboard operation
ord copied to clipboard

Handle block count RPC error gracefully

Open andrewtoth opened this issue 3 years ago • 2 comments

If we fail to fetch the block count, it will just return an error from update_index with a JSON-RPC error. However, any uncommitted blocks will not be committed because it doesn't exit the loop. They will have to be indexed again. This PR will just log the error but continue indexing, so we can keep our cache. It will show a progress greater than 100%, but better than having a JSON-RPC error and uncommitted blocks.

andrewtoth avatar Feb 10 '23 02:02 andrewtoth

I confirm that https://github.com/casey/ord/commit/50f2ad7aebcca87bd31d2b28fa2d8ab67d7cf7cc on ord 0.5.0 has fixed the time-wasting issue of blocks re-indexing at 775000 every time. This is awesome. I was able to finish the last 1% of indexing today 🎉 Now i have an ord index compatible with 0.5.0

donnlee avatar Feb 18 '23 04:02 donnlee

I second @donnlee . My node succeeded on this as well (4GB raspberry pi)

vicariousdrama avatar Feb 18 '23 05:02 vicariousdrama

This PR works!

dougEfresh avatar Feb 18 '23 13:02 dougEfresh

Hi guys,

I have the version 0.5.0 and I still have the issue of indexing: HTTP response too short: length 0, needed 12

What can I do in this case? Thank you

jesuspb2 avatar Feb 22 '23 21:02 jesuspb2

@jesuspb2 upgrade to 0.5.1.

andrewtoth avatar Feb 22 '23 21:02 andrewtoth