Last modified: 2011-11-09 02:29:17 UTC
When a namespace is added to LocalSettings.php using the parameter $smwgNamespacesWithSemanticLinks, the pages in the newly added namespace will not be updated to have the default property "Modification date". This needs to be corrected to add this property. The only solution I know of is to manually click "Edit" on each page, and then click "Save". That will work even if nothing is changed. If nothing is changed, then the correct modification date will be shown even if it is a date from before the namespace was added. Since the manual solution to this is so simple, I think it will be straightforward to automatically fix this problem using the maintenance script in Special:SMWAdmin simply by making it repeat the manual solution above in an automatic fashion for all EXISTING pages in the newly added namespace that do not have a modification date property. Since SMW has a bug with deleted pages (https://bugzilla.wikimedia.org/show_bug.cgi?id=29892), it is important to make sure that the pages really exist before doing this procedure.
A quick way to test this bug and play with it is with this in LocalSettings.php $smwgNamespacesWithSemanticLinks = array( NS_MAIN => true, NS_TALK => false, NS_USER => true, NS_USER_TALK => false, NS_PROJECT => true, NS_PROJECT_TALK => false, NS_MEDIAWIKI => true, NS_MEDIAWIKI_TALK => false, NS_TEMPLATE => true, NS_TEMPLATE_TALK => false, NS_HELP => true, NS_HELP_TALK => false, NS_CATEGORY => true, NS_CATEGORY_TALK => false, SMW_NS_PROPERTY => true, SMW_NS_PROPERTY_TALK => false, SMW_NS_TYPE => true, SMW_NS_TYPE_TALK => false, SMW_NS_CONCEPT => true, SMW_NS_CONCEPT_TALK => false, SF_NS_FORM => true, SF_NS_FORM_TALK => false, ); And then use this on a wiki page to display one of the newly added namespaces ("Mediawiki" in this example): {{#ask: [[:Mediawiki:+]] | ?Modification date | mainlabel=Mediawiki namespace [[Special:AllPages]] | limit=500}}
This makes sense since this data gets saved on save, so it won't magically appear on all pages when enabling it. If you want it to show up everywhere immediately, then you can run the data update/refresh thing on SMWAdmin and then run maintenance/runJobs.php. If you can't do the later, at least the data will be set eventually (depending on your wikis size and jobQueue settings) without having to do more manual work.