This guide describes the expected local workflow for contributors and Codex runs. Keep changes focused, preserve deterministic generated outputs, and use only synthetic public-safe examples.
Install the package and development dependencies, then confirm the CLI is available:
python -m pip install -e ".[dev]"
agent-librarian --helpRegenerate and validate the synthetic sample catalog before running the test and whitespace checks:
agent-librarian catalog examples/sample-collection --out examples/generated-catalog
agent-librarian validate examples/generated-catalog
pytest
git diff --checkValidation confirms generated JSON matches the expected schema. It does not certify that a catalog is complete, safe, semantically correct, or free of private data.
CI sets:
SOURCE_DATE_EPOCH=1781481600This fixes generated timestamps so CI can enforce that the committed synthetic sample outputs stay current. On shells that support inline environment variables, reproduce the check with:
SOURCE_DATE_EPOCH=1781481600 agent-librarian catalog examples/sample-collection --out examples/generated-catalog
agent-librarian validate examples/generated-catalog
git diff --exit-code -- examples/generated-catalogIn Windows PowerShell, use:
$env:SOURCE_DATE_EPOCH = "1781481600"
agent-librarian catalog examples/sample-collection --out examples/generated-catalog
agent-librarian validate examples/generated-catalog
git diff --exit-code -- examples/generated-catalogNormal pytest remains the default for local development and CI. Use this
workaround only when local Windows temp or cache permissions prevent pytest
from running normally:
New-Item -ItemType Directory -Force .pytest-tmp | Out-Null
pytest --basetemp .\.pytest-tmp -p no:cacheproviderThe .pytest-tmp/ and .tmp/ directories are ignored and must remain
local-only.
Start from an up-to-date main branch and create a focused issue branch:
git checkout main
git pull --ff-only origin main
git checkout -b type/issue-number-short-descriptionExamples:
docs/issue-17-developer-workflow-codex-handoff
test/issue-14-github-actions-ci
chore/issue-16-windows-pytest-temp-handling
feature/issue-15-schema-validation-command
Use a conventional type followed by a concise description:
type: concise description
Examples:
feat: add catalog schema validation command
test: add GitHub Actions CI
chore: improve Windows pytest temp handling
docs: add developer workflow and Codex handoff guidance
When a commit should close an issue, include the issue reference in the commit body:
Closes #17
- Open pull requests into
main. - Keep each pull request focused on one issue or cohesive change.
- List the validation commands run in the pull request description.
- Keep documentation, tests, and generated examples synthetic.
- Delete merged branches.
- Do not push directly to
mainunless a repository administrator is intentionally bypassing branch rules.
At the end of a Codex run, summarize:
- issue number
- files changed
- behavior changed
- documentation changed
- tests added or changed
- validation commands run
- CI status, if available
- generated outputs changed, if any
- public-safety review notes
- risks or TODOs
- recommended next issue
Do not commit:
- secrets
- credentials
- private prompts
- private generated catalogs
- real trace logs
- real memory or state snapshots
- employer-specific examples
- internal URLs
- private local paths
- real user data
Use only synthetic examples in public documentation and tests. Review both source artifacts and generated outputs before publishing them.