<#1034 fix: propagate USER_LOG_LEVEL to remote tas...
# flyte-github
a
#1034 fix: propagate USER_LOG_LEVEL to remote task and serve environments Pull request opened by AdilFayyaz Motivation
--user-log-level
affected local initialization only. Remote task containers and app environments fell back to
INFO
because
USER_LOG_LEVEL
was never forwarded in the env setup for
_run_remote
or
_serve_remote
. Additionally, connector code incorrectly imported the public
flyte.logger
instead of the internal one, routing SDK-internal logs through the user-facing logger. Summary of Changes • Add
user_log_level
parameter to
_Runner
,
with_runcontext
,
_Serve
, and `with_servecontext`; emit
USER_LOG_LEVEL
into the remote env alongside
LOG_LEVEL
• Fix
connectors/utils.py
and BigQuery, Databricks, and Snowflake plugin connectors to import from
flyte._logging import logger
instead of from
flyte import logger
, preserving internal log level and
[flyte] prefix
Test Plan • Three new async tests in
tests/flyte/test_serve.py
verify
_serve_remote
sets
USER_LOG_LEVEL
when provided, omits it when None, and that
user_log_level
takes precedence over an explicit value in
env_vars
• Run
uv run pytest tests/flyte/test_serve.py -k user_log_level
to exercise the new cases flyteorg/flyte-sdk