Geolocation Service broken because of access token

RESOLVED FIXED in Firefox 9

Status

()

Core
Geolocation
RESOLVED FIXED
6 years ago
5 years ago

People

(Reporter: René-Luc, Assigned: René-Luc)

Tracking

({regression})

9 Branch
mozilla11
x86
Linux
regression
Points:
---

Firefox Tracking Flags

(firefox9 fixed, firefox10 fixed)

Details

(Whiteboard: [mozfr][qa?])

Attachments

(1 attachment, 1 obsolete attachment)

(Assignee)

Description

6 years ago
User Agent: Mozilla/5.0 (X11; Linux i686 on x86_64; rv:9.0a2) Gecko/20111026 Firefox/9.0a2
Build ID: 20111026042018

Steps to reproduce:

I call geolocation Service to an url with a token stored in prefs.


Actual results:

Error : access_token is not defined
Source File : resource:///components/NetworkGeolocationProvider.js
Line : 206


Expected results:

No error, access_token has to be accessToken on line 206.

The code is
204: let accessToken = this.getAccessTokenForURL(providerUrlBase);
205: if (accessToken !== "")
206:   providerUrl = providerUrl + "&access_token="+access_token;

The code has to be
204: let accessToken = this.getAccessTokenForURL(providerUrlBase);
205: if (accessToken !== "")
206:   providerUrl = providerUrl + "&access_token="+accessToken;
(Assignee)

Updated

6 years ago
Depends on: 677256
Keywords: regression

Comment 1

6 years ago
Created attachment 574242 [details] [diff] [review]
patch v.1

patch as described.
Assignee: nobody → doug.turner
Status: UNCONFIRMED → NEW
Ever confirmed: true
Attachment #574242 - Flags: review?(doug.turner)

Comment 2

6 years ago
René-Luc, thanks!  can you verify that this patch I attached is exactly what you meant in comment #0
(Assignee)

Comment 3

6 years ago
Created attachment 574274 [details] [diff] [review]
patch v.1 correction

You're welcome.
Doug Turner, I verifying the patch and correct it.
Attachment #574274 - Flags: review?(doug.turner)
Attachment #574274 - Flags: approval-mozilla-beta?

Comment 4

6 years ago
Comment on attachment 574242 [details] [diff] [review]
patch v.1

accesstoken != accessToken
Attachment #574242 - Flags: review?(doug.turner) → review-

Updated

6 years ago
Attachment #574274 - Flags: review?(doug.turner) → review+

Updated

6 years ago
Keywords: checkin-needed

Updated

6 years ago
Attachment #574242 - Attachment is obsolete: true

Comment 5

6 years ago
Comment on attachment 574274 [details] [diff] [review]
patch v.1 correction

[Triage comment]
Approving for Beta since this breaks the geolocation service. Please land today to make it into our next beta release.

Please also make sure to set approval‑mozilla‑aurora? if this is not in 10 Aurora already.
Attachment #574274 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

Comment 6

6 years ago
Has this landed for the 9.0b2 candidate builds? Geolocation is still broken for me.

Provided that the issue that I'm observing is what this bug relates to. I set "geo.wifi.uri" to "file:///.../location.json" which contains something like this:

{"location": {
              "latitude": 123.45, 
              "longitude": 12.34, 
              "accuracy": 10.0}}

However, unlike versions up to 8.0, 9.0 and higher don't find this location.

Comment 7

6 years ago
Comment on attachment 574274 [details] [diff] [review]
patch v.1 correction

This hasn't landed anywhere yet as far as I can tell.
Attachment #574274 - Flags: approval-mozilla-aurora?
In my queue with a few other bits that are being sent to try first and then onto inbound.

https://tbpl.mozilla.org/?tree=Try&rev=329bc2d383a3 
(this changeset is there, just was pushed to try previously, so have to view parent)

René-Luc, to save time for future patches (this one is fine for now), could you set your hgrc to include the author automatically, along the lines of:
http://blog.bonardo.net/2010/06/22/so-youre-about-to-use-checkin-needed

Thanks :-)
Assignee: doug.turner → rldhont
Status: NEW → ASSIGNED
Keywords: checkin-needed

Updated

6 years ago
Whiteboard: [mozfr]
https://hg.mozilla.org/integration/mozilla-inbound/rev/3a55d64f56ef
Flags: in-testsuite?
Target Milestone: --- → mozilla11
https://hg.mozilla.org/mozilla-central/rev/3a55d64f56ef
Status: ASSIGNED → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED

Comment 11

6 years ago
My location.json is still being ignored (using the 2011-11-21 Nightly).

(as you may have noticed, the location used in my example in Comment 6 is not my real location and a latitude of 123.45 does not make much sense)

Is there any other explanation why my location.json gets ignored starting with Firefox 9.0? Should I open a new bug report?

Comment 12

6 years ago
Comment on attachment 574274 [details] [diff] [review]
patch v.1 correction

[triage comment]
Approved for aurora as well!
Attachment #574274 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
https://hg.mozilla.org/releases/mozilla-aurora/rev/36975a40a443
status-firefox10: --- → fixed
status-firefox9: --- → affected
(Assignee)

Comment 14

6 years ago
Markus Popp, Geolocation schema has changed :
{
  "status": "OK",
  "accuracy": 150.0,
  "location": {
    "lat": -33.85702,
    "lng": 151.21494
  },
  "access_token": "quijibo"
}
take a look has the new NetworkGeolocationProvider.js
http://mxr.mozilla.org/mozilla-central/source/dom/system/NetworkGeolocationProvider.js

Comment 15

6 years ago
(In reply to René-Luc from comment #14)
> Markus Popp, Geolocation schema has changed :
> {
>   "status": "OK",
>   "accuracy": 150.0,
>   "location": {
>     "lat": -33.85702,
>     "lng": 151.21494
>   },
>   "access_token": "quijibo"
> }
> take a look has the new NetworkGeolocationProvider.js
> http://mxr.mozilla.org/mozilla-central/source/dom/system/
> NetworkGeolocationProvider.js

Thank you very much! This did the trick.
http://hg.mozilla.org/releases/mozilla-beta/rev/e6aec165b161
status-firefox9: affected → fixed
Whiteboard: [mozfr] → [mozfr][qa+]
What is the test case and steps to verify this fix? I assume it means adding something to about:config and going to a site like google maps to verify location. Could someone please clarify what needs to be done? Thanks
Whiteboard: [mozfr][qa+] → [mozfr][qa?]
I asked juan becerra  to add litmus tests for this.  He should be able to help.
(Clearing to stop this request showing up on the 'My Requests' page)
Flags: in-testsuite?
You need to log in before you can comment on or make changes to this bug.