NotSupportedError: unicode queries not yet supported

Bug #931909 reported by Zorbo Lorenzo
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Geospatial Addons for OpenERP
Fix Committed
High
Unassigned

Bug Description

In geoegine demo, when i want to use the search zip management, i have this message :

Traceback (most recent call last):
  File "/usr/local/lib/python2.6/dist-packages/openerp-6.1rc1_20120112_173907-py 2.6.egg/openerp/osv/osv.py", line 120, in wrapper
    return f(self, dbname, *args, **kwargs)
  File "/usr/local/lib/python2.6/dist-packages/openerp-6.1rc1_20120112_173907-py 2.6.egg/openerp/osv/osv.py", line 175, in execute
    res = self.execute_cr(cr, uid, obj, method, *args, **kw)
  File "/usr/local/lib/python2.6/dist-packages/openerp-6.1rc1_20120112_173907-py 2.6.egg/openerp/osv/osv.py", line 163, in execute_cr
    return getattr(object, method)(cr, uid, *args, **kw)
  File "/usr/local/lib/python2.6/dist-packages/openerp-6.1rc1_20120112_173907-py 2.6.egg/openerp/osv/orm.py", line 3372, in read
    result = self._read_flat(cr, user, select, fields, context, load)
  File "/usr/local/lib/python2.6/dist-packages/openerp-6.1rc1_20120112_173907-py 2.6.egg/openerp/osv/orm.py", line 3495, in _read_flat
    res2 = self._columns[f].get(cr, self, ids, f, user, context=context, values= res)
  File "/usr/local/lib/python2.6/dist-packages/openerp-6.1rc1_20120112_173907-py 2.6.egg/openerp/osv/fields.py", line 1052, in get
    result = self._fnct(obj, cr, uid, ids, name, self._arg, context)
  File "/usr/local/lib/python2.6/dist-packages/openerp-6.1rc1_20120112_173907-py 2.6.egg/openerp/addons/base_geoengine_demo/geo_npa.py", line 32, in _get_ZIP_tot al_sales
    geo_domain=[('the_point', 'geo_intersect', {'dummy.zip.the_geom': [('id', '= ', zip_id)]})])
  File "/usr/local/lib/python2.6/dist-packages/openerp-6.1rc1_20120112_173907-py 2.6.egg/openerp/addons/base_geoengine/geo_model.py", line 134, in geo_search
    offset=offset, limit=limit, order=order, context=context)
  File "/usr/local/lib/python2.6/dist-packages/openerp-6.1rc1_20120112_173907-py 2.6.egg/openerp/addons/base_geoengine/geo_operators.py", line 89, in geo_search
    print cursor.mogrify(sql, where_clause_params)

NotSupportedError: unicode queries not yet supported

Revision history for this message
Zorbo Lorenzo (lorenzo-zorbo) wrote :

When i put ligne 89 and 90 in comment :

#print cursor.mogrify(sql, where_clause_params)
    #logger.debug(cursor.mogrify(sql, where_clause_params))

i don't have an error message and i can see zip and cities.

Revision history for this message
Nicolas Bessi - Camptocamp (nbessi-c2c-deactivatedaccount) wrote :

Yes thanks I forgot some debug statement in code.

Regards

Nicolas

Changed in c2c-geoengine-addons:
status: New → Fix Committed
Changed in c2c-geoengine-addons:
importance: Undecided → Low
importance: Low → High
assignee: nobody → Nicolas Bessi - Camptocamp (nbessi-c2c)
status: Fix Committed → In Progress
status: In Progress → Fix Committed
affects: c2c-geoengine-addons → geospatial-addons
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.