Error occurred while loading images in search activity when start typing
See original GitHub issueSummary:
Whenever i try to search under “Media” or “Categories” tab, The “Error occurred while loading image” SNACKBAR is poping up upon typing each character in the search bar. The Snackbar appears exactly after the debounce timeout ends “500 ms”. Once i end up my typing the progress bar starts looping forever without showing any results.
Steps to reproduce:
1- Slide in the navigation drawer 2- Go to Explore 3- Press the search icon to start typing 4- Start typing and wait after each character
System logs:
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: Error occurred while loading queried images
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.String fr.free.nrw.commons.media.model.ExtMetadata$Values.value()' on a null object reference
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at fr.free.nrw.commons.Media.from(Media.java:457)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at fr.free.nrw.commons.mwapi.OkHttpJsonApiClient.lambda$searchImages$6$OkHttpJsonApiClient(OkHttpJsonApiClient.java:281)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at fr.free.nrw.commons.mwapi.OkHttpJsonApiClient$$Lambda$6.call(Unknown Source)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.internal.operators.single.SingleFromCallable.subscribeActual(SingleFromCallable.java:44)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.Single.subscribe(Single.java:3394)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at com.tspoon.traceur.SingleOnAssembly.subscribeActual(SingleOnAssembly.java:43)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.Single.subscribe(Single.java:3394)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.internal.operators.single.SingleSubscribeOn$SubscribeOnObserver.run(SingleSubscribeOn.java:89)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:579)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:66)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:57)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at java.util.concurrent.FutureTask.run(FutureTask.java:237)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:272)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133)
2019-03-02 23:30:41.694 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at java.lang.Thread.run(Thread.java:761)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: Caused by: com.tspoon.traceur.TraceurException: Debug Exception generated at call site
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at dalvik.system.VMStack.getThreadStackTrace(Native Method)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at java.lang.Thread.getStackTrace(Thread.java:1566)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.Single.fromCallable(Single.java:580)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at fr.free.nrw.commons.mwapi.OkHttpJsonApiClient.searchImages(OkHttpJsonApiClient.java:265)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at fr.free.nrw.commons.explore.images.SearchImageFragment.updateImageList(SearchImageFragment.java:144)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at fr.free.nrw.commons.explore.SearchActivity.lambda$setTabs$1$SearchActivity(SearchActivity.java:125)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at fr.free.nrw.commons.explore.SearchActivity$$Lambda$1.accept(Unknown Source)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.internal.observers.LambdaObserver.onNext(LambdaObserver.java:63)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.internal.operators.observable.ObservableObserveOn$ObserveOnObserver.drainNormal(ObservableObserveOn.java:200)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.internal.operators.observable.ObservableObserveOn$ObserveOnObserver.run(ObservableObserveOn.java:252)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.android.schedulers.HandlerScheduler$ScheduledRunnable.run(HandlerScheduler.java:119)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at android.os.Handler.handleCallback(Handler.java:836)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at android.os.Handler.dispatchMessage(Handler.java:103)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at android.os.Looper.loop(Looper.java:203)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at android.app.ActivityThread.main(ActivityThread.java:6251)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at java.lang.reflect.Method.invoke(Native Method)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1073)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:934)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: Caused by: com.tspoon.traceur.TraceurException: Debug Exception generated at call site
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at dalvik.system.VMStack.getThreadStackTrace(Native Method)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at java.lang.Thread.getStackTrace(Thread.java:1566)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.Single.subscribeOn(Single.java:3465)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at fr.free.nrw.commons.explore.images.SearchImageFragment.updateImageList(SearchImageFragment.java:145)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: ... 13 more
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: Caused by: com.tspoon.traceur.TraceurException: Debug Exception generated at call site
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at dalvik.system.VMStack.getThreadStackTrace(Native Method)
2019-03-02 23:30:41.695 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at java.lang.Thread.getStackTrace(Thread.java:1566)
2019-03-02 23:30:41.696 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.Single.observeOn(Single.java:2917)
2019-03-02 23:30:41.696 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at fr.free.nrw.commons.explore.images.SearchImageFragment.updateImageList(SearchImageFragment.java:146)
2019-03-02 23:30:41.696 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: ... 13 more
2019-03-02 23:30:41.696 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: Caused by: com.tspoon.traceur.TraceurException: Debug Exception generated at call site
2019-03-02 23:30:41.696 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at dalvik.system.VMStack.getThreadStackTrace(Native Method)
2019-03-02 23:30:41.696 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at java.lang.Thread.getStackTrace(Thread.java:1566)
2019-03-02 23:30:41.696 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.Single.timeout0(Single.java:3635)
2019-03-02 23:30:41.696 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at io.reactivex.Single.timeout(Single.java:3563)
2019-03-02 23:30:41.696 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: at fr.free.nrw.commons.explore.images.SearchImageFragment.updateImageList(SearchImageFragment.java:147)
2019-03-02 23:30:41.696 25759-25759/fr.free.nrw.commons.beta E/SearchImageFragment: ... 13 more
Device and Android version:
Devices: Infinix HOT5 & Nexus 5X Android version: Android 7.0
Commons app version:
App version: Built from codebase master (Version name: 2.10.1)
Screen-shots:
Would you like to work on the issue?
YES! But I may need some help from old contributors if available
Issue Analytics
- State:
- Created 5 years ago
- Comments:8 (4 by maintainers)
Top GitHub Comments
someone has fixed this already @Bahaaib @domdomegg
Thanks @Bahaaib ! Let us know how you get on. 😃