← Back to DAGDA | Support | Source: https://github.com/pypa/pipx/pull/2157
Skip to content

Allow selecting dependencies that only ship shell completions - #2157

Merged
gaborbernat merged 3 commits into
pypa:mainfrom
AryanRG:fix/completion-only-dependencies-w31
Oct 17, 2026
Merged

gaborbernat merged 3 commits into
pypa:mainfrom
AryanRG:fix/completion-only-dependencies-w31

Conversation

@AryanRG

@AryanRG AryanRG commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor

Fixes #2156.

--include-resources-from rejects a dependency that provides shell completions but no apps or manual pages, then rolls back the parent installation. Include the discovered completion dependencies in metadata validation, update the diagnostic and docs, and add local-wheel regressions for pip and uv. The regression checks normalized selection metadata and exposed Bash, Zsh, and Fish completions.

Validation

Full tox run --skip-missing-interpreters false -e 3.11,3.15,type,docs passed on the five-file patch:

  • Python 3.11.16: 1,509 passed, 29 skipped.
  • Python 3.15.0: 1,526 passed, 12 skipped.
  • Type checking: ty check passed.
  • Docs: Sphinx -W --keep-going passed.
  • Full pre-commit run --all-files and git diff --check passed.

Validation uses macOS 27 arm64, the normal 80-column terminal width and 60-second macOS timeout, and a PATH without the misleading Miniforge python3.1 symlink. No source, test, or interpreter overrides are used. Both new backend regression cases ran without skips.

Final head: fc02bf27222bf255f63321f07271383ec4858379. Its only addition to the tested code/test/docs commit is changelog.d/2157.bugfix.md. At this exact head, the 38-case focused suite passed on each interpreter (3.11: 24.70 seconds; 3.15: 10.36 seconds), and type checking and Sphinx docs passed again. Full pre-commit passed on the same six-file tree. The generated changelog includes the new entry with the #2157 link.

Final six-file diff SHA-256: 3ed9f2c757487d10cddc73f4162a9112c822447d53bb849674793194d565af48, using git diff --binary --full-index --no-ext-diff 57023060214b662d31484337864918e1846bd608 fc02bf27222bf255f63321f07271383ec4858379. The original five-file subset still hashes to c5ed6848849a79bdbad402ed88ea9f91309817b84158954aadf5d62cebb240b6.

CI snapshot at 2026-10-17 05:16 UTC: final-head tests and zizmor report completed/action_required, with no check runs. pre-commit.ci and Read the Docs passed. Passing hosted test CI is not claimed, and the PR remains draft.

Contribution checklist

  • ran the linter to address style issues (pre-commit run --all-files)
  • wrote descriptive pull request text
  • ensured there are test(s) validating the fix
  • added news fragment in changelog.d/ folder (choose a type: feature, bugfix, doc, removal, or misc)
  • updated/extended the documentation
  • ran tests on Python 3.11 and 3.15 (tox run -e 3.11,3.15)
  • linked upstream issues beside any temporary interpreter overrides
  • kept the PR in draft until CI passes

No temporary interpreter overrides are added; that checklist item is not applicable. The numbered changelog fragment was added after obtaining this PR's actual number.

AI assistance was used to prepare implementation and regression tests.

@AryanRG
AryanRG marked this pull request as ready for review October 17, 2026 05:23
@gaborbernat
gaborbernat enabled auto-merge (squash) October 17, 2026 10:32
@gaborbernat
gaborbernat merged commit 8c225d7 into pypa:main Oct 17, 2026
16 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.

Completion-only dependencies are rejected by --include-resources-from

2 participants