mirror of
https://github.com/khoaliber/khoj.git
synced 2026-03-05 13:21:18 +00:00
Set default values for sys.stdout if they're unavailable
This commit is contained in:
@@ -2,6 +2,12 @@
|
||||
import os
|
||||
import signal
|
||||
import sys
|
||||
|
||||
if sys.stdout is None:
|
||||
sys.stdout = open(os.devnull, "w")
|
||||
if sys.stderr is None:
|
||||
sys.stderr = open(os.devnull, "w")
|
||||
|
||||
import logging
|
||||
import threading
|
||||
import warnings
|
||||
|
||||
Reference in New Issue
Block a user