Skip to content

Solve underlying problem#362

Open
Axxxeel89 wants to merge 15 commits intoLu-Yi-Hsun:masterfrom
Axxxeel89:fix-underlying-key
Open

Solve underlying problem#362
Axxxeel89 wants to merge 15 commits intoLu-Yi-Hsun:masterfrom
Axxxeel89:fix-underlying-key

Conversation

@Axxxeel89
Copy link
Copy Markdown

This patch improves the get_all_open_time method by:

Ignoring the stray “underlying” key in the v2 init payload to prevent KeyError.

Respecting each asset’s is_suspended flag, so OTC/Turbo instruments are only marked open when truly available.

Adding robust error handling around digital, forex, crypto, and CFD schedules—any API failure in one section no longer breaks the entire loop.

Together, these changes prevent silent crashes when the platform payload changes, avoid phantom “open” assets that are actually suspended, and make the open-time lookup far more resilient.

@TxusBlack
Copy link
Copy Markdown

Hello. Your PR solve this (Issue message).

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

Successfully merging this pull request may close these issues.

2 participants