From e2c910fc50e1de9503eaef0a7607c683dfbcf276 Mon Sep 17 00:00:00 2001 From: Omer Tuchfeld Date: Thu, 14 Aug 2025 13:43:30 +0200 Subject: [PATCH] fix: streaming_query: empty conversation ID The query endpoint would treat an empty conversation ID as not provided, but the streaming query endpoint would treat it as if it were an ID (which doesn't belong to anyone, so it would fail). Align the behavior of the streaming query endpoint with the query endpoint, so when users provide a "conversation_id" with an empty string, it will be as if they didn't provide it at all. --- src/app/endpoints/streaming_query.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app/endpoints/streaming_query.py b/src/app/endpoints/streaming_query.py index 206b82358..8b00ef61f 100644 --- a/src/app/endpoints/streaming_query.py +++ b/src/app/endpoints/streaming_query.py @@ -399,7 +399,7 @@ async def streaming_query_endpoint_handler( # pylint: disable=too-many-locals user_id, _user_name, token = auth user_conversation: UserConversation | None = None - if query_request.conversation_id is not None: + if query_request.conversation_id: user_conversation = validate_conversation_ownership( user_id=user_id, conversation_id=query_request.conversation_id )