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

Dx siteroot #27

Merged
merged 15 commits into from
Aug 26, 2021
Merged

Dx siteroot #27

merged 15 commits into from
Aug 26, 2021

Conversation

jaroel
Copy link
Member

@jaroel jaroel commented Apr 6, 2019

No description provided.

jaroel added 2 commits July 31, 2018 00:36
…y ?> with a VerifyingAdapterLookup, which doesn't have a dependents attribute. Not sure why tf this is happening.
@mister-roboto
Copy link

@jaroel thanks for creating this Pull Request and help improve Plone!

To ensure that these changes do not break other parts of Plone, the Plone test suite matrix needs to pass.

Whenever you feel that the pull request is ready to be tested, either start all jenkins jobs pull requests by yourself, or simply add a comment in this pull request stating:

@jenkins-plone-org please run jobs

With this simple comment all the jobs will be started automatically.

Happy hacking!

@jensens
Copy link
Member

jensens commented Feb 16, 2020

@jaroel This change could be merged even w/o dx-site-root. It needs a Changelog entry and tests run.

@jaroel
Copy link
Member Author

jaroel commented Mar 29, 2020

This whole thing can/should be revisited. The latter part of finalizeSchemas is a workaround for Python2 where isintance doesn't work as expected with InterfaceClasses, see zopefoundation/zope.interface#16.
This does work for Python3.

plone/supermodel/model.py Outdated Show resolved Hide resolved
plone/supermodel/model.py Outdated Show resolved Hide resolved
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.

LGTM.

Can probably be merged separately, but we would need to create a branch of supermodel first for Plone 5.2.

But I wonder if this might be save to use on 5.2 as well. The news snippet says it is a breaking change, but to me it only seems a slight performance gain. The original code yields all schemas upfront, but then ignores them anyway when they do not have an attribute _SchemaClass_finalize, and it warns when it is an instance of InterfaceClass instead of SchemaClass.
This could be influenced by the zope.interface version though.

For stability, we should probably not add this in 5.2 though. But if someone wants this, it could be considered.
Okay, I have created branch 1.x and let coredev 5.2 use this.
We could revisit this.

Anyway: it is now probably mergeable to master for Plone 6. Needs another Jenkins run though.

plone/supermodel/model.py Show resolved Hide resolved
# to find out why this is happening in the first place.
try:
children = schema.dependents.keys()
except AttributeError:
Copy link
Member

Choose a reason for hiding this comment

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

I added a breakpoint here, and it did not get triggered on startup and also not when running the (non-robot) tests from CMFPlone. So there is a chance that this is no longer needed.
But it seems fine for me to keep this, so we avoid weird errors in corner cases in tests.

Copy link
Member

@ale-rt ale-rt Aug 25, 2021

Choose a reason for hiding this comment

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

It seems this branch is needed to fix the plip branch build.
After I added this commit:

Before I started:

which is not yet over but I expect it to fail

Copy link
Member

Choose a reason for hiding this comment

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

It was my mistake to remove this checkout from the PLIP.
I probably got confused between the various packages. Sorry!

Since the job of this individual PR is green on 6.0, and I already let 5.2 use a maintenance branch, it would be fine to merge this PR now, without the other PLIP PRs.
@ale-rt Do you want to push the merge button?

Copy link
Member

@ale-rt ale-rt Aug 25, 2021

Choose a reason for hiding this comment

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

@mauritsvanrees I see no harm in doing that, but waiting for other people review seems a good idea: CC @plone/framework-team

@mister-roboto
Copy link

@jaroel thanks for creating this Pull Request and help improve Plone!

To ensure that these changes do not break other parts of Plone, the Plone test suite matrix needs to pass.

Whenever you feel that the pull request is ready to be tested, either start all jenkins jobs pull requests by yourself, or simply add a comment in this pull request stating:

@jenkins-plone-org please run jobs

With this simple comment all the jobs will be started automatically.

Happy hacking!

@mister-roboto
Copy link

@jaroel thanks for creating this Pull Request and help improve Plone!

To ensure that these changes do not break other parts of Plone, the Plone test suite matrix needs to pass.

Whenever you feel that the pull request is ready to be tested, either start all jenkins jobs pull requests by yourself, or simply add a comment in this pull request stating:

@jenkins-plone-org please run jobs

With this simple comment all the jobs will be started automatically.

Happy hacking!

@mauritsvanrees
Copy link
Member

I closed and reopened the PR, to see if that would get rid of the proposed Jenkins runs on 5.2, but that is not the case.
Let's see what happens when we say:

@jenkins-plone-org please run jobs

@jensens
Copy link
Member

jensens commented Aug 26, 2021

Plone 5.2 coredev is on branch 1.x, so this is fine to merge.

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

Successfully merging this pull request may close these issues.

6 participants