This repository has been archived on 2024-10-27. You can view files and clone it, but cannot push or open issues or pull requests.
2024-05-07 09:48:51 -06:00
|
|
|
from llm_server.logging import create_logger
|
|
|
|
|
|
|
|
_logger = create_logger('handle_server_error')
|
|
|
|
|
|
|
|
|
2023-09-12 10:30:45 -06:00
|
|
|
def handle_server_error(e):
|
2024-05-07 09:48:51 -06:00
|
|
|
_logger.error(f'Internal Error: {e}')
|
2023-10-27 19:19:22 -06:00
|
|
|
return {'error': True, 'code': 500, 'message': 'Internal Server Error :('}, 500
|