GithubHelp home page GithubHelp logo

Comments (6)

sowens-csd avatar sowens-csd commented on September 17, 2024

Thanks for the very thorough problem report. That's an interesting issue. I wonder if I'm leaking channels.

  1. Does the application use any other sound input, like WebRTC, sound recorder, etc?
  2. Do you have any idea how many sound recognition sessions did/could happen during the 10-15 minute period?
  3. Can you reproduce the problem?

from speech_to_text.

kakobayashi avatar kakobayashi commented on September 17, 2024

Thank you for your reply.

  1. My application includes the record package.

  2. I will add the logs in my app and check it. I am also asking the user who is getting this error.

  3. I have tried my iPhone15 Pro and could not get it to occur.
    However, I can confirm that it is occurring on the iPhone15 Pro on Crashlytics.
    I don't think it is a device issue.


Here is what I have tried to do

  1. The error did not change when AudioSession was regenerated when channelCount was 0, as shown below.
    https://github.com/kakobayashi/speech_to_text/blob/v6.4.1/autoPunctuation/speech_to_text/ios/Classes/SwiftSpeechToTextPlugin.swift#L397

  2. I have removed the "Not enough available inputs." error throw process so that the details of the error can be checked on the Flutter side, as shown below.
    https://github.com/kakobayashi/speech_to_text/blob/v6.4.1/autoPunctuation_v4/speech_to_text/ios/Classes/SwiftSpeechToTextPlugin.swift#L451-L452

I have checked the following logs

SpeechRecognitionError msg: error_listen_failed, permanent: true, detail: Error Domain=Try Code=1 "(null)" UserInfo={exception=required condition is false: IsFormatSampleRateAndChannelCountValid(hwFormat)} 0 48000.0

The audioSession.sampleRate was confirmed only at 48000.
I have confirmed over 100 cases at 48000, but not occurring at other times.

I tried setting sampleRate to 48000 as shown below, but this did not fix this error.

      await _speechToText.listen(
        localeId: localeId,
        listenMode: ListenMode.dictation,
        onDevice: false,
        onResult: onResult,
        sampleRate: 48000,  // add
      );

from speech_to_text.

sowens-csd avatar sowens-csd commented on September 17, 2024

My first thought, since you're also using the record package in the app, is that the microphone is in use at the time STT is trying to install the tap. I don't know whether in your app it would be possible for the user to not enable or at least not use the record functionality and see if they can still reproduce the issue? If not perhaps you could get them on TestFlight and get them a version that allows for that test?

from speech_to_text.

kakobayashi avatar kakobayashi commented on September 17, 2024

I can ask the user who is experiencing this error to test the app without the record package for testing.
I will try to distribute the app to this user on TestFlight.

Thank you.

from speech_to_text.

kakobayashi avatar kakobayashi commented on September 17, 2024

I distributed the app on TestFlight with the Record package removed.
However, that app is getting the same error.
I would like to know if you have any other thoughts.

from speech_to_text.

kakobayashi avatar kakobayashi commented on September 17, 2024

This error was occurring when the interstitial ads were not disposed properly.
Thank you very much.

from speech_to_text.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.