Skip to content
Snippets Groups Projects
Commit 11ef9fa6 authored by Florent Aide's avatar Florent Aide
Browse files

Now gives an example error message returning from server

parent 808cbbd7
No related branches found
No related tags found
No related merge requests found
......@@ -45,7 +45,7 @@
Launch the oec program::
oec -c oec.conf -i example/crmleads_create.json -t crm.lead -m create
$ oec -c oec.conf -i example/crmleads_create.json -t crm.lead -m create
Oec can also consume data from STDIN instead of a filename::
......@@ -49,7 +49,7 @@
Oec can also consume data from STDIN instead of a filename::
cat example/crmleads_create.json | oec -c oec.conf -t crm.lead -m create
$ cat example/crmleads_create.json | oec -c oec.conf -t crm.lead -m create
For more information about the command line arguments run::
......@@ -53,6 +53,6 @@
For more information about the command line arguments run::
oec --help
$ oec --help
If an error occurs on the OpenERP server, the error message will be printed on
......@@ -57,3 +57,19 @@
If an error occurs on the OpenERP server, the error message will be printed on
the STDOUT alongside the original data item sent for easy debugging.
the STDOUT alongside the original data item sent for easy debugging::
$ oec -i example/crmleads_error_create.json -c ./oec.conf -t crm.lead -m create
***********************************
OpenERP Error message:
warning -- Integrity Error
The operation cannot be completed, probably due to the following:
- deletion: you may be trying to delete a record while other records still reference it
- creation/update: a mandatory field is not correctly set
[object with reference: name - name]
-----------------------------------
{'street': u'10 Downing street'}
***********************************
Import done in 0:00:00.255700
Average time per item: 0:00:00.127850
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment