Skip to content

Can't upload pictures after targetSdkVersion bumped to 33 #5297

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

Closed
nicolas-raoul opened this issue Sep 20, 2023 · 2 comments · Fixed by #5299
Closed

Can't upload pictures after targetSdkVersion bumped to 33 #5297

nicolas-raoul opened this issue Sep 20, 2023 · 2 comments · Fixed by #5299
Labels

Comments

@nicolas-raoul
Copy link
Member

nicolas-raoul commented Sep 20, 2023

Steps to reproduce and problems description

  1. Reset the app's storage, for instance by uninstalling/reinstalling.
  2. Log in.
  3. When asked "Allow Commons to access photos and videos on this device?", tap "Allow all".
  4. Share a picture to the app.
  5. Problem 1: Asked again "Requesting storage permission - We need your permission to access the external storage of your device in order to upload images." I believe I already gave permission at step 2?
  6. Problem 2: Background is flickering as seen in the first screencast.
  7. Problem 3: After tapping "Settings", it is not clear what needs to be done. See the two screenshots. I am not able to get past the dialog and thus can't upload pictures.

As seen in the second screencast, I also did not find a way to upload using the in-app camera. The custom picker also does not seem usable.

Version

  • This does not occur with 81030d1 ("Fix retried uploads stuck in queued state"), I just tried.
  • This starts occurring with the next commit f577053 ("Target the latest Android version") which means it is currently occurring on the main branch.

I am testing on Android 14.

Research

https://developer.android.com/about/versions/13/behavior-changes-13#granular-media-permissions
https://developer.android.com/about/versions/12/behavior-changes-12

Interestingly, if I uninstall then install 81030d1 and use it (tap the gallery button then choose picture and reach the caption filling screen) then upgrade to f577053 without resetting the app's storage, then the problems do not happen (tried just now). This may be related to this API 33 note (and may suggest that getting appropriate READ_MEDIA_* permission(s) would solve this whole issue):

If your app was previously granted the READ_EXTERNAL_STORAGE permission, then any requested READ_MEDIA_* permissions are granted automatically when upgrading.

Screencast / screenshots

screen-20230920-203931.mp4

Screenshot_20230920-205833.png

Screenshot_20230920-205844.png

screen-20230920-222025.mp4
@nicolas-raoul nicolas-raoul changed the title Upload wizard: Instead of caption screen, "Requesting storage permission" popup with flashing background Can't upload pictures after targetSdkVersion bumped to 33 Sep 20, 2023
@RitikaPahwa4444
Copy link
Collaborator

RitikaPahwa4444 commented Sep 21, 2023

I doubt if problem 2 (step 6) is related to the targetSdkVersion. I remember facing something similar earlier as well for the "Requesting Location Permission" dialog in the Explore fragment map.

@nicolas-raoul
Copy link
Member Author

nicolas-raoul commented Sep 21, 2023

You are right Ritika, the map activities (in particular Nearby) also sometimes show a seemingly useless permission dialog, that can be ignored by tapping "back" and does not prevent use of the activity. Flickering or showing too many dialogs is not a big issue. On the other hand, the present bug does prevent upload. 😥

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

Successfully merging a pull request may close this issue.

2 participants