We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b52b0d2 commit f59e4b1Copy full SHA for f59e4b1
src/diffusers/utils/logging.py
@@ -82,7 +82,9 @@ def _configure_library_root_logger() -> None:
82
# This library has already configured the library root logger.
83
return
84
_default_handler = logging.StreamHandler() # Set sys.stderr as stream.
85
- _default_handler.flush = sys.stderr.flush
+
86
+ if sys.stderr: # only if sys.stderr exists, e.g. when not using pythonw in windows
87
+ _default_handler.flush = sys.stderr.flush
88
89
# Apply our default configuration to the library root logger.
90
library_root_logger = _get_library_root_logger()
0 commit comments