MCPcopy
hub / github.com/PromtEngineer/localGPT / handle_delete_session

Method handle_delete_session

backend/server.py:647–656  ·  view source on GitHub ↗

Delete a session and its messages

(self, session_id: str)

Source from the content-addressed store, hash-verified

645 return response_text, source_docs
646
647 def handle_delete_session(self, session_id: str):
648 """Delete a session and its messages"""
649 try:
650 deleted = db.delete_session(session_id)
651 if deleted:
652 self.send_json_response({'deleted': deleted})
653 else:
654 self.send_json_response({'error': 'Session not found'}, status_code=404)
655 except Exception as e:
656 self.send_json_response({'error': str(e)}, status_code=500)
657
658 def handle_file_upload(self, session_id: str):
659 """Handle file uploads, save them, and associate with the session."""

Callers 1

do_DELETEMethod · 0.95

Calls 2

send_json_responseMethod · 0.95
delete_sessionMethod · 0.80

Tested by

no test coverage detected