Skip to content

Commit 4a6f56a

Browse files
committed
refactor: simplify logging messages and remove unused code
- In chat service, reduced verbosity in log messages by removing server/prompt_name and filename details to streamline output. - Removed unused response variable assignment in websocket endpoint. - Eliminated unused Filter icon import from frontend component.
1 parent 0958210 commit 4a6f56a

File tree

3 files changed

+3
-6
lines changed

3 files changed

+3
-6
lines changed

backend/application/chat/service.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -219,9 +219,7 @@ async def handle_chat_message(
219219
# Prepend as system message override
220220
messages = [{"role": "system", "content": prompt_text}] + messages
221221
logger.info(
222-
"Applied MCP system prompt override from %s:%s (len=%d)",
223-
server,
224-
prompt_name,
222+
"Applied MCP system prompt override (len=%d)",
225223
len(prompt_text),
226224
)
227225
break # apply only one
@@ -378,7 +376,7 @@ async def handle_attach_file(
378376
update_callback=update_callback
379377
)
380378

381-
logger.info(f"Attached file {filename} ({s3_key}) to session {session_id}")
379+
logger.info(f"Attached file ({s3_key}) to session {session_id}")
382380

383381
return {
384382
"type": "file_attach",

backend/main.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -226,7 +226,7 @@ async def websocket_endpoint(websocket: WebSocket):
226226
if message_type == "chat":
227227
# Handle chat message with streaming updates
228228
try:
229-
response = await chat_service.handle_chat_message(
229+
await chat_service.handle_chat_message(
230230
session_id=session_id,
231231
content=data.get("content", ""),
232232
model=data.get("model", ""),

frontend/src/components/AllFilesView.jsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ import {
1111
Search,
1212
SortAsc,
1313
SortDesc,
14-
Filter,
1514
Loader
1615
} from 'lucide-react'
1716
import { useChat } from '../contexts/ChatContext'

0 commit comments

Comments
 (0)