sycommon-python-lib 0.2.4a5__py3-none-any.whl → 0.2.4a6__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.
@@ -1,12 +1,18 @@
1
1
  from sqlalchemy.ext.asyncio import create_async_engine, AsyncSession
2
2
  from sqlalchemy import text
3
3
 
4
- # Fix: aiomysql's AsyncAdapt ping() requires 'reconnect' arg,
4
+ # Fix: aiomysql's AsyncAdapt ping() requires 'reconnect' positional arg,
5
5
  # but SQLAlchemy's pymysql dialect calls ping() without it.
6
+ # aiomysql asserts reconnect must be False (async reconnection is handled by pool).
6
7
  from sqlalchemy.dialects.mysql.pymysql import MySQLDialect_pymysql
7
8
 
9
+ _original_do_ping = MySQLDialect_pymysql.do_ping
10
+
8
11
  def _patched_do_ping(self, dbapi_connection):
9
- dbapi_connection.ping(reconnect=True)
12
+ try:
13
+ return _original_do_ping(self, dbapi_connection)
14
+ except TypeError:
15
+ dbapi_connection.ping(reconnect=False)
10
16
 
11
17
  MySQLDialect_pymysql.do_ping = _patched_do_ping
12
18
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: sycommon-python-lib
3
- Version: 0.2.4a5
3
+ Version: 0.2.4a6
4
4
  Summary: Add your description here
5
5
  Requires-Python: >=3.11
6
6
  Description-Content-Type: text/markdown
@@ -159,7 +159,7 @@ sycommon/config/SentryConfig.py,sha256=OsLb3G9lTsCSZ7tWkcXWJHmvfILQopBxje5pjnkFJ
159
159
  sycommon/config/XxlJobConfig.py,sha256=VSG6dn9ysfUVunOs7PqugyZUGJWmX_cEePz2ZCfqHtU,392
160
160
  sycommon/config/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
161
161
  sycommon/database/async_base_db_service.py,sha256=w6ONUiTtF4-bXRnkBt9QpL9BAy0XUDbQG7F9Hf2rfjw,1337
162
- sycommon/database/async_database_service.py,sha256=cDu8Ssv5TVxOT4qOeG9hCbl7r_UbMtASL18ANYkUutw,4635
162
+ sycommon/database/async_database_service.py,sha256=Cf3RaO3skP6IAJrkta-CRE-Q1NtjWLPLUe9hazB8LRM,4873
163
163
  sycommon/database/base_db_service.py,sha256=J5ELHMNeGfzA6zVcASPSPZ0XNKrRY3_gdGmVkZw3Mto,946
164
164
  sycommon/database/database_service.py,sha256=IMoJ9554dYkr6QfRofvNa0VR24U1WQDz_ATrg0-6EQ0,3857
165
165
  sycommon/database/elasticsearch_service.py,sha256=qm490GRlxZlYsQgyfyclSbARRP1-Tc4Lwav3lbPINvQ,3092
@@ -265,8 +265,8 @@ sycommon/tools/syemail.py,sha256=BDFhgf7WDOQeTcjxJEQdu0dQhnHFPO_p3eI0-Ni3LhQ,561
265
265
  sycommon/tools/timing.py,sha256=OiiE7P07lRoMzX9kzb8sZU9cDb0zNnqIlY5pWqHcnkY,2064
266
266
  sycommon/xxljob/__init__.py,sha256=7eoBlQxv-B39IfRSCY2bkqdGYs1QRe1umAWd88VMEEM,86
267
267
  sycommon/xxljob/xxljob_service.py,sha256=JIEJaGXhqrTLcyxlyynSrsHg9bBnDNzX-D4qIWLRPUE,6815
268
- sycommon_python_lib-0.2.4a5.dist-info/METADATA,sha256=TrKuiToYcZfjlvBiK3pOPBwg6aTw7Iy6gsZEoyrQMtY,7879
269
- sycommon_python_lib-0.2.4a5.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91
270
- sycommon_python_lib-0.2.4a5.dist-info/entry_points.txt,sha256=gsR4SssKxDWjRU8ggidzNcdMXDPRSKRS7UaGyNP84Qg,92
271
- sycommon_python_lib-0.2.4a5.dist-info/top_level.txt,sha256=RgphKrg7nJyZ7irJqbxFr-5H2LUYTvI7ivoWZH2hcD0,29
272
- sycommon_python_lib-0.2.4a5.dist-info/RECORD,,
268
+ sycommon_python_lib-0.2.4a6.dist-info/METADATA,sha256=zEXUYpdlTosCIr50Ie2AN9v8GTI7AX_amje0Ag07KBI,7879
269
+ sycommon_python_lib-0.2.4a6.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91
270
+ sycommon_python_lib-0.2.4a6.dist-info/entry_points.txt,sha256=gsR4SssKxDWjRU8ggidzNcdMXDPRSKRS7UaGyNP84Qg,92
271
+ sycommon_python_lib-0.2.4a6.dist-info/top_level.txt,sha256=RgphKrg7nJyZ7irJqbxFr-5H2LUYTvI7ivoWZH2hcD0,29
272
+ sycommon_python_lib-0.2.4a6.dist-info/RECORD,,