Skip to main content

advice-animal

Advice Animal answers the question of what do we do after running cookiecutter, or how to we avoid telling people we support to run a sed script.

Design Goals

Existing projects such as cookiecutter do a pretty solid job of initial project generation, and ones such as ruff, fixit, and pyupgrade do a solid job of suggesting universal (that is, applicable to everyone) changes.

Advice Animal is developed to serve a central team that has opinions, but wants to leave the application of that advice up to teams owning individual repos that have the interest and time to apply it.

  • The storage of fixes is decoupled from the release of the thing that runs them.
    • It's just a git repo, which gets pulled on each run.
    • But can also be a directory, if you want to manage distribution with puppet or your monorepo or are working on proposed changes.
  • Fixes are run with a trivial workflow engine.
    • Creates a branch-per-fix with git.
    • Expensive fixes can record that they're done, to avoid running again
    • Fixes can be manual (think "feature add")
    • Your fix repo can customize workflow, including branch naming and commands that get run (say you have a FUSE/mercurial setup or need to run tox -e stylefix and amend).
  • Your users choose what fixes they want (either by quality=their available time), or by declining a fix.
  • Third-party libraries are easy to use in your fixes, and they don't even need to be public.

Fix confidence

Using traffic light colors for simplicity:

  • FixConfidence.GREEN are high-confidence fixes that a) something is wrong and b) this won't make it worse (think, formatting). Trust your tests and land these.

  • FixConfidence.YELLOW ought to have human review (and definitely make sure the tests run), but are low-effort to apply (think, renaming python modules that have uppercase in them, or bumping a version to avoid a known CVE). Meets the bar for a passing mention in release notes.

  • FixConfidence.RED likely need a human to pick up the baton and finish it (think: you clearly use types, you probably should enable mypy in CI).

Version Compat

Usage of this library should work back to 3.7, but development (and mypy compatibility) only on 3.10-3.12. Linting requires 3.12 for full fidelity.

Versioning

This library follows meanver which basically means semver along with a promise to rename when the major version changes.

License

advice-animal is copyright Tim Hatch, and licensed under the MIT license. See the LICENSE file for details.

Metadata

Release files for advice-animal 0.4.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for advice-animal 0.4.5
File Size Uploaded Provenance Actions
advice_animal-0.4.5.tar.gz 22.2 kB With provenance Details for advice_animal-0.4.5.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for advice-animal 0.4.5
File Interpreter ABI Platform Actions
advice_animal-0.4.5-py3-none-any.whl Python 3 none any Details for advice_animal-0.4.5-py3-none-any.whl

Total release size: 37.2 kB

Release files / advice_animal-0.4.5.tar.gz

Download URL advice_animal-0.4.5.tar.gz
Size 22.2 kB
Tags Source
SHA-256 checksum
How to use checksums
75657c53f6c5067b0c283e9f7718c39eba20bdc47eb5a7f6737dd07e60f2856f
BLAKE2b-256 checksum
How to use checksums
65917e1983154d318d9b767c8ead9da2cc189d08703f4d640ddd9b80b2655df3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 20, 2025.

Transparency log

Release files / advice_animal-0.4.5-py3-none-any.whl

Download URL advice_animal-0.4.5-py3-none-any.whl
Size 15.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
466125c2e25f6443dee2861ad33de79f0a30e9b1fe4f8257ab11c49ba54710a8
BLAKE2b-256 checksum
How to use checksums
bf8cc0696e780f956373d082c5ff21421dc64e1a9e8d0f23e6c6b07bafae04e7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 20, 2025.

Transparency log

Security for advice-animal 0.4.5

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for advice_animal-0.4.5.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Mar 20, 2025.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page