Hi everyone!
I’m currently developing a website using Express.js to list challenges we can find on steemit. I was facing a bug when I was requesting the blockchain.
My error was a timeout every time I was trying to request the blockchain for the second time. The first request was always working but the second one always gave me this « Timeout Error » and I had to restart my server every time to be able to request again the blockchain.
I tried everything and I finally found my answer thanks to @codingdefined.
Here is the link to @codingdefined ’s post where i found the solution
As @codingdefined explain in his post, we need to use another URL to request the blockchain with asynchronous functions.
Here are the commands to change the URL you will use :
// Steem var
const steem = require('steem');
steem.api.setOptions({url: 'https://api.steemit.com'});
Using that helped me to get rid of the timeout error.
Hope that’s gonna help you guys.
Posted on Utopian.io - Rewarding Open Source Contributors