agentleFS
CodeSigilsCodeSigils/python-project-workflow-skill/skills/python-project-workflow/SKILL.md

python-project-workflow

Skill1 starsChanged 18 days agoMITView on GitHub

Set up, inspect, preserve, and verify Python project workflows, including greenfield scaffolding, packaging, dependency and tool configuration, CI, compatibility contracts, mature automation repositories, and project-native validation. Use when the task affects repository-wide Python structure or workflow. Do not use for pure code review, isolated support-script edits in otherwise non-Python repositories, or framework-specific implementation unless the request also changes project tooling or workflow.

  • Reads credentials

1 other project uses a version of this.

Adopted by

Most recently taken up by

  • Other versions1 project uses a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 1

    1. brookite/skills★ 0same name

    How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.

  • In this repositoryOne other file it gives its agents.

The file

Show its rules and text

We split this skill into the rules it gives an agent

25 rules. About 0 are common, 19 are distinctive, and 6 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈19

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 6

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  • could be automatic: a setting could enforce it
  1. Distinctive:

    Verify with project-native gates and report actual results.

    line 25
  2. Distinctive:

    Inspect or advise: use read-only discovery. Do not install dependencies, synchronize environments, generate files, or edit configuration.

    line 46
  3. Distinctive:

    Verify: run already-available project-native gates first.

    line 50
  4. Distinctive:

    Bootstrap: create or replace project structure only for an explicit greenfield or modernization request.

    line 52
  5. Distinctive:

    When resuming interrupted work, treat summaries and prior claims as leads.

    line 71
  6. Distinctive:

    Treat declared packaging range, effective CI/deployment range, tool targets, and minimum-supported syntax/dependencies as one contract.

    line 77
  7. Distinctive:

    When a task touches packaging/pyproject metadata, inspect before claiming PEP 621 alignment.

    line 90
  8. Very specific:

    Report status with evidence: use aligned, partial, missing, legacy-alternative, unknown, or N/A.

    line 97
  9. Distinctive:

    Preserve coherent layouts: do not impose PEP 621 on a coherent legacy repository unless the user explicitly requests migration.

    line 100
  10. Very specific:

    Version contract: treat requires-python as part of the Python Version Contract.

    line 103
  11. Distinctive:

    Use project-native gates first, then relevant skill references, then current official tool documentation.

    line 126
  12. Very specific:

    Do not impose uv, src/, Ruff, MyPy, pytest, PEP 621, or a new package layout when coherent alternatives already exist.

    line 133
  13. Distinctive:

    Keep modernization separate from required fixes.

    line 135
  14. Distinctive:

    Do not reformat unrelated code or combine broad mechanical changes with logic changes.

    line 136
  15. Distinctive:

    Treat project-native warnings according to their documented severity.

    line 140
  16. Distinctive:

    When canonical source has runtime, generated, or installed mirrors, edit the canonical source first.

    line 147
  17. Distinctive:

    Never expose or commit secrets: do not commit or print credentials, access tokens, private keys, populated secret files, sensitive URLs, or …

    line 158
  18. Distinctive:

    Do not claim a repository is secret-free from filename checks or absence of a regex match.

    line 164
  19. Very specific:

    Load detailed procedure: before advising or editing ignore rules, credentials, tracked sensitive files, or history exposure, load …

    line 166
  20. Very specific:

    Prefer commands already defined by CI, Make, tox, nox, task runners, or repository scripts.

    line 172
  21. Distinctive:

    Before running a command, distinguish:

    line 176
  22. Distinctive:

    Read-only checks that inspect existing state.

    line 178
  23. Distinctive:

    Run setup and mutating verification only when authorized and necessary.

    line 183
  24. Very specific:

    When no canonical gate covers changed behavior, create a focused temporary verifier under /tmp only when it adds meaningful evidence.

    line 186
  25. Distinctive:

    Do not invent success or hide failures behind unrelated passing checks.

    line 210

≈ “Common” is an estimate: at least 1 in 5 of the 408,460 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Python Project Workflow

Apply a preservation-first workflow to Python project setup, tooling, CI, packaging, compatibility, and repository-wide verification.

Framework-specific project conventions are out of scope. For Django, FastAPI, Flask, and similar frameworks, use dedicated framework guidance or preserve the project's established workflow. Do not present this generic baseline as framework-complete guidance.

Workflow

  1. Inspect before advising: read repository instructions, version-control state, and project-native configuration first. Do not recommend or make changes until the current state is established from repository facts.
  2. Classify the repository and the requested operation.
  3. Load only the references relevant to that classification.
  4. Preserve coherent local conventions unless the user explicitly requests modernization.
  5. Verify with project-native gates and report actual results.

Repository Classification

Apply Existing and Automation before considering Greenfield. Missing packaging metadata or tests does not make a repository greenfield when meaningful source, scripts, documentation, or history already exist.

SignalClassificationGuidance
Empty directory or explicit new-scaffold requestGreenfieldLoad references/pyproject-template.md
Packaging metadata and coherent toolingExisting projectOrient first, then load task-specific guidance
Python used for repository checkers or governanceMature automationLoad references/mature-repo-preservation.md
Eval or benchmark runnersAutomation with benchmarksAlso load references/eval-benchmark-hardening.md when runner behavior, assertions, or artifacts are in scope

For isolated support scripts that fall outside this skill's trigger, use repository-native instructions and focused checks. Do not infer correctness from classification alone.

Operation Modes

  • Inspect or advise: use read-only discovery. Do not install dependencies, synchronize environments, generate files, or edit configuration.
  • Implement: make only changes authorized by the user and preserve unrelated worktree changes.
  • Verify: run already-available project-native gates first. Treat setup or dependency installation as a separate step when it is required.
  • Bootstrap: create or replace project structure only for an explicit greenfield or modernization request.

Orientation Checklist

Inspect only what is relevant to the task:

  • Active repository instructions such as AGENTS.md, CONTRIBUTING.md, and framework-specific guidance.
  • git status --short --branch, relevant diffs, and recent bounded history.
  • Packaging metadata: pyproject.toml, setup.py, setup.cfg, build backend, dependencies, and lockfiles.
  • Source, test, namespace-package, and CLI entry-point layout.
  • Tool configuration for Ruff, MyPy, Pyright, pytest, tox, nox, pre-commit, Hatch, Poetry, Pixi, or project-specific scripts.
  • CI workflows, supported operating systems, and Python-version matrices.
  • README and developer documentation claims that form part of the workflow contract.

When resuming interrupted work, treat summaries and prior claims as leads. Reconstruct state from repository facts before editing, committing, or claiming completion.

Python Version Contract

Treat declared packaging range, effective CI/deployment range, tool targets, and minimum-supported syntax/dependencies as one contract. Target the project-wide minimum unless configuration intentionally scopes a newer target. Do not silently raise requires-python or remove older CI versions.

Surface mismatches before changing any contract element. Do not assume tool support or defaults; confirm current tool Python support, interpreter lifecycle, platform defaults, dependency support, and packaging guidance from official sources before making a new compatibility recommendation. Do not encode point-in-time lifecycle claims as durable policy.

PEP 621 Inspection-First Contract

When a task touches packaging/pyproject metadata, inspect before claiming PEP 621 alignment. This is a bounded workflow contract, not a universal compliance scanner.

  • Inspect evidence: [project] table presence and key fields; project.dynamic; [build-system]; requires-python; dependency declarations; existing setup.py/setup.cfg/Poetry/Flit/Hatch/PDM metadata; tool targets and CI version matrices relevant to the Python Version Contract.
  • Report status with evidence: use aligned, partial, missing, legacy-alternative, unknown, or N/A. State what was inspected and what was not. Do not invent compliance when evidence is absent or unreadable.
  • Preserve coherent layouts: do not impose PEP 621 on a coherent legacy repository unless the user explicitly requests migration. For greenfield or explicitly incoherent projects, PEP 621 is a negotiable baseline.
  • Version contract: treat requires-python as part of the Python Version Contract; report mismatches, do not silently change it.
  • Canonical sources: PyPA pyproject.toml specification, PEP 621, PyPA core metadata, Writing your pyproject.toml, PEP 639; load references/pyproject-template.md for baseline template/caveats.

Reference Routing

Load references progressively:

TaskReference
Greenfield setup, packaging, release, or CLI entry pointsreferences/pyproject-template.md
Linting, formatting, typing, tests, or CI commandsreferences/lint-format-typing-testing.md
Mature repositories and automationreferences/mature-repo-preservation.md
Eval or benchmark runnersreferences/eval-benchmark-hardening.md (thin runtime checklist; detailed maintainer guidance in repo docs)
.gitignore, secrets, credentials, or Git-history exposurereferences/security-and-gitignore.md
Canonical/runtime payload or installed-copy driftreferences/drift-classes.md (thin runtime summary; detailed maintainer procedure in repo docs)
Escape-heavy shell, regex, or generated textreferences/safe-editing.md
Compact correctness awareness outside pure reviewreferences/core-footguns.md

Use project-native gates first, then relevant skill references, then current official tool documentation. Ask the user when a material choice remains.

Preserve Local Conventions

For existing repositories:

  • Do not impose uv, src/, Ruff, MyPy, pytest, PEP 621, or a new package layout when coherent alternatives already exist.
  • Keep modernization separate from required fixes.
  • Do not reformat unrelated code or combine broad mechanical changes with logic changes.
  • Decide lockfile policy from the repository's application or library contract; do not automatically ignore, regenerate, or commit lockfiles.
  • Treat project-native warnings according to their documented severity.

For greenfield or explicitly incoherent projects, a reasonable starting point is uv, Ruff, MyPy, pytest, PEP 621, and a src/ layout. Present this as a negotiable baseline and verify compatibility with the intended deployment and dependency ecosystem.

When canonical source has runtime, generated, or installed mirrors, edit the canonical source first. Synchronize mirrors only through project-provided commands, then run both source-only and mirror-aware gates.

Sensitive-Evidence Safety

Runtime-critical invariants (canonical runtime detail: references/security-and-gitignore.md):

  • Preserve before editing: inspect existing .gitignore behavior before changing it; keep project-specific/security rules, including sanitized !.env.example when used.
  • Never expose or commit secrets: do not commit or print credentials, access tokens, private keys, populated secret files, sensitive URLs, or secret-bearing commit metadata; never print raw commit bodies.
  • Tracked/history exposure: .gitignore does not protect tracked files. If sensitive material is tracked or may have entered history, stop, alert the user, report existence/location only, and recommend revocation or rotation. Do not claim a repository is secret-free from filename checks or absence of a regex match.
  • Load detailed procedure: before advising or editing ignore rules, credentials, tracked sensitive files, or history exposure, load references/security-and-gitignore.md.

Verification

Prefer commands already defined by CI, Make, tox, nox, task runners, or repository scripts. Load references/lint-format-typing-testing.md only when generic tool commands are needed.

Before running a command, distinguish:

  • Read-only checks that inspect existing state.
  • Environment setup such as uv sync, virtual-environment creation, or package installation.
  • Generators or fixers that can modify source, configuration, or lockfiles.

Run setup and mutating verification only when authorized and necessary. Do not claim a full suite is green when only a focused check ran.

When no canonical gate covers changed behavior, create a focused temporary verifier under /tmp only when it adds meaningful evidence. Name it with a py-workflow-verify- prefix, exercise the smallest relevant pass and fail paths, remove it afterward when practical, and report it as ad-hoc verification.

Re-run verification when later edits can affect the behavior or contract already checked. Match documentation-only changes with documentation checks; do not create a new behavioral harness solely because an unrelated comment or example changed.

For escape-heavy edits, load references/safe-editing.md and use a focused byte-level diagnostic where relevant.

Reporting

Report:

  • Repository and operation classification.
  • Files changed or reviewed.
  • Verification commands and observed results.
  • Skipped checks and remaining risks.
  • A concise next step when work remains.

Do not invent success or hide failures behind unrelated passing checks.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.