Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pydevd-odoo does not work for Python 3.8 #3

Closed
joao-p-marques opened this issue Nov 10, 2020 · 5 comments
Closed

Pydevd-odoo does not work for Python 3.8 #3

joao-p-marques opened this issue Nov 10, 2020 · 5 comments

Comments

@joao-p-marques
Copy link

When I try to run pydevd-odoo in Python 3.8 along with debugpy, it introduces an error that prevents it from running

The error is the following:

root@631a7db35ba5:/# python -m debugpy -h
Traceback (most recent call last):
  File "/usr/local/lib/python3.8/runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/local/lib/python3.8/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/usr/local/lib/python3.8/site-packages/debugpy/__main__.py", line 43, in <module>
    from debugpy.server import cli
  File "/usr/local/lib/python3.8/site-packages/debugpy/server/__init__.py", line 9, in <module>
    import debugpy._vendored.force_pydevd  # noqa
  File "/usr/local/lib/python3.8/site-packages/debugpy/_vendored/force_pydevd.py", line 14, in <module>
    _unvendored, _ = check_modules('pydevd',
  File "/usr/local/lib/python3.8/site-packages/debugpy/_vendored/__init__.py", line 106, in check_modules
    elif not mod.__file__.startswith(root):
AttributeError: 'NoneType' object has no attribute 'startswith'

I associate this bug with pydev-odoo because:

image

cc @Tecnativa @yajo

joao-p-marques added a commit to Tecnativa/doodba that referenced this issue Nov 10, 2020
Introduces error in Python 3.8 (used in v14): odoo-ide/pydevd-odoo#3

Removing until issue is fixed
yajo pushed a commit to Tecnativa/doodba that referenced this issue Nov 10, 2020
Introduces error in Python 3.8 (used in v14): odoo-ide/pydevd-odoo#3

Removing until issue is fixed
@gdgellatly
Copy link

microsoft/debugpy#475 crosslink

@gdgellatly
Copy link

@joao-p-marques Please see fabioz/debugpy@792458b .

Seems it is not an issue with this module, but ratther pydevd.

@joao-p-marques
Copy link
Author

Thanks @gdgellatly. I will test if that fixes the issue.

My only question is why did installing pydevd-odoo trigger the issue? pydevd should already come from debugpy right? Does this have to do with some specific pydevd version that pydevd-odoo installs?

@gdgellatly
Copy link

@joao-p-marques No it is nothing like that. It is simply that you happened to install a pydevd extension. If it wasn't this module it would have been another. The error is in the extension loading mechanism of pydevd. Looking at the failing code it is quite obviously a pydevd issue and not to do with this module.

@gdgellatly
Copy link

@joao-p-marques I have checked and this issue was closed upstream by this commit microsoft/debugpy@ac05dab

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants