Skip to content

Ignore unknown sys.argv #404

@isc-psulin

Description

@isc-psulin

I really like the ability to override args from my config from the cli, but it breaks a lot of other things that also rely on sys.argv like pytest and uvicorn. I have tried setting cli_exit_on_error=False, but it doesn't seem to stop it from blowing up with args that are not declared in the model if I have cli_parse_args=True.

How can I have it just ignore args it does not know so I can use it with pytest, uvicorn, etc...?

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions