Priority ALLPAIRS-params.js vs poloniex-BTC_XXX-config.js changes after starting GUNBOT.
Tested: gunthy-linuxx64 - only with poloniex
ALLPAIRS-params.js:
...
BOT_SLEEP_DELAY:(1000) * 22
BOT_ON_FAIL_DELAY:(1000) * 55
...
poloniex-BTC_XXX-config.js:
...
BOT_SLEEP_DELAY:(1000) * 44
BOT_ON_FAIL_DELAY:(1000) * 55
...
>>> STARTING
When starting the bot (./gunthy-linuxx64 BTC_XXX poloniex) it prioritizes ALLPAIRS-params.js over poloniex-BTC_XXX-config.js.
Output:
next delay will be 22s
>>> RUNNING
Changing the ALLPAIRS-params.js while the bot is running will have no effect. Looks like the file is not watched.
But changing poloniex-BTC_XXX-config.js while the bot is running, triggers the reconfiguration and now it prioritizes poloniex-BTC_XXX-config.js over ALLPAIRS-params.js.
Changing poloniex-BTC_XXX-config.js to:
...
BOT_SLEEP_DELAY:(1000) * 44
BOT_ON_FAIL_DELAY:(1000) * 99 // <-- changed
...
Output:
next delay will be 44s
Suggestions:
- Watch both configs (ALLPAIRS-params.js and market-BTC_XXX-config.js) for changes.
- In any case (starting and running) prioritize the specific config (market-BTC_XXX-config.js) over the general config (ALLPAIRS-params.js).
I think this is what I am talking about too... here's what I wrote in Telegram & Gun asked me to post here:
1) set refresh time to 20 secs in Allpairs
2) set refresh time to 120 in Dash pair
3) start bot — it will use the 20 sec time
4) make a change and resave the Dash pair
5) Bot will reconfigure and use the 120 time
6) stop the bot and restart the bot — it will switch to the 20 sec time from AllPairs again
The problem here is, it breaks the reconfig totally. I suggest it always use the AllPairs as the override regardless of which is saved last. Of course, I also am an advocate of switching this, to make the coin's config the override, and All Pairs just a default (opposite of the way it works now)... but that's another issue for down the road. I think the "quick fix" is to do what I said in second sentence.
PS - I always feel bad reporting/suggesting... I wanted to compliment Gunthar on an awesome job on the bot! Really good work!