Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Data Connection Logic #80

Open
4 tasks done
AlexCatarino opened this issue Sep 14, 2023 · 2 comments
Open
4 tasks done

Improve Data Connection Logic #80

AlexCatarino opened this issue Sep 14, 2023 · 2 comments

Comments

@AlexCatarino
Copy link
Member

AlexCatarino commented Sep 14, 2023

Expected Behavior

If the data connection is lost, LEAN recovers it. No need to restart the deployment.

Actual Behavior

Apparently the algorithm trading SPX options fails because the algorithm stops receiving SPX (index data), so it didn't trigger the option universe filter.
The latest "Market data farm connection" says

2023-08-08T05:07:28.4818118Z TRACE:: InteractiveBrokersBrokerage.HandleError(): RequestId: -1 ErrorCode: 2108 - Market data farm connection is inactive but should be available upon demand.usopt

but it refers to usopt, not index.
When the user restarted the algorithm, it received the data.

Potential Solution

N/A

Checklist

  • I have completely filled out this template
  • I have confirmed that this issue exists on the current master branch
  • I have confirmed that this is not a duplicate issue by searching issues
  • I have provided detailed steps to reproduce the issue
@AlexCatarino
Copy link
Member Author

We had a second report today (Jul 22nd, 2024).

@AlexCatarino
Copy link
Member Author

LEAN should not trigger soft restart

2024-08-11T23:51:08.7178800Z TRACE:: InteractiveBrokersBrokerage.StartGatewayRestartTask(): triggering soft restart

for data connection if there are no subscriptions:

2024-08-11T22:11:27.0548386Z TRACE:: CompositeDataQueueHandler.SetJob(): will use ["QuantConnect.DataDistribution.Common.LocalDataDistributionConsumer"]

...

2024-08-11T23:50:56.5941827Z TRACE:: InteractiveBrokersBrokerage.HandleError(): RequestId: -1 ErrorCode: 2157 - Sec-def data farm connection is broken:secdefnj
2024-08-11T23:51:08.7178800Z TRACE:: InteractiveBrokersBrokerage.StartGatewayRestartTask(): triggering soft restart

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant