diff --git a/addons/google_calendar/google_calendar.py b/addons/google_calendar/google_calendar.py index b65d1b337a9..c3dd39153a7 100644 --- a/addons/google_calendar/google_calendar.py +++ b/addons/google_calendar/google_calendar.py @@ -667,7 +667,7 @@ class google_calendar(osv.AbstractModel): registry = openerp.modules.registry.RegistryManager.get(request.session.db) with registry.cursor() as cur: self.pool['res.users'].write(cur, uid, [uid], {'google_calendar_last_sync_date': False}, context=context) - error_key = simplejson.loads(e.read()) + error_key = simplejson.loads(str(e)) error_key = error_key.get('error', {}).get('message', 'nc') error_msg = "Google are lost... the next synchro will be a full synchro. \n\n %s" % error_key raise self.pool.get('res.config.settings').get_config_warning(cr, _(error_msg), context=context)