Fix some server implementations not properly logging context #933
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
User description
The contextualize method needs to be called on the same thread.
Also added some missing setup_logger invocations.
PR Type
Bug fix, Enhancement
Description
setup_logger
invocation with JSON format and DEBUG level in Azure DevOps and Bitbucket server webhooks.handle_request
method in Azure DevOps, Bitbucket, and GitLab server webhooks to use an inner async function for logging context.Changes walkthrough 📝
azuredevops_server_webhook.py
Fix logging context and add logger setup in Azure DevOps server
webhook
pr_agent/servers/azuredevops_server_webhook.py
setup_logger
invocation with JSON format and DEBUG level.handle_request
to use an inner async function for loggingcontext.
bitbucket_server_webhook.py
Fix logging context and add logger setup in Bitbucket server webhook
pr_agent/servers/bitbucket_server_webhook.py
setup_logger
invocation with JSON format and DEBUG level.handle_request
to use an inner async function for loggingcontext.
gitlab_webhook.py
Fix logging context in GitLab server webhook
pr_agent/servers/gitlab_webhook.py
handle_request
to use an inner async function for loggingcontext.