Closed Bug 1374989 Opened 7 years ago Closed 5 years ago

Geolocation is not working if don't ask again is left unmarked

Categories

(Core :: DOM: Geolocation, defect, P2)

ARM
Android
defect

Tracking

()

RESOLVED FIXED
mozilla69
Tracking Status
fennec + ---
firefox-esr60 --- wontfix
firefox55 --- wontfix
firefox56 --- wontfix
firefox66 --- wontfix
firefox67 --- wontfix
firefox68 --- fixed
firefox69 --- fixed

People

(Reporter: bsurd, Assigned: andrei.a.lazar)

References

Details

(Whiteboard: [bcs:p2])

Attachments

(4 files)

Build: 56.0a1 
Device: 
 - Huawei MediaPad M2 (Android 5.1.1)

STR:

1. Go to http://maps.google.com
2. Tap on the GPS icon.
3. In the share your location pop-up unmark the  "Don't ask again for this site" checkbox
4. Tap Share

Expected result:
The user should be taken to his location. 

Actual result:
 - The user is not showed his location. If he taps again on the GPS icon another pop-up is displayed.
 - After tapping on share, location sharing should be available until the user closes the page or the browser.

Notes:
 - If the checkbox is left marked, location sharing works 
 - Video: https://goo.gl/7446Y1
tracking-fennec: --- → ?
[triage@july 5th] per above the "don't ask again" works as expected but the location share doesn't. set as P1.
Priority: -- → P2
Priority: P2 → P1
tracking-fennec: ? → +
Maybe Kan-Ru or Garvan know what could be going wrong here?
Flags: needinfo?(kchen)
Flags: needinfo?(gkeeley)
No ideas on this one (sorry to be brief, really I don't know where this might be in the stack (is it front-end, Android Java-only code, deeper in gecko stack)). I would start by debugging this in the front-end or checking for recent changes there to look for suspects, given that it behaves like the dialog isn't properly setting this.
Flags: needinfo?(gkeeley)
See Also: → 1401531
Susheel, how important do you think this is? I could see it as a P1 considering we don't permit the user's privacy decision to share only once.
Flags: needinfo?(sdaswani)
Mike, definitely bad behavior, but I worry about the potential costs of tracking this down (see Garvan's comment above), and when you couple it with the simple workaround which is available on *all* Android devices (use the Google Maps App), I'm not sure a P1 is warranted. I'd make it a P2 S1 and let's deal with it as soon as we have regular staffing on Fennec.
Flags: needinfo?(sdaswani)
Severity: normal → major
Priority: P1 → P3
Re-triaging per https://bugzilla.mozilla.org/show_bug.cgi?id=1473195

Needinfo :susheel if you think this bug should be re-triaged.
Priority: P3 → P5
Assignee: nobody → andrei.a.lazar
Priority: P5 → P2

Chris: feel free to just clear the ni as I wanted to make sure you saw this one, your Fx Android expertise might be needed.

Flags: needinfo?(kanru) → needinfo?(cpeterson)
Whiteboard: [bcs:p2]

I can still reproduce this bug in Fennec and Fenix. Google Maps asks me to share my position 2-3 times before actually showing my position on the map. This might just be a web content problem and not a Gecko bug. I only get one permission prompt when testing geolocation on https://geolocation.com/ in Fennec and Fenix.

I can reproduce these multiple permission prompts on Firefox desktop, but only if I use DevTool's Responsive Design Mode with a Fennec User-agent string Mozilla/5.0 (Android 8.1.0; Tablet; rv:66.0) Gecko/66.0 Firefox/66.0. Since I can reproduce this bug on desktop, I'll move this bug to the "Core::DOM: Geolocation" Bugzilla component.

@ Andrei, can you please verify whether Google Maps is actually calling Gecko's navigator.geolocation.getCurrentPosition() or watchPosition() multiple times? If so, we can reach out to Google and ask them to just call it once.

Component: General → DOM: Geolocation
Flags: needinfo?(cpeterson)
Product: Firefox for Android → Core

My suspicion is that when the page checks that navigator.geolocation exists, this triggers a prompt.

AFAIK from working with google maps in the past, it doesn't make redundant extra calls to getCurrent or watch.
EDIT: I should add that is with the desktop version of google maps, it could be a different code path for the mobile version.

Now that 1371618 is verified, Andrei just tested again and shows this is also working as expected.

Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Attached image 1.png
Attached image 2.png
Attached image 3.png
Attached image 4.png
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: