Repository navigation
Honor selected collections during shell completion - #1104
Open
2836048681 wants to merge 1 commit into
Open
2836048681 wants to merge 1 commit into
2836048681 wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #238.
Bash and Fish pass the command being completed after
--complete --. Invokecurrently loads the default task collection before considering that command's
-c/--collectionoption. Completion therefore suggests the wrong tasks, orfails if there is no default task file.
Recover the collection with the existing core argument parser before loading
tasks. This supports spaced, equals-delimited and attached collection arguments
without adding shell-specific parsers. An explicit collection on the completion
process still takes precedence. Task-local
-cflags remain task arguments,and incomplete core flags retain the collection already parsed.
The generated shell scripts and ordinary task execution are unchanged. A
changelog entry credits the original reporter.
Validation on Linux, Python 3.12.3:
unchanged upstream source at
6a71e680c535ba6520e935c497099fbca011d03c.including task and option completion, both presence and absence of default
tasks, and task-local
-carguments. The same harness passes only the fourcontrols on the upstream source; all twenty bug cases fail there.
79-column convention, compilation and committed-diff whitespace checks pass.
The test runner requires a controlling terminal for its terminal I/O tests;
the full unit suite was run under
scriptwith capture disabled. The selectedCLI integration module was run with an isolated home directory. There is one
existing
pytest-relaxeddeprecation warning, also seen on the baseline.Other interpreters, operating systems, sudo integration, runner integration,
documentation builds and downstream projects were not tested.
Local submission handoff:
upstream
3.0andmainat review. Suggested target:3.0.invoke/program.py,tests/completion.py,sites/www/changelog.rst— 62 insertions, 1 deletion.Bug; the maintainer left Bash/Fishsupport open for contributions. Issue timeline, all-state issue-number PR
search, completion PR search, and final open issue-number PR search show no
competing collection completion fix. The owner has zero open repository PRs.
shortlist.md; prior completedworker-01 repositories excluded. API responses are saved under
screening/.ready/invoke-238/; test evidence:evidence/.Reproduce from the checkout:
Placement limitation:
../ready-w01-r100.md,../LEDGER-w01.md, and thefactory-wide ready/ledger destinations are read-only and outside this round's
writable root. This file and the append-ready
LEDGER-w01.mdare staged locallyfor supervisor placement. See
evidence/handoff-paths.json.Fixes #238.