pydantic / pydantic-settings

Settings management using pydantic
https://docs.pydantic.dev/latest/usage/pydantic_settings/
MIT License
502 stars 47 forks source link

Deprecate `read_env_file` and move it to `DotEnvSettingsSource` #318

Closed WarpedPixel closed 6 days ago

WarpedPixel commented 2 weeks ago

Fixes #296 Adds a method _read_env_file to DotEnvSettingsSource that can be easily overridden. This fix keeps a global function so it can continue to be tested, but adds an underscore to the name. The plain read_env_file is marked as deprecated.

Selected Reviewer: @samuelcolvin

WarpedPixel commented 1 week ago

please review

hramezani commented 6 days ago

Thanks @WarpedPixel