Page MenuHomePhabricator

When using auto-positioning, Special:Map displays confusing/misleading caption "Invalid coordinates supplied"
Closed, ResolvedPublic

Description

Currently if auto-positioning is used (no coordinates entered in map syntax) then the non-JavaScript fallback page Special:Map displays caption "Invalid coordinates supplied". Missing coordinates should be handled in a less confusing way.

If there is a way to do so, then perhaps center coordinates of the auto-positioned map could be passed to Special:Map. Or, maybe link to Special:Map could be omitted altogher if auto-positioning is used. This is because showing location of map center is not necessarily meaningful anyway, especially if auto-positioned map displays object(s) across large part of the world (actually the latter applys to maps that have coordinates entered, too).

Then again, omitting the link is probably even more confusing if maplink syntax is used (no map, only link). Then maybe displaying caption that reads something like "You need to enable JavaScript to see map content" on Special:Map for auto-positioned content would be sufficient.

Event Timeline

Aklapper renamed this task from Auto-positioning and Special:Map to When using auto-positioning, Special:Map displays confusing/misleading caption "Invalid coordinates supplied".May 20 2019, 12:25 PM

Please give a specific example, there are so many different modes and templates wrapping the modes, an example page really helps investigating a ticket.

Please give a specific example, there are so many different modes and templates wrapping the modes, an example page really helps investigating a ticket.

The following is an example of map using auto-positioning (no latitude/longitude entered). If I disable JS and click on map, then map caption says "Invalid coordinates supplied":
<mapframe height="200" width="200">[{"type":"ExternalData","service":"geoline","ids":"Q12359820"}]</mapframe>

That is, compared to no auto-positioning for which Special:Map displays marker on world map:
<mapframe latitude="59.3647" longitude="24.893" zoom="12" height="200" width="220">[{"type":"ExternalData","service":"geoline","ids":"Q12359820"}]</mapframe>

Renders as:

<a class="mw-kartographer-map" data-mw="interface" data-style="osm-intl" data-width="200" data-height="200" data-overlays="[&quot;_9cdb73f3621bb1a9c19a393cd219c4f90bf7ce3e&quot;]" style="background-image: url(https://maps.wikimedia.org/img/osm-intl,a,a,a,200x200.png?lang=en&amp;domain=localhost&amp;title=T223880&amp;groups=_9cdb73f3621bb1a9c19a393cd219c4f90bf7ce3e); height: 200px;" href="/wiki/index.php/Special:Map/a/a/a/en"></a>

Change 889179 had a related patch set uploaded (by Thiemo Kreuz (WMDE); author: Thiemo Kreuz (WMDE)):

[mediawiki/extensions/Kartographer@master] Stop creating links to Special:Map that are known to be broken

https://gerrit.wikimedia.org/r/889179

Change 889493 had a related patch set uploaded (by Thiemo Kreuz (WMDE); author: Thiemo Kreuz (WMDE)):

[mediawiki/extensions/Kartographer@master] Don't create impossible Special:Map/a/a/a links

https://gerrit.wikimedia.org/r/889493

Change 889493 merged by jenkins-bot:

[mediawiki/extensions/Kartographer@master] Don't create impossible Special:Map/a/a/a links

https://gerrit.wikimedia.org/r/889493

Change 889179 abandoned by Thiemo Kreuz (WMDE):

[mediawiki/extensions/Kartographer@master] Stop creating links to Special:Map that are known to be broken

Reason:

Done as part of Icc4d142.

https://gerrit.wikimedia.org/r/889179

Pikne assigned this task to thiemowmde.

It seems this issue no longer comes up. Thanks!

Now there's a targetless a element that might be a bit confusing when hovered over but I suppose that's no big deal and there's little point to keep this task open because of it (or if necessary a new task can be created about handling this better).