py-near 1.1.34__tar.gz → 1.1.36__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.
- {py_near-1.1.34 → py_near-1.1.36}/PKG-INFO +1 -1
- {py_near-1.1.34 → py_near-1.1.36}/pyproject.toml +2 -2
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/providers.py +14 -8
- {py_near-1.1.34 → py_near-1.1.36}/LICENSE +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/README.md +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/__init__.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/account.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/constants.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/__init__.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/core.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/ft/__init__.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/ft/async_client.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/ft/exceptions.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/ft/models.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/fts.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/keypom/__init__.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/keypom/async_client.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/keypom/exceptions.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/keypom/models.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/staking/__init__.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/staking/async_client.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/staking/exceptions.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/dapps/staking/models.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/exceptions/__init__.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/exceptions/exceptions.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/exceptions/provider.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/models.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/transactions.py +0 -0
- {py_near-1.1.34 → py_near-1.1.36}/src/py_near/utils.py +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
[tool.poetry]
|
2
2
|
name = "py-near"
|
3
|
-
version = "1.1.
|
3
|
+
version = "1.1.36"
|
4
4
|
description="Pretty simple and fully asynchronous framework for working with NEAR blockchain"
|
5
5
|
authors = ["pvolnov <petr@herewallet.app>"]
|
6
6
|
readme = "README.md"
|
@@ -22,7 +22,7 @@ base58 = "^2.1.1"
|
|
22
22
|
|
23
23
|
[project]
|
24
24
|
name = "py-near"
|
25
|
-
version = "1.1.
|
25
|
+
version = "1.1.36"
|
26
26
|
description = "Pretty simple and fully asynchronous framework for working with NEAR blockchaink"
|
27
27
|
authors = [ {name = "pvolnov", email = "petr@herewallet.app"} ]
|
28
28
|
requires-python = ">=3.7"
|
@@ -23,7 +23,7 @@ from py_near.exceptions.provider import (
|
|
23
23
|
InvalidTransactionError,
|
24
24
|
RPCTimeoutError,
|
25
25
|
UnknownAccessKeyError,
|
26
|
-
ERROR_CODE_TO_EXCEPTION,
|
26
|
+
ERROR_CODE_TO_EXCEPTION, InvalidNonce,
|
27
27
|
)
|
28
28
|
from py_near.models import TransactionResult
|
29
29
|
|
@@ -134,7 +134,6 @@ class JsonProvider(object):
|
|
134
134
|
r.raise_for_status()
|
135
135
|
res = json.loads(await r.text())
|
136
136
|
return res
|
137
|
-
|
138
137
|
tasks = [
|
139
138
|
asyncio.create_task(f(rpc_addr)) for rpc_addr in self._available_rpcs
|
140
139
|
]
|
@@ -227,12 +226,19 @@ class JsonProvider(object):
|
|
227
226
|
:param timeout: rpc request timeout
|
228
227
|
:return:
|
229
228
|
"""
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
|
234
|
-
|
235
|
-
|
229
|
+
try:
|
230
|
+
return await self.json_rpc(
|
231
|
+
"send_tx",
|
232
|
+
{"signed_tx_base64": signed_tx, "wait_until": "INCLUDED"},
|
233
|
+
timeout=timeout,
|
234
|
+
broadcast=self.allow_broadcast,
|
235
|
+
)
|
236
|
+
except InvalidNonce:
|
237
|
+
logger.warning("Invalid nonce during broadcast included transaction")
|
238
|
+
return None
|
239
|
+
except RPCTimeoutError:
|
240
|
+
raise RPCTimeoutError("Transaction not included")
|
241
|
+
|
236
242
|
|
237
243
|
async def wait_for_trx(self, trx_hash, receiver_id) -> TransactionResult:
|
238
244
|
for _ in range(6):
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|