Real-time data stops updating when switching back to 1-minute timeframe
Description: I am using the TradingView Chart Library in my project.
The historical candle feed is generated randomly on the backend so the chart is not empty.
I also generate a random real-time data feed and send it to the chart via WebSocket.
Problem:
When I am on the 1-minute timeframe, the real-time feed works correctly and shows active price updates.
Switching to the 5-minute timeframe, the real-time price is still visible and updating as expected.
However, if I switch back to the 1-minute timeframe, the real-time data stops updating on the chart.
By inspecting the WebSocket data stream, I confirmed that real-time price updates are still being sent continuously. Despite this, the 1-minute chart does not reflect any real-time movement.
Code: (Provide your relevant code here)
Environment:
TradingView Charting Library
WebSocket real-time feed
Randomized backend-generated historical candles
Expected Behavior: Real-time updates should continue to display correctly when switching between timeframes, including back to the 1-minute chart.
Additional Notes: This seems related to how subscribeBars and resolution changes are handled.
`