Davide Casale
e262c81f97
Change default log_level value (from 'INFO' to 'ERROR'). Implement error event into AsyncIOEventEmitter. Add error logging.
2022-11-29 17:17:17 +01:00
Davide Casale
b308bbacbd
Add Flags enumeration to enums.py. Rename new_order and new_position to order_new and position_new to mantain consistency. Add _BfxWebsocketInputs class with order_new, order_update and order_cancel inputs.
2022-11-29 15:26:02 +01:00
Davide Casale
fa073823ce
Add .run method in BfxWebsocketClient class.
2022-11-28 17:08:27 +01:00
Davide Casale
4bb62a942f
Allow users to use .on and .once as non-decorators methods.
2022-11-28 16:58:09 +01:00
Davide Casale
9e8bea905a
Rename .chanIds field in _BfxWebsocketBucket to .subscriptions.
2022-11-28 16:50:07 +01:00
Davide Casale
a5083c36cf
Add type hinting using typings.py in bfxapi/websocket/serializers.py.
2022-11-24 17:48:41 +01:00
Davide Casale
3a09ba2e90
Add filter parameter to BfxWebsocketClient's __init__.py. Rewrite .notify coroutine adding new feature. Add Notifications channel handlers in handlers.py. Add Notification serializer in serializers.py.
2022-11-24 17:31:47 +01:00
Davide Casale
6f1befbcf0
Rewrite and apply some refactoring to AuthenticatedChannelsHandler in handlers.py.
2022-11-24 16:24:31 +01:00
Davide Casale
c8d8586841
Add bfxapi/websocket/enums.py file. Rewrite bfxapi.websocket's __init__.py. Rename HEARTBEAT constant to _HEARTBEAT to make it internal.
2022-11-23 16:56:13 +01:00
Davide Casale
4933ae6d9a
Add new_order (coroutine) websocket authenticated input. Fix bug in BfxWebsocketClient.__require_websocket_authentication decorator.
2022-11-23 16:45:33 +01:00
Davide Casale
45a9565cf4
Fix bug regarding closing websocket connection with .close coroutine method.
2022-11-23 16:28:05 +01:00
Davide Casale
16bbe19634
Add bfx.api subpackage to setup.py.
2022-11-22 19:10:43 +01:00
Davide Casale
729a3ce8a3
Add examples/websocket/ticker.py demo.
2022-11-22 19:01:57 +01:00
Davide Casale
acbed0bc57
Fix small bug from merge conflicts resolving.
2022-11-22 18:58:36 +01:00
Davide Casale
256841099b
Merge pull request #2 from Davi0kProgramsThings/add-logging-system
...
Add bfxapi/utils subpackage. Add bfxapi/utils/logger.py. Implement logger with log_level in BfxWebsocketClient.py.
2022-11-22 18:50:04 +01:00
Davide Casale
29abf2d7ea
Merge branch 'master' into add-logging-system
2022-11-22 18:49:55 +01:00
itsdeka
958134b0f4
Add bfxapi/utils subpackage. Add bfxapi/utils/logger.py. Implement logger with log_level in BfxWebsocketClient.py.
2022-11-22 17:40:26 +00:00
Davide Casale
a9902648b7
Merge pull request #4 from Davi0kProgramsThings/feature/asyncio
...
Add BfxWebsocketBucket class in bfxapi/websocket/BfxWebsocketClient.py. Implement running multiple websocket client concurrently using asyncio to allow more than 25 connections to public channels. Rewrite BfxWebsocketClient to handle only websocket authenticated channels.
2022-11-22 18:17:09 +01:00
Davide Casale
f24ed52075
Add setup.py file in project root.
2022-11-22 18:13:06 +01:00
Davide Casale
a8dec5c6bc
Rename bfxapi/websocket/errors.py to exceptions.py. Add Errors enumeration inside BfxWebsocketClient.py and bfxapi/websocket/__init__.py.
2022-11-22 18:11:05 +01:00
Davide Casale
999766a307
Add .close coroutine to BfxWebsocketClient and _BfxWebsocketBucket classes.
2022-11-22 18:02:19 +01:00
Davide Casale
721e82b86d
Add pendings in _BfxWebsocketBucket. Add new logic for selecting the bucket with less connections. Add ._unsubscribe coroutine.
2022-11-22 17:21:21 +01:00
Davide Casale
2f561a4fba
Fix small bug in bfxapi/websocket/errors.py (__all__).
2022-11-21 18:41:40 +01:00
Davide Casale
92f6e691f5
Add BfxWebsocketBucket class in bfxapi/websocket/BfxWebsocketClient.py. Implement running multiple websocket client concurrently using asyncio to allow more than 25 connections to public channels. Rewrite BfxWebsocketClient to handle only websocket authenticated channels.
2022-11-21 18:41:05 +01:00
Davide Casale
8e56e9971e
Rename error event to wss-error.
2022-11-21 16:28:55 +01:00
Davide Casale
ba992d34b3
Change tp_ and fc_ prefixes to t_ and f_.
2022-11-21 16:24:10 +01:00
Davide Casale
7314578dd7
Separate _require_websocket_connection decorator from BfxWebsocketClient class. Add _require_websocket_authentication decorator. Implement .notify method in bfxapi/websocket/BfxWebsocketClient.py.
2022-11-17 18:54:43 +01:00
Davide Casale
971e4759fa
Add and implement serializers for websocket authenticated channels in bfxapi/websocket/handlers.py.
2022-11-17 17:44:18 +01:00
Davide Casale
1cda4fcb3c
Wrap type hinting for subscription objects inside Subscriptions namespace class. Update _Serializer class in serializers.py. Separate Books and Raw Books channels into tp_ and fc_ versions.
2022-11-17 16:54:32 +01:00
Davide Casale
d58c60b02d
Add EventNotSupported exception in errors.py.
2022-11-16 19:01:52 +01:00
Davide Casale
41aa49d2bb
Add derivatives_status_update event in handlers.py. Add DerivativesStatus in serializers.py and typings.py.
2022-11-16 18:45:25 +01:00
Davide Casale
6448fd59b9
Add bfxapi/websocket/serializers.py. Implement _Serializer internal class. Separate labeling from PublicChannelsHandler in handlers.py.
2022-11-16 18:33:33 +01:00
Davide Casale
d3715d3f9c
Fix small bug in bfxapi/websocket/BfxWebsocketClient.py.
2022-11-15 18:37:17 +01:00
Davide Casale
7fcd2e0970
Add OutdatedClientVersion exception in bfxapi/websocket/errors.py. Add check for version mismatch between client and server. Add support for error event.
2022-11-15 18:06:21 +01:00
Davide Casale
217f767a30
Add handlers for ticker, trades and candles public channels. Add new type hinting inside bfxapi/websocket/typings.py.
2022-11-15 17:21:03 +01:00
Davide Casale
b7ac7f9caf
Separate some nested typings in bfxapi/websocket/typings.py.
2022-11-15 15:22:00 +01:00
Davide Casale
b9db5dd133
Update bfxapi/websocket/handlers.py and bfxapi/websocket/typings.py with new public channel handling logic.
2022-11-15 04:34:29 +01:00
Davide Casale
7d6ba4302a
Rename AuthenticatedEventsHandler to AuthenticatedChannelsHandler. Rewrite handlers.py gathering events in channels. Update references in bfxapi.
2022-11-14 18:37:31 +01:00
Davide Casale
495b51a2f6
Rewrite bfxapi/websocket/typings.py script adding new types and fixing some naming bug.
2022-11-14 17:41:55 +01:00
Davide Casale
a03a82d57a
Add support for various new authenticated channels. Add new typings in bfxapi/websocket/typings.py. Add BfxWebsocketException in bfxapi/websocket/errors.py.
2022-11-11 18:54:38 +01:00
Davide Casale
2c70d299b3
Fix small bug in bfxapi/websocket/typings.py file.
2022-11-10 12:27:35 +01:00
Davide Casale
54542ac23b
Add bfxapi/websocket/typing.py script and define some custom types.
2022-11-10 12:24:50 +01:00
Davide Casale
61b082db2e
Rewrite AuthenticatedEventsHandler with _label_array_elements logic. Add support to multiple new events. Fix bug in BfxWebsocketClient.py.
2022-11-10 11:57:57 +01:00
Davide Casale
50644e8116
Rename manager.py to handlers.py. Add code to BfxWebsocketClient.py to handle authenticated channel. Update bfxapi/websocket/__init__.py imports.
2022-11-09 19:13:48 +01:00
Davide Casale
1fc9aacd86
Add authenticate method in BfxWebsocketClient. Add API_KEY and API_SECRET to Client's constructor parameters. Add new AuthenticationCredentialsError exception.
2022-11-09 18:26:30 +01:00
Davide Casale
7e416219e0
Add handlers in manager.py for CANDLES and STATUS channels. Add support for heartbeat data.
2022-11-08 18:16:24 +01:00
Davide Casale
a37b7dda33
Add bfxapi/websocket/errors.py script. Add __require_websocket_connection decorator inside BfxWebsocketClient class. Implement unsubscribe and clear methods.
2022-11-08 17:47:46 +01:00
Davide Casale
5dfe3d6b13
Add bfxapi/websocket/manager.py file. Separate channel handlers from BfxWebsocketClient.py to manager.py. Fix bug in subscribe method.
2022-11-08 17:04:22 +01:00
Davide Casale
048eedcd8e
Add bfxapi package. Add bfxapi.websocket subpackage. Add requirements.txt file.
2022-11-07 18:35:39 +01:00
Davide Casale
8fd261fd19
Add some barebone files.
2022-11-07 17:20:30 +01:00