generated from deepgram/oss-repo-template
-
Notifications
You must be signed in to change notification settings - Fork 104
Closed
Description
What is the current behavior?
You get an exception when you send clear message due to accessing an undefined variable while logging.
Exception:
"description": "Exception in AsyncSpeakWebSocketClient._process_text",
"message": "cannot access local variable 'meta_result' where it is not associated with a value",
problematic line in Async Client here.
case SpeakWebSocketEvents.Cleared:
clear_result: ClearedResponse = ClearedResponse.from_json(message)
self._logger.verbose("ClearedResponse: %s", meta_result)
await self._emit(
SpeakWebSocketEvents(SpeakWebSocketEvents.Cleared),
cleared=clear_result,
**dict(cast(Dict[Any, Any], self._kwargs)),
problematic line in Client here
case SpeakWebSocketEvents.Cleared:
clear_result: ClearedResponse = ClearedResponse.from_json(message)
self._logger.verbose("ClearedResponse: %s", meta_result)
self._emit(
SpeakWebSocketEvents(SpeakWebSocketEvents.Cleared),
cleared=clear_result,
**dict(cast(Dict[Any, Any], self._kwargs)),
Expected behavior
...
clear_result: ClearedResponse = ClearedResponse.from_json(message)
self._logger.verbose("ClearedResponse: %s", clear_result)
...
davidvonthenen
Metadata
Metadata
Assignees
Labels
No labels