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

Temporarily disallow constraints when creating the parent folder chain #174

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

ale-rt
Copy link
Member

@ale-rt ale-rt commented Jan 26, 2023

Fixes #173

@ale-rt ale-rt force-pushed the 173-fix-constraints branch from 3d9840e to cd0e0c7 Compare January 26, 2023 15:13
Copy link
Member

@mauritsvanrees mauritsvanrees left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you do this in a try/finally block? Should be slightly safer.

@pbauer
Copy link
Member

pbauer commented Jan 31, 2023

Or you can use Products.CMFPlone.utils._createObjectByType to bypass these checks.

@ale-rt
Copy link
Member Author

ale-rt commented Jan 31, 2023

Yeah, a context manager might be an idea.

Probably @pbauer idea is even better because it might be that even the type in not constrained it is not allowed in the FTI settings.

One other thing is that this always create a Folder.
This might be a problem if later we import the proper object.

I am working on a migration and found some other things, I will try to contribute back as soon as possible!

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

Successfully merging this pull request may close these issues.

Temporarily disallow constraints when creating content
3 participants