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
I work with pytest and logging quite a bit, it would be nice to have a function tee-fd that's similar to the tee-sys function for pytest. When I use the logging module, and want more granular control over logging, I usually have propagate set to False, and the logs gets outputted to capfd instead of capsys.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I work with pytest and logging quite a bit, it would be nice to have a function
tee-fd
that's similar to thetee-sys
function for pytest. When I use the logging module, and want more granular control over logging, I usually havepropagate
set toFalse
, and the logs gets outputted tocapfd
instead ofcapsys
.So for example:
I would like to have
capfd
to capture theDebug Message
as well as have it outputted real time to console.Beta Was this translation helpful? Give feedback.
All reactions