duckduckgo / Android

DuckDuckGo Android App
https://play.google.com/store/apps/details?id=com.duckduckgo.mobile.android
Apache License 2.0
3.83k stars 903 forks source link

[Bug] Text search of bookmarks crashes app #2344

Open trailblazingfive opened 2 years ago

trailblazingfive commented 2 years ago

Describe the bug

Having a huge bookmark list +5000 records, after latest update 5.137.5 app crashes when trying to do a text search - error message. Downgraded to 5.135.0, and imported bookmarks to the app (previously exported from it), but out of 1MB file only ~300kB imported, rest got dropped.

How to Reproduce

Go to bookmarks Click search Start inserting text App crashes - error message

Expected behavior

Expected to get search results.

Environment

- DDG App Version: 5.137.5
- Device: Pocophone F1
- OS: Android 9
dinesh-thiyagarajan commented 2 years ago

Hey @trailblazingfive can you assign this bug to me ? I can help with this

bemusementpark commented 2 months ago

This seems to be fixed.

There was some line overriding the size, but ListAdapter seems to do diffing async so we have to let ListAdapter give the getItemCount, as the diff might not be ready yet. The file's been renamed BookmarkFolderStructureAdapter, and the override has been removed.

https://github.com/duckduckgo/Android/blob/d46883eda1ca176d5555ec9b15e809db99438070/app/src/main/java/com/duckduckgo/app/bookmarks/ui/bookmarkfolders/BookmarkFoldersAdapter.kt#L81

suyash-modi commented 1 month ago

Hey @trailblazingfive can you assign this bug to me ? I can help with this