Butterfly
Butterfly copied to clipboard
[Bug]: Add option to change data directory on android
What happened?
When adding a default local connection, I exit the app and then start it to receive this message: FileSystemException: Creation failed, path = 'content:' (OS Error: Read-only file system, errno = 30
I also cannot seem to save anything to the connection.
Path: content://com.android.externalstorage.documents/tree/primary%3AButterfly
Same result on two Android systems: GrapheneOS (Android 14) Samsung Galaxy S21 FE 5G (Android 13)
Version
2.0.1-rc.0
Platform
Android
Relevant log output
No response
Code of Conduct
- [X] I agree to follow this project's Code of Conduct
Bug confirmed. I will look at it
Hmm, I use the file_selector package that uses the OPEN_DIR intent to access the folder. Seems like the new android 11 storage system does not work good with it... If anyone wants to help feel free to make a pull request
I researched a bit and the problem is: the getDirectoryPath function gives me a content uri instead of a path and dart cannot work with uris and only with paths. But I have currently no solution how to fix this. if anyone has more information regarding this, feel free to add a comment here
I created an issue on the flutter repository: https://github.com/flutter/flutter/issues/141250. After this is closed I will reenable this feature in the android version
The time has come... The issue was closed in the library. I will reenable this feature for android in the 2.1.0-rc.1 update 🎉
Fixed in 2.1.0-rc.1