LUCIT-Systems-and-Development / unicorn-binance-websocket-api

A Python SDK by LUCIT to use the Binance Websocket API`s (com+testnet, com-margin+testnet, com-isolated_margin+testnet, com-futures+testnet, com-coin_futures, us, tr, dex/chain+testnet) in a simple, fast, flexible, robust and fully-featured way.
https://unicorn-binance-websocket-api.docs.lucit.tech/
Other
685 stars 165 forks source link

Basic websocket question #152

Closed zwang17 closed 3 years ago

zwang17 commented 3 years ago

I really like this API and it's incredibly convenient! I am very new to websocket and still trying to figure things out. Quick question - after I end a program, does the streaming connection close? Or does it keep running in the background? I am trying things out on Jupyter notebook and created a bunch of BinanceWebSocketApiManager and a bunch of streams, so I am wondering if I need to manually close all steams before shutting down Jupyter notebook or do they get disconnected automatically. Thanks!

oliver-zehentleitner commented 3 years ago

If you kill or exit the process which is running the subroutines for websockets its closed too.

As far as I can remember, its enough to close jupyter. You can proof this via a taskmanager....

oliver-zehentleitner commented 3 years ago

If need, just reopen!