[sobjects] fix fresh.workcases importer
authorPhilippe Pepiot <philippe.pepiot@logilab.fr>
Thu, 18 Jul 2019 11:40:02 +0200
changeset 110 e4e6a0b0719a
parent 109 923b1d1e2d12
child 111 c85712f80d85
[sobjects] fix fresh.workcases importer In extentities generator, extid is cwuri from database which is a text field. So in python3 exteid2eid[extid] wasn't matching anything because extid was bytes. Use text extid instead.
cubicweb_fresh/sobjects.py
--- a/cubicweb_fresh/sobjects.py	Tue Jun 18 16:50:29 2019 +0200
+++ b/cubicweb_fresh/sobjects.py	Thu Jul 18 11:40:02 2019 +0200
@@ -52,7 +52,6 @@
                                 ' X cw_source S, S eid %(s)s'.format(etype),
                                 {'s': self.source.eid})
         for extid, eid in rset:
-            extid = extid.encode('ascii')
             self._source_uris[extid] = (eid, etype)
             yield extid, eid