Last modified: 2011-09-04 15:32:29 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 12131 - Names given to system messages should follow a single naming covention
Names given to system messages should follow a single naming covention
Product: MediaWiki
Classification: Unclassified
General/Unknown (Other open bugs)
All All
: Low enhancement with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
: i18n
Depends on:
Blocks: code_quality
  Show dependency treegraph
Reported: 2007-11-27 18:09 UTC by Huji
Modified: 2011-09-04 15:32 UTC (History)
6 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Description Huji 2007-11-27 18:09:17 UTC
...We have names-with-hyphens, names_with_underscores, nameswithoutanyseparator, and perhaps more! I don't think I should give a reason why having them all in a single format is better.

I know why every single developer would avoid changing current messages to make all of them follow one writing method (except for fixing the code in lots of places, there is the issue of wikis which use texts other than that on the message file, and even fixing Wikimedia wikis will be a big trouble).

However, I don't see a reason why we shouldn't decide a single format to be used for "newly created" messages.

Please advise
Comment 1 Aryeh Gregor (not reading bugmail, please e-mail directly) 2007-12-18 18:13:04 UTC
We should probably go with whatever is most prevalent now.  I generally use hyphens, they're more readable in the code, but underscores translate to spaces in the UI and so are perhaps more readable there.
Comment 2 Huji 2007-12-18 18:35:25 UTC
I'm glad there is a reply to this one! Anyways, the most prevalent way is to simply put the words next to each other (likethisone) which I don't really like.
Comment 3 Brion Vibber 2007-12-18 19:15:05 UTC
Avoid spaces/underscores; where word separators are desired, use the hyphen (-).
Comment 4 Huji 2007-12-21 11:42:06 UTC
Is there a way to anounce this (other than bugzilla and its counterpart mailing list), so developers would know about the standard you suggested here, brion? (I'm also thinking of updating
Comment 5 Brion Vibber 2007-12-21 17:07:03 UTC
Dropping a note on wikitech-l maybe?
Comment 6 Huji 2007-12-23 09:36:32 UTC
Thank you Brion; I sent the email.

Now that we have a standard for our newly created messages, we can discuss about generalizing it to already in-use messages too. I suggest we should define the problems and then find the solutions for them.

These are the problems I see in changing the name of previously created system messages to make them use hyphens:

# The whole code should be scanned and all instances of calling that message should be updated. This is sometimes more than a simple find and replace, because some message names do not appear in the code obviously, but are called by using some variables (things like wgMsg( $var . "_blah" ); )

# Extensions should also be scanned. (Such changes may break some extensions which are not maintained through our subversion system. I'm not sure if this is our problem to fix those independent extensiosn too.)

# Some local wikis use MediaWiki namespace to define other translations for the messages. A typical example is the delete reason dropdown list, which is usually changed on local wikis.

Before proceding to solutions for the above, are there any other difficulties which I've missed?
Comment 7 Dan Jacobson 2007-12-26 23:20:46 UTC
Don't get angry but Bug 12362 is a similar problem.
Comment 8 Huji 2007-12-27 13:48:21 UTC
Why to get angry? The problems are more "related" rather than "similar" I think. They don't depend on each other or duplicated each other, so they can be discussed separately on different bugs.
Comment 9 Niklas Laxström 2009-08-03 08:38:39 UTC
The rules and guidelines for naming should be written down, and somewhat forced for new messages. Renaming existing messages causes more harm than good if done on large scale.
Comment 10 Siebrand Mazeland 2011-09-03 16:24:49 UTC
Per previous comments, not making large global changes to get everything consistent. Guidelines are at [[mw:Localisation#Adding_new_messages]] which I just reviewed and updated a bit. We are planning to start paying more attention to following these guidelines in the localisation team, and we will be more picky during code review.

WONTFIX is the most appropriate solution, even though it doesn't look all that friendly :).

Note You need to log in before you can comment on or make changes to this bug.