crypto-ws-api 2.1.4__tar.gz → 2.1.6__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,3 +1,9 @@
1
+ ## 2.1.6 - 2026-01-29
2
+ 🐛 fix(ws_session/okx_error_handle): return msg for code 51138
3
+
4
+ ## 2.1.5 - 2026-01-29
5
+ 🧹 chore(version/websockets): Bump to **2.1.5** and update `websockets` to **16.0**
6
+
1
7
  ## 2.1.4 - 2025-12-02
2
8
  - Add optional root logger configuration to set_logger()
3
9
  - Introduce malloc_trim() wrapper for C library memory management
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: crypto-ws-api
3
- Version: 2.1.4
3
+ Version: 2.1.6
4
4
  Summary: Crypto WS API connector for ASYNC requests
5
5
  Author-email: Jerry Fedorenko <jerry.fedorenko@yahoo.com>
6
6
  Requires-Python: >=3.10
@@ -14,7 +14,7 @@ Classifier: Operating System :: MacOS
14
14
  Requires-Dist: shortuuid~=1.0.13
15
15
  Requires-Dist: platformdirs==4.5.0
16
16
  Requires-Dist: toml~=0.10.2
17
- Requires-Dist: websockets==15.0.1
17
+ Requires-Dist: websockets==16.0
18
18
  Requires-Dist: ujson~=5.11.0
19
19
  Requires-Dist: cryptography~=46.0.3
20
20
  Project-URL: Source, https://github.com/DogsTailFarmer/crypto-ws-api
@@ -13,7 +13,7 @@ __maintainer__ = "Jerry Fedorenko"
13
13
  __contact__ = "https://github.com/DogsTailFarmer"
14
14
  __email__ = "jerry.fedorenko@yahoo.com"
15
15
  __credits__ = ["https://github.com/DanyaSWorlD"]
16
- __version__ = "2.1.4"
16
+ __version__ = "2.1.6"
17
17
 
18
18
  from pathlib import Path
19
19
  import shutil
@@ -412,8 +412,7 @@ class UserWSS:
412
412
  return msg
413
413
  elif self.exchange == 'okx':
414
414
  if msg.get('code') != '0':
415
- self.okx_error_handle(msg)
416
- msg = None
415
+ msg = self.okx_error_handle(msg)
417
416
  return msg
418
417
  elif self.exchange == 'bitfinex':
419
418
  return await self.bitfinex_error_handle(msg)
@@ -499,8 +498,11 @@ class UserWSS:
499
498
  # endregion
500
499
 
501
500
  def okx_error_handle(self, msg):
501
+ _msg = None
502
502
  if msg.get('code') == '1':
503
503
  self.logger.warning(f"OKX User WSS operation failed: {msg}")
504
+ if msg['data'][0]['sCode'] == '51138':
505
+ _msg = msg
504
506
  elif msg.get('code') == '63999':
505
507
  self.logger.warning(f"An issue occurred on exchange's side: {msg}")
506
508
  elif msg.get('code') == '60014':
@@ -508,6 +510,7 @@ class UserWSS:
508
510
  self.request_limit_reached = True
509
511
  else:
510
512
  self.logger.warning(f"Malformed request: status: {msg}")
513
+ return _msg
511
514
 
512
515
  async def binance_error_handle(self, msg):
513
516
  error_msg = msg.get('error')
@@ -20,7 +20,7 @@ dependencies = [
20
20
  "shortuuid~=1.0.13",
21
21
  "platformdirs==4.5.0",
22
22
  "toml~=0.10.2",
23
- "websockets==15.0.1",
23
+ "websockets==16.0",
24
24
  "ujson~=5.11.0",
25
25
  "cryptography~=46.0.3"
26
26
  ]
@@ -1,6 +1,6 @@
1
1
  shortuuid~=1.0.13
2
2
  platformdirs==4.5.0
3
3
  toml~=0.10.2
4
- websockets==15.0.1
4
+ websockets==16.0
5
5
  ujson~=5.11.0
6
6
  cryptography~=46.0.3
File without changes
File without changes