fix maybe

This commit is contained in:
Rudis Muiznieks 2025-04-02 17:16:27 -05:00
parent 81270377c9
commit b01443815c
Signed by: rudism
GPG key ID: CABF2F86EF7884F9
2 changed files with 3 additions and 3 deletions

View file

@ -41,7 +41,7 @@ class KagiSkill(FallbackSkill):
'Accept': 'text/event-stream',
'cookie': f'kagi_session={session_cookie}'
}
read_url = f'https://kagi.com/stream_fastgpt?query={quote_plus(message.data.get('utterance'))}'
read_url = f"https://kagi.com/stream_fastgpt?query={quote_plus(message.data.get('utterance'))}"
try:
client = sseclient.SSEClient(read_url,
headers=header_content,
@ -49,7 +49,7 @@ class KagiSkill(FallbackSkill):
dirty_response = None
for event in client:
if event.data == '"[DONE]"':
break;
break
dirty_response = event.data
if dirty_response is None:
self.log.error('bad session response from kagi')

View file

@ -4,7 +4,7 @@ import os
from os import walk, path
PYPI_NAME = "skill-ovos-fallback-kagi" # pip install PYPI_NAME
VERSION = "0.1.1"
VERSION = "0.1.2"
URL = f"https://code.sitosis.com/rudism/{PYPI_NAME}"
SKILL_CLAZZ = "KagiSkill" # needs to match __init__.py class name