Skip to content

Add scripts/check_explainer_count.py, wire into build-explainers.yml - #363

Merged
yakew7 merged 4 commits into
yakew7:mainfrom
evanjain-dot:main
Sep 2, 2026
Merged

Add scripts/check_explainer_count.py, wire into build-explainers.yml#363
yakew7 merged 4 commits into
yakew7:mainfrom
evanjain-dot:main

Conversation

@evanjain-dot

Copy link
Copy Markdown
Contributor

Nothing cross-checked the plain-prose "N explainers" mentions scattered
across README.md, CONTRIBUTORS.md, METRICS.md, and ROADMAP.md against
the real count of explainers/*.md, so this class of drift could recur
silently. Uses a small, explicit list of exact regexes rather than a
fuzzy scan - METRICS.md's weekly log is full of legitimate historical
counts that a loose "N explainers" match would false-positive on.

Also fixes the drift the check immediately caught: CONTRIBUTORS.md's
maintainer bio still said "the bulk of the 39 explainers" against a
real count of 53.

Fixes #352

@vercel

vercel Bot commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

@evanjain-dot is attempting to deploy a commit to the yashkewlani2020-gmailcom's projects Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions

github-actions Bot commented Sep 2, 2026

Copy link
Copy Markdown

@yakew7 @ahmdkaml @Shreyash0712 - new PR touching a path you own, please review.

@ahmdkaml

ahmdkaml commented Sep 2, 2026

Copy link
Copy Markdown
Collaborator

I can't find any issue

@Shreyash0712

Copy link
Copy Markdown
Collaborator

2 things -

Bug - I don't think you've taken the traction table in readme into account. Add that as well.

Improvement - can we automate it? Like if there is drift or mismatch - why not let the script automatically fix it instead of just raising an error? In fact I think we should leave it entirely on script only - why should a contributor need to manually make changes in readme and all those files?

@yakew7 your thoughts?

@yakew7

yakew7 commented Sep 2, 2026

Copy link
Copy Markdown
Owner

Nice fix, but I don't think this accounts for README.md's own Traction table.

README.md:1169 has a separate "Explainers Published" row:

| Explainers Published | 47 |

which is a second, independent "current explainer count" claim in this same file - distinct from the "Show all 53 explainers" summary this PR's CHECKS list covers (README.md:778). It's currently stale too (47 vs the real count of 53), and check_explainer_count.py as written won't catch it going forward since its README regex only targets the "Show all N explainers" string.

Can you add a CHECKS entry for r"Explainers Published \| (\d+)" (or similar) and fix the current 47 -> 53 drift in the same table row?

@yakew7

yakew7 commented Sep 2, 2026

Copy link
Copy Markdown
Owner

Okay! The bug seems to be fixed and since the improvement is out of scope of this issue i will just add it myself to either this branch or main directly

@Shreyash0712

Copy link
Copy Markdown
Collaborator

That's just static fix @evanjain-dot . You're working on script changes right?

@yakew7
yakew7 merged commit 48074da into yakew7:main Sep 2, 2026
17 of 18 checks passed
@yakew7

yakew7 commented Sep 2, 2026

Copy link
Copy Markdown
Owner

@Shreyash0712 heads up - I pushed a follow-up directly to main (aead1aa) after this merged, since it's small and I wanted to close the gap I'd flagged above right away: check_explainer_count.py now also covers the Traction table's "Explainers Published" row (was still stale at 47), and it gained a --fix mode (make fix-explainer-count) so a contributor doesn't have to hand-edit README/CONTRIBUTORS/METRICS/ROADMAP whenever the explainer count changes - CI still just checks, since a fork PR's token can't push a fix back anyway.

If you spot any problem with it, either open an issue and I'll take it, or just open a PR fixing whatever you want directly.

yakew7 added a commit that referenced this pull request Sep 2, 2026
Credits PR #361 (evanjain-dot, closes #342 - llms.txt missing 6 explainers),
PR #362 (propcgamer20-png, closes #343 - check_em_dash.py .yml scan gap),
and PR #363 plus its same-day follow-up (evanjain-dot + maintainer, closes
#352 - explainer-count drift check and --fix mode).
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.

No automated check keeps the explainer count in sync across README.md, CONTRIBUTORS.md, METRICS.md, and ROADMAP.md

4 participants