Answer architecture round 3: 0 🔴, 1 🟡; give each left-out case its own test, and read the log from the default branch the checkout names

This commit is contained in:
2026-10-15 20:59:43 +02:00
parent c2a4757d56
commit 44d882f9e2
2 changed files with 18 additions and 9 deletions
+2 -2
View File
@@ -123,8 +123,8 @@ def code_of(found: Round, effects: Effects) -> Code | Failure:
if isinstance(default, Failure):
return default
default = default.strip().removeprefix("origin/")
log = git(effects, found.root, "log", "--format=%H %at", "refs/remotes/origin/HEAD")
main_line = git(effects, found.root, "log", "--first-parent", "--format=%H %at", "refs/remotes/origin/HEAD")
log = git(effects, found.root, "log", "--format=%H %at", f"refs/remotes/origin/{default}")
main_line = git(effects, found.root, "log", "--first-parent", "--format=%H %at", f"refs/remotes/origin/{default}")
if isinstance(log, Failure):
return log
if isinstance(main_line, Failure):