[Updated] Fixing @someguy123's steemfeed-js to work with BTC-E down

in #witness-category7 years ago (edited)

Since BTC-e is down, steemfeed-js by @someguy123 is not working... In fact, when checking the price with BTC-e, it crashes.

@someguy123 updated his steemfeed-js repo, so you don't have to do all this! Read his post here

Note: As @drakos said in his comment below, his steemfeed is working fine. While my edit is easily reversible, make sure yours is crashing before changing it, otherwise you are wasting your time!


This is a quick fix, until a new version is released, so follow these instructions:

  1. Go to the steemfeed-js folder.
  2. cd lib
  3. nano exchange.js
  4. Inside this file, locate this part:
var BTCEAdapter = require('./adapters/BTCEAdapter'),
    PoloniexAdapter = require('./adapters/PoloniexAdapter'),
    BittrexAdapter = require('./adapters/BittrexAdapter')
    ;


change it to read like this:

// var BTCEAdapter = require('./adapters/BTCEAdapter'),
var PoloniexAdapter = require('./adapters/PoloniexAdapter'),
    BittrexAdapter = require('./adapters/BittrexAdapter')
    ;


Then, locate this line:

add_adapter(BTCEAdapter);


And change it to this:

// add_adapter(BTCEAdapter);



Exit and save..


We now have to recompile the steemfeed-js by going to its folder and running this command:

docker build -t steemfeed-js .


Start the feed again:

docker run -itd --rm --name feed steemfeed-js



If you are not running the dockerised version, start it via nodejs

And now, business as usual!


Also, I am running a witness server.

Please consider voting me, dimitrisp, for a witness if you find what I post & do helpful and add value to the network

You can read my witness declaration here

Sort:  

It's working fine here though, it simply skips BTC-e:

[2017-07-29T16:00:04.940Z] Publishing immediately, then every 360 minute(s)
[2017-07-29T16:00:04.942Z] Querying Poloniex (btc/steem)
[2017-07-29T16:00:04.946Z] Querying Bittrex (btc/steem)
[2017-07-29T16:00:04.949Z] Querying Poloniex (btc/usd)
[2017-07-29T16:00:04.950Z] Querying BTC-e (btc/usd)

Invalid response code or server error: null 522
Exchange BTC-e is down! Skipping... true
[2017-07-29T16:00:35.043Z] STEEM/USD is  1.238
[2017-07-29T16:00:35.047Z] Data published at:  Sat Jul 29 2017 16:00:35 GMT+0000 (UTC)

Mine stopped crashing as soon as I disabled BTC-e 😐

Everything else on the server was working (and still is) fine

Coin Marketplace

STEEM 0.22
TRX 0.26
JST 0.039
BTC 98362.82
ETH 3451.59
USDT 1.00
SBD 3.21