collective / collective.jsonmigrator

JSON based migrations for Plone
GNU General Public License v2.0
8 stars 21 forks source link

use string values when traversing, instead of unicode #21

Closed erral closed 7 years ago

erral commented 8 years ago

In some scenarios, I found that the path is a unicode string, and when that happens the unrestrictedTraverse refuses to traverse the object so it can't change the workflow history.

This change uses safe_unicode to make the unicode -> utf8 conversion and have a sane string to call to unrestrictedTraverse

lepri commented 8 years ago

Or you can use str function to convert.

calvinhp commented 7 years ago

Any reason not to merge this?

cdw9 commented 7 years ago

this same problem happens in the other blueprints as well, we should fix it throughout the whole package

sunew commented 7 years ago

Fixed for all blueprints in https://github.com/collective/collective.jsonmigrator/pull/26