Skip to content

feat: make lifecycle options independently composable - #80

Merged
codeforester merged 1 commit into
mainfrom
enhancement/58-20260802-composable-lifecycle-options
Aug 3, 2026
Merged

feat: make lifecycle options independently composable#80
codeforester merged 1 commit into
mainfrom
enhancement/58-20260802-composable-lifecycle-options

Conversation

@codeforester

Copy link
Copy Markdown
Contributor

Summary

  • Add immutable LifecycleOption and LifecycleOptions policies so every standard lifecycle option can be enabled, disabled, renamed, and configured independently while preserving existing defaults.
  • Publish normalized LifecycleValues through namespaced Click metadata without replacing application-owned Context.obj.
  • Make native root/leaf precedence explicit and source-aware, and make attached-tree adoption preserve vendor callbacks and destinations while rejecting alias, destination, polarity, shape, and help collisions transactionally.
  • Keep legacy native dry-run behavior while making attached/global dry-run opt-in, and document placement, value sources, adoption ownership, and migration behavior.

Issue

Closes #58

Validation

  • python -W error -m pytest -q -p no:cacheprovider — 320 tests pass with Click 8.4.2.
  • PYTHONPATH=/private/tmp/base-cli-click-818.sdDdsi:lib/python python -W error -m pytest -q -p no:cacheprovider — 320 tests pass with Click 8.1.8.
  • ./tests/validate.sh
  • python -m build --sdist --wheel
  • python scripts/validate_package_artifact.py <dist-dir>
  • python -m twine check <wheel> <sdist>
  • git diff --check

Notes

Two independent adversarial audits found no remaining release blockers. Runtime-only Click token normalizers cannot be known at registration; static command token normalizers are validated.

Checklist

  • Branch name follows <category>/<issue>-<YYYYMMDD>-<slug>, and its category prefix matches the issue's single standard category label.
  • Pull request is scoped to one issue, unless a documented multi-issue exception applies.
  • Pull request body explains what changed and how it was validated.
  • Relevant project checks pass.
  • Documentation is updated when behavior or user-facing commands change.
  • CHANGELOG is updated for notable user-visible or release-worthy changes.
  • Pull request includes Fixes #<issue> or Closes #<issue> when merge should close the issue.

@codeforester
codeforester marked this pull request as ready for review August 3, 2026 00:18
@codeforester
codeforester merged commit 9433bdf into main Aug 3, 2026
17 checks passed
@codeforester
codeforester deleted the enhancement/58-20260802-composable-lifecycle-options branch August 3, 2026 00:19
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.

Make standard lifecycle options independently composable

1 participant