2025-10-15T04:30:01.5894594Z ERROR:: CharlesSchwabWebSocketClientWrapper.ParseResponse: Error during deserialization. Exception: StreamDataConverter.CreateStreamDataResponse.jToken: {
"service": "ACCT_ACTIVITY",
"timestamp": 1760502601557,
"command": "SUBS",
"content": [
{
"seq": 11,
"key": "Account Activity",
"1": "89874630",
"2": "",
"3": "Feature not supported"
}
]
}. JSON: {"data":[{"service":"ACCT_ACTIVITY", "timestamp":1760502601557,"command":"SUBS","content":[{"seq":11,"key":"Account Activity","1":"89874630","2":"","3":"Feature not supported"}]}]}
2025-10-15T04:30:01.5901651Z ERROR:: Brokerage.OnMessage(): Error - Code: -1 - CharlesSchwabWebSocketClientWrapper.ParseResponse: Unable to parse response.
2025-10-15T04:30:01.6904506Z ERROR:: Extensions.SetRuntimeError(): Extensions.SetRuntimeError(): RuntimeError at 10/15/2025 04:30:01 UTC. Context: Brokerage Error System.Exception: CharlesSchwabWebSocketClientWrapper.ParseResponse: Unable to parse response.
2025-10-15T04:30:02.0016919Z ERROR:: AlgorithmManager.Run(): Stopping, encountered a runtime error at 10/15/2025 4:30:02 AM UTC.
2025-10-15T04:30:02.0022652Z TRACE:: Engine.Run(): Exiting Algorithm Manager
2025-10-15T04:30:02.0032923Z TRACE:: LiveTradingDataFeed.Exit(): Start. Setting cancellation token...
2025-10-15T04:30:02.0046075Z TRACE:: StopSafely(): Waiting for 'CustomDataExchange' thread to stop...
2025-10-15T04:30:02.0046915Z TRACE:: BaseDataExchange(CustomDataExchange).ConsumeQueue(): Exiting...
2025-10-15T04:30:02.0049337Z TRACE:: LiveTradingDataFeed.Exit(): Exit Finished.
2025-10-15T04:30:02.0051483Z TRACE:: FileSystemDataFeed.Exit(): Start. Setting cancellation token...
2025-10-15T04:30:02.0081946Z TRACE:: FileSystemDataFeed.Exit(): Exit Finished.
2025-10-15T04:30:02.0083550Z TRACE:: Engine.Run(): Sending runtime error to user...
2025-10-15T04:30:02.0121965Z TRACE:: StopSafely(): Waiting for 'Transaction Thread 0' thread to stop...
2025-10-15T04:30:02.0134727Z TRACE:: BrokerageTransactionHandler.Run(): Ending Thread 0...
2025-10-15T04:30:02.0137881Z TRACE:: StopSafely(): Waiting for 'RealTime Thread' thread to stop...
2025-10-15T04:30:02.4267539Z TRACE:: Log: Runtime Error: CharlesSchwabWebSocketClientWrapper.ParseResponse: Unable to parse response.
2025-10-15T04:30:02.4269264Z ERROR:: Runtime Error: CharlesSchwabWebSocketClientWrapper.ParseResponse: Unable to parse response.
CharlesSchwabWebSocketClientWrapper.ParseResponse: Unable to parse response.
2025-10-15T04:30:03.0000417Z TRACE:: LiveTradingRealTimeHandler.Run(): Exiting thread... Exit triggered: True
2025-10-15T04:30:03.0054014Z TRACE:: DataManager.RemoveSubscription(): Removed QC-UNIVERSE-USERDEFINED-USA-EQUITY,#0,QC-UNIVERSE-USERDEFINED-USA-EQUITY,Minute,TradeBar,Trade,Adjusted,OpenInterest,Internal
2025-10-15T04:30:03.0104375Z TRACE:: DataManager.RemoveSubscription(): Removed QQQ,#0,QQQ,Minute,TradeBar,Trade,Adjusted,OpenInterest
2025-10-15T04:30:03.0109246Z TRACE:: EventBasedDataQueueHandlerSubscriptionManager.Unsubscribe(): SPY
2025-10-15T04:30:03.0187644Z TRACE:: DataManager.RemoveSubscription(): Removed SPY,#0,SPY,Minute,TradeBar,Trade,Adjusted,OpenInterest,Internal
2025-10-15T04:30:03.0189186Z TRACE:: DataManager.RemoveSubscription(): Removed TQQQ,#0,TQQQ,Minute,TradeBar,Trade,Adjusted,OpenInterest
2025-10-15T04:30:03.0189638Z TRACE:: EventBasedDataQueueHandlerSubscriptionManager.Unsubscribe(): QQQ
2025-10-15T04:30:03.0192071Z TRACE:: DataManager.RemoveSubscription(): Removed QQQ,#0,QQQ,Minute,QuoteBar,Quote,Adjusted,OpenInterest
2025-10-15T04:30:03.0222334Z TRACE:: EventBasedDataQueueHandlerSubscriptionManager.Unsubscribe(): TQQQ
2025-10-15T04:30:03.0225013Z TRACE:: DataManager.RemoveSubscription(): Removed TQQQ,#0,TQQQ,Minute,QuoteBar,Quote,Adjusted,OpenInterest
2025-10-15T04:30:03.0230029Z TRACE:: StopSafely(): Waiting for 'Isolator Thread' thread to stop...
2025-10-15T04:30:03.0251645Z TRACE:: StopSafely(): Waiting for 'RealTimeScheduleEventService' thread to stop...
2025-10-15T04:30:03.0275819Z TRACE:: LiveTradingResultHandler.Run(): Ending Thread...
2025-10-15T04:30:03.0291861Z TRACE:: StopSafely(): Waiting for 'Result Thread' thread to stop...
2025-10-15T04:30:03.0306651Z TRACE:: LiveTradingResultHandler.SendFinalResult(): Starting...
2025-10-15T04:30:03.0566950Z TRACE:: CharlesSchwabWebSocketClientWrapper.HandleWebSocketMessage.WS.Response.JSON: {"response":[{"service":"LEVELONE_EQUITIES","command":"UNSUBS","requestid":"5","SchwabClientCorrelId":"1898160d-345f-1928-d30d-f401fcdde76a","timestamp":1760502603034,"content":{"code":0,"msg":"UNSUBS command succeeded"}}]}
2025-10-15T04:30:03.0844028Z TRACE:: CharlesSchwabWebSocketClientWrapper.HandleWebSocketMessage.WS.Response.JSON: {"response":[{"service":"LEVELONE_EQUITIES","command":"UNSUBS","requestid":"6","SchwabClientCorrelId":"1898160d-345f-1928-d30d-f401fcdde76a","timestamp":1760502603035,"content":{"code":0,"msg":"UNSUBS command succeeded"}}]}
2025-10-15T04:30:03.0865836Z TRACE:: CharlesSchwabWebSocketClientWrapper.HandleWebSocketMessage.WS.Response.JSON: {"response":[{"service":"LEVELONE_EQUITIES","command":"UNSUBS","requestid":"7","SchwabClientCorrelId":"1898160d-345f-1928-d30d-f401fcdde76a","timestamp":1760502603038,"content":{"code":0,"msg":"UNSUBS command succeeded"}}]}
2025-10-15T04:30:03.1391851Z TRACE:: LiveTradingResultHandler.SendFinalResult(): Finished storing results. Start sending...
2025-10-15T04:30:03.1392155Z TRACE:: LiveTradingResultHandler.SendFinalResult(): Ended
2025-10-15T04:30:03.1428223Z TRACE:: Engine.Run(): Disconnecting from brokerage...
2025-10-15T04:30:03.2099642Z TRACE:: WebSocketClientWrapper connection task ended: wss://streamer-api.schwab.com/ws
2025-10-15T04:30:03.2130925Z TRACE:: WebSocketClientWrapper.OnClose(): Connection closed (IsOpen:False, State:Aborted): wss://streamer-api.schwab.com/ws
2025-10-15T04:30:03.2132638Z TRACE:: Engine.Run(): Disposing of setup handler...
2025-10-15T04:30:03.2140786Z TRACE:: BrokerageSetupHandler.Setup(): Found data queue handler to dispose: QuantConnect.Brokerages.CharlesSchwab.CharlesSchwabBrokerage
2025-10-15T04:30:03.2141538Z TRACE:: Engine.Main(): Analysis Completed and Results Posted.
2025-10-15T04:30:03.2145089Z TRACE:: StopSafely(): Waiting for 'Transaction Thread 0' thread to stop...
2025-10-15T04:30:03.2145741Z TRACE:: StopSafely(): Waiting for 'RealTime Thread' thread to stop...
2025-10-15T04:30:03.2223535Z TRACE:: Engine.Main(): Packet removed from queue: L-3533130984
2025-10-15T04:30:03.2225240Z TRACE:: LeanEngineSystemHandlers.Dispose(): start...
2025-10-15T04:30:03.2256999Z TRACE:: LeanEngineSystemHandlers.Dispose(): Disposed of system handlers.
2025-10-15T04:30:03.2259720Z TRACE:: LeanEngineAlgorithmHandlers.Dispose(): start...
2025-10-15T04:30:03.2262362Z TRACE:: LocalObjectStore.Dispose(): start...
2025-10-15T04:30:03.2262609Z TRACE:: LocalObjectStore.Dispose(): end
2025-10-15T04:30:03.2263574Z TRACE:: LeanEngineAlgorithmHandlers.Dispose(): Disposed of algorithm handlers.
Mia Alissi
Here's a targeted guide and example code for Dujinxin to resolve the Charles Schwab "Account Activity" subscription runtime error in QuantConnect:
Why This Error Occurs
The Charles Schwab integration with QuantConnect does not support subscribing to the "Account Activity" stream via its WebSocket API. Attempting to subscribe to this feature results in a JSON message like:
Attempting to parse/handle this unsupported feature triggers deserialization errors, leading QuantConnect to raise a runtime error and halt your algorithm.
How to Prevent This Error
on_brokerage_messagehandler.Example of Robust Error Handling in Your Algorithm
Summary of Best Practices
on_brokerage_messagehandler to swallow/ignore Schwab's unsupported-feature errors.What If You Need Account Activity Features?
If you require live account activity monitoring (orders, deposits, etc.), you'll need to:
This approach will safeguard your algorithm from future breaks whenever the Account Activity feature is triggered or queried (either by you or future QuantConnect changes).
Let me know if you need help further customizing this error-handling logic!
Sources: Brokerages - QuantConnect.com, Brokerage Activity Event Handling Algorithm, Charles Schwab - QuantConnect.com, Brokerage Message Handler - QuantConnect.com
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
Dujinxin
The material on this website is provided for informational purposes only and does not constitute an offer to sell, a solicitation to buy, or a recommendation or endorsement for any security or strategy, nor does it constitute an offer to provide investment advisory services by QuantConnect. In addition, the material offers no opinion with respect to the suitability of any security or specific investment. QuantConnect makes no guarantees as to the accuracy or completeness of the views expressed in the website. The views are subject to change, and may have become unreliable for various reasons, including changes in market conditions or economic circumstances. All investments involve risk, including loss of principal. You should consult with an investment professional before making any investment decisions.
To unlock posting to the community forums please complete at least 30% of Boot Camp.
You can continue your Boot Camp training progress from the terminal. We hope to see you in the community soon!