Skip to content
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

Audioplayers MissingPluginException #420

Open
Winterteq opened this issue May 17, 2024 · 1 comment
Open

Audioplayers MissingPluginException #420

Winterteq opened this issue May 17, 2024 · 1 comment

Comments

@Winterteq
Copy link

Hey!

flutter-pi for the most part has worked great for my app. it seems to be running (albeit a little slow because of my old RPI3!).

However I am using the audioplayers package on my app - it works fine when I run on my windows machine, but when I build on WSL and move the bundle across to my rpi and run with flutter-pi I get the following error:

[ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: MissingPluginException(No implementation found for method create on channel xyz.luan/audioplayers) #0 MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:332:7) <asynchronous suspension> #1 AudioplayersPlatform.create (package:audioplayers_platform_interface/src/audioplayers_platform.dart:18.5) <asynchronous suspension> #2 AudioPlayer._create (package:audioplayers/src/audioplayer.dart:161:7) <asynchronous suspension>

To confirm the steps I have taken is:

  1. Developed functioning app on Windows dev machine using libraries that all support linux.
  2. Used WSL with latest flutter stable build to build the code using flutter build bundle
  3. Transferred the assets from the "build" folder in my project over to my raspberry pi
  4. used "flutter-pi build

The app runs and appears on the screen, but the features requiring the audioplayers app are throwing this error.

any help would be appreciated!

@HSVDO
Copy link

HSVDO commented May 30, 2024

Hi,

I ran into this problem, too.

In addition to the points mentioned above:

I followed the instructions given in the readme and verified the audio setup using gst-launch-1.0 -v playbin uri=file:///home/pi/my_apps_flutter_assets/assets/path_to_audio.mp3.

Using gst-launch everything works fine and the audiofiles are played as expected.

I tried both audioplayers versions: ^5.0.0 and ^6.0.0 with the same error.

Any ideas on how to fix this would be appreciated :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants