Page MenuHomePhabricator

Better handling of invalid titles
Open, LowPublicBUG REPORT

Description

What is the problem?

If I search for an invalid title (such as one containing [ or <) I am taken to the title conflict step, told incorrectly that the article already exists and the continue button is greyed out.

I am not informed that my title contains invalid characters so I don't know how to fix it. I am not suggested a new title without those characters.

It also seems to have an impact on what suggestions you are shown (compare reproduction Case 1 with Case 2).

Steps to reproduce problem

Case 1

  1. https://test.wikipedia.org/wiki/Special:NewArticle?newarticletitle=[KHK2017]_165
  2. Select the first option

Case 2

  1. https://test.wikipedia.org/wiki/Special:NewArticle?newarticletitle=KHK2017_165
  2. Select the first option
  3. In this case, you are shown a suggestion of KHK2017 165 (Astronomical object)
Environment

Wiki(s): https://test.wikipedia.org ArticleGuidance – (6e031c0) 12:37, 9 July 2026.

Screenshots

badtitle.png (1,097×379 px, 29 KB)

Event Timeline

GGalofre-WMF moved this task from Backlog to Pre-Visual Editor on the Article-Guidance board.

Change #1310595 had a related patch set uploaded (by Shreyapedia; author: Shreyapedia):

[mediawiki/extensions/ArticleGuidance@master] T432111: Better handling of invalid titles

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

Change #1310595 had a related patch set uploaded (by Shreyapedia; author: Shreyapedia):

[mediawiki/extensions/ArticleGuidance@master] newarticle: Show error when the entered title is invalid

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

can someone tell what does the "better handling" in this ticket? are we just

1/ disable any search with title that contains [ ] < (and others); or
2/ auto detect and change to relevant title? for example search for [Hg(CN)2], it has one related article Mercury(II)_cyanide

image.png (748×388 px, 53 KB)

Heyy, I've paused my work for now just let me know which direction we decide to go and I'll update the code!