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

IllegalArgumentsException: Empty Storage ID #116

Closed
Shashank066 opened this issue Apr 9, 2023 · 4 comments
Closed

IllegalArgumentsException: Empty Storage ID #116

Shashank066 opened this issue Apr 9, 2023 · 4 comments
Labels
bug Something isn't working

Comments

@Shashank066
Copy link

Shashank066 commented Apr 9, 2023

FileFullPath.kt line 115


Fatal Exception: java.lang.IllegalArgumentException: Empty storage ID
       at com.anggrayudi.storage.file.FileFullPath.checkIfStorageIdIsAccessibleInSafSelector(FileFullPath.kt:115)
       at com.anggrayudi.storage.SimpleStorage.requestStorageAccess(SimpleStorage.kt:156)
       at com.anggrayudi.storage.SimpleStorageHelper.requestStorageAccess(SimpleStorageHelper.kt:353)
       at com.anggrayudi.storage.SimpleStorageHelper.requestStorageAccess$default(SimpleStorageHelper.kt:345)
       at com.anggrayudi.storage.SimpleStorageHelper.requestStorageAccess(SimpleStorageHelper.kt:8)

One of the user is getting this crash on Android 9. The Storage is located on SD card.

@anggrayudi
Copy link
Owner

Probably this is because the user uses : special character in his file/folder. Maybe I need to replace the current logic from substring the SD card ID to regex extraction for more accurate results.

@anggrayudi anggrayudi added the bug Something isn't working label Apr 9, 2023
@Shashank066
Copy link
Author

If any additional logging can be helpful, I can ask the user for installing custom apk.

@anggrayudi
Copy link
Owner

Put logs wherever you construct FileFullPath() object. That will be really helpful.

@Shashank066
Copy link
Author

The issue was empty path being passed to FileFullPath() in a specific case.

anggrayudi added a commit that referenced this issue Jun 16, 2023
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