Skip to content

feat(init)!: remove apm init --plugin and --marketplace (Fixes #4073) - #4074

Merged
Daniel Meppiel (danielmeppiel) merged 4 commits into
mainfrom
danielmeppiel-4073-remove-init-plugin
Nov 20, 2026
Merged

Daniel Meppiel (danielmeppiel) merged 4 commits into
mainfrom
danielmeppiel-4073-remove-init-plugin

Conversation

@danielmeppiel

@danielmeppiel Daniel Meppiel (danielmeppiel) commented Nov 20, 2026 •

Copy link
Copy Markdown
Collaborator

Description

Removes the deprecated apm init --plugin and apm init --marketplace flags in 0.37, as the #4073 scope record sets out. The flags were deprecated in 0.14 and their removal was already announced.

  • apm init --plugin and apm init --marketplace are now hidden stubs. They write nothing, exit 2, and print the full replacement command on stderr, keeping the project name, --yes, --target and metadata flags (for example Run: apm plugin init my-skill --yes --target claude). With both flags, both steps are printed.
  • apm plugin init gains --version, --author and --description, written to both apm.yml and plugin.json, so it fully replaces apm init --plugin.
  • The marketplace-block path that only --marketplace reached is removed from _perform_init. apm marketplace init keeps using render_marketplace_block.
  • Help, reference/cli/init.md, reference/cli/plugin.md and the apm-usage skill (commands.md, package-authoring.md) no longer offer the old flags. The init page's "Deprecations" section becomes "Removed flags" and points to the replacements. README never mentioned the flags.

Issue and approved scope

Issue: Fixes #4073

Human scope-approval comment: #4073 (comment)

Does this PR complete the issue, or what remains? It completes it.

Type of change

  • Bug fix
  • New feature
  • Documentation
  • Maintenance / refactor

Testing

  • Tested locally
  • All existing tests pass (CI)
  • Added tests for new functionality (if applicable)

New tests:

  • Installed CLI, tests/integration/test_init_removed_flags_lifecycle.py:
    • each removed flag exits 2, names its replacement, writes nothing and is hidden from apm init --help;
    • apm plugin init --version/--author/--description writes all three fields.
  • Unit, TestRemovedInitFlags in tests/unit/commands/test_plugin_init_command.py: the same contract via CliRunner.

Migrated tests:

Local evidence at the head:

  • pytest -n 2 over the init, plugin, marketplace and producer-journey files plus the new lifecycle file: 2542 passed.
  • uvx [email protected] check and format --check: clean.
  • pylint R0801: clean.
  • scripts/lint-auth-signals.sh: clean.
  • scripts/lint-architecture-boundaries.sh: exit 0.

Changelog

  • One line under ## [Unreleased] / ### Breaking changes and upgrade notes, prefixed **BREAKING:**, ending (closes #4073, #4074). The scope record says "under Removed"; changelog.instructions.md routes must-act removals only to Breaking, so the line lives there (same intent: record the removal with its migration).
  • N/A -- internal-only change (CI, tests, refactor).

Spec conformance (OpenAPM v0.1)

No req-XXX covers these flags.

…nit gains metadata flags (#4073)

Both flags (deprecated since 0.14) are hidden stubs that write nothing,
exit 2 and name the replacement command. apm plugin init accepts
--version, --author and --description so it fully replaces
apm init --plugin; the dead marketplace-block path leaves _perform_init.
Help, reference docs and the apm-usage skill drop the old flags.

BREAKING CHANGE: apm init --plugin / --marketplace now exit 2.

apm-spec-waiver: removes deprecated CLI flags; no OpenAPM requirement covers them

Co-authored-by: Copilot App <[email protected]>
init.md still documented the removed flag in the --version row, the
Behavior list and a copy-paste example that now exits 2, missing the
#4073 Done-when. The migration text was also written three times; the
init.md "Removed flags" section is now the single source, and it says
that --name has no plugin init equivalent. The CHANGELOG line moves to
Breaking changes per changelog.instructions.md (must-act removal).

Addresses panel follow-ups from doc-writer and devx-ux-expert.

Co-authored-by: Copilot App <[email protected]>
'apm init my-skill --plugin --yes --target claude' printed only
'Run: apm plugin init', and pasting that scaffolds interactively in the
current directory. The refusal now rebuilds the plugin init command
with the project name, --yes, --target and metadata flags, and prints
both steps when --plugin and --marketplace were passed together. Adds
a unit test for the prompt-seeded plugin init metadata path, which no
test covered. Mutation-break verified for all new tests.

Addresses panel follow-ups from devx-ux-expert and test-coverage-expert.

apm-spec-waiver: CLI refusal wording for removed init flags; no OpenAPM req covers these flags
Co-authored-by: Copilot App <[email protected]>
@danielmeppiel

Copy link
Copy Markdown
Collaborator Author

APM Review Panel: ship_with_followups

Removes the long-deprecated apm init --plugin/--marketplace flags and makes apm plugin init a near-complete replacement. Behavior and tests are solid; the docs and CHANGELOG fell short of the approved Done-when (now folded, see below).

panel-mode=lean; personas=devx-ux-expert,test-coverage-expert,doc-writer (adhoc: docs, help and CHANGELOG are explicit Done-when deliverables)

cc Sergio Sisternes (@sergio-sisternes-epam) -- a fresh advisory pass is ready for your review.

The behavior matches the approved #4073 scope. The removed flags are hidden stubs that write nothing, print the replacement command and exit 2. apm plugin init now accepts --version, --author and --description and writes them to both apm.yml and plugin.json. Tests cover this at the unit tier and against the installed CLI, and test-coverage-expert confirmed the --yes paths and that an explicit version beats the 0.1.0 default. Users had warning since 0.14, so removing the flags in 0.37 is fair to the community.

The doc-writer's blocking-severity call was right on the facts, and devx-ux-expert found the same drift independently: reference/cli/init.md still mentioned --plugin in three places, one of them a copy-paste example that exits 2. The approved Done-when says docs no longer mention the old flags, so this was a missed acceptance criterion. Two devx findings also belong in this PR: the refusal should rebuild the user's full command (the scope promised the exact replacement command), and the docs should stop claiming a full replacement while --name has no equivalent. Adding --name to apm plugin init goes beyond the three approved flags, so it waits for a follow-up issue.

On the CHANGELOG, the scope said "under Removed with a migration line" and changelog.instructions.md says must-act changes go ONLY under ### Breaking changes and upgrade notes with **BREAKING:**. Both express the same intent; the repo rule decides the section. The PR title already carries !.

Dissent. doc-writer rated the init.md drift blocking-severity and devx-ux-expert rated it recommended. The CEO sides with doc-writer on substance (explicit Done-when), noting the fix is small enough to fold here. On the CHANGELOG the CEO sides with the repo rule over the literal scope wording, disclosed in the PR body.

Aligned with: Pragmatic as npm -- removed flags fail with exit 2 and name the replacement command; rebuilding the full command makes migration a single paste. Portable by manifest -- apm plugin init writes version, author and description to apm.yml and plugin.json together. OSS community driven -- the break follows a 0.14 to 0.37 deprecation window with a migration line.

Panel summary

Persona B R N Takeaway
DevX UX Expert 0 3 0 Exit-2 stubs and the new plugin init flags are right. Two doc lines and one example still used apm init --plugin, the refusal dropped the user's args, and --name has no replacement.
Test Coverage Expert 0 1 0 Removed-flag refusal and plugin init metadata under --yes are covered at unit and installed-CLI tier. One gap: prompt-seeded (non --yes) plugin init metadata was untested.
Doc Writer 1 2 0 init.md still documented the removed --plugin flag in 3 places, including a runnable example that exits 2. Move the CHANGELOG line to Breaking. Remove duplicate migration text.

B = blocking-severity findings, R = recommended, N = nits.
Counts are signal strength, not gates. The maintainer ships.

Top 5 follow-ups

  1. [Doc Writer] (blocking-severity) Remove the remaining --plugin mentions from reference/cli/init.md (the --version row, the Behavior list and the example that exits 2), plus the 'same as legacy --plugin' docstring at init.py:272. -- Misses the approved Done-when; a copy-paste example that exits 2 breaks the rule that every example must work.
  2. [DevX UX Expert] Have the refusal rebuild the user's full apm plugin init ... command, and print both steps when --plugin and --marketplace were passed together. -- A bare apm plugin init drops name, target and version and falls back to an interactive scaffold.
  3. [Doc Writer] Move the CHANGELOG entry to ### Breaking changes and upgrade notes with **BREAKING:**, 25 words or fewer, and note the scope-wording reading in the PR body. -- The repo changelog rule routes must-act removals only to Breaking.
  4. [Test Coverage Expert] Add a unit test for apm plugin init --version/--author/--description without --yes. -- If forwarding broke on the interactive path, or the 0.1.0 override fired outside --yes, no test would fail.
  5. [DevX UX Expert] State that --name has no equivalent instead of claiming a full replacement; open a follow-up issue to add --name to apm plugin init. -- Fixing the doc claim is in scope; adding a fourth flag is not.

Recommendation

The behavior and tests are right, so the PR does not need rework. Merge after fixing the init.md drift, moving the CHANGELOG entry to Breaking, rebuilding the user's full command in the refusal, adding the interactive-path test and softening the full-replacement claim. Track adding --name to apm plugin init as the only follow-up issue.

Folded in this run

  • (panel) init.md: removed the --plugin mentions in the --version row, the Behavior list and the exit-2 example; exit-code line no longer cites a plugin name; init.py:272 docstring cleaned -- resolved in e6c8726, beaa0df.
  • (panel) Refusal prints the full replacement command (Run: apm plugin init my-skill --yes --target claude --version 2.0.0 --author 'Ada L') and both steps when both flags are passed -- resolved in beaa0df.
  • (panel) CHANGELOG line moved to ### Breaking changes and upgrade notes with **BREAKING:**, under 25 words; PR body discloses the scope-wording reading -- resolved in e6c8726.
  • (panel) Unit test for prompt-seeded apm plugin init metadata, including the 1.0.0 default outside --yes -- resolved in beaa0df.
  • (panel) init.md "Removed flags" is the single migration source and says --name has no equivalent; plugin.md migration section is a one-line link -- resolved in e6c8726.

Copilot signals reviewed

  • No copilot-pull-request-reviewer[bot] reviews or inline threads on this PR after 2 fetch rounds; 0 review threads, 0 unresolved.

Deferred (out-of-scope follow-ups)

Regression-trap evidence (mutation-break gate)

  • TestRemovedInitFlags::test_removed_plugin_flag_prints_the_full_replacement_command -- replaced the rebuilt command with a bare Run: apm plugin init; test FAILED as expected; guard restored.
  • TestRemovedInitFlags::test_both_removed_flags_print_both_replacement_steps -- suppressed the marketplace step when both flags are set; test FAILED as expected; guard restored.
  • TestRemovedInitFlags::test_plugin_init_metadata_flags_seed_interactive_prompts -- dropped --version forwarding in plugin/init.py, and separately let the 0.1.0 plugin default fire outside --yes; the matching case FAILED each time; guards restored.

Lint contract

ruff check and ruff format --check (ruff 0.15.12) over src/ tests/ plus the architecture linter sources: silent. pylint R0801: 10.00/10. scripts/lint-auth-signals.sh: exit 0. scripts/lint-architecture-boundaries.sh: exit 0.

CI

PR checks at beaa0df: build SUCCESS, license/cla SUCCESS, deploy SKIPPED (0 CI fix iterations). ci.yml runs only on PRs to main, so the full CI matrix for this stacked PR is proven by the Lane L release train. Local evidence: 372 targeted init/plugin/marketplace/producer-journey tests passed; installed-CLI tests/integration/test_init_removed_flags_lifecycle.py 3 passed; discovery owner tests (unit onboarding + installed-CLI brownfield) passed.

Mergeability status

PR head SHA CEO stance iters folds defers Copilot rounds CI mergeable mergeStateStatus notes
#4074 beaa0df ship_with_followups 1 5 1 2 green MERGEABLE CLEAN stacked on #4072; ci.yml proven by Lane L train
Full per-persona findings

DevX UX Expert

  • [recommended] init.md still documents the removed --plugin flag in the --version row, the Behavior list and a copy-paste example that now exits 2 at docs/src/content/docs/reference/cli/init.md:97
    Done-when says help and docs no longer mention the old flags; lines 50, 93-102 and 145 still did, and the example now exits 2.
  • [recommended] The refusal names a bare replacement command and drops the user's own arguments, so recovery takes more than one paste at src/apm_cli/commands/init.py:212
    All those args are accepted by apm plugin init, so the stub can rebuild the exact command. With both flags, only the first was reported.
  • [recommended] The docs claim apm plugin init fully replaces apm init --plugin, but --name for in-place init has no replacement at src/apm_cli/commands/plugin/init.py:51
    Scope named only three flags, so adding --name is a follow-up; the doc claim should be honest now.

Test Coverage Expert

  • [recommended] apm plugin init --version/--author/--description without --yes (prompt-seeded path) had no test at tests/unit/test_init_command.py
    Every test of the new flags used --yes. plugin.json author is asserted in the unit test; 0.1.0-with-yes and explicit-version-wins are covered.
    Proof (missing at): tests/unit/test_init_command.py -- proves: a plugin author running apm plugin init interactively with metadata flags gets them written to apm.yml and plugin.json.

Doc Writer

  • [blocking] init.md still documents the removed --plugin flag in 3 places, including a runnable example that now exits 2 at docs/src/content/docs/reference/cli/init.md:97
    Misses the approved Done-when and breaks the rule that every example must work.
  • [recommended] The CHANGELOG entry is a removal users must act on, so the repo rule puts it under Breaking with BREAKING:, not Removed at CHANGELOG.md
    changelog.instructions.md routes must-act changes only to Breaking changes and upgrade notes; the entry was also over 25 words.
  • [recommended] The migration path was written out 3 times at docs/src/content/docs/reference/cli/plugin.md:53
    State once, link elsewhere: init.md Removed flags is the single source.

This panel is advisory. It does not block merge. Re-apply the
panel-review label after addressing feedback to re-run.


Generated by autopilot-pr-merge-worker. This comment is AI-generated and may contain errors.

Base automatically changed from danielmeppiel-release-gate-oracles to main November 20, 2026 06:46
Daniel Meppiel (danielmeppiel) added a commit that referenced this pull request Nov 20, 2026
@danielmeppiel
Daniel Meppiel (danielmeppiel) merged commit c564d01 into main Nov 20, 2026
39 checks passed
@danielmeppiel
Daniel Meppiel (danielmeppiel) deleted the danielmeppiel-4073-remove-init-plugin branch November 20, 2026 06:59
Copilot AI mentioned this pull request Nov 20, 2026
5 of 10 tasks
Daniel Meppiel (danielmeppiel) added a commit that referenced this pull request Nov 20, 2026
@danielmeppiel Daniel Meppiel (danielmeppiel) added this to the 0.37.0 milestone Nov 20, 2026
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.

Remove deprecated apm init --plugin and --marketplace in 0.37

1 participant