charting-library-tutorial icon indicating copy to clipboard operation
charting-library-tutorial copied to clipboard

Add support intraday resolutions

Open axelkeegan opened this issue 4 years ago • 14 comments

Greetings,

thank you team for this great tutorial. I managed to switch the timeframe to 1 minute chart successfully, but getBars method is calling only once. Currently only the last bar is receiving the updates, and new bars are not generated. What needs to be done in order to call getBars every 60 seconds ?

axelkeegan avatar Aug 28 '20 19:08 axelkeegan

can you provide steps to reproduce please?

timocov avatar Sep 01 '20 14:09 timocov

will provide info later today. sorry for the delay.

axelkeegan avatar Sep 09 '20 14:09 axelkeegan

onReady method added support for 1,5,15 minutes.

....
const configurationData = {
    supported_resolutions: ['1D', '1W', '1M'],
    exchanges: [
....

Turned intraday to true, in order to enable above resolutions

....
   has_intraday: false,
....

inside getBars method, changed

const data = await makeApiRequest(data/histoday?${query}); to

const data = await makeApiRequest(data/histominute?${query});

Basically nothing else was changed from the tutorial steps. The end result is perfectly working 1-5-15 minute TV chart, data is collected successfully. Once TV chart is ready and all bars are drawn, all next changes are drawn only on the last candle, no new candles are drawn. No matter which resolution is used 1-5-15.

Will be happy to understand how i can make it working on 1-5-15 minutes chart.

Another interesting problem is, if we have two separate servers where this tutorial is loaded, if we open them in two separate browser tab, only one of them is working because of 'CORS'. But this is another issue.

Regards,

axelkeegan avatar Sep 10 '20 10:09 axelkeegan

UP @timocov

axelkeegan avatar Sep 14 '20 11:09 axelkeegan

Sorry for late reply.

Can you prepare a repro for that and steps for reproduce after that changes please? A repo or a git diff with changes so I can apply them and see what's going on?

Another interesting problem is, if we have two separate servers where this tutorial is loaded, if we open them in two separate browser tab, only one of them is working because of 'CORS'. But this is another issue.

Not sure how 2 tabs are related to the CORS problem.

timocov avatar Sep 15 '20 17:09 timocov

No problem for the late reply, i suppose all of us are busy enough already.

Will be hard to upload the project to repo since already deleted the project due to debug process stuck. I believe will be much easier, if you are able to share some guidance how to convert your tutorial to 1-5-15 minutes chart configuration.

Regards,

axelkeegan avatar Sep 16 '20 05:09 axelkeegan

Ok, I marked it as feature request to add intraday resolutions.

timocov avatar Sep 16 '20 12:09 timocov

Highly appreciate it. Any expected ETA on it ?

Regards,

axelkeegan avatar Sep 16 '20 17:09 axelkeegan

UP @timocov

axelkeegan avatar Sep 23 '20 14:09 axelkeegan

No, we don't have any ETA for that. If somebody wants to fix it - PRs are welcomed.

timocov avatar Sep 24 '20 13:09 timocov

Some guiding lines will be appreciated ...

axelkeegan avatar Oct 16 '20 18:10 axelkeegan

: D ETAs are for professional companies, after you checked out their guides, you know they are not

Ezriral avatar Feb 20 '21 08:02 Ezriral

one year later no resolution ? is that hard to be introduced a way how to add intraday resolutions ?

vladyosifov avatar Aug 24 '21 11:08 vladyosifov

Hello, For those having same issues, I will try to answer as far as I know. You can't reach all resolutions because you are getting data by using cryptocompare websocket, you can see this in streaming.js where the line "wss://streamer.cryptocompare.com", you need to pay for all resolutions, but cryptocompare is not only option to get data from, for example i am getting minute resolution data from binance websocket for free.

serhatopcu avatar Jun 15 '23 08:06 serhatopcu