Page MenuHomePhabricator

UserMerge does not parse wikitext on "usermerge-success-log"
Closed, ResolvedPublic



16:58, 1 August 2017 DerHexer (talk | contribs | block) merged the account "Yuvipanda" (349102) into "User:YuviPanda|YuviPanda" (2484972)

Either we remove the wikisyntax from 'usermerge-success-log' message or we fix UserMerge to parse that correctly.

Related Objects

Event Timeline

This is a problem with using getUserPage() and getName(). We can use, for the merged account getUserPage() as well and it'll fix the log if I understand this rightly. But maybe you want to use a different logging system/format? If you want to take that path instead I'm not sure I'll be able to do it.

or... add in extension.json

"LogActions": {
  "usermerge/*: "LogFormatter"

? (seems rather easy to be true)

Change 431477 had a related patch set (by MarcoAurelio) published:
[mediawiki/extensions/UserMerge@master] Temporary fix to unbreak logs

Adding it to extension.json will be enough:

"LogActionsHandlers": {
	"usermerge/*": "WikitextLogFormatter"

Or if you only want it formatted in wikitext for successful messages, switch out usermerge/* with usermerge/mergeuser instead.

Also note that doing that change will also mean bumping the MediaWiki requirement to at least 1.31.0 (currently it's 1.28.0 and above)

@SamanthaNguyen Do I have to get rid of the UserMergeLogger.php file as well? I'm surprised this is so easy to fix :)

Change 431477 abandoned by MarcoAurelio:
Unbreak log entries due to user merge log not supporting wikitext

Abandon in favor of using WikitextLogFormatter.

Nope! Just make the change in extension.json. :) The UserMergeLogger class is just a helper class for adding log entries.

Okay! I'll try that. Sorry if it's a dumb question but, will this fix then the log issues described in the task description? Thanks.

Change 431485 had a related patch set (by MarcoAurelio) published:
[mediawiki/extensions/UserMerge@master] Use WikitextLogFormatter on UserMerge

Change 431485 merged by jenkins-bot:
[mediawiki/extensions/UserMerge@master] Use WikitextLogFormatter on UserMerge

MarcoAurelio claimed this task.
MarcoAurelio removed a project: Patch-For-Review.