Block adding Wikipedia relationships to anchors (STYLE-835)

Tags: #<Tag:0x00007f2a00a47b68>


As I wrote on the STYLE-835 ticket:

An entity should only be linked to a Wikipedia (or Wikidata) page that is indeed for the entity in question. This follows from these two guideline segments: “The URL should still be specific to the entity being linked” (although this is mostly meant as “do not link to too wide pages”) and “Points to the Wikipedia page for this artist”.

This suggests that we should block linking to anchors in Wikipedia pages.

Generally, this is being used to point to things like a section for a particular member of a group, or a particular album, on the page for the group as a whole. This not only goes against the previous idea of a 1:1 matching between page and entity but also causes other problems, like MBS-9463 (the abstract extracted is of course for the page, not the section linked, which does not itself have an abstract). Additionally, since sections of a page do not get Wikidata pages, anchors will in any case be lost once we finish a migration from Wikipedia to Wikidata.

I am opening this to see if there’s any big problems I’m missing regarding this change, although unless a solution is offered with regard to the Wikidata migration dropping anchors anyway, it might very well be a moot point to be honest.

pinned #2


Well, the anchor (technically, “fragment”) is part of the URL, so it’s technically following the first guideline. But yeah, it doesn’t really make sense with Wikipedia, so I don’t see any problem blocking it there.

As long as we’re only talking about blocking it for Wikipedia.

Some sites do weird things like displaying entirely different pages via client-side JavaScript based on the fragment, and we should still be able to link to those for sites that aren’t Wikipedia.

BTW: It won’t be a complete fix, as sometimes Wikipedia editors merge multiple small pages together, and then leave redirects to sections of the larger page. E.g.,


Definitely :slight_smile: I have nothing against anchors all the time, and as you said some sites depend on them.

Heh. Well this guy does have a Wikidata page - so we would have something to link to, just no English article to display.


I think we should just move ahead and block Wikipedia altogether and finish the migration to only use Wikidata. But eh. :stuck_out_tongue:


I agree this is what should eventually happen, but first we need to write some code to let people paste a Wikipedia link and automatically add the Wikidata equivalent instead :slight_smile:


My $0.02
I think if John Smith has a WP page, we can link to WP. But we shouldn’t be linking to Band X. Nor should we point to, Band X#John Smith.

One of the problems with only linking to articles, rather than subsections of articles is that WP is fluid.
An article today may become a redirect tomorrow.

For example:
Fred Eltringham redirects to his band, The Wallflowers. Not a specific subsection. His article was created as a redirect. It never had content.
And then there is Jesse Money (I created her MB entry), where her WP article redirects to a subsection of her father’s article.
But, Normani Kordei previously had an article. It no longer is an article. It redirects to her band, Fifth Harmony.

Tomorrow, who knows, those three people could have their own article instead of pointing to somewhere else.

It’s just something to think about.


Added a new guideline to Wikipedia relationships:

“Do not link to anchors on a wider page (Page_Name#Page_Section), even if they are specifically about this work. You should only add this relationship if the page itself is about the work.”

Also entered MBS-9515 to actually block people from entering anchor links.