Last modified: 2008-06-12 10:52:21 UTC
User reported on the mailing list
that two relations Rel1 and A:Rel1 on the same page collapse into one relation, "Rel1".
I was able to reproduce this by creating a property with the namespace "Help:" in its name.
[[Test relation::Sandbox2a]] [[MyPrefix:Test relation::Sandbox2b]] [[Help:Test relation::Sandbox2c]
The factbox lists the property "Test relation" with the values Sandbox2a and Sandbox2c. (The property name "MyPrefix: Test relation" has no problem because it's just a name with a colon in it.)
I'm not sure why the "Help" namespace vanished. But it seems insane to allow a property name to include a namespace name. So rather than show the confusing
Help:Test relation sandbox2
in the factbox when the link actually goes to a property, it would be better to warn the user
Don't use namespace ("Help") in a property's name.
This is fixed now, though it is still not recommended to label properties like that. Anyway, similar problems are likely to occur again: the troble is that we often use MediaWiki's Title::newFromText to process user input. This method takes a namespace as a parameter, but this namespace is the default only, not an overwrite. So as long as titles have no namespaces, the default works as expected, but if title strings bring their own namespace, it overrides the default. The only workaround is to fetch the local label of a desired namespace and to prepend it manually.