Skip to content

Commit 56d6aeb

Browse files
committed
Add script to close identified AI slop issues and PRs
Closes 8 items: automated spam (#775), contribution farming (#780), incorrect Sentry bot fixes (#728, #724, #737, #722), unused-dep PR (#720), and over-engineered scroll listener (#735). Each with a polite explanatory comment. https://claude.ai/code/session_012aRt7qrUbktsyuz85BwXJz
1 parent 43fa62c commit 56d6aeb

File tree

1 file changed

+99
-0
lines changed

1 file changed

+99
-0
lines changed

close-slop.sh

Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,99 @@
1+
#!/usr/bin/env bash
2+
# Close identified AI slop issues and PRs on tanstack/tanstack.com
3+
# Run with: bash close-slop.sh
4+
# Requires: gh CLI authenticated with repo scope
5+
6+
set -euo pipefail
7+
REPO="tanstack/tanstack.com"
8+
9+
echo "=== Closing AI slop on $REPO ==="
10+
11+
# ─────────────────────────────────────────────
12+
# ISSUE #775 — Automated spam (AccessScore promo)
13+
# ─────────────────────────────────────────────
14+
echo "Closing issue #775..."
15+
gh issue close 775 -R "$REPO" -c "$(cat <<'EOF'
16+
Closing this issue. This was filed as part of an automated campaign that mass-opened identical templated issues across 20+ major open-source repos (React, Vercel, Bun, Deno, Vite, etc.) on the same day to promote a paid accessibility scanning tool. The account's own public repo describes this as a "GitHub outreach sprint" for product promotion.
17+
18+
We take accessibility seriously, but this isn't a good-faith contribution — it's marketing spam. If anyone wants to open a genuine accessibility issue with specific findings (which elements, which pages, reproduction steps), we'd welcome that.
19+
EOF
20+
)"
21+
22+
# ─────────────────────────────────────────────
23+
# PR #780 — Contribution farming (trivial 2-line change)
24+
# ─────────────────────────────────────────────
25+
echo "Closing PR #780..."
26+
gh pr close 780 -R "$REPO" -c "$(cat <<'EOF'
27+
Thanks for the contribution, but closing this. The change (wrapping text in a `<code>` tag and adding two Tailwind color classes) is cosmetic and not something we need — the existing rendering is fine.
28+
29+
We appreciate the effort, but the elaborate PR description with verification checklists is disproportionate to a 2-line formatting tweak and suggests this may have been AI-generated without much human review. We'd rather see contributions that address real issues.
30+
EOF
31+
)"
32+
33+
# ─────────────────────────────────────────────
34+
# PR #728 — Sentry bot: wrong fix (GET → POST)
35+
# ─────────────────────────────────────────────
36+
echo "Closing PR #728..."
37+
gh pr close 728 -R "$REPO" -c "$(cat <<'EOF'
38+
Closing this. Changing these server functions from GET to POST doesn't address the reported error (missing `serverFnErrorMiddleware`) and is semantically incorrect — these are read-only data-fetching functions that should remain GET for cacheability.
39+
EOF
40+
)"
41+
42+
# ─────────────────────────────────────────────
43+
# PR #724 — Sentry bot: wrong fix location
44+
# ─────────────────────────────────────────────
45+
echo "Closing PR #724..."
46+
gh pr close 724 -R "$REPO" -c "$(cat <<'EOF'
47+
Closing this. The null-safety checks are added inside the IntersectionObserver callback, but the reported crash (`ownerDocument` on null) occurs when the observer is constructed or begins observing a null element — before the callback is ever invoked. These guards don't prevent the actual error.
48+
EOF
49+
)"
50+
51+
# ─────────────────────────────────────────────
52+
# PR #737 — Sentry bot: sledgehammer tooltip disable
53+
# ─────────────────────────────────────────────
54+
echo "Closing PR #737..."
55+
gh pr close 737 -R "$REPO" -c "$(cat <<'EOF'
56+
Closing this. Disabling tooltips entirely on touch devices is too broad a workaround — it hides the bug rather than fixing it, and `navigator.maxTouchPoints > 0` false-positives on laptops with touchscreens. The underlying null container issue should be fixed directly instead.
57+
EOF
58+
)"
59+
60+
# ─────────────────────────────────────────────
61+
# PR #722 — Sentry bot: over-engineered SSR fix
62+
# ─────────────────────────────────────────────
63+
echo "Closing PR #722..."
64+
gh pr close 722 -R "$REPO" -c "$(cat <<'EOF'
65+
Closing this. The direction (gate portal rendering until mounted) is right, but the implementation has unnecessary complexity — `typeof window` check inside `useEffect` is redundant (effects only run in the browser), the `portalRoot` ref adds no value over passing `document.body` directly, and the cleanup `setIsMounted(false)` is pointless during unmount. We'll address the underlying tooltip SSR issue separately with a cleaner approach.
66+
EOF
67+
)"
68+
69+
# ─────────────────────────────────────────────
70+
# PR #720 — Unused deps, fragile regex, unnecessary approach
71+
# ─────────────────────────────────────────────
72+
echo "Closing PR #720..."
73+
gh pr close 720 -R "$REPO" -c "$(cat <<'EOF'
74+
Thanks for identifying the Solid docs hook transformation issue — that's a real problem. However, closing this PR because:
75+
76+
1. The approach conflicts with the existing block-replacement mechanism (as Sean mentioned), which is the preferred way to handle framework-specific doc transforms.
77+
2. Six Babel dependencies are added to `package.json` but none are actually imported or used — the implementation uses regex instead.
78+
3. The regex (`[\s\S]*?` non-greedy) will break on nested braces, and the replacement strips code block language tags (breaking syntax highlighting).
79+
80+
If you'd like to contribute a fix using the block-replacement approach, we'd be happy to review that.
81+
EOF
82+
)"
83+
84+
# ─────────────────────────────────────────────
85+
# PR #735 — Over-engineered scroll listener
86+
# ─────────────────────────────────────────────
87+
echo "Closing PR #735..."
88+
gh pr close 735 -R "$REPO" -c "$(cat <<'EOF'
89+
Thanks for working on this. Closing because the approach has performance concerns — storing `scrollY` in React state triggers a re-render on every scroll event, and calling `getComputedStyle` + `getBoundingClientRect` on each render is expensive. This would be better solved with an `IntersectionObserver` or a CSS-only z-index fix. Happy to review a revised approach if you'd like to take another pass.
90+
EOF
91+
)"
92+
93+
echo ""
94+
echo "=== Done. Closed 8 items. ==="
95+
echo ""
96+
echo "Items left for manual review (not auto-closed):"
97+
echo " PR #731 — c15t consent banner (may be coordinated, needs maintainer decision)"
98+
echo " PR #747 — Sentry tooltip/dropdown fix (partially useful, needs cleanup)"
99+
echo " Issues #725, #726, #730 — yuvarajsai (valid bugs, just burst-filed)"

0 commit comments

Comments
 (0)