Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

Odoo 7.0 on CentOS 6.5 fails to start with error: "result = {v['id']: v[name] for v in values}"

By
David Dean
on 6/16/14, 5:46 PM 960 views

Hi all,

I've installed the latest 7.0 version of Odoo from github on CentOS 6.5. All the dependencies listed in setup.py have been installed.

When I launch Odoo I see this Traceback:

Traceback (most recent call last):
  File "/usr/bin/odoo-server", line 2, in <module>
    import openerp
  File "/opt/odoo/openerp/__init__.py", line 39, in <module>
    import addons
  File "/opt/odoo/openerp/addons/__init__.py", line 38, in <module>
    from openerp.modules import get_module_resource, get_module_path
  File "/opt/odoo/openerp/modules/__init__.py", line 27, in <module>
    from . import db, graph, loading, migration, module, registry
  File "/opt/odoo/openerp/modules/graph.py", line 32, in <module>
    import openerp.osv as osv
  File "/opt/odoo/openerp/osv/__init__.py", line 22, in <module>
    import osv
  File "/opt/odoo/openerp/osv/osv.py", line 30, in <module>
    import orm
  File "/opt/odoo/openerp/osv/orm.py", line 62, in <module>
    import fields
  File "/opt/odoo/openerp/osv/fields.py", line 1149
    result = {v['id']: v[name] for v in values}
                                 ^
SyntaxError: invalid syntax

 

I've tried fiddling with the configuration options, re-installing and done lots of Googling but no joy.

Can someone give me a hint about what might be the root cause?

Thanks.

 

0

Ludo - Neobis

--Ludo - Neobis--
2387
| 2 2 5
Hoogvliet, Netherlands
--Ludo - Neobis--

Developer

Ludo - Neobis
On 6/17/14, 5:08 AM

I have had the same error. The cause is python in this case. You are prob. running python 2.6 on your server. The syntax as above is only available on python 2.7 and up. Update your python and/or use virtualenv to install them side by side. The advantage of side-by-side installation is that any other program on your server that requires python 2.6 explicitly does not break in the process.

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

1 follower(s)

Stats

Asked: 6/16/14, 5:46 PM
Seen: 960 times
Last updated: 3/16/15, 8:10 AM