TeamAmaze / TeamAmaze/AmazeFileManager
`ConcurrentModificationException` on `LoadFilesListTask#postListCustomPathProcess`
Open
Nobody has claimed this yet.
From-Email
Issue-Bug
- Dominant language
- Kotlin
- Stars
- 6.4k
- Forks
- 1.7k
- Avg merge
- 3d 9h
- Merged PRs (30d)
- 1
Description
Issue explanation (write below this line)
deleted a file, then it crashed.
Exception
- App Name: Amaze File Manager
- Package: com.amaze.filemanager
- Version: 3.8.5
- User Action: UI Error
- Request: Application crash
- OS: Linux Android 10 - 29
- Device: star2qltechn
- Model: SM-G9650
- Product: star2qltezh
Crash log
java.lang.RuntimeException: An error occurred while executing
doInBackground()
at android.os.AsyncTask$4.done(AsyncTask.java:399)
at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:383)
at java.util.concurrent.FutureTask.setException(FutureTask.java:252)
at java.util.concurrent.FutureTask.run(FutureTask.java:271)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.lang.Thread.run(Thread.java:919)
Caused by: java.util.ConcurrentModificationException
at java.util.ArrayList.sort(ArrayList.java:1472)
at java.util.Collections.sort(Collections.java:206)
at
com.amaze.filemanager.asynchronous.asynctasks.LoadFilesListTask.postListCustomPathProcess(LoadFilesListTask.java:276)
at
com.amaze.filemanager.asynchronous.asynctasks.LoadFilesListTask.doInBackground(LoadFilesListTask.java:193)
at
com.amaze.filemanager.asynchronous.asynctasks.LoadFilesListTask.doInBackground(LoadFilesListTask.java:85)
at android.os.AsyncTask$3.call(AsyncTask.java:378)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
... 3 more
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at LoadFilesListTask.postListCustomPathProcess (line 276) and doInBackground (line 193), focusing on the sort that throws ConcurrentModificationException after a file is deleted. Reproduce the deletion during list processing and verify that the file-list operation completes without the crash.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, java, kotlin
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100