Unable to get the odoo connector to work

243 views
Skip to first unread message

Marc Cassuto

unread,
Nov 28, 2014, 9:28:06 PM11/28/14
to freppl...@googlegroups.com
Hello Dear community,

I tried to interconnect Odoo and frePPLe with the 3 methods :

* from frePPLe, I get the following errors in the Odoo's log :

    raise except_osv('Object Error', 'Object %s doesn\'t exist' % str(obj))
except_osv: ('Object Error', "Object hr.holidays.public.line doesn't exist")
 
 File "/home/mcassuto/Perso/Projets/CubePlastics/openerp/new-oe-sandy/git/frepple/contrib/odoo/addons_v7/frepple/controllers/outbound.py", line 574, in export_salesorders
    due = j['requested_date'] or j['date_order']
KeyError: 'requested_date'

• from Odoo , I get the following errors in the Odoo's log :
  File "/home/mcassuto/Perso/Projets/CubePlastics/openerp/new-oe-sandy/git/frepple/contrib/odoo/addons_v7/frepple/scheduler.py", line 24, in run_frepple
    shell=False
  File "/usr/lib/python2.7/subprocess.py", line 522, in call
    return Popen(*popenargs, **kwargs).wait()
  File "/usr/lib/python2.7/subprocess.py", line 710, in __init__
    errread, errwrite)
  File "/usr/lib/python2.7/subprocess.py", line 1327, in _execute_child
    raise child_exception
OSError: [Errno 2] No such file or directory

• with the CLI :
# frepplectl frepple_run --env=odoo_read,odoo_write -v 2
Traceback (most recent call last):
  File "/usr/bin/frepplectl", line 29, in <module>
    execute_from_command_line(sys.argv)
  File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 365, in execute_from_command_line
    utility.execute()
  File "/usr/local/lib/python2.7/dist-packages/django/core/management/__init__.py", line 358, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 242, in run_from_argv
    self.execute(*args, **options.__dict__)
  File "/usr/local/lib/python2.7/dist-packages/django/core/management/base.py", line 285, in execute
    output = self.handle(*args, **options)
  File "/usr/lib/python2.7/dist-packages/freppledb/execute/management/commands/frepple_run.py", line 169, in handle
    raise e
Exception: Failed with exit code 1

Can someone help ?

Regards,
Marc

Marc Cassuto

unread,
Nov 28, 2014, 9:58:26 PM11/28/14
to freppl...@googlegroups.com
Auto-answer :

I needed to add the module 'sales_order_date' in Odoo (this means the 'frepple' module in Odoo should have this one as dependencie)


so this allowed the connector to go a step further... I know have the following error (this time in the frePPLe logs) :


Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/lib/python2.7/dist-packages/freppledb/odoo/commands.py", line 239, in <module>
    odoo_read(db)
  File "/usr/lib/python2.7/dist-packages/freppledb/odoo/commands.py", line 85, in odoo_read
    frepple.readXMLdata(f.read(), False, False)
frepple.RuntimeException: Error during XML parsing: Operation 'my product name @ my location' doesn't exist
Error: Error executing Python command

Johan De Taeye

unread,
Nov 29, 2014, 10:25:12 AM11/29/14
to freppl...@googlegroups.com

Marc,

 

>>I needed to add the module 'sales_order_date' in Odoo (this means the 'frepple' module in Odoo should have this one as dependencie)

Right.
It was in in the documented dependencies, but not included of the __openerp__.py. Corrected that mistake now…

 

>>Traceback (most recent call last):
>>  File "<string>", line 1, in <module>
>>  File "/usr/lib/python2.7/dist-packages/freppledb/odoo/commands.py", line 239, in <module>
>>    odoo_read(db)
>>  File "/usr/lib/python2.7/dist-packages/freppledb/odoo/commands.py", line 85, in odoo_read
>>    frepple.readXMLdata(f.read(), False, False)
>>frepple.RuntimeException: Error during XML parsing: Operation 'my product name @ my location' doesn't exist
>>Error: Error executing Python command

 

This indicates something in your odoo data isn’t expected as by the connector. I can’t tell from the error message what exactly.

I’ld need to see the part of the XML data that refers to 'my product name @ my location' to understand where it goes wrong…

 

Regards,

 

Johan

Johan De Taeye
+32 477.385.362
Skype jdetaeye

Visit us http://frepple.com
Woluwestraat 17, 1930 Zaventem, Belgium

frepple-logo

--
You received this message because you are subscribed to the Google Groups "frePPLe users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to frepple-user...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Marc Cassuto

unread,
Nov 29, 2014, 10:41:13 AM11/29/14
to freppl...@googlegroups.com
Hi Johan,

thanks for the answer !

Is there a specific reason to  have this module as dependency since it is not a module installed by default
even if you install sales and mrp ?

Which XML file should I look at or send you  ?

Regards,
Marc
You received this message because you are subscribed to a topic in the Google Groups "frePPLe users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/frepple-users/T3pD7nZdoPw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to frepple-user...@googlegroups.com.

Marc Cassuto

unread,
Nov 29, 2014, 11:27:43 AM11/29/14
to freppl...@googlegroups.com
auto-answer :
I added this little code to the file /usr/lib/python2.7/dist-packages/freppledb/odoo/commands.py:

  with open('/tmp/odoo.xml', 'w') as ofile:
    ofile.write(f.read())
  ofile.close()

Just before the following line.
  frepple.readXMLdata(f.read(), False, False)

I have just sent you the xml file off-list to not disclose our data.


Regards,
Marc

On 14-11-29 10:25 AM, Johan De Taeye wrote:
You received this message because you are subscribed to a topic in the Google Groups "frePPLe users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/frepple-users/T3pD7nZdoPw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to frepple-user...@googlegroups.com.

Johan De Taeye

unread,
Dec 2, 2014, 1:31:49 PM12/2/14
to freppl...@googlegroups.com

>>Is there a specific reason to  have this module as dependency since it is not a module installed by default
>>even if you install sales and mrp ?

This module adds a field requested_date on the sales order, which is read as the due date of the order in frePPLe.

If the field is left empty the connector uses the standard field “date_order” as the due date.


>>Which XML file should I look at or send you  ?

 

Connecting to this URL on the odoo server gives the XML data which frePPLe is processing:

      http://<host>:<port>/frepple/xml?database=<db>&language=<language>&company=<yourcompany>

Marc Cassuto

unread,
Dec 2, 2014, 3:48:20 PM12/2/14
to freppl...@googlegroups.com
Hello Johan,

my answers inline...


On 14-11-29 11:01 AM, Johan De Taeye wrote:

>>Is there a specific reason to  have this module as dependency since it is not a module installed by default
>>even if you install sales and mrp ?

This module adds a field requested_date on the sales order, which is read as the due date of the order in frePPLe.

If the field is left empty the connector uses the standard field “date_order” as the due date.

I know what does this module, I am asking why do you force odoo users to to install this module.
If by default frepple use the date_order field, why do you add this module ?


>>Which XML file should I look at or send you  ?

 

Connecting to this URL on the odoo server gives the XML data which frePPLe is processing:

      http://<host>:<port>/frepple/xml?database=<db>&language=<language>&company=<yourcompany>

I already sent you the file ;-)

we will skype tomorrow.

Regards,
Marc
Reply all
Reply to author
Forward
0 new messages