-
Notifications
You must be signed in to change notification settings - Fork 260
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add use_env_var flag to client #923
Conversation
Signed-off-by: Jun Ki Min <[email protected]>
Signed-off-by: Jun Ki Min <[email protected]>
Signed-off-by: Jun Ki Min <[email protected]>
Signed-off-by: Jun Ki Min <[email protected]>
Signed-off-by: Jun Ki Min <[email protected]>
Signed-off-by: Jun Ki Min <[email protected]>
Signed-off-by: Jun Ki Min <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The enhancement looks reasonable. It will be better if we could make _EnvVariableUtil less complex.
Hello @loomlike seems this doc should get updated as well https://feathr-ai.github.io/feathr/how-to-guides/feathr-configuration-and-env.html#configuration-and-environment-variables-in-feathr Can I ask is there any use case for introducing this new env? Have this new flag can make configuration more flexible but it introduces complexity on configuration code as well. |
The default behavior is to override the config file values ( |
Signed-off-by: Jun Ki Min <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks nice to me! Thanks for the changes.
Please also change the file names envvariableutil.py
& test_envvariableutil.py
to fit the new class name.
Signed-off-by: Jun Ki Min <[email protected]>
Signed-off-by: Jun Ki Min <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for making the changes and addressing the comments.
Signed-off-by: Jun Ki Min [email protected]
Description
Introduce an option to select between env vars and config yaml file.
Feathr client to use explicitly configured yaml file over environment variable if
use_env_var
flag is set to False.The changes are added as the last argument of the existing functions and set default to True (use env variables) so that
existing codes don't break.
Resolves #922
How was this PR tested?
Unit test
Does this PR introduce any user-facing changes?