Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6937705

Browse files
committed
fix: add expr to init
Signed-off-by: Gabor Boros <gabor.brs@gmail.com>
1 parentf1ab498 commit6937705

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

‎CHANGELOG.rst‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ Migration Guide
121121

122122
For users upgrading from 2.4.x to 2.5.0:
123123

124-
1. **Python**: Use Python 3.7+.
124+
1. **Python**: Use Python 3.10+.
125125
2. **Imports**: Update imports for moved modules (e.g., utilities now in `rethinkdb.utils`).
126126
3. **Exceptions**: Replace `Rql*` with `Reql*`. Adjust error handling for `ReqlAuthError`/`ReqlTimeoutError` host/port validation.
127127
4. **Handshake**: If customizing JSON encoding/decoding during handshake, pass `json_encoder`/`json_decoder` to `HandshakeV1_0`.

‎rethinkdb/__init__.py‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
importwarnings
2222

2323
fromrethinkdbimportnet
24+
fromrethinkdb.astimportexpr
2425
fromrethinkdb.queryimport (
2526
add,
2627
and_,
@@ -158,6 +159,7 @@
158159
"do":do,
159160
"epoch_time":epoch_time,
160161
"eq":eq,
162+
"expr":expr,
161163
"error":error,
162164
"february":february,
163165
"floor":floor,
@@ -239,12 +241,10 @@ class Client:
239241
def__init__(self):
240242
super().__init__()
241243

242-
self.net=net
243-
244244
net.Connection._r=self
245245
self.connection_type=None
246246

247-
self.make_connection=self.net.make_connection
247+
self.make_connection=net.make_connection
248248
self.set_loop_type(None)
249249

250250
defset_loop_type(self,library=None)->None:
@@ -279,7 +279,7 @@ def set_loop_type(self, library=None) -> None:
279279
self.connection_type=TwistedConnection
280280

281281
iflibraryisNoneorself.connection_typeisNone:
282-
self.connection_type=self.net.DefaultConnection
282+
self.connection_type=net.DefaultConnection
283283

284284
defconnect(self,*connect_args,**kwargs):
285285
"""

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp