py-near 1.1.52__py3-none-any.whl → 1.1.54__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.
- py_near/account.py +6 -6
- {py_near-1.1.52.dist-info → py_near-1.1.54.dist-info}/METADATA +38 -19
- {py_near-1.1.52.dist-info → py_near-1.1.54.dist-info}/RECORD +13 -12
- {py_near-1.1.52.dist-info → py_near-1.1.54.dist-info}/WHEEL +2 -1
- py_near-1.1.54.dist-info/top_level.txt +1 -0
- {py_near-1.1.52.dist-info → py_near-1.1.54.dist-info/licenses}/LICENSE +0 -0
py_near/account.py
CHANGED
@@ -4,6 +4,8 @@ import json
|
|
4
4
|
import sys
|
5
5
|
from typing import List, Union, Dict, Optional
|
6
6
|
|
7
|
+
from nacl.signing import VerifyKey
|
8
|
+
|
7
9
|
if sys.version_info.major == 3 and sys.version_info.minor >= 10:
|
8
10
|
from collections.abc import MutableSet, MutableMapping
|
9
11
|
|
@@ -86,8 +88,8 @@ class Account(object):
|
|
86
88
|
logger.error(f"Can't decode private key {pk[:10]}")
|
87
89
|
continue
|
88
90
|
private_key = signing.SigningKey(pk[:32], encoder=encoding.RawEncoder)
|
89
|
-
|
90
|
-
self._signer_by_pk[
|
91
|
+
public_key_b58 = base58.b58encode(private_key.verify_key.encode()).decode("utf-8")
|
92
|
+
self._signer_by_pk[public_key_b58] = pk
|
91
93
|
self._free_signers.put_nowait(pk)
|
92
94
|
self._signers.append(pk)
|
93
95
|
|
@@ -206,8 +208,6 @@ class Account(object):
|
|
206
208
|
|
207
209
|
private_key = signing.SigningKey(pk[:32], encoder=encoding.RawEncoder)
|
208
210
|
public_key = private_key.verify_key
|
209
|
-
public_key.to_curve25519_public_key()
|
210
|
-
|
211
211
|
resp = await self._provider.get_access_key(
|
212
212
|
self.account_id, base58.b58encode(public_key.encode()).decode("utf8")
|
213
213
|
)
|
@@ -449,14 +449,14 @@ class Account(object):
|
|
449
449
|
await self._update_last_block_hash()
|
450
450
|
|
451
451
|
private_key = signing.SigningKey(pk[:32], encoder=encoding.RawEncoder)
|
452
|
-
verifying_key = private_key.verify_key
|
452
|
+
verifying_key: VerifyKey = private_key.verify_key
|
453
453
|
return DelegateActionModel(
|
454
454
|
sender_id=self.account_id,
|
455
455
|
receiver_id=receiver_id,
|
456
456
|
actions=actions,
|
457
457
|
nonce=access_key.nonce + 1,
|
458
458
|
max_block_height=self._latest_block_height + 1000,
|
459
|
-
public_key=base58.b58encode(verifying_key.
|
459
|
+
public_key=base58.b58encode(verifying_key.encode()).decode("utf-8"),
|
460
460
|
)
|
461
461
|
|
462
462
|
def sign_delegate_transaction(
|
@@ -1,25 +1,45 @@
|
|
1
|
-
Metadata-Version: 2.
|
1
|
+
Metadata-Version: 2.4
|
2
2
|
Name: py-near
|
3
|
-
Version: 1.1.
|
3
|
+
Version: 1.1.54
|
4
4
|
Summary: Pretty simple and fully asynchronous framework for working with NEAR blockchain
|
5
|
-
Author: pvolnov
|
6
|
-
|
7
|
-
|
5
|
+
Author-email: pvolnov <petr@herewallet.app>
|
6
|
+
License: Permission is hereby granted, free of charge, to any
|
7
|
+
person obtaining a copy of this software and associated
|
8
|
+
documentation files (the "Software"), to deal in the
|
9
|
+
Software without restriction, including without
|
10
|
+
limitation the rights to use, copy, modify, merge,
|
11
|
+
publish, distribute, sublicense, and/or sell copies of
|
12
|
+
the Software, and to permit persons to whom the Software
|
13
|
+
is furnished to do so, subject to the following
|
14
|
+
conditions:
|
15
|
+
|
16
|
+
The above copyright notice and this permission notice
|
17
|
+
shall be included in all copies or substantial portions
|
18
|
+
of the Software.
|
19
|
+
|
20
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
|
21
|
+
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
|
22
|
+
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
|
23
|
+
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
|
24
|
+
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
25
|
+
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
26
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
|
27
|
+
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
|
28
|
+
DEALINGS IN THE SOFTWARE.
|
29
|
+
|
30
|
+
Project-URL: homepage, https://github.com/pvolnov/py-near
|
31
|
+
Project-URL: documentation, https://py-near.readthedocs.io/en/latest
|
32
|
+
Project-URL: repository, https://github.com/pvolnov/py-near
|
33
|
+
Project-URL: changelog, https://github.com/pvolnov/py-near/blob/main/CHANGELOG.md
|
34
|
+
Project-URL: funding, https://opencollective.com/py-near
|
35
|
+
Project-URL: twitter, https://twitter.com/p_volnov
|
36
|
+
Keywords: python,near,async
|
8
37
|
Classifier: Programming Language :: Python :: 3
|
9
|
-
Classifier:
|
10
|
-
Classifier:
|
11
|
-
Classifier: Programming Language :: Python :: 3.10
|
12
|
-
Classifier: Programming Language :: Python :: 3.11
|
13
|
-
Requires-Dist: base58 (>=2.1.1,<3.0.0)
|
14
|
-
Requires-Dist: eth-keys (>=0.6.1,<0.7.0)
|
15
|
-
Requires-Dist: eth-utils (>=5.2.0,<6.0.0)
|
16
|
-
Requires-Dist: frozenlist (>=1.4.1,<2.0.0)
|
17
|
-
Requires-Dist: httpx (==0.26.0)
|
18
|
-
Requires-Dist: loguru (>=0.7.2,<0.8.0)
|
19
|
-
Requires-Dist: py-near-primitives (==0.2.3)
|
20
|
-
Requires-Dist: pydantic (>=2.6.2,<3.0.0)
|
21
|
-
Requires-Dist: pynacl (>=1.5.0,<2.0.0)
|
38
|
+
Classifier: License :: OSI Approved :: MIT License
|
39
|
+
Classifier: Operating System :: OS Independent
|
22
40
|
Description-Content-Type: text/markdown
|
41
|
+
License-File: LICENSE
|
42
|
+
Dynamic: license-file
|
23
43
|
|
24
44
|
# py-near
|
25
45
|
|
@@ -143,4 +163,3 @@ for t in task:
|
|
143
163
|
|
144
164
|
This project exists thanks to all the people who contribute. [[Code of conduct](CODE_OF_CONDUCT.md)].
|
145
165
|
<a href="https://github.com/pvolnov/py-near/graphs/contributors"><img src="https://opencollective.com/py-near/contributors.svg?width=890&button=false" /></a>
|
146
|
-
|
@@ -1,13 +1,17 @@
|
|
1
1
|
py_near/__init__.py,sha256=t5fAxjaU8dN8xpQR2vz0ZGhfTkdVy2RCbkhJhZFglk4,50
|
2
|
-
py_near/account.py,sha256=
|
2
|
+
py_near/account.py,sha256=J9JSOXrglDr-91Lrr1cc2CgH845vGurLFdy91ty-cRA,18249
|
3
3
|
py_near/constants.py,sha256=inaWIuwmF1EB5JSB0ynnZY5rKY_QsxhF9KuCOhPsM6k,164
|
4
|
+
py_near/models.py,sha256=85ynmLVJnzWvFKq-Z8iIO0waU-2iP-CSkaOGX4mYoL0,11590
|
5
|
+
py_near/providers.py,sha256=X_GfddFzmafBatqFJH41Dp_lYvTNcz1Q3Ko2tEnN0VU,16193
|
6
|
+
py_near/transactions.py,sha256=QwEP3qOGxb8OB2vZA_rU20jvkPA0FmJowUKDxbuzOuI,3251
|
7
|
+
py_near/utils.py,sha256=FirRH93ydH1cwjn0-sNrZeIn3BRD6QHedrP2VkAdJ6g,126
|
4
8
|
py_near/dapps/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
5
9
|
py_near/dapps/core.py,sha256=LtN9aW2gw2mvEdhzQcQJIidtjv-XL1xjb0LK8DzqtqE,231
|
10
|
+
py_near/dapps/fts.py,sha256=MFe_wC96K_RfpFc7soeZr-ejuMWPl7SJqaX2mTbZHy0,959
|
6
11
|
py_near/dapps/ft/__init__.py,sha256=hx8qh4yEs37Ul_JhDWn8LHd-9lzsaATivxKOJPaUqTE,29
|
7
12
|
py_near/dapps/ft/async_client.py,sha256=Oir5EQOGueq0lsNn0ybe_1uvMnmV5K1m_mHFuFWIUu4,6717
|
8
13
|
py_near/dapps/ft/exceptions.py,sha256=UjXLFsDQX0vDGS9CGO7HE9XpLD0vovFNUzCb11WKAtc,92
|
9
14
|
py_near/dapps/ft/models.py,sha256=_URS8nXZvfuxjU7Ov2E-nteBak5qKtPKN3bLOR7sC9k,186
|
10
|
-
py_near/dapps/fts.py,sha256=MFe_wC96K_RfpFc7soeZr-ejuMWPl7SJqaX2mTbZHy0,959
|
11
15
|
py_near/dapps/keypom/__init__.py,sha256=6fWGxsVr_lb_wTf_MHrbwBl1fgf78b5ezmsVa3JeFjI,32
|
12
16
|
py_near/dapps/keypom/async_client.py,sha256=DS594S00xhcyvVtD1W0PjmtmT3YhvXTZZ3hskbn1-1w,1422
|
13
17
|
py_near/dapps/keypom/exceptions.py,sha256=pGz0w1Ubh2A1aHEWvUX4dVaCcO9r2Y-h2JwhBY5KJbU,45
|
@@ -19,20 +23,17 @@ py_near/dapps/staking/models.py,sha256=zC5M_pc1oMqHq4GaYif1uwFbW6acD2BsiA9rbyiaU
|
|
19
23
|
py_near/exceptions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
20
24
|
py_near/exceptions/exceptions.py,sha256=DEFipaAHm0y7oCuN2QKzHsiQvUTUQVl-Ce36Ag7n7hs,5509
|
21
25
|
py_near/exceptions/provider.py,sha256=K-wexgjPJ8sw42JePwaP7R5dJEIn9DoFJRvVcURsx6s,7718
|
22
|
-
py_near/models.py,sha256=85ynmLVJnzWvFKq-Z8iIO0waU-2iP-CSkaOGX4mYoL0,11590
|
23
26
|
py_near/mpc/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
27
|
+
py_near/mpc/models.py,sha256=9MSfBDqfqkaJu6eJxnwyjgihsexZboehbJ6vAGa4BTU,663
|
28
|
+
py_near/mpc/wallet.py,sha256=sNr9UlcyVDPF_Zho_4iTupbUoZct3paQlxxDHlHK67k,9768
|
24
29
|
py_near/mpc/auth/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
25
30
|
py_near/mpc/auth/auth_2fa.py,sha256=ZxO8mGO95ixb0qXnKrfmVxP7ivpDKerH4-udV_vUmbs,3124
|
26
31
|
py_near/mpc/auth/base.py,sha256=IoFdRWUQcerYZq8TCkpjXJQRcENnzA9WwFbVPgmHgcs,629
|
27
32
|
py_near/mpc/auth/core.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
28
33
|
py_near/mpc/auth/default_auth.py,sha256=i70412yXYx3MlFSsPxHLKbF0CXTjC39Qtl34et8kAEw,751
|
29
34
|
py_near/mpc/auth/keys_auth.py,sha256=DJPi37DnV6r6cSskHEhHBiR_QiaAQJkg0AEsYp6cePA,2359
|
30
|
-
py_near/
|
31
|
-
py_near/
|
32
|
-
py_near/
|
33
|
-
py_near/
|
34
|
-
py_near
|
35
|
-
py_near-1.1.52.dist-info/LICENSE,sha256=I_GOA9xJ35FiL-KnYXZJdATkbO2KcV2dK2enRGVxzKM,1023
|
36
|
-
py_near-1.1.52.dist-info/METADATA,sha256=A_pG9PjBofHZQSJFoimIFb33ljVJgC7qT1OCnhlDR9U,4846
|
37
|
-
py_near-1.1.52.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
38
|
-
py_near-1.1.52.dist-info/RECORD,,
|
35
|
+
py_near-1.1.54.dist-info/licenses/LICENSE,sha256=I_GOA9xJ35FiL-KnYXZJdATkbO2KcV2dK2enRGVxzKM,1023
|
36
|
+
py_near-1.1.54.dist-info/METADATA,sha256=WQeR_r0t--SwIfopnYnunfnheZpEGRZZClY42XPYIFo,6012
|
37
|
+
py_near-1.1.54.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
38
|
+
py_near-1.1.54.dist-info/top_level.txt,sha256=p8CZgfKEVmXnRfVX5VHR0Ls7OVFC2ZVEwthvNB8Rb2Q,8
|
39
|
+
py_near-1.1.54.dist-info/RECORD,,
|
@@ -0,0 +1 @@
|
|
1
|
+
py_near
|
File without changes
|