You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The line above the initialization of client_per_request we assign the Bolt app logger to the context of the request, from my perspective it makes sense to have a logger for Bolt and another for the WebClient since they are separate libraries 🤔 (slack-bolt, slack-sdk), what would be you expected behavior and why?
You are right they are separate libraries, but this particular WebClient is an internal resource created & owned by Slack Bolt. If I configure a custom logger while setting up Slack Bolt, I expect this custom logger to be propagated to every resource that Slack Bolt creates internally.
In my particular use-case, I want to customize all Slack-related loggers to include a prefix ([slack]). This expectation extends to the logger used by the WebClient too, since its an internal resource.
I searched the docs for a way to achieve this but found none. I noticed in some places Bolt tries to propagate the logger, eg.:
Bolt is creating a
WebClient
instance for each request its handling here:bolt-python/slack_bolt/app/app.py
Line 1376 in 3ad0788
It does not pass the
logger
param.This means that all requests that are logged by that client won't use the logger provided to the App.
The text was updated successfully, but these errors were encountered: