Open Bug 1025093 Opened 5 years ago Updated 4 years ago

Add Mapbox attribution to map UI on Edit Profile


(Participation Infrastructure :: Phonebook, defect)

Not set


(Not tracked)



(Reporter: williamr, Unassigned)


(Depends on 1 open bug, Blocks 1 open bug, )


(Whiteboard: [kb=1423316] [Triage 2015-04-17])


(1 file)

The current map UI on the Edit Profile page has attributions for Leaflet and OpenStreetMap. We may also want to add an attribution for Mapbox, which powers the geolocation data.

Here is the current attribution text:
Leaflet | © OpenStreetMap contributors

For reference, here is the attribution text used on
© OpenStreetMap contributors, © Mapbox © OpenStreetMap | Improve this map Terms & Feedback © Mapbox © OpenStreetMap Improve this map

Note that the attribution text on has some redundant parts. '© OpenStreetMap | Improve this map' appears twice.
Blocks: 920651
We previously had to hack leaflet to add attribution satisfying the OpenStreetMap guidelines. See bug 944750, bug 944758. 

As of the latest mapbox.js, the default attribution is satisfactory:

In other words, on maps where we previously hacked leaflet we can remove the hack and simply use the latest mapbox.js (for example, bug 1021035). On new maps we should just be sure to use the latest mapbox.js.
Assignee: nobody → jgiannelos
Whiteboard: [kb=1423316]
Commits pushed to master at
[Fix bug 1025093] Fix mapbox attribution to map UI.
Merge pull request #998 from johngian/1025093-fix-attribution

[Fix bug 1025093] Fix mapbox attribution to map UI.
Closed: 5 years ago
Resolution: --- → FIXED
Version: other → next
Attached image qa - reopened
Reopening for clarification
What is the expected text, the attributes in mapbox are redundant.

© OpenStreetMap contributors, © Mapbox © OpenStreetMap | Improve this map Terms & Feedback © Mapbox © OpenStreetMap

© OpenStreetMap contributors, © Mapbox © OpenStreetMap | Improve this map Terms & Feedback
Resolution: FIXED → ---
Hmm, this is only happening on stage, dev looks OK. I'll investigate.
Commit pushed to master at
Revert "[Fix bug 1025093] Fix mapbox attribution to map UI."

This reverts commit db03f6449ae073450bfa9fb0dab1666702087780.

Automatic attribution fails when using Mozilla's mapbox IDs.
We need to investigate this further.
Closed: 5 years ago5 years ago
Resolution: --- → FIXED
It seems that this happens only when using the ids for mozilla that mapbox issued. On our local environments we use example ids which work OK (and so does mozillians dev. I will file a bug to update those)

I already contacted mapbox for help. Meanwhile I'm reverting this change.
Resolution: FIXED → ---
Version: next → other
To clarify, this will not go out with the next release
I contacted Mapbox support:

From the project, `mozilla-webprod.i81ph114` in the account it looks
like there are two street layers composed which is why the attribution
is showing up twice and is identical. From the data pane, "Spiffy
streets" is added as a layer on top of Mapbox streets. One idea might
be to use the data layer, 'mozilla-webprod.e91ef8b3' directly?

I don't understand why we have two mapbox id's in the first place, one for the profile page alone and one generic. Maybe Wray can shed some light on this?
Flags: needinfo?(wbowling)
This was perhaps already clarified sooner (via IRC?), but I'll explain it here just to be sure.

Each Mapbox account is made up of two halves:
A. Projects
B. Data

The relationships are built like so:
1. Each Project and Data gets a unique Mapbox ID
2. Projects are collections of 1 or more Data
3. Front-end displays can load Projects or Data Layers
4. Only Projects track usage analytics

Mozillians only one Data but has two Projects
D1. Visualization data layer
P1. A project loading just D1 (visualization layer)
P2. A project loading Mozilla's 'mozilla-webprod.e91ef8b3' that keeps analytics separate from that's only used for editing your profile.

The reason there are two styles is that there are two needs.
P1. the data visualization layer is much more distilled There are no labels on it — it's purpose is to give users a general and anonymized review of who lives where
P2. while editing your profile it's nice to not have all the data visualization noise in your way and clear labels. Even though your information will be obfuscated later, it makes sense to allow more specificity since you only are viewing yourself.
Flags: needinfo?(wbowling)
Assignee: jgiannelos → nobody
This needs  upgrading mapboxjs and use tokens.
Whiteboard: [kb=1423316] → [kb=1423316] [Triage 2015-04-17]
No longer blocks: 1129848
Depends on: 1195705
You need to log in before you can comment on or make changes to this bug.