gnome-shell-bitcoin-markets
gnome-shell-bitcoin-markets copied to clipboard
Update interval
What is the default update interval?
Is it possible to change that value? If yes, how, please? If not, please consider this as a feature request.
the default interval are defined in each of the api provider see https://github.com/OttoAllmendinger/gnome-shell-bitcoin-markets/blob/master/src/ProviderBXinTH.js#L17
If you can follow the Javascript then you can find the code here (probably) https://github.com/OttoAllmendinger/gnome-shell-bitcoin-markets/blob/master/src/BaseProvider.js#L108-L113
And you can change the interval directly in the code (in seconds). However, it's tedicious since it requires each of the APIs to be altered manually. This also requires a bit of experience with fiddling of gnome extensions.
@dx486 Also please see https://github.com/OttoAllmendinger/gnome-shell-bitcoin-markets/issues/14 regarding the interval
The interval is defined for each provider in the "interval" attribute (in seconds): https://github.com/OttoAllmendinger/gnome-shell-bitcoin-markets/blob/master/src/ProviderPoloniex.js#L27
Most APIs have rate limits, the values are chosen so the extension doesn't hit the limit. Feel free to tweak them but be aware that your IP can get banned.
I don't think anybody wants a higher polling interval, and if there is a safe smaller polling interval for an API let me know and I will change it. I don't think this needs to be configurable by the user.
It's not only a question about rate limit, according to me i don't need to request each 10s. It's useless. Each minute should be enough. It's not about trading, but to be in touch with the current price. So a "Interval" setting in seconds would be great.