Skip to content

docs(auth): describe pesu-auth 5.x in the agent docs, skills and roles - #7

Merged
aditeyabaral merged 3 commits into
pesu-dev:mainfrom
aditeyabaral:docs/auth-5x
Oct 24, 2026
Merged

aditeyabaral merged 3 commits into
pesu-dev:mainfrom
aditeyabaral:docs/auth-5x

Conversation

@aditeyabaral

Copy link
Copy Markdown
Member

The auth/ material still described pesu-auth 4.x. Since then, 5.0.0 (pesu-dev/auth#241) moved to the API PESU Academy's mobile app uses, and later releases reworked CI, testing and the docs. Agents reading it were told about:

  • a CSRF prefetch cache and lock, and HTML selectors
  • one PESU session per account
  • a 95% coverage gate
  • missing profile values left out of the response
  • separate lint, docker and source workflows
  • files that no longer exist

An agent following that would "fix" the code back towards 4.x. This PR brings everything in line with pesu-dev/auth dev (5.6.0).

1. Reference docs named by full path (fb6de9e)

pesu-dev/auth now has its own docs/ (architecture.md, metrics.md, testing.md, ...). Here, docs/testing.md was shorthand for .agents/pesudev-skills/auth/docs/testing.md, so in that repo one path named two files.

Every reference to a reference doc now uses its full path. AGENTS.md says any other path, docs/<name>.md included, is relative to the repository root. No content changes.

2. 5.x content (1faeaca)

Area Change
upstream.md Rewritten for the login and profile requests: where each of the 17 fields comes from, and the maintainers' rules for values: as PESU sends them, from one source, null when missing; only a structural change is a 422; parse errors are never logged
api-contract.md All routes (API Explorer, /docs, HEAD routes, security headers); request limits; null rather than absent; 404, 405 and unreadable-body errors in the standard body; the Schemathesis contract tests and test_docs.py; one-step versioning with patch defined; v5.0.0 as a breaking-change precedent
architecture.md, metrics.md, testing.md Point at the repo's own docs/ pages, which tests/unit/test_docs.py keeps current. They keep only what agents need on top: invariants, patch points, fixture recipes (upstream, wire, payload fixtures) and the maintainers' test style. Open HTTP clients at rest is now 0, not 1
ci-cd.md The CI Checks jobs, Dependabot, and the production release steps: approval, deploy with rollback, release, then main
security.md, conventions.md Additions: the access token, upstream models that drop data they don't read, log injection, message vs detail, the non-root container, --locked installs, and ruff linting tests
known-issues.md Drops the seven entries fixed since and records what is misleading today
AGENTS.md Rule 1: the whole profile is logged by design. Rule 8: the one-session claim is dropped, but live runs stay single and are never looped. Rule 9: exactly one version step. New rule: values are returned as PESU sends them, or null
Skills and roles change-upstream-client, update-scraper, benchmark, fix-ci, run-locally, run-tests, setup-environment, update-dependencies, write-tests and diagnose-production are rewritten; the rest are updated. The em dashes in the report templates are replaced

update-scraper and scraper-specialist keep their names so links to them keep working; known-issues.md says why. common/ is unchanged: it still mentions source.yaml, which other pesu-dev repos may use, and auth's AGENTS.md takes precedence where the two disagree.

Closes #6

How this was checked

  • Each claim was checked against pesu-dev/auth dev and the running app: HEAD on every page, the 404 and 405 bodies and the Allow header, security headers, and the 400 for a bad fmt.
  • Every repository path these files name exists in auth. The only test names that don't are deliberate examples.
  • Every skill and role frontmatter block parses as YAML.
  • uvx pre-commit run --all-files passes.

After merge

Four role descriptions change: ci-investigator, docs-writer, scraper-specialist and test-engineer. Dependabot's submodule bump in pesu-dev/auth will therefore fail sync-agents. It needs a PR from a fork that bumps .agents/pesudev-skills, runs uv run python scripts/sync_agents.py and bumps the version (auth/docs/ci-cd.md, "Dependabot submodule bumps").

🤖 Generated with Claude Code

pesu-dev/auth now has its own docs/ directory, with architecture.md, metrics.md and testing.md among
its pages. The AGENTS.md, skills and roles here used `docs/<name>.md` as shorthand for
`.agents/pesudev-skills/auth/docs/<name>.md`, so in that repository the same path named two different
files, and an agent following `docs/testing.md` could read either one.

Every reference to a reference doc now uses its full path, and AGENTS.md says that any other path,
`docs/<name>.md` included, is relative to the repository root. The README's pointer to the Dependabot
steps names `auth/docs/ci-cd.md` for the same reason. No content changes.
pesu-auth 5.0.0 (pesu-dev/auth#241) moved from driving PESU Academy's web login to the API its mobile
app uses, and later releases changed CI, testing and the docs around it. The agent material still
described the old service: a CSRF prefetch cache and lock, HTML selectors, a single PESU session, a
95% coverage gate, missing values left out of the response, separate lint/docker/source workflows,
and files that no longer exist. Agents following it would "fix" code back towards 4.x.

Reference docs:
- upstream.md: the login and profile requests, how each profile field is read and the rules the
  maintainers set for values (as PESU sends them, one source, null when missing; only a structural
  change is a 422; parse errors never logged).
- api-contract.md: every route including the API Explorer, HEAD routes and security headers; the
  request limits; null rather than absent; all 17 fields; 404/405/body-parse errors in the standard
  body; the contract and docs tests; exactly-one-step versioning with patch defined.
- architecture.md, metrics.md, testing.md: point at the repository's own docs/ pages, which
  tests/unit/test_docs.py keeps current, and keep only what agents need on top: invariants, patch
  points, fixture recipes (upstream, wire, payload fixtures), the maintainers' test style.
- ci-cd.md: the CI Checks jobs, Dependabot, and the production release (approval, rollback,
  release, then main).
- security.md, conventions.md: the access token, upstream models that drop unread data, log
  injection, message vs detail, container and --locked installs; ruff now linting tests.
- known-issues.md: drops the entries fixed since (CSRF logging, requirements.txt, the bug template,
  test_readme.py, pytest.raises assertions, the PR template title, the README username) and records
  what is misleading today.

AGENTS.md: rule 1 says the whole profile is logged by design; rule 8 drops the one-session claim
(PESU allows several sessions) but keeps live runs single and never looped; rule 9 is the one-step
bump; a new rule says values are returned as PESU sends them, or null.

Skills and roles follow the same facts; change-upstream-client, update-scraper, benchmark, fix-ci,
run-locally, run-tests, setup-environment, update-dependencies, write-tests and diagnose-production
are rewritten. update-scraper and scraper-specialist keep their names so links to them still work.
Four role descriptions change (ci-investigator, docs-writer, scraper-specialist, test-engineer), so
pesu-dev/auth's sync-agents check needs the wrappers regenerated with the submodule bump.

Also covers pesu-dev#6 (--locked installs, the benchmark dependency group, ruff from uv.lock, the CI job
table) and replaces the em dashes in the report templates.
@aditeyabaral
aditeyabaral requested a review from a team as a code owner October 24, 2026 05:23
A second pass over every file against pesu-dev/auth dev:

- api-contract.md: the standard error body is for 4xx and 5xx (a 308 has none), and a ResponseModel
  failure is the route's own PESUAcademyError(500), not the catch-all handler.
- architecture.md: the runtime image holds the virtualenv as well as app/.
- testing.md: test_docs.py checks that the tables list everything and that named paths exist, not
  that paths are "reflected"; dropped an unsourced line about test docstrings.
- conventions.md: the examples of why-comments are long, so say new ones should be shorter rather
  than contradict them.
- update-scraper: the capture script writes the raw response, so say plainly that it holds real
  data to redact and delete, instead of a comment claiming it was already redacted.
- Rewrapped the prose lines the earlier edits had pushed well past 100 columns.
@aditeyabaral
aditeyabaral merged commit 588c9bb into pesu-dev:main Oct 24, 2026
2 checks passed
TVA-2 pushed a commit to TVA-2/auth that referenced this pull request Oct 24, 2026
* chore: update the agent skills to pesu-dev/skills 588c9bb

pesu-dev/skills#7 rewrote auth's agent docs, skills and roles for 5.x. They still described 4.x: a
CSRF prefetch cache, HTML scraping, a single PESU session, a 95% coverage gate and missing values
left out of the response, so agents following them would have worked against the current code. The
reference docs are now named by their full .agents/pesudev-skills/auth/docs/ path, so they no longer
clash with this repository's own docs/, and they point at those pages where they overlapped.

Four roles' descriptions changed (ci-investigator, docs-writer, scraper-specialist, test-engineer),
so their Copilot custom agents in .github/agents/ are regenerated with scripts/sync_agents.py; the
sync-agents hook fails without it, which is why Dependabot's own bump cannot land as is.

* chore: bump version to 5.7.0
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.

docs(auth): describe --locked installs and the benchmark dependency group

1 participant