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
cc66aee9
Commit
cc66aee9
authored
May 14, 2021
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
83e6cc19
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
wcfs/testprog/treegen.py
wcfs/testprog/treegen.py
+4
-5
No files found.
wcfs/testprog/treegen.py
View file @
cc66aee9
...
@@ -417,12 +417,11 @@ def commit(description, skipIfEmpty=False): # -> tid | None
...
@@ -417,12 +417,11 @@ def commit(description, skipIfEmpty=False): # -> tid | None
zconn
=
txn
.
_resources
[
0
]
zconn
=
txn
.
_resources
[
0
]
assert
isinstance
(
zconn
,
Connection
)
assert
isinstance
(
zconn
,
Connection
)
assert
len
(
zconn
.
_registered_objects
)
>
0
assert
len
(
zconn
.
_registered_objects
)
>
0
obj
=
zconn
.
_registered_objects
[
0
]
# NOTE objects in zconn._registered_objects are not necessarily in CHANGED state:
# FIXME vvv fails sometims with obj._p_state=0 (UPTODATE)
# see e.g. https://erp5.nexedi.net/test_result_module/20201016-89AA413F/5
# XXX objects in zconn._registered_objects are not necessarily in CHANGED state:
# https://github.com/zopefoundation/ZODB/blob/5.6.0-19-gdad778016/src/ZODB/Connection.py#L516-L530
# https://github.com/zopefoundation/ZODB/blob/5.6.0-19-gdad778016/src/ZODB/Connection.py#L516-L530
assert
obj
.
_p_state
==
CHANGED
,
(
obj
.
_p_state
,
obj
)
changed_objects
=
[
obj
for
obj
in
zconn
.
_registered_objects
if
obj
.
_p_state
==
CHANGED
]
assert
len
(
changed_objects
)
>
0
obj
=
changed_objects
[
0
]
txn
.
commit
()
txn
.
commit
()
return
obj
.
_p_serial
return
obj
.
_p_serial
...
...
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