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

The tools scripts cannot find "git" when using Snap installed python38 #713

Open
reliveyy opened this issue Sep 4, 2020 · 0 comments
Open
Labels
bug Something isn't working for-developers P3 low priority

Comments

@reliveyy
Copy link
Collaborator

reliveyy commented Sep 4, 2020

tools/build xud results in

/bin/sh: 1: git: not found
/bin/sh: 1: git: not found
sh: 1: git: not found
Traceback (most recent call last):
  File "/home/native/xud-docker/tools/core/git.py", line 28, in get_master_commit_hash
    return execute("git rev-parse master").splitlines()[0]
  File "/home/native/xud-docker/tools/core/utils.py", line 5, in execute
    output = check_output(cmd, shell=True, stderr=STDOUT)
  File "/snap/python38/22/usr/lib/python3.8/subprocess.py", line 411, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
  File "/snap/python38/22/usr/lib/python3.8/subprocess.py", line 512, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command 'git rev-parse master' returned non-zero exit status 127.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "tools/helper.py", line 51, in <module>
    main()
  File "tools/helper.py", line 35, in main
    toolkit = Toolkit(project_dir, ["linux/amd64", "linux/arm64"])
  File "/home/native/xud-docker/tools/core/toolkit.py", line 98, in __init__
    self.git_template = GitTemplate(self.project_dir)
  File "/home/native/xud-docker/tools/core/git.py", line 49, in __init__
    self.git_info = self._create_git_info()
  File "/home/native/xud-docker/tools/core/git.py", line 73, in _create_git_info
    master = get_master_commit_hash()
  File "/home/native/xud-docker/tools/core/git.py", line 31, in get_master_commit_hash
    return execute("git ls-remote origin master").split()[0]
  File "/home/native/xud-docker/tools/core/utils.py", line 5, in execute
    output = check_output(cmd, shell=True, stderr=STDOUT)
  File "/snap/python38/22/usr/lib/python3.8/subprocess.py", line 411, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
  File "/snap/python38/22/usr/lib/python3.8/subprocess.py", line 512, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command 'git ls-remote origin master' returned non-zero exit status 127.
native@ubuntu:~/xud-docker$ git rev-parse master
4727c56b5ec23aea168f8c48fce7f5703b76b89e
native@ubuntu:~/xud-docker$ git ls-remote origin master
4727c56b5ec23aea168f8c48fce7f5703b76b89e	refs/heads/master
@kilrau kilrau added bug Something isn't working P3 low priority labels Oct 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working for-developers P3 low priority
Projects
None yet
Development

No branches or pull requests

2 participants