Skip to Content
Menu
This question has been flagged
2 Replies
5371 Views

I had tried to setup odoo11 using python3 (3.4) as intrepreter and grammar version as 3.0.

Am not able to run the server due to below error like "SyntaxError: invalid character in identifier"

Error Details :

2018-05-18 12:42:52,701 20669 ERROR ? werkzeug: Error on request:
Traceback (most recent call last):
  File "/usr/local/lib/python3.4/dist-packages/werkzeug/serving.py", line 270, in run_wsgi
    execute(self.server.app)
  File "/usr/local/lib/python3.4/dist-packages/werkzeug/serving.py", line 258, in execute
    application_iter = app(environ, start_response)
  File "/home/dev727/workspace/Ten10odoo11/odoo/service/server.py", line 251, in app
    return self.app(e, s)
  File "/home/dev727/workspace/Ten10odoo11/odoo/service/wsgi_server.py", line 166, in application
    return application_unproxied(environ, start_response)
  File "/home/dev727/workspace/Ten10odoo11/odoo/service/wsgi_server.py", line 154, in application_unproxied
    result = handler(environ, start_response)
  File "/home/dev727/workspace/Ten10odoo11/odoo/http.py", line 1297, in __call__
    self.load_addons()
  File "/home/dev727/workspace/Ten10odoo11/odoo/http.py", line 1313, in load_addons
    manifest = ast.literal_eval(pycompat.to_native(manifest_data))
  File "/usr/lib/python3.4/ast.py", line 46, in literal_eval
    node_or_string = parse(node_or_string, mode='eval')
  File "/usr/lib/python3.4/ast.py", line 35, in parse
    return compile(source, filename, mode, PyCF_ONLY_AST)
File "<unknown>", line 1
    # -*- coding: utf-8 -*-
    ^
SyntaxError: invalid character in identifier





Avatar
Discard
Author Best Answer

I had upgraded my python version to 3.5.5 but still below error occurs

 File "/home/dev727/workspace/odoo11-base/odoo-bin", line 5, in <module>
    import odoo
  File "/home/dev727/workspace/odoo11-base/odoo/__init__.py", line 84, in <module>
    from . import modules
  File "/home/dev727/workspace/odoo11-base/odoo/modules/__init__.py", line 8, in <module>
    from . import db, graph, loading, migration, module, registry
  File "/home/dev727/workspace/odoo11-base/odoo/modules/graph.py", line 10, in <module>
    import odoo.tools as tools
  File "/home/dev727/workspace/odoo11-base/odoo/tools/__init__.py", line 7, in <module>
    from . import pdf
  File "/home/dev727/workspace/odoo11-base/odoo/tools/pdf.py", line 4, in <module>
    from PyPDF2 import PdfFileWriter, PdfFileReader
ImportError: No module named 'PyPDF2'


When i tried to install PyPDF2 using below command

root@tpt727:/home/dev727# sudo pip3 install pypdf2
Requirement already satisfied: pypdf2 in /usr/local/lib/python3.4/dist-packages (1.26.0)
pydot 1.2.4 has requirement pyparsing>=2.1.4, but you'll have pyparsing 2.0.1 which is incompatible.
mock 2.0.0 has requirement six>=1.9, but you'll have six 1.5.2 which is incompatible.


Am using ubuntu 14.04 OS.



Avatar
Discard
Best Answer

Before you try anything else, please check the requirements for Odoo 11.0 and here you will see that Odoo 11.0 support Python 3.5: https://www.odoo.com/groups/community-59/community-32859400

Avatar
Discard
Related Posts Replies Views Activity
3
Mar 21
3712
3
Feb 21
5368
2
Aug 19
2839
0
Jul 19
1983
9
Jun 23
11127