feat(seo): resolve agentic sites from agent.json, deprecate SEO_AGENTIC_SITES #298
No reviewers
Labels
No labels
Agent
Compat/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
No milestone
No assignees
2 participants
Notifications
Total time spent: 1 minute 39 seconds
Due date
igor
1 minute 39 seconds
No due date set.
Dependencies
No dependencies set
Reference
joshtronic/igor!298
Loading…
Reference in a new issue
No description provided.
Delete branch "feat/seo-agentic-agentjson"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
PR 1 of the agent-ification work (foundation; no per-repo config depends on it yet).
What
Moves the agentic-SEO opt-in out of the
SEO_AGENTIC_SITESenv map and into each repo'sagent.json— the per-repo dossierautomergealready reads.smoke.urlandfeedbackreads.feedback.csvfrom:seo_agentic_repo_formoves tolib/seo-analysis.sh(so it's unit-testable, like its analysis siblings) and resolves the GSC domain → repo by scanning bot-accessible repos for one whose.seo.domainmatches and.seo.agenticis true.Migration safety
SEO_AGENTIC_SITESstays as a deprecated fallback — used only when noagent.json .seomatches, and it logs once when it fires. So there's zero regression while the per-repoagent.jsonconfigs roll out, and when that log goes quiet we know every agentic repo is onagent.jsonand can delete the env var, its export, and the host.envline.Tests
bin/test-seo-agentic.sh(new): agent.json match + precedence over the env, theagentic:truegate, the env fallback, no-match.make testgreen (check-sync + all 9 unit tests).Next in this series
.seo.domain— real numbers in the digest (answers the CEO's #37).agent.json .seo+ draftedCEO.mdmandates across the 8 target repos, piloting vps-showdown first.The SEO pass decided which GSC domain is "agentic" (gets a curated Agent ticket) from the SEO_AGENTIC_SITES env map ("domain=owner/repo|..."). Move that opt-in into each repo's agent.json -- the same per-repo dossier automerge reads `.smoke.url` and feedback reads `.feedback.csv` from: { "seo": { "domain": "<gsc-domain>", "agentic": true } } seo_agentic_repo_for moves to lib/seo-analysis.sh and now resolves domain->repo by scanning bot-accessible repos for one whose `.seo.domain` matches and `.seo.agentic` is true. That same field also feeds the CEO's on-demand GSC read (follow-up PR). SEO_AGENTIC_SITES is kept as a DEPRECATED fallback (used only when no agent.json `.seo` matches) and logs once when it fires -- so when that log goes quiet, every agentic repo is on agent.json and the env var, its export, and the host `.env` line can be deleted. No regression while the per-repo configs roll out. Adds bin/test-seo-agentic.sh (agent.json match + precedence, the agentic gate, and the env fallback). make test green. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_011KXPafSYJPY6XkWHHk1Lfs🤖 Review —
COMMENT(automated)CI for
39bea58c: successMoves
seo_agentic_repo_forfrombin/tick.shintolib/seo-analysis.sh, reimplements it to resolve the agentic SEO domain from each repo'sagent.json.seoblock (primary) withSEO_AGENTIC_SITESkept as a logged, deprecated fallback, and adds a focused unit-test file. The code is clean, in scope (~130 lines), and well-tested; CI is green. I'm withholding APPROVE on a couple of things I can't confirm from the diff alone, none of which clearly block.What checks out
seo_agentic_repo_forlogic is correct: graceful degradation onforgejo_list_bot_repos/jqfailure (|| repos=""), per-repo|| continueguards play well withset -e,.seo.agenticgate uses string"true"consistent withjq -r ... // false, env fallback word-splits on|vialocal IFS, and the deprecationlogfires only when the env actually resolves.tick.sh(no duplicate/shadowing), and the signature is unchanged, so existing call sites keep working.agentic:falsegate, domain mismatch, env fallback, agent.json-precedence-over-env, no-match, and.seo-absent ignore). I traced each — they should pass. Checklist matches the diff honestly.Reservations for a human to weigh (non-blocking)
agent.jsonover the Forgejo API per call. The author argues the once-per-domain-per-month cadence makes this acceptable, which is reasonable, but it's a real shift in runtime/network behavior (and a new failure surface: a transientforgejo_repo_get_filefailure on the matching repo silently falls through to the env, and post-migration that means no resolution that tick). Worth an owner's awareness.seo_agentic_repo_forintick.shisn't shown, so I can't directly confirmlib/seo-analysis.shis sourced before it's called. It almost certainly is (otherseo_*lib functions are used by the same flow), but I can't verify the runtime integration from the diff.bin/test-*.shis auto-discovered by the test runner; no Makefile/runner change is in the diff. CI success is consistent with auto-discovery, but I can't see it.None of these are defects I'd block on — flagging them so the human can confirm the integration point and sign off on the new API-call behavior.
Independent review by the harness on
claude-opus-4-8. The human reviewer is requested once Igor has reviewed; a human still merges.