Skip to content

Commit

Permalink
[fc] Repository: Products.CMFEditions
Browse files Browse the repository at this point in the history
Branch: refs/heads/master
Date: 2024-12-11T12:48:52-08:00
Author: David Glick (davisagli) <[email protected]>
Commit: plone/Products.CMFEditions@6ee7fb4

Fix handling of aq-wrapped objects in children modifiers

Files changed:
A news/26.bugfix
M Products/CMFEditions/StandardModifiers.py
Repository: Products.CMFEditions

Branch: refs/heads/master
Date: 2024-12-11T13:55:16-08:00
Author: David Glick (davisagli) <[email protected]>
Commit: plone/Products.CMFEditions@0627338

Merge pull request #117 from plone/26-aqbase

Fix handling of aq-wrapped objects in children modifiers

Files changed:
A news/26.bugfix
M Products/CMFEditions/StandardModifiers.py
  • Loading branch information
davisagli committed Dec 11, 2024
1 parent adaa3c6 commit e1cff8d
Showing 1 changed file with 26 additions and 8 deletions.
34 changes: 26 additions & 8 deletions last_commit.txt
Original file line number Diff line number Diff line change
@@ -1,16 +1,34 @@
Repository: plone.volto
Repository: Products.CMFEditions


Branch: refs/heads/main
Date: 2024-12-11T13:27:21-08:00
Branch: refs/heads/master
Date: 2024-12-11T12:48:52-08:00
Author: David Glick (davisagli) <[email protected]>
Commit: https://github.com/plone/plone.volto/commit/6ce63e50ab2c133eba2e434eaf2c5c6cd6128425
Commit: https://github.com/plone/Products.CMFEditions/commit/6ee7fb4e9d176f2e394bd2232c7271ba6f157aef

Finish removing old demo profile
Fix handling of aq-wrapped objects in children modifiers

Files changed:
D src/plone/volto/profiles/demo/metadata.xml
D src/plone/volto/profiles/demo/rolemap.xml
A news/26.bugfix
M Products/CMFEditions/StandardModifiers.py

b'diff --git a/src/plone/volto/profiles/demo/metadata.xml b/src/plone/volto/profiles/demo/metadata.xml\ndeleted file mode 100644\nindex eec40a3..0000000\n--- a/src/plone/volto/profiles/demo/metadata.xml\n+++ /dev/null\n@@ -1,7 +0,0 @@\n-<?xml version="1.0" encoding="utf-8"?>\n-<metadata>\n- <version>1000</version>\n- <dependencies>\n- <dependency>profile-plone.volto:default</dependency>\n- </dependencies>\n-</metadata>\ndiff --git a/src/plone/volto/profiles/demo/rolemap.xml b/src/plone/volto/profiles/demo/rolemap.xml\ndeleted file mode 100644\nindex 3b0a0ea..0000000\n--- a/src/plone/volto/profiles/demo/rolemap.xml\n+++ /dev/null\n@@ -1,13 +0,0 @@\n-<?xml version="1.0" encoding="utf-8"?>\n-<rolemap>\n- <permissions>\n- <permission acquire="True"\n- name="Plone Site Setup: Overview"\n- >\n- <role name="Anonymous" />\n- <role name="Member" />\n- <role name="Site Administrator" />\n- <role name="Manager" />\n- </permission>\n- </permissions>\n-</rolemap>\n'
b'diff --git a/Products/CMFEditions/StandardModifiers.py b/Products/CMFEditions/StandardModifiers.py\nindex f32c25d5..50d03a08 100644\n--- a/Products/CMFEditions/StandardModifiers.py\n+++ b/Products/CMFEditions/StandardModifiers.py\n@@ -335,7 +335,7 @@ def persistent_id(obj):\n try:\n # return a non None value if it is one of the object\n # managers subobjects or raise an KeyError exception\n- return refs[id(obj)]\n+ return refs[id(aq_base(obj))]\n except KeyError:\n # signalize the pickler to just pickle the \'obj\' as\n # usual\ndiff --git a/news/26.bugfix b/news/26.bugfix\nnew file mode 100644\nindex 00000000..0a58eb0d\n--- /dev/null\n+++ b/news/26.bugfix\n@@ -0,0 +1,2 @@\n+Fix "Can\'t pickle objects in acquisition wrappers." error in\n+`OMOutsideChildrensModifier` and `OMInsideChildrensModifier`. @davisagli\n'

Repository: Products.CMFEditions


Branch: refs/heads/master
Date: 2024-12-11T13:55:16-08:00
Author: David Glick (davisagli) <[email protected]>
Commit: https://github.com/plone/Products.CMFEditions/commit/0627338eb36817ad3a5a96232425842fc861468c

Merge pull request #117 from plone/26-aqbase

Fix handling of aq-wrapped objects in children modifiers

Files changed:
A news/26.bugfix
M Products/CMFEditions/StandardModifiers.py

b'diff --git a/Products/CMFEditions/StandardModifiers.py b/Products/CMFEditions/StandardModifiers.py\nindex f32c25d5..50d03a08 100644\n--- a/Products/CMFEditions/StandardModifiers.py\n+++ b/Products/CMFEditions/StandardModifiers.py\n@@ -335,7 +335,7 @@ def persistent_id(obj):\n try:\n # return a non None value if it is one of the object\n # managers subobjects or raise an KeyError exception\n- return refs[id(obj)]\n+ return refs[id(aq_base(obj))]\n except KeyError:\n # signalize the pickler to just pickle the \'obj\' as\n # usual\ndiff --git a/news/26.bugfix b/news/26.bugfix\nnew file mode 100644\nindex 00000000..0a58eb0d\n--- /dev/null\n+++ b/news/26.bugfix\n@@ -0,0 +1,2 @@\n+Fix "Can\'t pickle objects in acquisition wrappers." error in\n+`OMOutsideChildrensModifier` and `OMInsideChildrensModifier`. @davisagli\n'

0 comments on commit e1cff8d

Please sign in to comment.