Skip to content

fix: milpa/core is a dev-time tool here, not a runtime dependency - #12

Merged
rodrigoteamx merged 1 commit into
mainfrom
fix/core-is-a-dev-time-tool
Sep 9, 2026
Merged

rodrigoteamx merged 1 commit into
mainfrom
fix/core-is-a-dev-time-tool

Conversation

@rodrigoteamx

Copy link
Copy Markdown
Contributor

milpa/ops declared milpa/core in require and used not one line of it. The only mention of core anywhere in the package is a docblock sentence in src/Cron/CronProviderInterface.php comparing its shape to core’s ToolProviderInterface.

What ops actually needs core for is tools/gen-docs.php, which reaches the family’s docs generator through this package’s own autoload-dev mapping (Milpa\Docs\ → vendor/milpa/core/tools/gen-docs/). That is a dev-time entry point, so the declaration belongs in require-dev.

Measured, with a positive control. A scratch consumer requiring milpa/ops through a path repo, resolved with --no-dev:

packages a production install pulls
before milpa/core v0.12.0, psr/container, psr/event-dispatcher, psr/log
after psr/log

Three packages leave the production graph of every consumer, and none of them was ever used.

Suite green (69 tests, 193 assertions), and php tools/gen-docs.php still generates its 31 pages with core in require-dev.

Follows greenhouse decisions/0237, where the family-wide census that found this is corrected to tell a tool dependency apart from an unexplained one.

milpa/ops declared milpa/core in `require` and used not one line of it. Its only
mention anywhere in the package is a docblock sentence comparing an interface to
core's. What it actually needs core for is `tools/gen-docs.php`, which reaches
the family's docs generator through this package's own autoload-dev mapping
(`Milpa\Docs\` → `vendor/milpa/core/tools/gen-docs/`) — a dev-time entry point.

Measured against a path-repo consumer with `--no-dev`: before, installing
milpa/ops pulled milpa/core, psr/container and psr/event-dispatcher; after, it
pulls psr/log alone. Suite green (69 tests) and gen-docs still generates its 31
pages with core in require-dev.

Follows greenhouse decisions/0237.
@rodrigoteamx
rodrigoteamx merged commit 4d3f076 into main Sep 9, 2026
2 checks passed
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.

1 participant