Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nearby starts upload without caption/description/depiction prefilled, on Pixel 9 Pro #6227

Open
nicolas-raoul opened this issue Feb 27, 2025 · 15 comments

Comments

@nicolas-raoul
Copy link
Member

nicolas-raoul commented Feb 27, 2025

On both main branch and google_play_safe branches.

screen-20250227-102244.mp4

Steps to reproduce:

  1. Take a picture (you will not have to upload it)
  2. Use latest main branch
  3. Go to Nearby tab
  4. Select a pin near you
  5. Tap the + and select the picture you took in step 1
  6. Expected: The app should fill the caption/description fields. Actually: The fields are empty.

Strangely I also see the same bug when going back to these commits:
88eedc3
d32ab15
7a685b1 <-- Nearby was working correctly a few days after that version: https://commons.wikimedia.org/wiki/File:Honry%C5%AB-ji.jpg

Suspicious part of logcat:
This part is especially suspicious:

02-27 20:00:08.655  5847  5847 E Parcel  : android.util.Log$TerribleFailure: Unparcelling of Place{name='Central Breakwater', lang='bug', label='UNKNOWN', longDescription='Central Breakwater (two artificial islands in the Tokyo Bay)', location='lat/lng: (35.6,139.816667)', category='', distance='null', siteLinks='Sitelinks{wikipediaLink='', commonsLink='', wikidataLink='http://www.wikidata.org/entity/Q11363815'}', pic='', exists='false', entityID='null'} of type VAL_PARCELABLE  consumed 752 bytes, but 764 expected.
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.util.Log.wtf(Log.java:338)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.util.Slog.wtfStack(Slog.java:246)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.Parcel.readValue(Parcel.java:4630)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.Parcel.-$$Nest$mreadValue(Unknown Source:0)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.Parcel$LazyValue.apply(Parcel.java:4735)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.Parcel$LazyValue.apply(Parcel.java:4688)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.BaseBundle.unwrapLazyValueFromMapLocked(BaseBundle.java:446)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.BaseBundle.getValueAt(BaseBundle.java:426)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.BaseBundle.getValue(BaseBundle.java:397)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.BaseBundle.getValue(BaseBundle.java:380)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.BaseBundle.get(BaseBundle.java:767)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.Bundle.getParcelable(Bundle.java:1121)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.content.Intent.getParcelableExtra(Intent.java:9589)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at fr.free.nrw.commons.upload.UploadActivity.receiveInternalSharedItems(UploadActivity.kt:723)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at fr.free.nrw.commons.upload.UploadActivity.receiveSharedItems(UploadActivity.kt:444)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at fr.free.nrw.commons.upload.UploadActivity.checkStoragePermissions(UploadActivity.kt:293)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at fr.free.nrw.commons.upload.UploadActivity.onCreate(UploadActivity.kt:207)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.app.Activity.performCreate(Activity.java:9140)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.app.Activity.performCreate(Activity.java:9118)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1505)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:4217)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:4422)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:222)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.app.servertransaction.TransactionExecutor.executeNonLifecycleItem(TransactionExecutor.java:133)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.app.servertransaction.TransactionExecutor.executeTransactionItems(TransactionExecutor.java:103)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:80)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2782)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.Handler.dispatchMessage(Handler.java:110)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.Looper.loopOnce(Looper.java:248)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.os.Looper.loop(Looper.java:338)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at android.app.ActivityThread.main(ActivityThread.java:8982)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at java.lang.reflect.Method.invoke(Native Method)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:593)
02-27 20:00:08.655  5847  5847 E Parcel  : 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:932)
02-27 20:00:08.656  5847  5847 E UploadActivity: Error reading place

Full logcat, from when I first tapped the pin until seeing the empty caption field, too long for GitHub but available on demand.

@rohit9625
Copy link
Contributor

I couldn't reproduce this bug. Maybe that's because the Is this a picture of dialog didn't show up in my case. Did you tried with other images @nicolas-raoul?

@nicolas-raoul
Copy link
Member Author

Thanks for checking! 🙂

Ideally the "is this a picture of X" dialog should not appear when coming from Nearby.

Anyway I have no caption prefilled in any case, with pictures for which the popup appears and with pictures for which the popup does not appear.

@rohit9625
Copy link
Contributor

Are there any other settings you may have in in-app settings?

@rohit9625
Copy link
Contributor

Well, I just noticed that the app crashes when tapping on the search icon from NearbyScreen. Can you reproduce that?

@nicolas-raoul
Copy link
Member Author

I reinstalled the app many times, reproducing all the time with default settings.

I can repro that crash yes. Would you mind filing an issue?

@rohit9625
Copy link
Contributor

rohit9625 commented Feb 27, 2025

I reinstalled the app many times, reproducing all the time with default settings.

Does this happen for all of the nearby places? I also tried replicating this on many nearby locations and with about 5 pictures.

I can repro that crash yes. Would you mind filing an issue?

Yeah, sure. I was just waiting for your approval.

@nicolas-raoul nicolas-raoul changed the title Nearby starts upload without caption/description/depiction prefilled Nearby starts upload without caption/description/depiction prefilled, on Pixel 9 Pro Feb 27, 2025
@nicolas-raoul
Copy link
Member Author

All nearby places, yes. I tried a dozen, including my usual test places which normally work fine.

I just tried on another phone (Pixel 7 Pro) and it works. Same user. So it seems to depend on device.

Anyone who can reproduce, please comment with your device model and Android version, thanks! :-)

@rohit9625
Copy link
Contributor

Mine is Samsung A14 with Android 14. What's your @nicolas-raoul? Maybe we can replicate this on emulator.

@nicolas-raoul
Copy link
Member Author

I get this bug on Pixel 9 Pro.

@nicolas-raoul
Copy link
Member Author

nicolas-raoul commented Feb 27, 2025

I am seeing the same Unparcelling [...] of type VAL_PARCELABLE consumed 864 bytes, but 876 expected. failure on the Pixel 7 Pro where the bug does not happen, so it is probably not the reason.

Pixel 7 Pro (no bug):

ImageProcessingService: Checking for dark image /data/user/0/fr.free.nrw.commons/cache/CommonsContributions/40f60e94-119d-483a-bca1-e9f4db9e143a.jpg
Image decoding logging dropped!
File SHA1: 4f09c3e7b2a1c6a9c5e10f0d11d7e115b324280b
ImageUtils: Checking image darkness took 193 ms.
UploadMediaDetail is UploadMediaDetail(languageCode=bug, descriptionText=Chiyo ga Ike (بركة في ميغورو، طوكيو، اليابان), captionText=Chiyo ga Ike)

Pixel 9 Pro (bug):

ImageProcessingService: Checking for dark image /data/user/0/fr.free.nrw.commons/cache/CommonsContributions/a7bdf39e-0444-4bca-9386-52157e6265d1.jpg
Image decoding logging dropped!
File SHA1: 221c45a03e6b57f85bce9adb63ef9618cc006309
[no "Checking image darkness took" log line]
UploadMediaDetail is UploadMediaDetail(languageCode=null, descriptionText=null, captionText=)

(and many more SPARQL request flying around, no sure if related)

@rohit9625
Copy link
Contributor

I am seeing the same Unparcelling [...] of type VAL_PARCELABLE consumed 864 bytes, but 876 expected. failure on the Pixel 7 Pro where the bug does not happen, so it is probably not the reason.

Does that means the image details not getting filled on Pixel 7?

@nicolas-raoul
Copy link
Member Author

I meant that the unparcelling can be ignored, it is not the cause of this bug. Because it happens on both phones. :-)

@rohit9625
Copy link
Contributor

Is it possible that I can try places on which you're trying?

@nicolas-raoul
Copy link
Member Author

@rohit9625
Copy link
Contributor

No progress on emulators either. Let's see if someone faces this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants