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

Prevent raising NotYet in removeIntIdSubscriber #4

Merged
merged 1 commit into from Aug 26, 2016
Merged

Conversation

ale-rt
Copy link
Member

@ale-rt ale-rt commented Aug 26, 2016

Prevent errors on removeIntIdSubscriber when the IKeyReference adapter raises a NotYet, e.g. because the object does not have a proper path.

Some background...

I had to use this patch to migrate a Plone4 site to Plone5.

A couple of examples of object removed triggering the NotYet:

ipdb> IKeyReference(ob, None)
*** NotYet: <SimpleItem at >
ipdb> ob.__dict__
{'_v__object_deleted__': 1, 'isAllowed': True, '__ac_local_roles__': {'admin': ['Owner']}, 'title': 'Generates RSS for folders'}

and:

ipdb> IKeyReference(ob, None)
*** NotYet: 
ipdb> ob.__dict__
{'_real': <Products.CMFCore.DirectoryView.DirectoryView object at 0x7f68fff85410>, '_dirpath': 'Products.CMFPlone:skins/cmf_legacy', '_v__object_deleted__': 1, '_objects': (), '__ac_local_roles__': {'admin': ['Owner']}, 'id': 'cmf_legacy'}

This is a fix similar to 513ca3c

@jensens jensens merged commit 0ab5a84 into master Aug 26, 2016
@jensens jensens deleted the fix-not-yet branch August 26, 2016 14:38
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.

None yet

2 participants