Skip to content

Commit cca2a11

Browse files
committed
srcinfo_cache: error if printsrcinfo doesn't give a result
arm64 is flaky since a few days, and this is one side effect
1 parent d6939b7 commit cca2a11

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

msys2_devtools/srcinfo_cache.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,18 +102,22 @@ def get_srcinfo_for_pkgbuild(msys2_root: str, args: Tuple[str, str]) -> Optional
102102
for name in get_mingw_arch_list(msys2_root, git_cwd, git_path):
103103
env = os.environ.copy()
104104
env["MINGW_ARCH"] = name
105-
srcinfos[name] = check_output_msys(
105+
srcinfo = check_output_msys(
106106
msys2_root,
107107
["/usr/bin/makepkg-mingw",
108108
"--printsrcinfo", "-p", git_path],
109109
cwd=git_cwd,
110110
env=env).decode("utf-8")
111+
assert srcinfo
112+
srcinfos[name] = srcinfo
111113
else:
112-
srcinfos["msys"] = check_output_msys(
114+
srcinfo = check_output_msys(
113115
msys2_root,
114116
["/usr/bin/makepkg",
115117
"--printsrcinfo", "-p", git_path],
116118
cwd=git_cwd).decode("utf-8")
119+
assert srcinfo
120+
srcinfos["msys"] = srcinfo
117121

118122
repo = subprocess.check_output(
119123
["git", "ls-remote", "--get-url", "origin"],

0 commit comments

Comments
 (0)