trd-utils 0.0.29__py3-none-any.whl → 0.0.30__py3-none-any.whl
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.
Potentially problematic release.
This version of trd-utils might be problematic. Click here for more details.
- trd_utils/__init__.py +1 -1
- trd_utils/exchanges/bx_ultra/bx_ultra_client.py +8 -0
- {trd_utils-0.0.29.dist-info → trd_utils-0.0.30.dist-info}/METADATA +1 -1
- {trd_utils-0.0.29.dist-info → trd_utils-0.0.30.dist-info}/RECORD +6 -6
- {trd_utils-0.0.29.dist-info → trd_utils-0.0.30.dist-info}/LICENSE +0 -0
- {trd_utils-0.0.29.dist-info → trd_utils-0.0.30.dist-info}/WHEEL +0 -0
trd_utils/__init__.py
CHANGED
|
@@ -50,6 +50,7 @@ from trd_utils.exchanges.bx_ultra.bx_types import (
|
|
|
50
50
|
)
|
|
51
51
|
from trd_utils.cipher import AESCipher
|
|
52
52
|
|
|
53
|
+
from trd_utils.exchanges.errors import ExchangeError
|
|
53
54
|
from trd_utils.exchanges.exchange_base import ExchangeBase, JWTManager
|
|
54
55
|
|
|
55
56
|
PLATFORM_ID_ANDROID = "10"
|
|
@@ -857,6 +858,13 @@ class BXUltraClient(ExchangeBase):
|
|
|
857
858
|
api_identity=api_identity,
|
|
858
859
|
page_size=50, # TODO: make this dynamic I guess...
|
|
859
860
|
)
|
|
861
|
+
if not result.data:
|
|
862
|
+
if result.msg:
|
|
863
|
+
raise ExchangeError(result.msg)
|
|
864
|
+
raise ExchangeError(
|
|
865
|
+
f"Unknown error happened while fetching positions of {uid}, "
|
|
866
|
+
f"code: {result.code}"
|
|
867
|
+
)
|
|
860
868
|
if result.data.hide == 0 and not result.data.positions:
|
|
861
869
|
# TODO: do proper exceptions here...
|
|
862
870
|
raise ValueError("The trader has made their positions hidden")
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
trd_utils/__init__.py,sha256=
|
|
1
|
+
trd_utils/__init__.py,sha256=yHJ8D3i2dO26rZPCv6zktwpCzBAZJncL4kRz1UsG-Po,25
|
|
2
2
|
trd_utils/cipher/__init__.py,sha256=V05KNuzQwCic-ihMVHlC8sENaJGc3I8MCb4pg4849X8,1765
|
|
3
3
|
trd_utils/common_utils/float_utils.py,sha256=aYPwJ005LmrRhXAngojwvdDdtRgeb1FfR6hKeQ5ndMU,470
|
|
4
4
|
trd_utils/common_utils/wallet_utils.py,sha256=OX9q2fymP0VfIWTRIRBP8W33cfyjLXimxMgPOsZe-3g,727
|
|
@@ -12,7 +12,7 @@ trd_utils/exchanges/blofin/blofin_client.py,sha256=x0CU75_wWRA6RmVfm2wh7y-jNjohp
|
|
|
12
12
|
trd_utils/exchanges/blofin/blofin_types.py,sha256=ZlHX1ClYTd2pDRTQIlZYyBu5ReGpMgxXxKASsPeBQug,4090
|
|
13
13
|
trd_utils/exchanges/bx_ultra/__init__.py,sha256=8Ssy-eOemQR32Nv1-FoPHm87nRqRO4Fm2PU5GHEFKfQ,80
|
|
14
14
|
trd_utils/exchanges/bx_ultra/bx_types.py,sha256=oEXd825UVTINiQTKuUsJqG0qUo4bkl4Bay6cEDOAS_g,34532
|
|
15
|
-
trd_utils/exchanges/bx_ultra/bx_ultra_client.py,sha256=
|
|
15
|
+
trd_utils/exchanges/bx_ultra/bx_ultra_client.py,sha256=rSGq95C7OmN44W9K7rAMLMMCL8vys-9TnO6Dmc7BOoo,33787
|
|
16
16
|
trd_utils/exchanges/bx_ultra/bx_utils.py,sha256=PwapomwDW33arVmKIDj6cL-aP0ptu4BYy_lOCqSAPOo,1392
|
|
17
17
|
trd_utils/exchanges/errors.py,sha256=P_NTuc389XL7rFegomP59BydWmHv8ckiGyNU-_l5qNQ,167
|
|
18
18
|
trd_utils/exchanges/exchange_base.py,sha256=6vlwQXogZaxg1wNgZWvGZ0BYv0hfjdQNdXBpV-tvHkE,7665
|
|
@@ -30,7 +30,7 @@ trd_utils/tradingview/tradingview_client.py,sha256=g_eWYaCRQAL8Kvd-r6AnAdbH7Jha6
|
|
|
30
30
|
trd_utils/tradingview/tradingview_types.py,sha256=z21MXPVdWHAduEl3gSeMIRhxtBN9yK-jPYHfZSMIbSA,6144
|
|
31
31
|
trd_utils/types_helper/__init__.py,sha256=lLbUiW1jUV1gjzTMFLthwkvF0hwauH-F_J2JZq--1U0,67
|
|
32
32
|
trd_utils/types_helper/base_model.py,sha256=Q2KK0r4UXP9PlWeIl6nxdAeCGB5InU5IkTNGAfJasfM,11808
|
|
33
|
-
trd_utils-0.0.
|
|
34
|
-
trd_utils-0.0.
|
|
35
|
-
trd_utils-0.0.
|
|
36
|
-
trd_utils-0.0.
|
|
33
|
+
trd_utils-0.0.30.dist-info/LICENSE,sha256=J1EP2xt87RjjmsTV1jTjHDQMLIM9FjdwEftTpw8hyv4,1067
|
|
34
|
+
trd_utils-0.0.30.dist-info/METADATA,sha256=uM6m-5n_NAzTrGqOgkVRlZHmUmqy-cwaZi-zDNJaen4,1179
|
|
35
|
+
trd_utils-0.0.30.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
|
|
36
|
+
trd_utils-0.0.30.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|