馃悰 Ensure that the default of a list argument is used correctly - #1821
Merged
Conversation
svlandeg
commented
Jun 2, 2026
| def test_list_empty() -> None: | ||
| result = runner.invoke(app, ["hello-all-args"]) | ||
| assert result.exit_code == 0 | ||
| assert "Hello World!" in result.output |
Member
Author
There was a problem hiding this comment.
Note that it's this particular test that's failing on master, i.e. what this bug fix PR addresses.
svlandeg
marked this pull request as ready for review
June 2, 2026 13:13
tiangolo
approved these changes
Jun 2, 2026
tiangolo
left a comment
Member
There was a problem hiding this comment.
Great, thank you! This will be available in Typer 0.26.6 in a the next few hours. 馃殌
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.
Pull Request
Discussion: #1811, reported by @tchervychek 馃檹
Description
Typer 0.26.0 introduced a regression with respect to using the default of a
Listargument. The only test we had related to this had an envvar setting, obscuring the bug.Commit that caused this issue was attempting to fix things after cleaning up
UNSET: svlandeg@cc485f6 馃槥For good measure, I also added a test for the default of a list option, though this was working fine on
master. Still, can't hurt to extend the test suite a little.AI Disclaimer
Used Cursor for quick diagnostic, but reviewed and written everything myself.
Checklist