Skip to content

fix(aur): do not fail a successful publish when AUR drops the connection#47

Merged
vietanhdev merged 1 commit into
mainfrom
fix/aur-push-verification
Jul 20, 2026
Merged

fix(aur): do not fail a successful publish when AUR drops the connection#47
vietanhdev merged 1 commit into
mainfrom
fix/aur-push-verification

Conversation

@vietanhdev

Copy link
Copy Markdown
Owner

The v0.2.0 AUR publish succeeded and the workflow reported failure:

[master (root-commit) 6785b0b] Update to 0.2.0
 * [new branch]      HEAD -> master        <- the push landed
Connection closed by 209.126.35.78 port 22 <- the verification step failed
fatal: Could not read from remote repository.

aur.archlinux.org/packages/thinkutils shows thinkutils 0.2.0-1. The package is live. What failed was the ls-remote check I added one commit earlier — AUR closes the SSH connection immediately after accepting a push, so the second connection was refused.

Why this direction matters

Reporting failure on a successful publish isn't the harmless version of this mistake. It invites a re-run, and re-running a publish is not always harmless.

Change

  • Retry ls-remote with backoff
  • If AUR still can't be reached: warn, naming the package page, rather than fail. git push already reported success, and an unreachable remote is not evidence the push didn't land.
  • A genuine mismatch — remote readable and disagreeing — still fails.

The general point

A verification step has to distinguish "this did not work" from "I could not tell". This one conflated them, and so produced a false negative on the very publish it was written to protect.

That's the mirror of the bug it was added for, three commits ago: git diff not seeing untracked files meant the workflow reported success having pushed nothing. Same workflow, opposite error, both from a check that couldn't tell the difference between an outcome and an absence of information.

The v0.2.0 AUR publish succeeded and the workflow reported failure:

  [master (root-commit) 6785b0b] Update to 0.2.0
   * [new branch]      HEAD -> master
  Connection closed by 209.126.35.78 port 22
  fatal: Could not read from remote repository.

The push landed -- aur.archlinux.org/packages/thinkutils shows
"thinkutils 0.2.0-1" -- and it was the verification step I added one
commit earlier that failed, because AUR closes the SSH connection
immediately after accepting a push.

Reporting failure on a successful publish is not the harmless direction
of this mistake. It invites a re-run, and re-running a publish is not
always harmless.

So: retry ls-remote with backoff, and if AUR still cannot be reached,
emit a warning naming the package page rather than failing -- git push
already reported success, and an unreachable remote is not evidence the
push did not land. A genuine mismatch, where the remote IS readable and
disagrees, still fails.

Verification steps need to distinguish "this did not work" from "I could
not tell". This one conflated them.
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 20, 2026

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Updated (UTC)
❌ Deployment failed
View logs
thinkutils c01c09b Jul 20 2026, 07:54 AM

@vietanhdev
vietanhdev merged commit bccf2c5 into main Jul 20, 2026
11 of 12 checks passed
@vietanhdev
vietanhdev deleted the fix/aur-push-verification branch July 20, 2026 08:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant