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

Git-Auto-Deploy doesn't work with python3 (at least on Ubuntu 19.10) #248

Open
gbonazzoli opened this issue Feb 29, 2020 · 3 comments
Open

Comments

@gbonazzoli
Copy link

On a vanilla python3 installation on Ubuntu 19.10 Git-Auto-Deploy doesn't work.

This is the error I got:

root@eoan:/opt/Git-Auto-Deploy# python3 -m gitautodeploy --config config.json
Traceback (most recent call last):
  File "/usr/lib/python3.7/runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "/usr/lib/python3.7/runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "/opt/Git-Auto-Deploy/gitautodeploy/__main__.py", line 14, in <module>
    main()
  File "/opt/Git-Auto-Deploy/gitautodeploy/gitautodeploy.py", line 676, in main
    init_config(config)
  File "/opt/Git-Auto-Deploy/gitautodeploy/cli/config.py", line 355, in init_config
    from ..models import Project
ValueError: attempted relative import beyond top-level package

It seems that there is a library that is too much recent for Git-Auto-Deploy. Unfortunally I'm very new to the python world and I'm not able to be proficent in troubleshooting. But if someone can guide me I can replicate some commands.

If the same command is issued after installing python2 (with apt install python2) it works.

root@eoan:/opt/Git-Auto-Deploy# python2 -m gitautodeploy --config config.json --allow-root-user
2020-02-29 06:38:06,248 [INFO ]  Cloning repository /root/repositories/Git-Auto-Deploy
2020-02-29 06:38:08,012 [ERROR]  Cloning into '/root/repositories/Git-Auto-Deploy'...

The environment is currently:

root@eoan:/opt/Git-Auto-Deploy# python3 --version
Python 3.7.5

root@eoan:/opt/Git-Auto-Deploy# python2 --version
Python 2.7.17

Ant chance to have it working with only python3 ?

@Guy293
Copy link

Guy293 commented Mar 2, 2020

Git auto-deploy only supports python2.
It doesn't really matter to you as an end-user.

@directrix1
Copy link

Yeah, unfortunately, it matters now that Python2 has been EOL'd, and distros start removing support.

@Letme
Copy link
Contributor

Letme commented Nov 16, 2022

I opened #264 so that it works with Python3

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

4 participants