Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
W
wendelin.core
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
Kirill Smelkov
wendelin.core
Commits
5cb39463
Commit
5cb39463
authored
Oct 13, 2020
by
Kirill Smelkov
1
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixup! X wcfs/zeo started to work locally
ZEO4 can have ._addr as either ("host", port) or "path".
parent
cec0447c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
4 deletions
+13
-4
lib/zodb.py
lib/zodb.py
+13
-4
No files found.
lib/zodb.py
View file @
5cb39463
...
@@ -322,10 +322,19 @@ def zstor_2zurl(zstor):
...
@@ -322,10 +322,19 @@ def zstor_2zurl(zstor):
# ZEO
# ZEO
if
ztype
==
"ZEO.ClientStorage.ClientStorage"
:
if
ztype
==
"ZEO.ClientStorage.ClientStorage"
:
u
=
"zeo://"
u
=
"zeo://"
addr
=
zstor
.
_addr
_addr
=
zstor
.
_addr
if
len
(
addr
)
!=
1
:
addr
=
None
raise
NotImplementedError
(
"ZEO client has multiple configured servers: %r"
%
(
addr
,))
# ZEO4/3 for backward compatibility accept either a single "address" or single ("host", port) pair
addr
=
addr
[
0
]
# https://github.com/zopefoundation/ZEO/blob/4.2.0b1-49-g47d3fbe8/src/ZEO/zrpc/client.py#L179
if
zmajor
<=
4
:
if
isinstance
(
_addr
,
str
):
addr
=
_addr
elif
len
(
_addr
)
==
2
and
isinstance
(
_addr
[
0
],
str
)
and
isinstance
(
_addr
[
1
],
int
):
addr
=
_addr
if
addr
is
None
:
if
len
(
_addr
)
!=
1
:
raise
NotImplementedError
(
"ZEO client has multiple configured servers: %r"
%
(
addr
,))
addr
=
_addr
[
0
]
# addr is either TCP (host,port) or UNIX path
# addr is either TCP (host,port) or UNIX path
if
isinstance
(
addr
,
str
):
if
isinstance
(
addr
,
str
):
u
+=
addr
u
+=
addr
...
...
Kirill Smelkov
@kirr
mentioned in commit
a05db040
·
Oct 28, 2021
mentioned in commit
a05db040
mentioned in commit a05db0408929b08ab5ecb7c8238711661e303ce0
Toggle commit list
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment