Skip to content

fix: wave 6 pre-launch bot fixes - #297

Merged
jamesconwaydev merged 11 commits into
mainfrom
fix-wave6-prelaunch
Nov 6, 2026
Merged

jamesconwaydev merged 11 commits into
mainfrom
fix-wave6-prelaunch

Conversation

@jamesconwaydev

Copy link
Copy Markdown
Collaborator

Pre-launch fixes for the bots. One commit per fix.

  • Blocked repos (DMCA 451, ToS 403). These used to abort the weekly health check. They're now handled like a 404: the repo gets the usual "no longer exists" notice, and a submission of one is rejected cleanly. An IP allow list is still undecided, and any other 403 still aborts. (quality.py blocked/get_repo)
  • repo_id mismatch. rot now looks up /repositories/{repo_id} first. If that repo still exists, it's re-checked by its new name, so the normal rename path runs and the Likes move with it. Only a 404 or a blocked repo keeps the "replaced" notice and review issue.
  • Repeat dispatch of a submission. When apply finds this same issue already on main, it prints done, and submit.yml skips the reject step, so the accepted issue no longer gets commented, labelled rejected and closed. decide also skips any issue that's already in entries.json. The sweeper now waits while a list-writes run is in_progress, and it doesn't dispatch a submission that's already listed but too new to finish.
  • Burst throughput. sweep.yml now also runs on workflow_run (Submit, Reports, completed), so the next item is dispatched as soon as one finishes. That only happens after a successful run on main, so a failing or rate-limited run can't loop. The job still checks out main and never reads the triggering run's head.
  • Report threshold. Only spam reports count toward an automatic hide. "Something else" reports still get the queued reply and go to needs-review.
  • Weekly submission limit. The current issue is now excluded from the search count, and the limit is >= 3, so search lag can't let a fourth submission through.
  • Archive cards. meta.json now has a card for every entry in entries.json, so archived and superseded entries show their stars again. That's about one extra GraphQL batch an hour.
  • Like thread text. New threads now say an account counts once only if it's at least 30 days old and has some public activity.

python3.12 -m unittest discover -s scripts -t .: 621 tests, OK.

A 451, or a 403 saying access is blocked or disabled, made check_repo
raise, which stopped the whole weekly health check. Both now read like a
404: rot posts the usual removal notice and submit rejects cleanly. An IP
allow list stays undecided and any other 403 still aborts.
A repo_id mismatch at the listed name went straight to removal, so an
owner who renamed their account lost the entry and its Likes if someone
took the old name. rot now looks up /repositories/{repo_id} and, when it
still exists, re-checks it by name so the usual rename path applies.
Only a 404 or blocked repo keeps the replaced notice and review issue.
COUNTED included "other", so three "Something else" reports could hide
an entry, which GOVERNANCE.md says only spam reports do. Those reports
still get the queued reply and needs-review label, as before.
The limit used total_count > 3, which only held if search had already
indexed the current issue. Count the author's other submissions instead,
as reports.py does, and reject at 3.
When a second run of the same issue found the repo already on main, apply
rewrote the result as a duplicate, and submit.yml commented, labelled
rejected and closed the accepted issue. apply now prints "done" for the
same issue and the reject step skips it; decide skips any issue already
in entries.json.

The sweeper now waits while a list-writes run is in progress, not only
queued or pending, and no longer dispatches a submission that is already
listed but too recent to finish.
The sweeper re-dispatches one item per run and ran every 15 minutes, so
100 dropped submissions took about a day. It now also runs when a Submit
or Reports run succeeds on main, so the next item goes out as soon as
list-writes is free. Failed runs don't chain, so a rate limit can't loop,
and the job still checks out main, never the triggering run's head.
meta.json only kept cards for ranked keys, so the Archive page showed a
dash for stars. Fetch meta for every entry in entries.json instead; it
costs about one extra GraphQL batch an hour and also restores the cards
already dropped.
New Like threads said "Every GitHub account counts once", but accounts
under 30 days old or with no public activity count zero. Say so.
The looser pattern also matched "repository has been disabled" wording,
and a false match would remove a live repo. A 403 now counts as blocked
only when its message is "Repository access blocked" or the body
carries a block object; a 451 still always does.
Hidden entries are off every page while a maintainer reviews them, so
they don't need a card or a slot in the GraphQL batches.
Say what the site says: an account counts once if it's at least 30 days
old with a public repo or a contribution in the last year. The line and
the old one live in COUNTS and COUNTS_OLD so existing threads can be
edited to match.
@jamesconwaydev
jamesconwaydev merged commit 3e46bc6 into main Nov 6, 2026
9 checks passed
@jamesconwaydev
jamesconwaydev deleted the fix-wave6-prelaunch branch November 6, 2026 20:33
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