mirror of
https://github.com/BerriAI/litellm.git
synced 2025-04-27 11:43:54 +00:00
v0 proxy logger
This commit is contained in:
parent
46d2ff4606
commit
0a5f8d564b
2 changed files with 13 additions and 0 deletions
|
@ -1,3 +1,5 @@
|
||||||
|
import logging
|
||||||
|
|
||||||
set_verbose = False
|
set_verbose = False
|
||||||
|
|
||||||
|
|
||||||
|
@ -7,3 +9,8 @@ def print_verbose(print_statement):
|
||||||
print(print_statement) # noqa
|
print(print_statement) # noqa
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
logging.basicConfig(level=logging.INFO)
|
||||||
|
# Create a custom logger for "debug-proxy"
|
||||||
|
debug_proxy_logger = logging.getLogger("LiteLLM Proxy")
|
||||||
|
|
|
@ -19,6 +19,7 @@ try:
|
||||||
import backoff
|
import backoff
|
||||||
import yaml
|
import yaml
|
||||||
import orjson
|
import orjson
|
||||||
|
import logging
|
||||||
except ImportError as e:
|
except ImportError as e:
|
||||||
raise ImportError(f"Missing dependency {e}. Run `pip install 'litellm[proxy]'`")
|
raise ImportError(f"Missing dependency {e}. Run `pip install 'litellm[proxy]'`")
|
||||||
|
|
||||||
|
@ -153,6 +154,11 @@ proxy_logging_obj = ProxyLogging(user_api_key_cache=user_api_key_cache)
|
||||||
async_result = None
|
async_result = None
|
||||||
celery_app_conn = None
|
celery_app_conn = None
|
||||||
celery_fn = None # Redis Queue for handling requests
|
celery_fn = None # Redis Queue for handling requests
|
||||||
|
### logger ###
|
||||||
|
# Configure the logging settings (you can customize this based on your needs)
|
||||||
|
logging.basicConfig(level=logging.INFO)
|
||||||
|
# Create a custom logger for "debug-proxy"
|
||||||
|
debug_proxy_logger = logging.getLogger("LiteLLM Proxy")
|
||||||
|
|
||||||
|
|
||||||
#### HELPER FUNCTIONS ####
|
#### HELPER FUNCTIONS ####
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue