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

Android - Crash after exporting db #6

Closed
Rory-Reid opened this issue Mar 26, 2023 · 5 comments
Closed

Android - Crash after exporting db #6

Rory-Reid opened this issue Mar 26, 2023 · 5 comments
Labels
android A thing that affects android bug Something isn't working

Comments

@Rory-Reid
Copy link
Owner

You can export the database on android but doing so will give you an error telling you to reload the application.

Need to find out why.

@Rory-Reid Rory-Reid added bug Something isn't working android A thing that affects android labels Mar 26, 2023
@Rory-Reid
Copy link
Owner Author

This appears to be an issue in certain circumstances inside of the MAUI Community Toolkit file saver. After saving, it tries to construct the filepath representing where the file was saved to in order to return that value to the calling code, but this path construction logic, for some reason, throws an index out of bounds exception.

I think this happens because it's trying to access a very specific array value in the current path (like index 1 or something) and in some circumstances the current path doesn't have that many parts OR maybe isn't set? I've added a workaround in basemix where we swallow the error (because we don't need the path) - will have to try submit a ticket on the file saver for this before resolving.

@Rory-Reid
Copy link
Owner Author

Resolved with some try/catches, as all good code is.

@Rory-Reid
Copy link
Owner Author

Actually, let's try feed this back into the lib.

@Rory-Reid Rory-Reid reopened this May 16, 2023
@Rory-Reid
Copy link
Owner Author

Might actually be invalidated by whatever we decide to do for #13 - keep an eye on this but it's really low priority.

@Rory-Reid
Copy link
Owner Author

Not using FileSaver to export now

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

No branches or pull requests

1 participant