LuckSiege / LuckSiege/PictureSelector
#2288(java.lang.IndexOutOfBoundsException at xxx PictureSelectorPreviewFragment.initViewPagerData)的问题依然存在
Open
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 13.6k
- Forks
- 3.1k
- PR merge metrics
- No merged PRs in 30d
Description
Current use version?
当前使用的版本是多少?
v3.10.2
Will this problem occur in demo?
Demo能否复现这问题?
否,线上问题,不必现
Describe the problem or provide an error log?
描述问题或提供错误log?
java.lang.ArrayIndexOutOfBoundsException
length=3; index=-1
java.util.ArrayList.get(ArrayList.java:439)
com.luck.picture.lib.PictureSelectorPreviewFragment.initViewPagerData(PictureSelectorPreviewFragment.java:1079)
com.luck.picture.lib.PictureSelectorPreviewFragment.onViewCreated(PictureSelectorPreviewFragment.java:265)
androidx.fragment.app.Fragment.performViewCreated(Fragment.java:3128)
androidx.fragment.app.FragmentStateManager.createView(FragmentStateManager.java:552)
androidx.fragment.app.FragmentStateManager.moveToExpectedState(FragmentStateManager.java:261)
androidx.fragment.app.FragmentManager.executeOpsTogether(FragmentManager.java:1890)
androidx.fragment.app.FragmentManager.removeRedundantOperationsAndExecute(FragmentManager.java:1808)
androidx.fragment.app.FragmentManager.execPendingActions(FragmentManager.java:1751)
androidx.fragment.app.FragmentManager.dispatchStateChange(FragmentManager.java:2976)
androidx.fragment.app.FragmentManager.dispatchActivityCreated(FragmentManager.java:2886)
...
Contributor guide
No contributing guide indexed for this repository
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 with PictureSelectorPreviewFragment.java at initViewPagerData line 1079 and trace how onViewCreated at line 265 supplies the list and index. Compare the report with issue #2288 and investigate the v3.10.2 state that produces index -1. Done means the reported preview path no longer throws ArrayIndexOutOfBoundsException.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- android, java
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100