Skip to content

Conversation

UmairOye
Copy link

…n (#6422)

Description (required)

Fixes #6422

What changes did you make and why?
This PR fixes a java.lang.SecurityException when accessing location.

  • Added ACCESS_COARSE_LOCATION permission in AndroidManifest.xml
  • Ensured runtime permission requests cover coarse/fine location correctly
  • Prevents crashes when location is accessed without fine permission granted

Tests performed (required)
Tested ProdDebug build on:

  • Pixel 5 emulator (API 33) → No crash, permission dialog works
  • Pixel 3 emulator (API 29) → No crash, location updates available

Tested {build variant, e.g. ProdDebug} on {name of device or emulator} with API level {API level}.

Screenshots (for UI changes only)
N/A (no UI changes)

Need help? See https://support.google.com/android/answer/9075928


Note: Please ensure that you have read CONTRIBUTING.md if this is your first pull request.

Copy link

✅ Generated APK variants!

@nicolas-raoul
Copy link
Member

Note: I have been using this branch for 3 days to perform many uploads and Nearby searches. I have not seen any negative effect so far.

I am also able to upload by sharing from Files. But I am able to do it on the main branch too.

@RitikaPahwa4444 Does this branch brings an improvement for you?

@RitikaPahwa4444
Copy link
Collaborator

Sorry, I'm not able to reproduce it now on main, so not sure if it was some intermittent issue 🤔

@nicolas-raoul
Copy link
Member

@UmairOye Sorry for taking your time, but would you be able to provide before/after videos? Thanks a lot! :-)

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

Successfully merging this pull request may close these issues.

java.lang.SecurityException for ACCESS_COARSE_LOCATION or ACCESS_FINE_LOCATION
3 participants