Baseflow / Baseflow/flutter_cache_manager

[Windows] FileSystemException: Cannot delete file

Open
#380 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Dart
Stars
809
Forks
510
Avg merge
6m
Merged PRs (30d)
1

Description

## 🐛 Bug Report
stacktrace like this:
```
FileSystemException: FileSystemException: Cannot delete file, path = 'E:\娱乐\TapBooster\cache\temp\libCachedImageData\e2ac1550-dc22-11ec-a02b-eb8d38960b87.jpg' (OS Error: 另一个程序正在使用此文件,进程无法访问。
, errno = 32)
File "file_impl.dart", line 283, in _File._delete.
File "zone.dart", line 1434, in _rootRunUnary
File ""
File "forwarding_file_system_entity.dart", line 66, in ForwardingFileSystemEntity.delete
File ""
File "web_helper.dart", line 219, in WebHelper._removeOldFile
```

### Expected behavior

Catch exception

**Version:** v3.3.0

**Platform:**
- [ ] 🖥️ Windows

Contributor guide

Open the contributing guide

Research direction

Start in web_helper.dart at line 219, in WebHelper._removeOldFile, and inspect how the file deletion is handled. Reproduce the Windows failure if possible and verify that the FileSystemException is caught when another process is using the file, without allowing the cleanup operation to fail.

Written by the indexing model from the issue text.

Assessment

Tech stack
dart
Domain
backend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.