Skip to content

Make websocket timeout configurable #372

Answered by arjanz
johnuopini asked this question in Q&A
Discussion options

You must be logged in to vote

It is actually already possible to provide all available options when creating the websocket connection. There are some defaults atm, but nothing is hardcoded.

For example:

substrate = SubstrateInterface(url='ws://127.0.0.1:9944', ws_options={'timeout': 10})

For all available options, see: https://websocket-client.readthedocs.io/en/latest/core.html#websocket._core.create_connection

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by arjanz
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #371 on December 29, 2023 15:06.