Tau: [BUG]: IOS can't register flutterSoundPlayerManager or flutterSoundRecorderManager

Created on 9 Mar 2021  路  5Comments  路  Source: Canardoux/tau

Flutter Sound Version : ^7.7.0+1

  • FULL or LITE flavor ? FULL

  • Important: Result of the command : flutter pub deps | grep flutter_sound

image


Severity

Crash ? It crashes every time I try to initialize player or recorder. In the console is being triggered the follow messages:

  • ERROR during registerWithRegistrar: flutterSoundPlayerManager != nil
  • ERROR during registerWithRegistrar: flutterSoundRecorderManager != nil

Platforms you faced the error

  • iOS ? It happens on iOS Emulator

Describe the bug
It is failing at registering the plugin for ios, it gets the follow messages in console:
ERROR during registerWithRegistrar: flutterSoundPlayerManager != nil
ERROR during registerWithRegistrar: flutterSoundRecorderManager != nil

The app builds and runs well, but when I try to initialize the player or the recorder, it crashes.

Logs!!!!

(This is very important. Most of the time we cannot do anything if we do not have information on your bug)
At the beginning it throws the follow messages:

  • ERROR during registerWithRegistrar: flutterSoundPlayerManager != nil
  • ERROR during registerWithRegistrar: flutterSoundRecorderManager != nil

When I try to initialize the recorder or player it throws:

  • flutter: FS:---> openAudioSession
  • flutter: ---> openAudioSession
  • flutter: Resetting flutter_sound Recorder Plugin
  • @resetPlugin
  • iOS: ---> resetPlugin
  • iOS: <--- resetPlugin

Then It crashes

maybe bug Not yet handled

Most helpful comment

I am getting the same logs:

flutter: FS:---> openAudioSession
flutter: ---> openAudioSession
flutter: Resetting flutter_sound Recorder Plugin
@resetPlugin
iOS: ---> resetPlugin
iOS: <--- resetPlugin

As soon as it hits the line

await _mRecorder.openAudioSession();

I followed the simple_recorder.dart example in ^7.7.0.

All 5 comments

I am getting the same logs:

flutter: FS:---> openAudioSession
flutter: ---> openAudioSession
flutter: Resetting flutter_sound Recorder Plugin
@resetPlugin
iOS: ---> resetPlugin
iOS: <--- resetPlugin

As soon as it hits the line

await _mRecorder.openAudioSession();

I followed the simple_recorder.dart example in ^7.7.0.

I am facing the same error in our project, any help @jordygarcias

Hi same error here, and it crashes.

Not always though.

I have an app that can play audio with the use of just_audio_plugin and audio_service plugin.

I use flutter_sound for recording.

If I launch my app, and directly start recording no problem at all.

But if I play any audio before I start recording (wether I stop the audio or not prior to recording doesn't change anything), then it crashes.

I'm using flutter_sound_lite last version (8.1.1).

Some more information:

it seems to be linked to just_audio.

Each time I play an audio with just_audio I get these messages in the console:

ERROR during registerWithRegistrar: flutterSoundPlayerManager != nil
ERROR during registerWithRegistrar: flutterSoundRecorderManager != nil

The audio plays fine though, but after that when I try to record, when I call openAudioSession, it crashes.

I tried to replace just_audio_plugin with flutter_sound for playing sound and avoid this conflict but just_audio_plugin has many features that are not part of flutter_sound, and that I need.

The main problem is that when I try to play an audio from internet, the latency before I can hear a sound is important. It seems that flutter_sound is downloading the entire file before playing it.

With just_audio, the file is buffered and can be played during its download. For big files (2 hours podcast for instance) it means that we can listen to the audio a few seconds after clicking play, while with flutter_sound we may wait for a long time.

Another problem is that flutter_sound doesn't support changing the playback speed.

Flutter Sound 8.1.4 is released and integrates a Pull Request kindly provided by @touficzayed .

Was this page helpful?
0 / 5 - 0 ratings

Related issues

xia-weiyang picture xia-weiyang  路  6Comments

palfrey picture palfrey  路  3Comments

gtilson picture gtilson  路  5Comments

deepbluev7 picture deepbluev7  路  5Comments

farrelanelca picture farrelanelca  路  5Comments