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

Plalist fails with local asset files but OK with URL files. #39

Open
mastermeric opened this issue Jun 21, 2024 · 3 comments
Open

Plalist fails with local asset files but OK with URL files. #39

mastermeric opened this issue Jun 21, 2024 · 3 comments
Labels
bug Something isn't working

Comments

@mastermeric
Copy link

mastermeric commented Jun 21, 2024

Which API doesn't behave as documented, and how does it misbehave?
Latest version

Minimal reproduction project

When I use audio files from web, as a playlist with ConcatenatingAudioSource , it is fine. Everything works.
But when I use with local assets instead of web, Progressbar lost its position.

NOTE: This issue never happens on Android but on Windows.

IMPORTANT NOTE !!!
Playing audio is fine, the problem is Progressbar which is properly used from apckage : "audio_video_progress_bar ".
When go next song, progressbar position crashes/frezes . (With signle song it is fine)

NOTE:
I tried ; AudioSource.asset() AND AudioSource.file() ... none of them worked.

// This is OK
final _playList = ConcatenatingAudioSource(
children: [
AudioSource.uri(Uri.parse("http://localhost:5000/song1")),
AudioSource.uri(Uri.parse("http://localhost:5000/song2")),
AudioSource.uri(Uri.parse("http://localhost:5000/song3")),
AudioSource.uri(Uri.parse("http://localhost:5000/song4")),
]);

// This has NOT OK : progressbar lost position and got frozen when hit next song.
final _playList = ConcatenatingAudioSource(
children: [
AudioSource.uri(Uri.parse("asset:///assets/songs/song1.mp3")),
AudioSource.uri(Uri.parse("asset:///assets/songs/song2.mp3")),
AudioSource.uri(Uri.parse("asset:///assets/songs/song3.mp3")),
AudioSource.uri(Uri.parse("asset:///assets/songs/song4.mp3")),
]);

To Reproduce (i.e. user steps, not code)
Only Playlist have issu. Single track is OK.

Error messages
ERROR message :

[just_audio_windows]: Broadcast playback evcent error: Error accessing BufferingProgress. Using default value of 1.

Expected behavior
Smooth pass to next song.

Screenshots
na

Desktop (please complete the following information):
Win 10 Pro

Smartphone (please complete the following information):
na

Flutter SDK version

Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 3.19.5, on Microsoft Windows [Version 10.0.22631.3737], locale en-GB)
[√] Windows Version (Installed version of Windows is version 10 or higher)
[√] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
[√] Chrome - develop for the web
[√] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.7.6)
[√] Android Studio (version 2022.3)
[√] IntelliJ IDEA Community Edition (version 2024.1)
[√] VS Code (version 1.90.2)
[√] Connected device (3 available)
[√] Network resources

Additional context
na

  • OS: Windows 10 Pro

Flutter SDK version
Latest

@mastermeric mastermeric added the bug Something isn't working label Jun 21, 2024
@bdlukaa
Copy link
Owner

bdlukaa commented Jun 21, 2024

On Windows, files use \ instead of /. May that be the cause?

@mastermeric
Copy link
Author

mastermeric commented Jun 21, 2024

No Bruno.. it is vice versa, \ is used for escape characters etc.
Moreover Asset accessiblities are OK. Files are playing fine.
Only the issue when we switch to next song, it craches the progressbar (as a playlist of ConcatenatingAudioSource )

Android has no problem, all playlist running smoothly.
But on Windows , I get error like this :
[just_audio_windows]: Broadcast playback evcent error: Error accessing BufferingProgress. Using default value of 1.

@moha-b moha-b mentioned this issue Sep 16, 2024
@bdlukaa
Copy link
Owner

bdlukaa commented Sep 16, 2024

On my local machine, it is working. No crashes.

Can you run the app with Visual Studio and get the stacktrace from there? Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants