Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(Export/)Import broken for "OFS.SimpleItem.Item_w__name__" instances #903

Closed
d-maurer opened this issue Oct 6, 2020 · 3 comments
Closed

Comments

@d-maurer
Copy link
Contributor

d-maurer commented Oct 6, 2020

BUG/PROBLEM REPORT

If an instance of OFS.SimpleItem.Item_w__name__ (e.g. an OFS.Image.File instance) is exported, a subsequent import fails with BadRequest: ('Empty or invalid id specified', '').

The reason: for Item_w__name__ instances, id must not be used (it is always ''); for those instances getId() must be used to access the object's id.
OFS.ObjectManager.ObjectManager._importObjectFromFile violates this restriction.

What version of Python and Zope/Addons I am using:

current Zope 4.x (likely Zope 5.x as well)

d-maurer added a commit that referenced this issue Oct 6, 2020
d-maurer added a commit that referenced this issue Oct 7, 2020
dataflake added a commit that referenced this issue Oct 8, 2020
@dataflake
Copy link
Member

dataflake commented Oct 8, 2020

@d-maurer I have handled the forward port to master so it gets into Zope 5. See bea75e6

@d-maurer
Copy link
Contributor Author

d-maurer commented Oct 8, 2020 via email

@dataflake
Copy link
Member

Both #906 and #907 are merged so I'll close this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants