WikiEduDashboard icon indicating copy to clipboard operation
WikiEduDashboard copied to clipboard

Some DeUserfyingAlert records have Article records that include a namespace prefix in the title

Open ragesoss opened this issue 2 years ago • 3 comments

What is happening?

In Wiki Education production, we noticed a few cases recently where the email for a DeUserfyingAlert included an incorrect article link, pointing to (for example) User:User:Cbetters23/sandbox instead of User:Cbetters23/sandbox.

The immediate cause for this is that the Article record that the Alert record is linked to has a title attribute that includes the "User:" prefix, in addition to namespace: 1. Normally, the title is saved without the namespace

Here are related links to some cases we found where this happened:

  • https://en.wikipedia.org/w/index.php?title=Special:Log&logid=153791580
  • https://en.wikipedia.org/w/index.php?title=Special:Log&logid=153798210
  • https://en.wikipedia.org/w/index.php?title=Special:Log&logid=155908877

To Reproduce

???

Expected behavior

All Article records in the Dashboard database should include titles without the namespace prefix (and of course, links in alert emails should point to the correct page).

Additional context

Although we noticed this problem via the DeUserfyingAlert, the actual bug — Article records with a prefix in the title — might be independent. We should investigate all the places that either create or update the title for Article records.

ragesoss avatar Oct 18 '23 18:10 ragesoss

@ragesoss I'd like to do this

123ZOKzok avatar Oct 19 '23 14:10 123ZOKzok

@123ZOKzok you're welcome to give it a try! feel free to ask questions here as you explore. I spent some time thinking about how this might be happening, but I was stumped.

ragesoss avatar Oct 19 '23 14:10 ragesoss

@ragesoss okay

123ZOKzok avatar Oct 19 '23 14:10 123ZOKzok