Comments (8)
Hi @cmollen and welcome!
Subscribe_to_orderbook_update() gives you only nounces and Its intended to do so. It’s used in the case when users have their own syncing mechanism, I.e through api request.
With regards to your last paragraph, this only applies when you subscribe to market updates, if you subscribe to the order book or executed trades, then the specific ticker is invoked.
I’m on the phone so I hope this is as clear as possible.
from python-bittrex-websocket.
Thanks for the quick reply, all clear! I would assume that my use case is more common (wanting to capture and store the orderbook for future recreation, without wasting space on levels that haven't changed), but the change was minimal so I will just keep my own branch then.
from python-bittrex-websocket.
If you want to keep a live orderbook you should use subscribe_to_orderbook. With respect to the wasting space on levels, I don’t completely understand what you mean :).
from python-bittrex-websocket.
:) I don't want to keep a live orderbook, I want to store the orderbook to disk and be able to recreate it at a later time for analysis and backtesting. If I store every update passed to the on_orderbook() callback to disk, I will be wasting disk space as it passes all levels of the orderbook, and not just the levels that have been updated. So if I subscribe to 50 levels and only one is updated, I still need to save 50 levels, or check every single update to see which levels have changed.
from python-bittrex-websocket.
With subscribe_to_orderbook_update
you will only get the nounces, this is exactly what you need.
from python-bittrex-websocket.
As stated in the first post, the only thing lacking with subscribe_to_orderbook_update
is that it doesn't have the option to return the full state in the first update. Otherwise, it is impossible to recreate the full orderbook state. And seeing as the snapshot sync is already implemented for SUB_TYPE_ORDERBOOK
, it seems like a waste to re-implement it on the outside.
from python-bittrex-websocket.
I agree that the option of requesting a full order book snapshot to be implemented, but don’t agree that it should be part of the update method. Although in your case it applies, it should be made general. I could implement it as a new method.
from python-bittrex-websocket.
That would be much appreciated. If you want to keep the number of callback methods down, one suggestion for making it more general would be to augment each level of the snapshot with a Type: 0
on the first call to on_orderbook_update
. Then the format and the semantics would be the same for the snapshot and the subsequent updates.
from python-bittrex-websocket.
Related Issues (20)
- QueryExchangeState Market Name is None. HOT 9
- Nonetype object not subscriptable HOT 1
- SubscribeToSummaryDeltas error HOT 2
- SSL Fail HOT 27
- Example not finished properly on Ubuntu HOT 4
- Are updates to Order Book provided in real-time or using a polling interval? HOT 3
- Authentication and trade executions HOT 2
- authenticate callback exception HOT 9
- SSL: CERTIFICATE_VERIFY_FAILED HOT 7
- SubscribeToSummaryDeltas read operation timed out
- ImportError: cannot import name 'six' HOT 1
- on monitoring new listings HOT 2
- Lastest price bug HOT 2
- Error messages not being thrown HOT 4
- Unhandled Exception <[Errno 104] Connection reset by peer> HOT 2
- Unhandled Exception Message = <'PassthroughUuid'> HOT 1
- AttributeError: 'ReconnectEvent' object has no attribute 'invoke' HOT 1
- Issue with IndexError after authenticate() HOT 1
- Auto-reconnection is disabled for unhandled exceptions when calling ws.query_summary_state()
- Websockets code to get tickers doesn't work anymore HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from python-bittrex-websocket.