Delete a session and its messages
(self, session_id: str)
| 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.""" |
no test coverage detected