Skip to content

Candle subscriptions - stale pair keeps retrying after connector change until Condor restart #134

Description

@rapcmia

Describe the bug

While checking market data in the web dashboard, a stale trading pair kept being reused even after the connector was changed or removed and the page was refreshed. In the observed case, Hyperliquid was removed from my portfolio, but the condor (web dashboard) still kept requesting PURR-USDC after refresh and started trying that pair against binance, which caused repeated invalid-symbol errors in the logs.

On the logs below, i requested BTC-FDUSD for binance from trade page

26-06-16 16:29:54,011 - condor.web.ws_manager - INFO - Started candle stream for candles:local:binance:BTC-FDUSD:5m
2026-06-16 16:29:54,014 - condor.web.routes.market - INFO - Fetching historical candles: connector=binance pair=BTC-FDUSD interval=5m start=1781339393 end=1781598594
2026-06-16 16:29:54,123 - condor.web.ws_manager - INFO - Candle WS subscribed: candles:local:binance:BTC-FDUSD:5m
2026-06-16 16:29:54,128 - condor.web.ws_manager - INFO - Candle WS subscribed: candles:local:binance:BTC-FDUSD:1m
2026-06-16 16:29:54,265 - condor.web.routes.market - INFO - Historical candles result: type=list len=864
2026-06-16 16:30:01,132 - condor.web.ws_manager - INFO - Candle WS first message for candles:local:binance:BTC-FDUSD:5m: {"type": "candles", "subscription_id": "candles_binance_BTC-FDUSD_5m", "data": [{"timestamp": 1781568600.0, "open": 66463.61, "high": 66486.6, "low": 66463.61, "close": 66475.9, "volume": 0.17357, "quote_asset_volume": 11538.3433935, "n_trades": 59.0, "taker_buy_base_volume": 0.13546, "taker_buy_quote_volume": 9004.8029804}, {"timestamp": 1781568900.0, "open": 66475.91, "high": 66500.0, "low": 66460.01, "close": 66467.1, "volume": 0.76149, "quote_asset_volume": 50634.3341024, "n_trades": 118.0,
2026-06-16 16:30:01,133 - condor.web.ws_manager - INFO - Candle WS first message for candles:local:binance:BTC-FDUSD:1m: {"type": "candles", "subscription_id": "candles_binance_BTC-FDUSD_1m", "data": [{"timestamp": 1781592600.0, "open": 66535.56, "high": 66569.99, "low": 66523.21, "close": 66557.54, "volume": 0.16564, "quote_asset_volume": 11021.8829832, "n_trades": 57.0, "taker_buy_base_volume": 0.16356, "taker_buy_quote_volume": 10883.454614}, {"timestamp": 1781592660.0, "open": 66569.99, "high": 66599.99, "low": 66565.38, "close": 66588.44, "volume": 0.22739, "quote_asset_volume": 15140.6821683, "n_trades": 50.
2026-06-16 16:30:02,828 - condor.web.ws_manager - WARNING - Candle stream error for candles:local:binance:ANON-USDC:1m: Subscribe failed: Trading pair 'ANON-USDC' appears to be invalid on 'binance': Error executing request GET https://api.binance.com/api/v3/klines. HTTP status is 400. Error: {"code":-1121,"msg":"Invalid symbol."}, reconnecting in 20s...
2026-06-16 16:30:02,938 - condor.web.ws_manager - WARNING - Candle stream error for candles:local:binance:ANON-USDC:5m: Subscribe failed: Trading pair 'ANON-USDC' appears to be invalid on 'binance': Error executing request GET https://api.binance.com/api/v3/klines. HTTP status is 400. Error: {"code":-1121,"msg":"Invalid symbol."}, reconnecting in 20s...
2026-06-16 16:30:17,828 - condor.web.ws_manager - WARNING - Candle stream error for candles:local:hyperliquid:ANON-USDC:1m: Subscribe failed: Trading pair 'ANON-USDC' appears to be invalid on 'hyperliquid': 'NoneType' object is not subscriptable, reconnecting in 60s...
2026-06-16 16:30:17,829 - condor.web.ws_manager - WARNING - Candle stream error for candles:local:hyperliquid:ANON-USDC:5m: Subscribe failed: Trading pair 'ANON-USDC' appears to be invalid on 'hyperliquid': 'NoneType' object is not subscriptable, reconnecting in 60s...
2026-06-16 16:30:23,002 - condor.web.ws_manager - WARNING - Candle stream error for candles:local:binance:ANON-USDC:1m: Subscribe failed: Trading pair 'ANON-USDC' appears to be invalid on 'binance': Error executing request GET https://api.binance.com/api/v3/klines. HTTP status is 400. Error: {"code":-1121,"msg":"Invalid symbol."}, reconnecting in 40s...
2026-06-16 16:30:23,076 - condor.web.ws_manager - WARNING - Candle stream error for candles:local:binance:ANON-USDC:5m: Subscribe failed: Trading pair 'ANON-USDC' appears to be invalid on 'binance': Error executing request GET https://api.binance.com/api/v3/klines. HTTP status is 400. Error: {"code":-1121,"msg":"Invalid symbol."}, reconnecting in 40s...

While checking the logs, I noticed that refreshing the page did not stop the old pair from retrying. From the user side, it looked like the previous market selection should already be gone, but the same pair kept producing errors after refresh. After fully stopping Condor and starting it again with make run, the retrying stopped. From this behavior, it looks like the old subscription or saved market state may still stay active longer than expected until Condor is restarted.

Steps to reproduce

  1. Build a Hummingbot .whl from the staging branch and use it in the stack you are testing. (OPTIONAL since hummingbot-lib could been updated already)
  2. Connect any connectors e.g hyperliquid and binance
  3. Go to trade page, select hyperliquid then any market pair, e.g ANON-USDC
  4. Then change to binance and any market pair e.g BTC-FDUSD
  5. Check the Condor logs and market-data behavior.
  6. Notice that the candle subscription and historical candle request fail with "Trading pair appears to be invalid" because binance is fetching ANON-USDC instead of BTC-FDUSD only

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions