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

fix: Non ASCII characters in the file path #109

Closed
Eliote opened this issue Jul 25, 2024 · 4 comments
Closed

fix: Non ASCII characters in the file path #109

Eliote opened this issue Jul 25, 2024 · 4 comments
Assignees
Labels
bug Something isn't working

Comments

@Eliote
Copy link

Eliote commented Jul 25, 2024

When you try to load a file with a non-ascii character, the lib throws a "file not found" error.
Example:

await SoLoud.instance.loadFile("D:\Motörhead - 01 Ace of Spades.mp3", mode: LoadMode.memory);
ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: SoLoudFileNotFoundException: The file was not found (on the C++ side).
#0      SoLoud.loadFile (package:flutter_soloud/src/soloud.dart:600:7)
<asynchronous suspension>
#1      _MainPageState._loadFile (package:eliote_player/main_page.dart:145:14)
<asynchronous suspension>
#2      _MainPageState._play (package:eliote_player/main_page.dart:274:17)
<asynchronous suspension>

If I change the name of the file to Motorhead - 01 Ace of Spades.mp3 without the ö, it works.
Tested on Windows 11.

@Eliote Eliote added the bug Something isn't working label Jul 25, 2024
@alnitak alnitak self-assigned this Jul 31, 2024
@alnitak
Copy link
Owner

alnitak commented Aug 1, 2024

Seems this was a bug that happens only on Windows.

I have fixed this in the main branch. Please, feel free to close this issue if the fix works for you also.

Thanks for reporting!

@Eliote
Copy link
Author

Eliote commented Aug 2, 2024

That fixed it, thanks!

One thing I notice in the main branch is that when loading some big files (or probably due to slow io) the UI is now freezing. In the version 2.0.2 it worked as expected, the Future just took it's time to complete, without freezing the UI.
Is there something new I need to do/know or should I open another issue?

@alnitak
Copy link
Owner

alnitak commented Aug 2, 2024

One thing I notice in the main branch is that when loading some big files (or probably due to slow io) the UI is now freezing. In the version 2.0.2 it worked as expected, the Future just took it's time to complete, without freezing the UI.
Is there something new I need to do/know or should I open another issue?

Thank you @Eliote, that was a bug. No need for a new issue, I already did PR #113 and merged it if you want to try! Unfortunately on the web, there is still this (known) bug.

@alnitak alnitak closed this as completed Aug 2, 2024
@Eliote
Copy link
Author

Eliote commented Aug 2, 2024

Awesome, thank you!

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