sqlalchemy-iris 0.17.1b2__py3-none-any.whl → 0.17.1b3__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.
- sqlalchemy_iris/intersystems/__init__.py +16 -13
- sqlalchemy_iris/intersystems/dbapi.py +4 -0
- {sqlalchemy_iris-0.17.1b2.dist-info → sqlalchemy_iris-0.17.1b3.dist-info}/METADATA +1 -1
- {sqlalchemy_iris-0.17.1b2.dist-info → sqlalchemy_iris-0.17.1b3.dist-info}/RECORD +8 -8
- {sqlalchemy_iris-0.17.1b2.dist-info → sqlalchemy_iris-0.17.1b3.dist-info}/LICENSE +0 -0
- {sqlalchemy_iris-0.17.1b2.dist-info → sqlalchemy_iris-0.17.1b3.dist-info}/WHEEL +0 -0
- {sqlalchemy_iris-0.17.1b2.dist-info → sqlalchemy_iris-0.17.1b3.dist-info}/entry_points.txt +0 -0
- {sqlalchemy_iris-0.17.1b2.dist-info → sqlalchemy_iris-0.17.1b3.dist-info}/top_level.txt +0 -0
@@ -1,5 +1,4 @@
|
|
1
1
|
import re
|
2
|
-
import pkg_resources
|
3
2
|
from ..base import IRISDialect
|
4
3
|
from sqlalchemy import text, util
|
5
4
|
from ..base import IRISExecutionContext
|
@@ -62,6 +61,8 @@ class IRISDialect_intersystems(IRISDialect):
|
|
62
61
|
|
63
62
|
logfile = None
|
64
63
|
|
64
|
+
server_version = None
|
65
|
+
|
65
66
|
def __init__(self, logfile: str = None, **kwargs):
|
66
67
|
self.logfile = logfile
|
67
68
|
IRISDialect.__init__(self, **kwargs)
|
@@ -115,19 +116,21 @@ class IRISDialect_intersystems(IRISDialect):
|
|
115
116
|
|
116
117
|
return ([], opts)
|
117
118
|
|
119
|
+
def on_connect(self):
|
120
|
+
super_ = super().on_connect()
|
121
|
+
|
122
|
+
def on_connect(conn):
|
123
|
+
if super_ is not None:
|
124
|
+
super_(conn)
|
125
|
+
|
126
|
+
server_version = dbapi.createIRIS(conn).classMethodValue("%SYSTEM.Version", "GetNumber")
|
127
|
+
server_version = server_version.split(".")
|
128
|
+
self.server_version = tuple([int("".join(filter(str.isdigit, v))) for v in server_version])
|
129
|
+
|
130
|
+
return on_connect
|
131
|
+
|
118
132
|
def _get_server_version_info(self, connection):
|
119
|
-
|
120
|
-
try:
|
121
|
-
return tuple(
|
122
|
-
map(
|
123
|
-
int,
|
124
|
-
pkg_resources.get_distribution(
|
125
|
-
"intersystems_irispython"
|
126
|
-
).version.split("."),
|
127
|
-
)
|
128
|
-
)
|
129
|
-
except: # noqa
|
130
|
-
return None
|
133
|
+
return self.server_version
|
131
134
|
|
132
135
|
def _get_option(self, connection, option):
|
133
136
|
with connection.cursor() as cursor:
|
@@ -73,12 +73,12 @@ sqlalchemy_iris/irisasync.py,sha256=7Kmso-RGjxQi9Y4x-zQaUk1ylDQ7TDvpvlZh_syJtGw,
|
|
73
73
|
sqlalchemy_iris/provision.py,sha256=drorbIgNO770Ws0XiCRXY_sDbQGIy2_zzNK3KYrDetY,198
|
74
74
|
sqlalchemy_iris/requirements.py,sha256=Xxk8eGmXHUQoz3a8Hg8UxebJ-bdJYhCazrcaJTgWzOE,44393
|
75
75
|
sqlalchemy_iris/types.py,sha256=M5uyeANVN6MU40kiWBePGTCnVaAAKmfLOHq7zuJ0z6A,12024
|
76
|
-
sqlalchemy_iris/intersystems/__init__.py,sha256=
|
76
|
+
sqlalchemy_iris/intersystems/__init__.py,sha256=LFMRKPMTEFSbnlIUyXLQuz6E5X1UAFJf107I_VEw6-Y,5506
|
77
77
|
sqlalchemy_iris/intersystems/cursor.py,sha256=I6hICJqlpomXpvE3fx0JWQwTlD6-GQi9cHxa4PAzGZM,464
|
78
|
-
sqlalchemy_iris/intersystems/dbapi.py,sha256=
|
79
|
-
sqlalchemy_iris-0.17.
|
80
|
-
sqlalchemy_iris-0.17.
|
81
|
-
sqlalchemy_iris-0.17.
|
82
|
-
sqlalchemy_iris-0.17.
|
83
|
-
sqlalchemy_iris-0.17.
|
84
|
-
sqlalchemy_iris-0.17.
|
78
|
+
sqlalchemy_iris/intersystems/dbapi.py,sha256=JOPjpXrD_cwCzAwnO9cRwBtv2SM8YbczOk8PFX3oM_4,899
|
79
|
+
sqlalchemy_iris-0.17.1b3.dist-info/LICENSE,sha256=RQmigqltsLq8lfOBc_KwtL0gkODyUCNpU-0ZiZwGlho,1075
|
80
|
+
sqlalchemy_iris-0.17.1b3.dist-info/METADATA,sha256=gHWh-UOSV6T-3bUUHoNjUabiVQJqWbt4JT6e6WOJzmc,2946
|
81
|
+
sqlalchemy_iris-0.17.1b3.dist-info/WHEEL,sha256=jB7zZ3N9hIM9adW7qlTAyycLYW9npaWKLRzaoVcLKcM,91
|
82
|
+
sqlalchemy_iris-0.17.1b3.dist-info/entry_points.txt,sha256=sYU1YvyyeGqOVVMpHySThfEhrVQL1lUVz5rDwmwCj7E,258
|
83
|
+
sqlalchemy_iris-0.17.1b3.dist-info/top_level.txt,sha256=QRY18YUXUJrRde4aayj_brj0lr2LBRVZS1ZoVoDFVS0,45
|
84
|
+
sqlalchemy_iris-0.17.1b3.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|