-
Notifications
You must be signed in to change notification settings - Fork 104
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
Improve logging in python worker #637
Conversation
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 good. Please do test E2E via private site extension and verify logs in kusto to ensure we see expected logs
logging_handler = AsyncLoggingHandler() | ||
root_logger = logging.getLogger() | ||
root_logger.setLevel(logging.INFO) | ||
root_logger.addHandler(logging_handler) | ||
|
||
# Since gRPC channel is established, should use it for logging | ||
disable_console_logging() |
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.
What happens to console logs from user code? We still need to flow them as console logs. Can you please test it?
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.
Oh, I thought the host will log all messages coming from gRPC channel. For sure, I will test it
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.
Yes. Host logs RpcLog messages coming via gRpc. Just to be safe test with a function that logs to console
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.
@pragnagopa Testing on my local dev environment, console log (e.g. print()) flows through.
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.
👍
Fixes
resolves: #635
resolves: #634
resolves: #580
Context
Miscellaneous