HMS-Core / hms-flutter-plugin

This repo contains all of Flutter HMS plugins.
https://developer.huawei.com/consumer/en/doc/overview/HMS-Core-Plugin?ha_source=hms1
Apache License 2.0
284 stars 140 forks source link

ml机器学习插件语音转文字错误 #106

Closed tygm closed 3 years ago

tygm commented 3 years ago

Description 华为机器没问题 非华为机器(oppo),不管装不装hms core,在调用语音转文字的时候,总是提示“服务不可用”,并有log报错。如下。根据官网错误码信息,11203是网络问题,但实际上网络没问题(确定)

Expected behavior 正常进行语音转文字

Current behavior 不正常,如上

Screenshots If applicable, add screenshots to help explain your issue

Logs I/MLASR_EmuiUtil(29607): Get Manufacturer: OPPO E/MLASR_AsrEngine(29607): not HuaWei phone and not Emui E/AsrProcessor(29607): onError code : 11203, message : 3016, not HuaWei phone and not Emui E/flutter (29607): [ERROR:flutter/lib/ui/ui_dart_state.cc(199)] Unhandled Exception: PlatformException(AsrMethodHandler, not HuaWei phone and not Emui, 112033016, null)

Environment

Other Add any other context about the problem here

sinan-aktepe commented 3 years ago

Hi @tygm , We have spotted the issue and it'll be fixed on our next release. For now, you can use this workaround to get asr service working:

After applying the changes, the service should work as expected.