balvinderz/video_player_web_hls

Example not playing on mac

gedw99 opened this issue Β· 2 comments

It opens but when pressing play its a blank white screen.
web and ios works.

I also upgraded the example before and after for the new null safety, but did not help for mac.


flutter run -d macos
Launching lib/main.dart on macOS in debug mode...
Running pod install...                                              3.5s
Building macOS application...                                           
[ERROR:flutter/lib/ui/ui_dart_state.cc(186)] Unhandled Exception: PlatformException(channel-error, Unable to establish connection on channel., null, null)
#0      VideoPlayerApi.initialize (package:video_player_platform_interface/messages.dart:149:7)
<asynchronous suspension>                                               
                                                                        
[ERROR:flutter/lib/ui/ui_dart_state.cc(186)] Unhandled Exception: PlatformException(channel-error, Unable to establish connection on channel., null, null)
#0      VideoPlayerApi.create (package:video_player_platform_interface/messages.dart:174:7)
<asynchronous suspension>                                               
#1      MethodChannelVideoPlayer.create (package:video_player_platform_interface/method_channel_video_player.dart:46:31)
<asynchronous suspension>                                               
#2      VideoPlayerController.initialize (package:video_player/video_player.dart:292:19)
<asynchronous suspension>                                               
#3      _VideoAppState.initState.<anonymous closure> (package:example/main.dart)
<asynchronous suspension>                                               
                                                                        
Syncing files to device macOS...                                 1,279ms

Flutter run key commands.
r Hot reload. πŸ”₯πŸ”₯πŸ”₯
R Hot restart.
h Repeat this help message.
d Detach (terminate "flutter run" but leave application running).
c Clear the screen
q Quit (terminate the application on the device).
An Observatory debugger and profiler on macOS is available at:
http://127.0.0.1:60276/Bhykl2izbxE=/

Flutter DevTools, a Flutter debugger and profiler, on macOS is available at:
http://127.0.0.1:9108?uri=http%3A%2F%2F127.0.0.1%3A60276%2FBhykl2izbxE%3D%2F

πŸ’ͺ Running with sound null safety πŸ’ͺ


flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[βœ“] Flutter (Channel beta, 2.0.1, on macOS 11.2.2 20D80 darwin-x64, locale en-DE)
[βœ—] Android toolchain - develop for Android devices
    βœ— Unable to locate Android SDK.
      Install Android Studio from: https://developer.android.com/studio/index.html
      On first launch it will assist you in installing the Android SDK components.
      (or visit https://flutter.dev/docs/get-started/install/macos#android-setup for detailed
      instructions).
      If the Android SDK has been installed to a custom location, please use
      `flutter config --android-sdk` to update to that location.

[βœ“] Xcode - develop for iOS and macOS
[βœ“] Chrome - develop for the web
[!] Android Studio (not installed)
[βœ“] VS Code (version 1.54.1)
[βœ“] Connected device (3 available)

you are trying to play video on macos which is not supported currently . There is currently an open issue on flutter repository for playing video on macos platform . you can follow that .

flutter/flutter#41688