Unfortunately this won't work for migrating existing portlet assignments -- Assignment is a persistent class and __init__ is only called when it is first created.

Instead I think we should make the related items widget converter in plone.app.widgets smart enough to try treating the value as a path if no UID match is found.