Python function speak_ssml has lost return value
See original GitHub issueDescribe the bug Hi,
I could not find an upstream repo of the azure-cognitiveservices-speech Python package, so I’m reporting it here as it seems to be the closest repository available.
In the version 1.23.0, the function speak_ssml had a return value:
def speak_ssml(self, ssml: str) -> SpeechSynthesisResult:
"""
Performs synthesis on ssml in a blocking (synchronous) mode.
:return: A SpeechSynthesisResult.
"""
return SpeechSynthesisResult(self._impl.speak_ssml(ssml))
In the latest version, 1.24.0, it has lost the return statement (same applies to the speak_text function):
def speak_ssml(self, ssml: str) -> SpeechSynthesisResult:
"""
Performs synthesis on ssml in a blocking (synchronous) mode.
:returns: A SpeechSynthesisResult.
"""
self.speak_ssml_async(ssml).get()
To Reproduce Install packages 1.23.0 and 1.24.0 and see for yourself.
Expected behavior Functions still return values as they claim in the docs comment.
Version of the Cognitive Services Speech SDK 1.24.0
Platform, Operating System, and Programming Language
- Linux
- x64
- Python
Additional context pylint reported this issue after I updated my dependencies:
E1111: Assigning result of a function call, where the function has no return (assignment-from-no-return)
Issue Analytics
- State:
- Created a year ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Return statement in python function not returning anything
You are not receiving the output the function is returning. This will show the result. Functions return a value, so you need to...
Read more >Python return statement
The python return statement is used to return values from the function. We can use the return statement in a function only.
Read more >12.5. Returning a value from a function
All Python functions return the special value None unless there is an explicit return statement with a value other than None . Consider...
Read more >Null in Python: Understanding Python's NoneType Object
None is the value a function returns when there is no return statement in the ... None also often used as a signal...
Read more >What Does Return Minus -1 Do in Python?
If the return value from a function is -1, it holds a special meaning in Python — it usually denotes an error or...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Thanks for pointing this out, it’s being fixed and will be in the next release.
It works! Thanks 😃