Error al Validar Factura Electrónica

Estimados.

El sistema odoo informa el siguiente error al validar factura en ambiente certificación SII:

Odoo Server Error

Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 648, in _handle_exception return super(JsonRequest, self)._handle_exception(exception) File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 685, in dispatch result = self._call_function(**self.params) File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 321, in _call_function return checked_call(self.db, *args, **kwargs) File "/usr/lib/python2.7/dist-packages/openerp/service/model.py", line 118, in wrapper return f(dbname, *args, **kwargs) File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 314, in checked_call result = self.endpoint(*a, **kw) File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 964, in __call__ return self.method(*args, **kw) File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 514, in response_wrap response = f(*args, **kw) File "/usr/lib/python2.7/dist-packages/openerp/addons/web/controllers/main.py", line 903, in exec_workflow return request.session.exec_workflow(model, id, signal) File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 1272, in exec_workflow r = self.proxy('object').exec_workflow(self.db, self.uid, self.password, model, signal, id) File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 1040, in proxy_method result = dispatch_rpc(self.service_name, method, args) File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 115, in dispatch_rpc result = dispatch(method, params) File "/usr/lib/python2.7/dist-packages/openerp/service/model.py", line 37, in dispatch res = fn(db, uid, *params) File "/usr/lib/python2.7/dist-packages/openerp/service/model.py", line 118, in wrapper return f(dbname, *args, **kwargs) File "/usr/lib/python2.7/dist-packages/openerp/service/model.py", line 194, in exec_workflow return exec_workflow_cr(cr, uid, obj, signal, *args) File "/usr/lib/python2.7/dist-packages/openerp/service/model.py", line 188, in exec_workflow_cr return execute_cr(cr, uid, obj, 'signal_workflow', [res_id], signal)[res_id] File "/usr/lib/python2.7/dist-packages/openerp/service/model.py", line 170, in execute_cr return getattr(object, method)(cr, uid, *args, **kw) File "/usr/lib/python2.7/dist-packages/openerp/api.py", line 250, in wrapper return old_api(self, *args, **kwargs) File "/usr/lib/python2.7/dist-packages/openerp/models.py", line 3632, in signal_workflow result[res_id] = workflow.trg_validate(uid, self._name, res_id, signal, cr) File "/usr/lib/python2.7/dist-packages/openerp/workflow/__init__.py", line 67, in trg_validate return WorkflowService.new(cr, uid, res_type, res_id).validate(signal) File "/usr/lib/python2.7/dist-packages/openerp/workflow/service.py", line 73, in validate res2 = wi.validate(signal) File "/usr/lib/python2.7/dist-packages/openerp/workflow/instance.py", line 62, in validate wi.process(signal=signal, force_running=force_running, stack=stack) File "/usr/lib/python2.7/dist-packages/openerp/workflow/workitem.py", line 102, in process ok = self._split_test(activity['split_mode'], signal, stack) File "/usr/lib/python2.7/dist-packages/openerp/workflow/workitem.py", line 230, in _split_test self._join_test(t[0], t[1], stack) File "/usr/lib/python2.7/dist-packages/openerp/workflow/workitem.py", line 239, in _join_test WorkflowItem.create(self.session, self.record, activity, inst_id, stack=stack) File "/usr/lib/python2.7/dist-packages/openerp/workflow/workitem.py", line 77, in create workflow_item.process(stack=stack) File "/usr/lib/python2.7/dist-packages/openerp/workflow/workitem.py", line 98, in process if not self._execute(activity, stack): File "/usr/lib/python2.7/dist-packages/openerp/workflow/workitem.py", line 144, in _execute returned_action = self.wkf_expr_execute(activity) File "/usr/lib/python2.7/dist-packages/openerp/workflow/workitem.py", line 295, in wkf_expr_execute return self.wkf_expr_eval_expr(activity['action']) File "/usr/lib/python2.7/dist-packages/openerp/workflow/workitem.py", line 273, in wkf_expr_eval_expr result = eval(line, env, nocopy=True) File "/usr/lib/python2.7/dist-packages/openerp/tools/safe_eval.py", line 298, in safe_eval return eval(c, globals_dict, locals_dict) File "", line 1, in <module> File "/usr/lib/python2.7/dist-packages/openerp/api.py", line 248, in wrapper return new_api(self, *args, **kwargs) File "/var/lib/odoo/addons/l10n_cl_invoice/models/invoice.py", line 565, in action_move_create sii_document_number = obj_inv.journal_document_class_id.sequence_id.next_by_id() File "/usr/lib/python2.7/dist-packages/openerp/api.py", line 248, in wrapper return new_api(self, *args, **kwargs) File "/usr/lib/python2.7/dist-packages/openerp/addons/base/ir/ir_sequence.py", line 259, in next_by_id return self._next() File "/usr/lib/python2.7/dist-packages/openerp/addons/base/ir/ir_sequence.py", line 245, in _next return self._next_do() File "/var/lib/odoo/addons/l10n_cl_dte_caf/models/caf.py", line 225, in _next_do self.update_next_by_caf(folio) File "/var/lib/odoo/addons/l10n_cl_dte_caf/models/caf.py", line 216, in update_next_by_caf for c in self.get_caf_files(folio): File "/var/lib/odoo/addons/l10n_cl_dte_caf/models/caf.py", line 211, in get_caf_files raise UserError(_(msg)) ValueError: "global name 'UserError' is not defined" while evaluating u'action_move_create()'

A que se deberá este error?

Saludos.

Carlos Cataldo
Carlos Cataldo
209
| 3 1 2
Preguntado en 21-04-17 7:29
0
voto
1641 Vistas

SOLUCIONADO.

Gracias Daniel, la solución pasaba por indicar la secuencia.

Saludos.

Carlos Cataldo
Carlos Cataldo
209
| 3 1 2
Respondido en 26-04-17 18:16
0
voto

Puede depender de la versión que estés usando, pero lo que veo es que quiere cortar el proceso con un raise UserError que no está encontrando.

Si es 8, chequear por favor si el archivo l10n_cl_dte_caf/models/caf.py contiene la siguiente linea de importación, caso contrario agregar o corregir:

from openerp.exceptions import Warning as UserError 

Si es 9:

from openerp.exceptions import UserError

 

Blanco Martín & Asociados Chile
Blanco Martín & Asociados
1737
| 5 2 5
Respondido en 24-04-17 5:09
0
voto

Su respuesta

Trate por favor de dar una respuesta sustancial. Si quiere comentar en la pregunta o la respuesta, sólo use la herramienta de comentarios. Recuerde que siempre puede revise sus respuestas - no hay necesidad de responder dos veces la misma pregunta. También no olvide votar - ¡ayuda realmente a seleccionar las mejores preguntas y respuestas!

Realizar una pregunta

Mantener informado

Sobre este foro 

Esta comunidad es para profesionales y entusiastas de nuestros productos y servicios.

Lea las directrices

Herramientas de las preguntas

54 seguidor(es)

Estadísticas

Preguntado: 21-04-17 7:29
Visto: 1641 veces
Última actualización: 26-04-17 18:16