Page MenuHomePhabricator

Investigation: what is Kartographer hashing?
Closed, ResolvedPublic1 Estimated Story Points

Description

The Kartographer extension creates a hash to identify a given revision of geojson. This hash will remain stable after a page is edited, depending on whether or not the map data is edited. Does this hash includes location markers which can be pulled in from elsewhere on the page, outside of the map tag? Is there one hash per page, or per map tag?

Findings

  • In Wikivoyage mode:
    • This is the only mode in which a maplink may be rendered as a marker inside of a mapframe elsewhere on the page.
    • Groups are named.
    • The SHA-1 hash we're investigating seems to not be present when group names are used (example)
    • Static maps are never (see below for the one exception) used, so we don't have to consider named groups for our solution.
  • For all non-wikivoyage wikis
    • "group" and "show" are ignored.
    • Markers from one maplink will not be overlaid on other maps in the page.
    • The internal "group ID" is a SHA-1 hash of geoinfo json for that maplink or mapframe (example).
  • $wgKartographerStaticMapframe = true and $wgKartographerWikivoyageMode = true are only set at the same time on exactly one wiki, mediawiki.org .
    • This mode seems to be broken, it doesn't look like any maplinks are rendered in the static maprame.
    • In its current state, this mode will defeat our proposed fixes, since the content hash is not sent.

Related Objects

Event Timeline

awight set the point value for this task to 1.Sep 29 2021, 10:21 AM
awight moved this task from Sprint Backlog to Doing on the WMDE-TechWish-Sprint-2021-09-29 board.
awight moved this task from Doing to Sprint Backlog on the WMDE-TechWish-Sprint-2021-09-29 board.
awight renamed this task from Investigation: what is included in a Kartographer hash? to Investigation: what is Kartographer hashing?.Oct 1 2021, 12:10 PM
awight updated the task description. (Show Details)

The big surprise is that the question about named groups turns out to be irrelevant, these aren't used with static maps configured.