Author

Topic: Bitcoin API and timeouts... (Read 556 times)

legendary
Activity: 2576
Merit: 2267
1RichyTrEwPYjZSeAYxeiFBNnKC9UjC5k
August 05, 2015, 03:25:19 PM
#1
If one attempts to make calls to the bitcoin API while it is still syncing, often (sometimes not), I will get a 500 error timeout. This will happen with commands such as getblockcount. Other times, I might get an error 28 (which I can deal with easily enough). getblocktemplate seems to always return (even with an error).

So my question is, what is the best way to avoid the 500 errors. Do I just need a longer timeout or is bitcoind pretty much "too busy" for the duration? Is there a strategy to use such as calling getblocktemplate first and if that doesn't return an error, I can proceed?
Jump to: