Hi all,
Our automation turned up the following error while running on a fairly stock Ubuntu 20.04 LTS host with Python 3.8.10.
info: A new version of repo is available
warning: repo is not tracking a remote branch, so it will not receive updates
info: Restarting repo with latest version
Traceback (most recent call last):
File ".../.repo/repo/main.py", line 47, in <module>
from subcmds.version import Version
File ".../.repo/repo/subcmds/__init__.py", line 33, in <module>
mod = __import__(__name__,
File ".../.repo/repo/subcmds/selfupdate.py", line 19, in <module>
from subcmds.sync import _PostRepoUpgrade
File ".../.repo/repo/subcmds/sync.py", line 92, in <module>
class _FetchResult(NamedTuple):
File .../.repo/repo/subcmds/sync.py", line 100, in _FetchResult
projects: set[str]
TypeError: 'type' object is not subscriptable
The following minimal patch works around the issue for me:
diff --git a/subcmds/sync.py b/subcmds/sync.py
index 5818b45..0780423 100644
--- a/subcmds/sync.py
+++ b/subcmds/sync.py
@@ -97,7 +97,7 @@ class _FetchResult(NamedTuple):
projects (set[str]): The names of the git directories of fetched projects.
"""
success: bool
- projects: set[str]
+ projects: set
class _FetchMainResult(NamedTuple):
@@ -106,7 +106,7 @@ class _FetchMainResult(NamedTuple):
Attributes:
all_projects (list[Project]): The fetched projects.
"""
- all_projects: list[Project]
+ all_projects: list
class _CheckoutOneResult(NamedTuple):