apps-android-commons icon indicating copy to clipboard operation
apps-android-commons copied to clipboard

Uploads always fail on any connection, for phone model M2101K6G

Open CordylusLizard opened this issue 3 years ago • 19 comments

I cannot send any of the images by an app. I managed to send just one few months ago but never managed to send any subsequent one. I use 3.1.1~1c9267ca0 version

Here is the last log I got after failing to send another image:

[[Category:PKP class Px48]] [[Category:Manowo train station]] [[Category:Koszalińska Kolej Wąskotorowa]] [[Category:Koszalińska Kolej Wąskotorowa w czasach TKKW]] 2021-10-03 01:18:20,834 [ERROR] [file-logging-thread-1] [OkHttpConnectionFactory$UnsuccessfulResponseInterceptor] : java.io.IOException: {"error":{"code":"missingtitle","info":"The page you specified doesn't exist.","*":"See https://commons.wikimedia.org/w/api.php for API usage. Subscribe to the mediawiki-api-announce mailing list at <https://lists.wikimedia.org/postorius/lists/mediawiki-api-announce.lists.wikimedia.org/> for notice of API deprecations and breaking changes."},"servedby":"mw1450"} at fr.free.nrw.commons.OkHttpConnectionFactory$UnsuccessfulResponseInterceptor.intercept(OkHttpConnectionFactory.java:90) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121) at okhttp3.logging.HttpLoggingInterceptor.intercept(HttpLoggingInterceptor.java:225) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121) at okhttp3.RealCall.getResponseWithInterceptorChain(RealCall.java:254) at okhttp3.RealCall.execute(RealCall.java:92) at retrofit2.OkHttpCall.execute(OkHttpCall.java:190) at retrofit2.adapter.rxjava2.CallExecuteObservable.subscribeActual(CallExecuteObservable.java:42) at io.reactivex.Observable.subscribe(Observable.java:12267) at retrofit2.adapter.rxjava2.BodyObservable.subscribeActual(BodyObservable.java:34) at io.reactivex.Observable.subscribe(Observable.java:12267) at io.reactivex.internal.operators.observable.ObservableSingleSingle.subscribeActual(ObservableSingleSingle.java:35) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleMap.subscribeActual(SingleMap.java:34) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleMap.subscribeActual(SingleMap.java:34) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleOnErrorReturn.subscribeActual(SingleOnErrorReturn.java:38) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleSubscribeOn$SubscribeOnObserver.run(SingleSubscribeOn.java:89) at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:578) at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:66) at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:57) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:301) 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:923)

2021-10-03 01:18:20,837 [DEBUG] [file-logging-thread-1] [MediaDataExtractor] : Error occurred while fetching discussion 2021-10-03 01:18:20,891 [ERROR] [file-logging-thread-1] [OkHttpConnectionFactory$UnsuccessfulResponseInterceptor] : java.io.IOException: {"error":{"code":"badinteger","info":"Invalid value "Mcc194efb-30a7-406c-91bc-141aeaa5f8ed" for integer parameter "pageids".","docref":"See https://commons.wikimedia.org/w/api.php for API usage. Subscribe to the mediawiki-api-announce mailing list at <https://lists.wikimedia.org/postorius/lists/mediawiki-api-announce.lists.wikimedia.org/> for notice of API deprecations and breaking changes."},"servedby":"mw1339"} at fr.free.nrw.commons.OkHttpConnectionFactory$UnsuccessfulResponseInterceptor.intercept(OkHttpConnectionFactory.java:90) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121) at okhttp3.logging.HttpLoggingInterceptor.intercept(HttpLoggingInterceptor.java:225) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121) at okhttp3.RealCall.getResponseWithInterceptorChain(RealCall.java:254) at okhttp3.RealCall.execute(RealCall.java:92) at retrofit2.OkHttpCall.execute(OkHttpCall.java:190) at retrofit2.adapter.rxjava2.CallExecuteObservable.subscribeActual(CallExecuteObservable.java:42) at io.reactivex.Observable.subscribe(Observable.java:12267) at retrofit2.adapter.rxjava2.BodyObservable.subscribeActual(BodyObservable.java:34) at io.reactivex.Observable.subscribe(Observable.java:12267) at io.reactivex.internal.operators.observable.ObservableSingleSingle.subscribeActual(ObservableSingleSingle.java:35) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleMap.subscribeActual(SingleMap.java:34) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleFlatMap.subscribeActual(SingleFlatMap.java:36) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleMap.subscribeActual(SingleMap.java:34) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleResumeNext.subscribeActual(SingleResumeNext.java:39) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleAmb.subscribeActual(SingleAmb.java:84) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleSubscribeOn$SubscribeOnObserver.run(SingleSubscribeOn.java:89) at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:578) at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:66) at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:57) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:301) 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:923)

2021-10-03 01:18:20,906 [ERROR] [file-logging-thread-1] [OkHttpConnectionFactory$UnsuccessfulResponseInterceptor] : java.io.IOException: {"error":{"code":"badinteger","info":"Invalid value "M3a391c57-43df-499b-882a-45c57edfb018" for integer parameter "pageids".","docref":"See https://commons.wikimedia.org/w/api.php for API usage. Subscribe to the mediawiki-api-announce mailing list at <https://lists.wikimedia.org/postorius/lists/mediawiki-api-announce.lists.wikimedia.org/> for notice of API deprecations and breaking changes."},"servedby":"mw1357"} at fr.free.nrw.commons.OkHttpConnectionFactory$UnsuccessfulResponseInterceptor.intercept(OkHttpConnectionFactory.java:90) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121) at okhttp3.logging.HttpLoggingInterceptor.intercept(HttpLoggingInterceptor.java:225) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121) at okhttp3.RealCall.getResponseWithInterceptorChain(RealCall.java:254) at okhttp3.RealCall.execute(RealCall.java:92) at retrofit2.OkHttpCall.execute(OkHttpCall.java:190) at retrofit2.adapter.rxjava2.CallExecuteObservable.subscribeActual(CallExecuteObservable.java:42) at io.reactivex.Observable.subscribe(Observable.java:12267) at retrofit2.adapter.rxjava2.BodyObservable.subscribeActual(BodyObservable.java:34) at io.reactivex.Observable.subscribe(Observable.java:12267) at io.reactivex.internal.operators.observable.ObservableSingleSingle.subscribeActual(ObservableSingleSingle.java:35) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleMap.subscribeActual(SingleMap.java:34) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleFlatMap.subscribeActual(SingleFlatMap.java:36) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleMap.subscribeActual(SingleMap.java:34) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleResumeNext.subscribeActual(SingleResumeNext.java:39) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleAmb.subscribeActual(SingleAmb.java:84) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleSubscribeOn$SubscribeOnObserver.run(SingleSubscribeOn.java:89) at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:578) at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:66) at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:57) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:301) 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:923)

2021-10-03 01:18:20,908 [ERROR] [file-logging-thread-1] [OkHttpConnectionFactory$UnsuccessfulResponseInterceptor] : java.io.IOException: {"error":{"code":"missingtitle","info":"The page you specified doesn't exist.","*":"See https://commons.wikimedia.org/w/api.php for API usage. Subscribe to the mediawiki-api-announce mailing list at <https://lists.wikimedia.org/postorius/lists/mediawiki-api-announce.lists.wikimedia.org/> for notice of API deprecations and breaking changes."},"servedby":"mw1449"} at fr.free.nrw.commons.OkHttpConnectionFactory$UnsuccessfulResponseInterceptor.intercept(OkHttpConnectionFactory.java:90) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121) at okhttp3.logging.HttpLoggingInterceptor.intercept(HttpLoggingInterceptor.java:225) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:147) at okhttp3.internal.http.RealInterceptorChain.proceed(RealInterceptorChain.java:121) at okhttp3.RealCall.getResponseWithInterceptorChain(RealCall.java:254) at okhttp3.RealCall.execute(RealCall.java:92) at retrofit2.OkHttpCall.execute(OkHttpCall.java:190) at retrofit2.adapter.rxjava2.CallExecuteObservable.subscribeActual(CallExecuteObservable.java:42) at io.reactivex.Observable.subscribe(Observable.java:12267) at retrofit2.adapter.rxjava2.BodyObservable.subscribeActual(BodyObservable.java:34) at io.reactivex.Observable.subscribe(Observable.java:12267) at io.reactivex.internal.operators.observable.ObservableSingleSingle.subscribeActual(ObservableSingleSingle.java:35) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleMap.subscribeActual(SingleMap.java:34) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleMap.subscribeActual(SingleMap.java:34) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleOnErrorReturn.subscribeActual(SingleOnErrorReturn.java:38) at io.reactivex.Single.subscribe(Single.java:3603) at io.reactivex.internal.operators.single.SingleSubscribeOn$SubscribeOnObserver.run(SingleSubscribeOn.java:89) at io.reactivex.Scheduler$DisposeTask.run(Scheduler.java:578) at io.reactivex.internal.schedulers.ScheduledRunnable.run(ScheduledRunnable.java:66) at io.reactivex.internal.schedulers.ScheduledRunnable.call(ScheduledRunnable.java:57) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:301) 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:923)

2021-10-03 01:18:20,910 [DEBUG] [file-logging-thread-1] [MediaDataExtractor] : Error occurred while fetching discussion

CordylusLizard avatar Oct 02 '21 23:10 CordylusLizard

Hi @CordylusLizard , thanks for letting us know! Does the web-based Upload Wizard work for you?

misaochan avatar Oct 04 '21 13:10 misaochan

The web-based one works just fine, just uploaded the new image: https://commons.wikimedia.org/w/index.php?title=Special:ListFiles/Cordylus On the files list you can see the first and the only image I managed to send by an app. All subsequent images failed.

CordylusLizard avatar Oct 04 '21 17:10 CordylusLizard

Thanks a lot @CordylusLizard . @madhurgupta10 would you mind taking a look at this?

misaochan avatar Oct 04 '21 18:10 misaochan

Also, @CordylusLizard could you please try logging out and then in again, and see if that solves the problem for you?

misaochan avatar Oct 04 '21 18:10 misaochan

I relogged and tried to upload image. After filling the category form and taping the upload button, app crashed. Got a log. Next attempt didn't cause crash, but had a same result as before: the upload failure.

The crash log:

USER_COMMENT= APP_VERSION_CODE=1025 APP_VERSION_NAME=3.1.1 ANDROID_VERSION=11 PHONE_MODEL=M2101K6G STACK_TRACE=android.database.sqlite.SQLiteException: no such table: worktag (code 1 SQLITE_ERROR): , while compiling: SELECT DISTINCT tag FROM worktag WHERE work_spec_id=? at android.database.sqlite.SQLiteConnection.nativePrepareStatement(Native Method) at android.database.sqlite.SQLiteConnection.acquirePreparedStatement(SQLiteConnection.java:1045) at android.database.sqlite.SQLiteConnection.prepare(SQLiteConnection.java:652) at android.database.sqlite.SQLiteSession.prepare(SQLiteSession.java:590) at android.database.sqlite.SQLiteProgram.(SQLiteProgram.java:61) at android.database.sqlite.SQLiteQuery.(SQLiteQuery.java:37) at android.database.sqlite.SQLiteDirectCursorDriver.query(SQLiteDirectCursorDriver.java:46) at android.database.sqlite.SQLiteDatabase.rawQueryWithFactory(SQLiteDatabase.java:1545) at android.database.sqlite.SQLiteDatabase.rawQueryWithFactory(SQLiteDatabase.java:1520) at androidx.sqlite.db.framework.FrameworkSQLiteDatabase.query(FrameworkSQLiteDatabase.java:161) at androidx.room.RoomDatabase.query(RoomDatabase.java:446) at androidx.room.util.DBUtil.query(DBUtil.java:83) at androidx.work.impl.model.WorkTagDao_Impl.getTagsForWorkSpecId(WorkTagDao_Impl.java:94) at androidx.work.impl.WorkerWrapper.run(WorkerWrapper.java:134) at androidx.work.impl.utils.SerialExecutor$Task.run(SerialExecutor.java:91) 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:923)

IS_SILENT=false REPORT_ID=86837e78-3a0d-408f-a7eb-76bce4b6962d USER_CRASH_DATE=2021-10-04T21:57:12.737+02:00 USER_EMAIL=

CordylusLizard avatar Oct 04 '21 20:10 CordylusLizard

Thanks for the investigations @CordylusLizard ! The task has been assigned to a dev, we hope to have a fix for you soon. :)

misaochan avatar Oct 05 '21 10:10 misaochan

@misaochan @CordylusLizard I am looking into the logs, just to confirm both logs are related to the same problem?

madhurgupta10 avatar Oct 09 '21 16:10 madhurgupta10

@madhurgupta10 , no, I don't think they are related. The crash is related to #4651 , the upload failure is probably a separate issue altogether. You would only need to handle the upload failure, Ashish is working on the crash.

misaochan avatar Oct 11 '21 07:10 misaochan

@madhurgupta10, I get similar log on clicking an upload in contribution or explore tab. Additionally, thumbnails are not shown in contribution and explore on latest master.

4D17Y4 avatar Oct 12 '21 13:10 4D17Y4

I forgot to mention that I have the same symptoms as @4D17Y4 mentioned. Also no thumbnails.

CordylusLizard avatar Oct 12 '21 15:10 CordylusLizard

@4D17Y4 Could you do us a favour and try the Play Store version, and see if you can reproduce this issue there as well? Thanks!

misaochan avatar Oct 13 '21 08:10 misaochan

No @misaochan. The playstore version does not has this bug. I can upload images from gallery plus the contribution and explore tab are working fine.

4D17Y4 avatar Oct 17 '21 17:10 4D17Y4

Hi, @misaochan and @CordylusLizard I looked up the issue carefully but was still not able to reproduce the issue.

I uploaded multiple photos and all of them were uploaded successfully (https://commons.wikimedia.beta.wmflabs.org/wiki/Special:ListFiles?limit=20&user=Madhurgupta10)

I tested on the same version (3.1.1~1c9267ca0) and also in master. Screenshot_20211021-104229

madhurgupta10 avatar Oct 21 '21 05:10 madhurgupta10

Recently a similar report came to Wikimedia Commons Telegram group. It says uploads are failing for 3.1.1~1c9267ca0

neslihanturan avatar Oct 22 '21 11:10 neslihanturan

@madhurgupta10 Indeed these issues tend to be difficult to reproduce. :( We usually have to rely on logs and guesswork for this. Are you able to deduce anything from the logs in the first post?

misaochan avatar Oct 26 '21 06:10 misaochan

@madhurgupta10 Indeed these issues tend to be difficult to reproduce. :( We usually have to rely on logs and guesswork for this. Are you able to deduce anything from the logs in the first post?

The logs seem to suggest that there was a network interruption during uploading, which could be a mobile phone's internet or server, @CordylusLizard do you remember if you used 3G/4G or Wifi?

madhurgupta10 avatar Oct 26 '21 07:10 madhurgupta10

I also thought initially that it might be an internet issue - so I tried both on the 4G and on WiFi - effect was the same. And I tried this 4G on a few very different locations.

EDIT: I just tried that another time, same effect. Both using WiFi or mobile data. No thumbnails, just a permanent "fail". Retrying doesn't help. image

CordylusLizard avatar Oct 27 '21 02:10 CordylusLizard

I also thought initially that it might be an internet issue - so I tried both on the 4G and on WiFi - effect was the same. And I tried this 4G on a few very different locations.

EDIT: I just tried that another time, same effect. Both using WiFi or mobile data. No thumbnails, just a permanent "fail". Retrying doesn't help. image

Hi @CordylusLizard, I am trying to replicate this issue on my end but even after trying 10+ different scenarios, I am still unable to. For me, image (solo or multiple) uploads works just fine in both beta and prod.

I request you to try uploading the same images from a different device and/or different account and let us know if they gets uploaded or not.

I really want to help you out, but until I know what's causing the issue, I am unable to :(

madhurgupta10 avatar Nov 12 '21 14:11 madhurgupta10

Here is an 'apk' file for the latest master build for you to test

app-commons-v3.1.1-master-prod-debug.zip

Edit: Use this version below if Android 10+ app-commons-v3.1.1-master-prod-release.zip

madhurgupta10 avatar Nov 12 '21 14:11 madhurgupta10