ndahlquist / stable-horde-flutter

An Android+iOS app for the Stable Horde
https://stablehorde.net
GNU General Public License v3.0
53 stars 20 forks source link

FileSystemException: Creation failed, path = '/sdcard/Pictures/stable-diffusion' (OS Error: Permi... #122

Closed sentry-io[bot] closed 1 year ago

sentry-io[bot] commented 1 year ago

Sentry Issue: STABLE-HORDE-FLUTTER-3R

OSError: OS Error: Permission denied, errno = 13
FileSystemException: FileSystemException: Creation failed, path = '/sdcard/Pictures/stable-diffusion' (OS Error: Permission denied, errno = 13)
  File "tasks_bloc.dart", line 271, in _TasksBloc._retrieveTaskResult
  File "tasks_bloc.dart", line 301, in _TasksBloc._waitOnTask
...
(2 additional frame(s) were not displayed)
ndahlquist commented 1 year ago

This happens only on Android 10. Not sure why; the logic at https://github.com/ndahlquist/stable-horde-flutter/blob/main/lib/blocs/shared_prefs_bloc.dart#L176 looks correct to me?

This should be non-fatal: the images should still be generated, but they won't get saved to the filesystem.

@Khosbayar: might help to get your eyes on this when you get a chance.

evguu commented 1 year ago

It seems like it's a feature gap. The only semi-working solution I've found is to save images to Android/package>/data/files directory - at least it's accessible to end-user from there...