-
Notifications
You must be signed in to change notification settings - Fork 238
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug on Flutter Web #242
Comments
i've got the same issue, looking for help. |
@phonghoang2k if you find any answer, please tell me |
Can you give me some details to help make this reproducible?
|
Please check this issue. I got all when start listening. |
Thanks, I've reproduced it, looking for a cause now. |
As far as I can tell something has gone wrong with the Flutter JS binding for the speech recognition API. This definitely used to work in previous Flutter versions. I just filed an issue with the Flutter team hoping they can give me some guidance. The issue is here flutter/flutter#86621. Feel free to upvote if this is causing you problems. |
For those following along here the bug has been accepted by the initial review as a regression in Flutter, see the issue linked above. If you need Web support for speech recognition currently you'll need to stick with Flutter 2.0.6 or before. I'm hopeful that a patch to the 2.2.x series will fix the regression but I have no idea how quickly regressions are addressed. |
BTW https://github.com/csdcorp/speech_to_text/tree/main/multi_platform_example works with Flutter 2.2.3 in my Chrome web browser. But if I create a new flutter project and copy Here is my
|
Thanks @proddam I'm not sure what's going on, I am pretty sure I had reproduced the failure in that app previously. However, I just tried it expecting to find that it fails and I am very surprised that it worked for me as well. The only difference I can think of right now is that |
@sowens-csd any update? |
i encountered this bug at localhost. Then i deploy and bug is fixed :)) |
For me it continues not working @tuanduy183 |
I just tried it once and nothing can be done. What is your version? |
Same probleme here, a fix would be very welcome :) |
Sorry folks, the issue remains open on the Flutter issue list. They seem to have identified the exact commit that introduced the problem but I see nothing that would indicate that a fix is even available in a patch yet. That's pretty bad given that the issue was identified back in July and they agreed that it's a clear regression. Because Flutter has mapped all of the speech APIs for the web they have to be the ones that resolve it. |
Finally some good news on this. The Flutter team has suggested a work around for the issue. I've just committed a possible fix. This is working in the example app on Chrome. If anyone else could try this fix out in other environments and in their owns apps that would be very helpful. Once we confirm this is working I'll push an update to pub.dev. |
5.3.0 is now on pub.dev. I'm going to close this, mostly so I get a feeling of accomplishment. If anyone has issues with the web please open a new issue. |
TypeError: result[$item] is not a function
at speech_to_text_web.SpeechToTextPlugin.new.[_onResult] (http://localhost:57473/packages/speech_to_text/speech_to_text_web.dart.lib.js:143:36)
at http://localhost:57473/packages/speech_to_text/speech_to_text_web.dart.lib.js:97:98
at Object._checkAndCall (http://localhost:57473/dart_sdk.js:5246:16)
at Object.dcall (http://localhost:57473/dart_sdk.js:5251:17)
at SpeechRecognition. (http://localhost:57473/dart_sdk.js:100646:100)
The text was updated successfully, but these errors were encountered: