0

I am trying to run repo init and repo sync commands and having trouble with them as detailed below:

repo init -u <git-url> -b release -m <manifest-xml> --repo-url=<url> --repo-branch=<branch>

I was getting the following error

gpg: Can't check signature: No public key
fatal: cloning the git-repo repository failed, will remove '.repo/repo'

but then I followed these steps and was able to get it to work but then repo sync fails now

repo sync

warning: Python 3 support is currently experimental. YMMV.
Please use Python 2.6 - 2.7 instead.
Traceback (most recent call last):
  File "/home/tmp/.repo/repo/main.py", line 500, in <module>
    _Main(sys.argv[1:])
  File "/home/tmp/.repo/repo/main.py", line 476, in _Main
    result = repo._Run(argv) or 0
  File "/home/tmp/.repo/repo/main.py", line 155, in _Run
    result = cmd.Execute(copts, cargs)
  File "/home//tmp/.repo/repo/subcmds/sync.py", line 624, in Execute
    submodules_ok=opt.fetch_submodules)
  File "/home/tmp/.repo/repo/command.py", line 148, in GetProjects
    all_projects_list.extend(derived_projects.values())
AttributeError: 'dict_values' object has no attribute 'extend'

Is it implying I need to use python 2 now? I thought repo version 1.22 would require python 3.6+

Is this a safe solution?

I even tried this solution to no avail

Jazzy
  • 324
  • 4
  • 15
  • Did you read the warning? `warning: Python 3 support is currently experimental. YMMV.` – user2357112 Dec 11 '20 at 00:50
  • Yes, but `python -V` is 2.7.12 – Jazzy Dec 11 '20 at 00:53
  • While `python -V` may report 2.7.12, the version of python that `repo` is getting is 3.something. You might want to figure out why that is the case and fix that first. (It seems odd that the virtualenv trick did not work - that's how I normally deal with these Python version issues myself, and it works fine for me in multiple OSes.) – torek Dec 11 '20 at 07:27
  • it's weird because I had to upgrade to python 3.6 for the initial `repo init` command to work, and now `repo sync` seemingly requires python 2.x – Jazzy Dec 11 '20 at 18:23

1 Answers1

0

I have run into the same repo sync issue. However, for my case the scenario was quite specific, since I have already had the source tree checked out initially and then just wanted to make sure that it is up to date by running repo sync. It seems the problem for my case was the repo tool upgrade that I performed in between the initial and problematic repo sync. There seems to be some incompatibility that blocked me from updating the already checked out tree. Fortunately, initializing new source tree and repo sync-ing it from scratch worked fine.

gf11
  • 1