voice icon indicating copy to clipboard operation
voice copied to clipboard

[URGENT!] App under iOS <14.0 crashes on Voice.start()

Open MedRedha opened this issue 4 years ago • 20 comments

Greetings beautiful people,

I'm having a big issue if someone can help me please 🙏 the package works perfectly under iOS >14.0 but immediately crashes when I try to build on an inferior one (i.e. 13.6). I tried my best to debug it and here's what I'm getting from xCode console :

2021-01-27 14:45:44.620057+0100 LegalDoctrineAlpha[75986:1310434] [aqme] AQME.h:254:IOProcFailure: AQDefaultDevice (1): output stream 0: null buffer 2021-01-27 14:45:44.620305+0100 LegalDoctrineAlpha[75986:1310434] [aqme] AQMEIO_HAL.cpp:1774:IOProc: EXCEPTION thrown (-50): error != 0

and here is a screenshot of the line pointing to it. image_2021-01-27_145143

image_2021-01-27_145309

MedRedha avatar Jan 27 '21 13:01 MedRedha

yo, face the same issue... Did u find any solution?

YesSkyscrapers avatar Feb 01 '21 21:02 YesSkyscrapers

yo, face the same issue... Did u find any solution?

Not yet bro 😞 I disabled the mic button for iOS <14.0 waiting for a fix or something

MedRedha avatar Feb 01 '21 21:02 MedRedha

Hey man! The problem was unexpected for me, cuz it worked perfectly just a week ago... I almost believed it happened cuz of MacOS's update to Big Sur, but today a little trick was able to fix everything... I was compiling the release via the command line, when the iPhone XR simulator was selected in xcode...

Снимок экрана 2021-02-02 в 11 19 46

I looked at the simulator's ios version... there was ios 12.0...

Снимок экрана 2021-02-02 в 10 56 32

Then I added the same iPhone but with the latest version of iOS 14.4. I selected new simulator and built it to check that the bug doesn't reproduce (cuz ios >=14)...

Снимок экрана 2021-02-02 в 11 19 01

After that, I repeated build through the command line.... The bug wasn't reproduced on any of the phones where it was reproduced recently, namely: 5S iOS 12.0 XR iOS 14.3 SE1 iOS 13.7

Idk how it relates, but the bug isn't reproduced now...

YesSkyscrapers avatar Feb 02 '21 08:02 YesSkyscrapers

I tried the same steps with @YesSkyscrapers but no luck at all...

Still having a crash same as @MedRedha mentioned under iOS 14.x

Any different workaround or fixes would be perfect. I could not make that function work under iOS 14.x both on emulator and real device.

Hm is there any documentation referencing a change to these libraries for iOS 14?

safaiyeh avatar Feb 20 '21 07:02 safaiyeh

Hm is there any documentation referencing a change to these libraries for iOS 14?

Precisely! I checked everywhere and nothing!! There is no reason for the package or for the usage of the speech recognition to crash or bug and that's what is weird 😞

MedRedha avatar Feb 28 '21 11:02 MedRedha

@MedRedha Could you create a small demo app with the latest version of voice and RN so I could check it out and debug it.

safaiyeh avatar Mar 02 '21 05:03 safaiyeh

I have the same problem but only if connect the ios earphones, has anyone found a solution?

josemojena avatar Apr 01 '21 20:04 josemojena

I have the same problem but only if connect the ios earphones, has anyone found a solution?

I've seen this reported a few times where earphones messes things up. https://github.com/react-native-voice/voice/pull/294 is one example. Could you make a separate issue for this?

safaiyeh avatar Apr 02 '21 18:04 safaiyeh

Could be related to this problem

forresthopkinsa avatar May 05 '21 22:05 forresthopkinsa

Hey guys.

I was having the same issue reported here and the only thing that fix this problem was putting the code below in the info.plist file as documented in the installation guide.

<key>NSMicrophoneUsageDescription</key>
<string>Description of why you require the use of the microphone</string>
<key>NSSpeechRecognitionUsageDescription</key>
<string>Description of why you require the use of the speech recognition</string>

rodolfobarretoweb avatar Sep 16 '21 19:09 rodolfobarretoweb

Hey guys.

I was having the same issue reported here and the only thing that fix this problem was putting the code below in the info.plist file as documented in the installation guide.


<key>NSMicrophoneUsageDescription</key>

<string>Description of why you require the use of the microphone</string>

<key>NSSpeechRecognitionUsageDescription</key>

<string>Description of why you require the use of the speech recognition</string>

Thanks a lot buddy! I'm gonna try it and check if it fixes the issue for me as well 🙏

MedRedha avatar Sep 16 '21 19:09 MedRedha

Hey guys. I was having the same issue reported here and the only thing that fix this problem was putting the code below in the info.plist file as documented in the installation guide.


<key>NSMicrophoneUsageDescription</key>

<string>Description of why you require the use of the microphone</string>

<key>NSSpeechRecognitionUsageDescription</key>

<string>Description of why you require the use of the speech recognition</string>

Thanks a lot buddy! I'm gonna try it and check if it fixes the issue for me as well 🙏

Let me know if works for you too.

rodolfobarretoweb avatar Sep 16 '21 19:09 rodolfobarretoweb

yo, i have the same issue... Did u find any solution?

NguyenHieu1011 avatar Oct 14 '21 09:10 NguyenHieu1011

I have the same problem but only if connect the ios earphones, has anyone found a solution?

Check this PR. It resolves this issue. headset and bluetooth crashing issue

DeepakM02 avatar Oct 19 '21 12:10 DeepakM02

@DeepakM02 link is not working. I am also facing this issue. Any solution?

anujmpec avatar Dec 13 '21 08:12 anujmpec

Hey @anujmpec You can check this link now.

DeepakM02 avatar Dec 26 '21 20:12 DeepakM02

@DeepakM02 please share the link.

Anujmoglix avatar Dec 27 '21 05:12 Anujmoglix

@Anujmoglix you can use this https://github.com/react-native-voice/voice/issues/289#issuecomment-946662633

DeepakM02 avatar Jan 03 '22 07:01 DeepakM02

I'm still facing this issue despite using version 3.2.4

samuelzxu avatar Aug 18 '23 16:08 samuelzxu