ezKit 3.0.71__tar.gz → 3.0.73__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ezKit
3
- Version: 3.0.71
3
+ Version: 3.0.73
4
4
  Summary: Easy Kit
5
5
  Author: septvean
6
6
  Author-email: septvean@gmail.com
@@ -523,7 +523,7 @@ class Database:
523
523
  info: str = f"{info_prefix}database execute statement"
524
524
 
525
525
  if DEBUG:
526
- logger.debug(f"{info} | SQL\n----------\n\n{statement}\n\n----------")
526
+ logger.debug(f"{info} | statement:\n----------\n\n{statement}\n\n----------")
527
527
 
528
528
  logger.info(f"{info} | start")
529
529
 
@@ -749,7 +749,7 @@ class Database:
749
749
  Returns:
750
750
  所有语句执行后返回 `{"count": rowcount总和}`。
751
751
  参数无效、校验失败或没有待执行语句时返回 None;
752
- 单条语句执行失败会记录错误并继续处理其余语句。
752
+ 单条语句执行失败会记录错误并停止处理其余语句。
753
753
 
754
754
  安全提示:
755
755
  每项更新都必须提供非空 where 和 values,避免意外无条件更新全表。
@@ -810,7 +810,7 @@ class Database:
810
810
 
811
811
  if result is None:
812
812
  logger.error(f"{info} | failed to execute statement")
813
- continue
813
+ return None
814
814
 
815
815
  total_count += result.rowcount
816
816
 
@@ -851,7 +851,7 @@ class Database:
851
851
  Returns:
852
852
  所有语句执行后返回 `{"count": rowcount总和}`。
853
853
  参数无效、校验失败或没有待执行语句时返回 None;
854
- 单条语句执行失败会记录错误并继续处理其余语句。
854
+ 单条语句执行失败会记录错误并停止处理其余语句。
855
855
 
856
856
  安全提示:
857
857
  每组条件都必须非空,以免无 WHERE 条件删除全表。
@@ -898,7 +898,7 @@ class Database:
898
898
 
899
899
  if result is None:
900
900
  logger.error(f"{info} | failed to execute statement")
901
- continue
901
+ return None
902
902
 
903
903
  total_count += result.rowcount
904
904
 
@@ -1066,7 +1066,7 @@ class AsyncDatabase:
1066
1066
  info: str = f"{info_prefix}database execute statement"
1067
1067
 
1068
1068
  if DEBUG:
1069
- logger.debug(f"{info} | SQL\n----------\n\n{statement}\n\n----------")
1069
+ logger.debug(f"{info} | statement:\n----------\n\n{statement}\n\n----------")
1070
1070
 
1071
1071
  logger.info(f"{info} | start")
1072
1072
 
@@ -1295,7 +1295,7 @@ class AsyncDatabase:
1295
1295
  Returns:
1296
1296
  所有语句执行后返回 `{"count": rowcount总和}`。
1297
1297
  参数无效、校验失败或没有待执行语句时返回 None;
1298
- 单条语句执行失败会记录错误并继续处理其余语句。
1298
+ 单条语句执行失败会记录错误并停止处理其余语句。
1299
1299
 
1300
1300
  安全提示:
1301
1301
  每项更新都必须提供非空 where 和 values,避免意外无条件更新全表。
@@ -1356,7 +1356,7 @@ class AsyncDatabase:
1356
1356
 
1357
1357
  if result is None:
1358
1358
  logger.error(f"{info} | failed to execute statement")
1359
- continue
1359
+ return None
1360
1360
 
1361
1361
  total_count += result.rowcount
1362
1362
 
@@ -1397,7 +1397,7 @@ class AsyncDatabase:
1397
1397
  Returns:
1398
1398
  所有语句执行后返回 `{"count": rowcount总和}`。
1399
1399
  参数无效、校验失败或没有待执行语句时返回 None;
1400
- 单条语句执行失败会记录错误并继续处理其余语句。
1400
+ 单条语句执行失败会记录错误并停止处理其余语句。
1401
1401
 
1402
1402
  安全提示:
1403
1403
  每组条件都必须非空,以免无 WHERE 条件删除全表。
@@ -1444,7 +1444,7 @@ class AsyncDatabase:
1444
1444
 
1445
1445
  if result is None:
1446
1446
  logger.error(f"{info} | failed to execute statement")
1447
- continue
1447
+ return None
1448
1448
 
1449
1449
  total_count += result.rowcount
1450
1450
 
@@ -184,7 +184,7 @@ async def api_execute(
184
184
  data = params_object
185
185
 
186
186
  if DEBUG:
187
- logger.debug(f"\n----------\n\nParameters:\n\n\t{data}\n\n----------")
187
+ logger.debug(f"parameters:\n----------\n\n{data}\n\n----------")
188
188
 
189
189
  if data in ("", {}, []) or (isinstance(data, FormData) and not data):
190
190
 
@@ -199,7 +199,7 @@ async def api_execute(
199
199
  result = operation(data) if download_file else await operation(data)
200
200
 
201
201
  if DEBUG:
202
- logger.debug(f"\n----------\n\nResult:\n\n{result}\n\n----------")
202
+ logger.debug(f"result:\n----------\n\n{result}\n\n----------")
203
203
 
204
204
  if result is None:
205
205
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: ezKit
3
- Version: 3.0.71
3
+ Version: 3.0.73
4
4
  Summary: Easy Kit
5
5
  Author: septvean
6
6
  Author-email: septvean@gmail.com
@@ -4,7 +4,7 @@ from setuptools import find_packages, setup
4
4
 
5
5
  setup(
6
6
  name="ezKit",
7
- version="3.0.71",
7
+ version="3.0.73",
8
8
  author="septvean",
9
9
  author_email="septvean@gmail.com",
10
10
  description="Easy Kit",
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