Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inconsistent link embeds with [[]] and {{}} #235

Open
zsotroav opened this issue Jan 8, 2022 · 2 comments
Open

Inconsistent link embeds with [[]] and {{}} #235

zsotroav opened this issue Jan 8, 2022 · 2 comments

Comments

@zsotroav
Copy link

zsotroav commented Jan 8, 2022

When requesting a URL with [[<page>]] or {{<page>}} the bot usually doesn't show the page embed. However, this is inconsistent when the bot has to "think".

Expected result:
[[Template:Babel]], {{Babel}}, and {{Template:Babel}} all return the same link without any embeds shown

Actual result:
The embed is visible when using {{Template:Babel}}

Affected versions:

  • Fandom MediaWiki pages (Tested on multiple wikis, including CC)
  • wikipedia.org

Additional remarks:

  • The bot "thinks" (reacts with ⌛ ) before sending the link with the embed visible
  • The bot responds with the link for the page Babel (instead of Template:Babel) when requesting {{Babel}} on wikipedia.org

image

@Markus-Rost
Copy link
Owner

{{<page>}} was originally intended to embed the page under that name (like !wiki <page>) and the fallback to template links was only added later.

  • {{Babel}} is looking for a page named "Babel" in the main namespace, doesn't find anything and then falls back to "Template:Babel" which exists and is only linked.
  • {{Template:Babel}} is looking for a page named "Template:Babel" which exists and is therefor fully embedded. The fallback for template links is not triggered.

I know this is unintuitive and annoying for normal users and wiki editors alike and I have been planning to overwork the inline links for a while but just didn't get to it yet.

@zsotroav
Copy link
Author

Okay, I think I understand that, but the inconsistency error is still present.

Putting aside the question of intuitive design, {{Babel}} and {{Template:Babel}} should return the same result with the embed in this context.

But on the side of intuitive design, {{<page>}} should, in my opinion, prioritize templates

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants