SimpleStorage: CANNOT_CREATE_FILE_IN_TARGET
If copying the same file to same destionation with
@Override
public void onConflict(@NotNull DocumentFile destinationFile, @NotNull FileCallback.FileConflictAction action) {
action.confirmResolution(ConflictResolution.REPLACE);
}
the app tombstones Works only the first time…
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 76 (28 by maintainers)
Commits related to this issue
- Fix issue #24 — committed to anggrayudi/SimpleStorage by anggrayudi 3 years ago
- Fix issue #24 — committed to anggrayudi/SimpleStorage by anggrayudi 3 years ago
- Fix issue #24 — committed to anggrayudi/SimpleStorage by anggrayudi 3 years ago
- Add isWritable to fix issue #24 — committed to anggrayudi/SimpleStorage by anggrayudi 3 years ago
Normal
moveFileTo()
usesrenameTo()
when possible, but it requires storage access.renameTo()
can move 1GB file in a second when the source and target files are located in the same file partition.0.5.3 has been released. Wait for several minutes until it is available on Maven.
Did not happen after I add this check into
MediaStoreCompat
:Update your snapshots again. BTW, what’s your OS version?
I’ve found the root cause. The fixes will be on v0.5.3. I’ll release it this week.
Put your breakpoint here. Let’s see whether it is triggered: