I remembered the full zodbverify guide and was able to identify the problem with it Best practice documentation on ZODB Debugging. Object databases are scary to work with when classes are removed, but this is a powerful light in the dark.
The problem was a registered component and I was able to unregister it in the debugger. Here is the relevant part in my testing (followed by transaction.commit()
)
>>> site.getSiteManager()
<PersistentComponents plone_demo>
>>> sm=site.getSiteManager()
>>> from Products.CMFCore.interfaces import IPropertiesTool
>>> sm._utility_registrations.get((IPropertiesTool, ''))
(<persistent broken Products.CMFPlone.PropertiesTool.PropertiesTool instance b'\x00\x00\x00\x00\x00\x026\xe5'>, '', None)
>>> component=sm._utility_registrations.get((IPropertiesTool, ''))[0]
>>> sm.unregisterUtility(component, IPropertiesTool, '')
True
And if I look at /manage_components on the source site (6.0) I do see it registered there.
I'm still confused why would this not be a problem for others? I also tested on a local dev site where I did not have a problem, migrating a site created in 6.0.14 to 6.1 I see this registered component, though again, I do not get any errors on that site.
<utility factory="Products.CMFPlone.PropertiesTool.PropertiesTool"
id="broken object"
interface="Products.CMFCore.interfaces.IPropertiesTool"/>
But maybe this should still be removed? I'm curious if those with a successful migration also have that as a broken object in their components.