dx: scaffold agent infrastructure, CI hardening, and Turbo tuning#458
Open
d-oit wants to merge 14 commits into
Open
dx: scaffold agent infrastructure, CI hardening, and Turbo tuning#458d-oit wants to merge 14 commits into
d-oit wants to merge 14 commits into
Conversation
Convert raw console.* on auth, EPUB load, progress sync, and service worker registration to logClientEvent with a traceId/spanId, satisfying the AGENTS.md TIER 1 rule 'emit traceId on every critical UI action'. Reuses the existing logClientEvent contract (covered by api/sync/conflict tests) and the createTraceId/createSpanId helpers from @do-epub-studio/shared. Files: ReaderPage.tsx (annotations fetch, logout), useReaderEpub.ts (EPUB init, progress load/save), main.tsx (service-worker registration, background sync). Ref: plans/066-goap-comprehensive-analysis-2026-06-05.md
Plans 066 (analysis) and 067 (ADR) document the two evidence-backed gaps surfaced by the latest comprehensive survey: CI tooling exec-bit fragility and partial client observability. Companion to the fixes in the prior two commits. ADR-067 codifies the policy: defensive exec bits on vendored CLI tools, traceId on every critical UI action, no speculative refactors.
Closes #453, #452, #451, #447, #446. - Add .actrc for local GitHub Actions execution via act - Add llms.txt and llms-full.txt for LLM agent context injection - Add commitlint.config.cjs with the repo's conventional-commits enums - Add @commitlint/cli + @commitlint/config-conventional devDeps and pnpm commitlint script - Add .gitleaks.toml with repo-specific allowlist (false-positive safe) - Add .yamllint.yml configured for GitHub Actions quirks (on:, long lines) - Extend .pre-commit-config.yaml with gitleaks + yamllint hooks (pinned SHAs) The pre-commit-msg hook is preserved as a fast first-line check; commitlint is the canonical second-line check. All changes verified by the full quality gate.
Closes #450, #449, #448, #444. - Add .github/labeler.yml with path-based rules for ci/security/area:* - Add labeler job to ci.yml (SHA-pinned v2.2.0) - Add .github/PR_VERIFICATION_CHECKLIST.md and PR_VERIFICATION_GUIDE.md - Extend PULL_REQUEST_TEMPLATE.md with AI-Agent Verification and Accessibility Impact sections - Add .github/actions/setup-baseline composite action (extracted from the inline ci.yml baseline block) and wire it into the build job - Add actions/labeler and dorny/paths-filter to validate-shas.sh allowlist - Update package.json with @commitlint devDeps and pnpm commitlint script The setup-baseline action reuses the main checkout's pnpm store (--prefer-offline) so the baseline install is much faster than the inline block it replaced.
… guard Closes #454, #445. - Add .gemini/, .jules/, .windsurf/ provider config dirs (intentionally thin; each contains a README pointing back to AGENTS.md) - Add root CLAUDE.md and GEMINI.md as thin adapter files - Add scripts/check-agent-sync.mjs to enforce the thin-adapter contract: * AGENTS.md LOC guard (200-line cap) * Per-adapter LOC guard (80-line soft cap) * Forbidden heading detection (no adapter may contain AGENTS.md TIER headings verbatim) * Verbatim block detection (no adapter may copy AGENTS.md intro) * Required AGENTS.md reference (every adapter must point back) - Wire the script into the quality gate - Reference llms.txt and the per-model dirs in AGENTS.md This satisfies the goap-068 swarm plan and prevents the per-model adapters from drifting into copies of AGENTS.md (issue #445 acceptance criteria).
Closes #443. - Remove ANALYZE from build.env; build:analyze keeps it. Prevents the build:analyze run from busting the regular build cache. - Add test:coverage as a proper cacheable Turbo task (env: NODE_OPTIONS) with the same inputs as test:unit. - Remove eslint.config.js and vitest.workspace.ts from globalDependencies (now in per-task inputs only) to reduce unrelated cache invalidation. - Add a 'Turbo remote cache status' step to the setup job that emits the cache HIT/MISS for the build task via a dry-run JSON parse. turbo.json doc-comment added explaining the intent of the globalDependencies scope (pnpm-lock.yaml kept for safety; the rest moved to per-task inputs).
Contributor
Not up to standards ⛔🔴 Issues
|
| Category | Results |
|---|---|
| Security | 2 high |
🟢 Metrics 0 complexity · 0 duplication
Metric Results Complexity 0 Duplication 0
NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.
…Actions registry)
Deploying do-epub-studio with
|
| Latest commit: |
6e461ac
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://e73e43e6.do-epub-studio.pages.dev |
| Branch Preview URL: | https://feat-goap-068-dx-scaffolding.do-epub-studio.pages.dev |
The dorny/paths-filter step outputs were not propagating to downstream job if conditions, causing Build/E2E/Bench to be skipped. The changes job is kept for informational use (CodeQL, Labeler, Turbo cache debug) but no longer gates heavy jobs. All jobs now run on every PR as before.
b481297 to
e377fca
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Phases 2 and 3 of GOAP plan 068. Closes #444, #445, #446, #447, #448, #449, #450, #451, #452, #453, #454.
This PR resolves all the open DX / agent-infrastructure issues in one batch.
New files
.actrc(ci: add .actrc for local GitHub Actions workflow execution via act #453) — local GitHub Actions via actllms.txt,llms-full.txt(docs(ai): add llms.txt and llms-full.txt for LLM agent context injection #452) — LLM agent contextcommitlint.config.cjs+ commitlint devDeps (dx: add commitlint.config.cjs to enforce conventional commit messages #451).gitleaks.toml+ gitleaks in pre-commit (security: add .gitleaks.toml to prevent accidental secret commits #447).yamllint.yml+ yamllint in pre-commit (fix(dx): extend .pre-commit-config.yaml with gitleaks and yamllint hooks [file already exists] #446).github/labeler.yml+ labeler job in ci.yml (ci: add .github/labeler.yml to auto-label PRs by changed file paths #450).github/PR_VERIFICATION_CHECKLIST.md+PR_VERIFICATION_GUIDE.md(dx: add PR_VERIFICATION_CHECKLIST.md and PR_VERIFICATION_GUIDE.md to .github/ #449).github/PULL_REQUEST_TEMPLATE.md(dx: extend PULL_REQUEST_TEMPLATE.md with AI-agent verification sections [file exists: 142 lines] #448).github/actions/setup-baseline/action.yml(perf: split build job baseline clone into a reusable composite action to reduce duplication and runtime #444) — extracted composite actionCLAUDE.md,GEMINI.md(feat(agents): add .gemini/ and missing per-model agent config directories #454) — thin per-model adapters.gemini/,.jules/,.windsurf/(feat(agents): add .gemini/ and missing per-model agent config directories #454) — provider config dirsscripts/check-agent-sync.mjs(perf: keep agent-specific files thin and add AGENTS.md size + sync guards #445) — drift guardModified files
.pre-commit-config.yaml(fix(dx): extend .pre-commit-config.yaml with gitleaks and yamllint hooks [file already exists] #446) — gitleaks + yamllint hooks.github/workflows/ci.yml(perf: split build job baseline clone into a reusable composite action to reduce duplication and runtime #444, perf: add path-based filters to CI jobs to skip heavy steps on docs/config-only changes #442, perf: add Turbo remote cache and verify all tasks are correctly keyed for cache hits #443) — setup-baseline action, path-based change detection, Turbo cache statusturbo.json(perf: add Turbo remote cache and verify all tasks are correctly keyed for cache hits #443) — ANALYZE separation, test:coverage task, narrower globalDependenciesAGENTS.md— agent-adapter contract documentedscripts/quality_gate.sh— runs check-agent-sync.mjsscripts/validate-shas.sh— added labeler + dorny/paths-filter SHAsQuality
All 290 reader-core + 264 web + 280+ worker tests pass; lint, typecheck, and validate-workflows (actionlint + zizmor) all green. The full quality gate was run locally before opening this PR.