Repository navigation
Fix pytest completion list separators - #1287
Merged
Merged
Conversation
Semicolons silently omit the second choice on Nu 0.115.1 and fail parsing on Nu 0.116.1. Use comma-separated lists and cover both providers and actual command-line completion values. Validated module parsing, standalone assertions and toolkit check pr on both Nushell versions.
Contributor
|
Thanks |
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.
Summary
Two pytest completion providers use semicolons inside list literals. On Nu 0.115.1 this silently returns only the first value; on Nu 0.116.1 importing the completion module fails with
Unexpected semicolon in list. Replace those separators with commas, matching the neighboring providers, and add a standalone regression that sources the real completion file and checks the intended values.Evidence
On native x86_64 Linux, using Nu 0.115.1 and 0.116.1:
[w]instead of[w, a]and completion omitsa; assertion completion similarly omitsrewrite. On 0.116.1 importing the original file fails at the semicolon.commandline complete --detailedresults include all intended values.nu --no-config-file --commands 'use toolkit.nu; toolkit check pr --and-exit'passes on both versions.nu --no-config-file custom-completions/pytest/tests/pytest-completions.nupasses on both versions.The regression script is run explicitly:
toolkit testis currently a stub, so a successfultoolkit check pralone does not prove the assertions executed.Assistance: OpenAI Codex implemented the change and regression, ran the recorded checks, and drafted this description.
Merge Danger
Door: two-way. Blast Radius: pytest completions. No pytest invocation or option semantics change; the providers return the same intended values.