OpenEmbedded repo initialization failure

I’m trying to customize the Open Embedded (core) Linux image 2.8 for the Colibri T30. I’m following this : OpenEmbedded (core) - Toradex System/Computer on Modules

I’m at the initial step, synching a local copy of the repository using “repo”. I did this about half a year ago and it worked fine. But now I’m having issues with repo. When I run the command “repo init … -b LinuxImageV2.8”, a .repo folder is created and several Python scripts downloaded. Then at some point it tries to run, and I get the error :

File “/home/x/Toradex/oe-core/.repo/repo/”, line 79
file=sys.stderr) < invalid syntax.

From searching I get that this is a Python 3 script being run in Python 2. Python 2 end-of-lifed last year, repo version 2.9 on September 6 2020 has : “A recent change broke repo version on Python 2.7. Rather than
fix it, lets drop Python 2.7 support so it can slowly rot.”

I tried aliasing python to python 3, but still got the error, meaning python 2 was still being used to run the repo scripts. I changed the link in /usr/bin temporarily to point to python 3 instead of python 2, and got warnings out of repo that python 3 support is experimental.

I’m doing this on Ubuntu & Lubuntu, it does the same thing on both. Does anyone know a workaround for this?

This appears to be resolved for me. I was using repo installed by the Ubuntu package manager, which I’m assuming was the most recent. The article I was following made it sound like getting repo via package manager would work, and I’m almost sure that’s what I did before. But I uninstalled it, then got the version at the URL in the curl installation ( That version is different, and works as advertised.

Glad you were able to resolve this. Yes some distros provide their own version of repo which may or may not work as you’ve seen.

I get a similar error following instructions in:

I’m doing this on Ubuntu 16.04 as specified in those instructions. this is my first time building with Toradex.

So is there a list somewhere to identify which build of repo to use for each version of Toradex?

Also there apparently was a solution for the python issue at the website, but it seems to be gone. the link was:
How to Install Python 3.6 on Ubuntu & LinuxMint - TecAdmin

Any help is greatly appreciated.