xtn-tools-pro 1.0.0.2.5__tar.gz → 1.0.0.2.7__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- {xtn-tools-pro-1.0.0.2.5/xtn_tools_pro.egg-info → xtn-tools-pro-1.0.0.2.7}/PKG-INFO +1 -1
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/setup.py +1 -1
- xtn-tools-pro-1.0.0.2.7/xtn_tools_pro/task_pro/go_fun.py +54 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7/xtn_tools_pro.egg-info}/PKG-INFO +1 -1
- xtn-tools-pro-1.0.0.2.5/xtn_tools_pro/task_pro/go_fun.py +0 -24
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/LICENSE +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/README.md +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/setup.cfg +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/__init__.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/db/MongoDB.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/db/MysqlDB.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/db/RedisDB.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/db/__init__.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/proxy/XiaoXiangProxy.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/proxy/__init__.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/proxy/proxy.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/task_pro/__init__.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/tools.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/utils/__init__.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/utils/crypto.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/utils/file_utils.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/utils/helpers.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/utils/log.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/utils/retry.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/utils/sql.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro/utils/time_utils.py +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro.egg-info/SOURCES.txt +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro.egg-info/dependency_links.txt +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro.egg-info/requires.txt +0 -0
- {xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro.egg-info/top_level.txt +0 -0
@@ -0,0 +1,54 @@
|
|
1
|
+
#!/usr/bin/env python
|
2
|
+
# -*- coding: utf-8 -*-
|
3
|
+
|
4
|
+
# 说明:
|
5
|
+
# 程序说明xxxxxxxxxxxxxxxxxxx
|
6
|
+
# History:
|
7
|
+
# Date Author Version Modification
|
8
|
+
# --------------------------------------------------------------------------------------------------
|
9
|
+
# 2025/1/14 xiatn V00.01.000 新建
|
10
|
+
# --------------------------------------------------------------------------------------------------
|
11
|
+
import os
|
12
|
+
import configparser
|
13
|
+
from xtn_tools_pro.utils.file_utils import check_file_exists
|
14
|
+
|
15
|
+
|
16
|
+
class GoFun:
|
17
|
+
def __init__(self, ini_dict):
|
18
|
+
# 读取配置信息
|
19
|
+
host = ini_dict.get('host', '')
|
20
|
+
port = ini_dict.get('port', 0)
|
21
|
+
task = ini_dict.get('task', '')
|
22
|
+
auto = ini_dict.get('auto', '')
|
23
|
+
is_processes = ini_dict.get('is_processes', False)
|
24
|
+
processes_num = ini_dict.get('processes_num', 0)
|
25
|
+
is_thread = ini_dict.get('is_thread', False)
|
26
|
+
thread_num = ini_dict.get('thread_num', 0)
|
27
|
+
|
28
|
+
self.__ini_info = {
|
29
|
+
"host": host,
|
30
|
+
"port": port,
|
31
|
+
"task": task,
|
32
|
+
"auto": auto,
|
33
|
+
"is_processes": is_processes,
|
34
|
+
"processes_num": processes_num,
|
35
|
+
"is_thread": is_thread,
|
36
|
+
"thread_num": thread_num,
|
37
|
+
}
|
38
|
+
|
39
|
+
for server_k, server_v in self.__ini_info.items():
|
40
|
+
if not server_v and server_k not in ["port", "is_processes", "processes_num", "is_thread", "thread_num"]:
|
41
|
+
raise Exception(f"ini_dict 配置 {server_k} 不存在")
|
42
|
+
|
43
|
+
if port:
|
44
|
+
task_host = f"http://{host}:{port}"
|
45
|
+
else:
|
46
|
+
task_host = f"http://{host}"
|
47
|
+
|
48
|
+
download_url = task_host + "/filter_server/phone/get"
|
49
|
+
upload_url = task_host + "/filter_server/phone/update"
|
50
|
+
|
51
|
+
self.__ini_info["download_url"] = download_url
|
52
|
+
self.__ini_info["upload_url"] = upload_url
|
53
|
+
|
54
|
+
print(self.__ini_info)
|
@@ -1,24 +0,0 @@
|
|
1
|
-
#!/usr/bin/env python
|
2
|
-
# -*- coding: utf-8 -*-
|
3
|
-
|
4
|
-
# 说明:
|
5
|
-
# 程序说明xxxxxxxxxxxxxxxxxxx
|
6
|
-
# History:
|
7
|
-
# Date Author Version Modification
|
8
|
-
# --------------------------------------------------------------------------------------------------
|
9
|
-
# 2025/1/14 xiatn V00.01.000 新建
|
10
|
-
# --------------------------------------------------------------------------------------------------
|
11
|
-
import os
|
12
|
-
from xtn_tools_pro.utils.file_utils import check_file_exists
|
13
|
-
|
14
|
-
|
15
|
-
class GoFun:
|
16
|
-
def __init__(self, ini_file=""):
|
17
|
-
if not ini_file:
|
18
|
-
ini_current_dir = os.getcwd()
|
19
|
-
ini_file = os.path.join(ini_current_dir, "st.ini")
|
20
|
-
if not check_file_exists(ini_file):
|
21
|
-
raise Exception("st.ini 配置文件不存在,请在当前文件夹中新建该配置文件")
|
22
|
-
|
23
|
-
print(ini_file)
|
24
|
-
print(f"The current working directory is: {ini_current_dir}")
|
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
|
{xtn-tools-pro-1.0.0.2.5 → xtn-tools-pro-1.0.0.2.7}/xtn_tools_pro.egg-info/dependency_links.txt
RENAMED
File without changes
|
File without changes
|
File without changes
|