My property list is mainly empty - what happened and how do I fix it?
I noticed that my in-line queries weren't working. So I looked at some pages that had set the properties - the pages were OK, but the properties seemed to have been ignored.
When I list all the properties, they are there, but the show (0 users).
I've tried running rebuildData.php on all IDs, and touching LocalSettings.php - but it remains the same.
How do I get it to re-link all the properties again?
This very much sounds like this worry. Just answered to this thread on the list though it will probably not help the cause. :(
Thank you for the suggestion - my problem is similar, but, fortunately, not quite the same.
The properties are there, and they don't show 'invalid content' - just no references.
I'm trying this at the moment, as recommended:
running this three times to rebuild the properties:
php rebuildData.php -ftpv
Now running this twice (maybe three times, it doesn't take too long) to rebuild them:
php rebuildData.php -v
Then I'm going to do a normal 'update', remove the cache and hope..
If that doesn't work, I'm not sure what the next step is.
I don't know if this is connected. Mainly the rebuildData runs through OK, but there are these:
PHP Notice: Undefined index: REMOTE_ADDR in /home/kchcl200/public_html/wiki/extensions/userInfo/userInfo.php on line 43 PHP Notice: Undefined index: REMOTE_ADDR in /home/kchcl200/public_html/wiki/extensions/userInfo/userInfo.php on line 58 PHP Notice: Undefined variable: os in /home/kchcl200/public_html/wiki/extensions/userInfo/userInfo.php on line 83 PHP Notice: Undefined variable: bw in /home/kchcl200/public_html/wiki/extensions/userInfo/userInfo.php on line 133 PHP Notice: Undefined variable: bw in /home/kchcl200/public_html/wiki/extensions/userInfo/userInfo.php on line 158
and:
PHP Warning: preg_split() expects parameter 3 to be long, string given in /home/kchcl200/public_html/wiki/extensions/ParserFunctions/ParserFunctions_body.php on line 811 (1990) Processing ID 1990 ... PHP Warning: preg_split() expects parameter 3 to be long, string given in /home/kchcl200/public_html/wiki/extensions/ParserFunctions/ParserFunctions_body.php on line 811
I'll have to fund page ID 1989 and1990 and see what's going on there.
I've found the pages - it was a very complicated template - that I don't need. I've deleted it and I hope things will get better.
The first lot of notices comes from the unmaintained UserInfo extension, so this is not connected to the problem. Indeed sometimes a template may contain syntax which breaks things or triggers warnings. Usually some falsely applied syntax within the template is the cause. This happens once in a while, but I think that this is not really connected to the issue.
I've narrowed this down.
The problem is that properties are not created and don't have their count increased when a page is saved.
They are recognised as properties on the page.
Categories are saved.
I've put the versions at the bottom - but PHP and MySQL are at different versions - the wikis are both running the same SMW (also listed at the bottom)
This is the test I've run. The first wiki is the original wiki. The second is the copy of it running on another machine.
Test of two wiki's: First wiki: http://kchclinics.com/wiki/index.php?title=Sandpit:Property_test ==Property Test== __NOEDITSECTION__ [[Has type::Text]] [[Has colour::Orange]] [[Location::Ouagadougou]] [[Population::1,475,223]] [[Capital of::Burkina Faso]] [[Category:City]] [[Category:African]] =================== Create Page: Left hand column shows 'Browse properties' Items show up as: Blue - Text Red - Orange 1,475,223 Burkina Faso - City African Black - Ouagadougou ================================ Browse property page shows: Sandpit:Property test Capital of Burkina Faso Has colour Orange Location Ouagadougou Population 1,475,223 Categories City , African Modification date 22 August 2014 07:34:45 Has type Text --- Categories page shows African & City --- Properties Page: Shows: Capital of - 1 use Has Type - 4 uses Has colour - 1 use Location - 75 uses Population - 9 uses --------------------------------------------------------- Second Wiki =================== Create Page: Left hand column DOES NOT show 'Browse properties' Items show up as: Blue - Text Red - Orange 1,475,223 Burkina Faso - City African Black - Ouagadougou --- Properties Page: Does NOT show: Capital of Has colour Population Does show: Has Type - but only 1 use Location - but '0' uses --- Categories page shows African & City ================================================ The physical set up is: First Machine Apache version 2.2.27 PHP version 5.3.28 MySQL version 5.5.34-cll-lve Architecture x86_64 Operating system linux Dedicated IP Address 69.28.199.12 Path to sendmail /usr/sbin/sendmail Path to Perl /usr/bin/perl Perl version 5.10.1 Kernel version 2.6.32-531.17.1.lve1.2.60.e Second Machine Apache version PHP version 5.5.9 MySQL version 5.5.38 Architecture x86_64 Operating system linux Kernel version Ubuntu 14.04.1 === SMW versions Machine One: Semantic Compound Queries (Version 0.3.4) A parser function that displays multiple semantic queries at the same time Yaron Koren Semantic Drilldown (Version 1.4) A drilldown interface for navigating through semantic data Yaron Koren and others Semantic Extra Special Properties (Version 1.2.1) Adds some extra special properties to all pages Leo Wallentin, James Hong Kong and others Semantic Forms (Version 2.7) Forms for adding and editing semantic data Yaron Koren, Stephan Gambke and others Semantic Forms Inputs (Version 0.7) Additional input types for Semantic Forms Stephan Gambke and others Semantic Image Input (Version 0.3.0 alpha) Adds an image input that pulls images from Wikipedia to Semantic Forms Jeroen De Dauw Semantic Internal Objects (Version 0.7.6) Setting of internal objects in Semantic MediaWiki Yaron Koren Semantic Maps (Version 3.0.4) Provides the ability to view and edit coordinate data stored with the Semantic MediaWiki extension Jeroen De Dauw Semantic MediaWiki (Version 1.9.2) Making your wiki more accessible - for machines and humans (online documentation) Markus Krötzsch, Jeroen De Dauw, James Hong Kong and others Semantic Result Formats (Version 1.9.1) Additional result formats for Semantic MediaWiki queries James Hong Kong, Stephan Gambke, Jeroen De Dauw, Yaron Koren and others Semantic Watchlist (Version 0.2.2) Lets users be notified of specific changes to Semantic MediaWiki data Jeroen De Dauw for WikiWorks SemanticFormsSelect (Version 1.1) Generate a select field in Semantic Form which values are from query Jasonzhang Special pages Access Log (Version 2.0) Logs user access to MediaWiki Aleksandar Bojinovic, Peter Kin-Fong Fong CheckUser (Version 2.3) Grants users with the appropriate permission the ability to check user's IP addresses and other information Tim Starling and Aaron Schulz EmailPage (Version 2.3.0, 2013-11-30) Send rendered HTML page to an e-mail address or list of addresses using phpmailer User:Nad MaintenanceShell (Version 0.4.0) === SMW versions machine Two Semantic Compound Queries (Version 0.3.4) A parser function that displays multiple semantic queries at the same time Yaron Koren Semantic Drilldown (Version 1.4) A drilldown interface for navigating through semantic data Yaron Koren and others Semantic Extra Special Properties (Version 1.2.1) Adds some extra special properties to all pages Leo Wallentin, James Hong Kong and others Semantic Forms (Version 2.7) Forms for adding and editing semantic data Yaron Koren, Stephan Gambke and others Semantic Forms Inputs (Version 0.7) Additional input types for Semantic Forms Stephan Gambke and others Semantic Image Input (Version 0.3.0 alpha) Adds an image input that pulls images from Wikipedia to Semantic Forms Jeroen De Dauw Semantic Internal Objects (Version 0.7.6) Setting of internal objects in Semantic MediaWiki Yaron Koren Semantic Maps (Version 3.0.4) Provides the ability to view and edit coordinate data stored with the Semantic MediaWiki extension Jeroen De Dauw Semantic MediaWiki (Version 1.9.2) Making your wiki more accessible - for machines and humans (online documentation) Markus Krötzsch, Jeroen De Dauw, James Hong Kong and others Semantic Result Formats (Version 1.9.1) Additional result formats for Semantic MediaWiki queries James Hong Kong, Stephan Gambke, Jeroen De Dauw, Yaron Koren and others Semantic Watchlist (Version 0.2.2) Lets users be notified of specific changes to Semantic MediaWiki data Jeroen De Dauw for WikiWorks SemanticFormsSelect (Version 1.1) Generate a select field in Semantic Form which values are from query Jasonzhang Special pages Access Log (Version 2.0) Logs user access to MediaWiki Aleksandar Bojinovic, Peter Kin-Fong Fong CheckUser (Version 2.3) Grants users with the appropriate permission the ability to check user's IP addresses and other information Tim Starling and Aaron Schulz EmailPage (Version 2.3.0, 2013-11-30) Send rendered HTML page to an e-mail address or list of addresses using phpmailer User:Nad MaintenanceShell (Version 0.4.0) Wiki interface for maintenance scripts Andrew Fitzgerald and Timo Tijhof Parser hooks and http://www.shadowritter.net Chklist (Version 0.1.1) Add checkbox on your wiki page Shadowritter DynamicPageList (Version 2.01) A highly flexible report generator for MediaWikis Gero Scholz GetUserName (Version 1.0) Get current user's name. Ejcaputo Maps (Version 3.0.1) Enables embedding of dynamic maps into wiki pages, geocoding of addresses and other geographical operations. Jeroen De Dauw MsUpload (Version 9.5.1) Enables easy uploads (when available also via drag&drop) for one or multiple files simultaneously info@ratin.de | Ratin ParserFunctions (Version 1.5.1) Enhance parser with logical functions Tim Starling, Robert Rohde, Ross McClure and Juraj Simlovic Strtotime (Version 1.0) Represents time as a string containing a US English date format Xavier Atero SubPageList (Version 1.1) Allows to list and count subpages Jeroen De Dauw Variables UserInfo (Version 1.0)
I have a feeling that the advice should, maybe, have been to run:
php rebuildData.php -f
once - because this rebuilds everything from scratch.
Then this a few times:
php rebuildData.php -vcpt
to rebuild all the tables
then to build the remaining table with:
php rebuildData.php -v
At least I'm trying this now - it didn't seem to make sense to run with the -f option more than once.
Am I missing something?
Ah, new options to the script. Hmm ..., did I document this? No I would do the classic php rebuildData.php -fv
once and when php rebuildData.php -v
once. I do not think that what you are doing will work / is meant to work. If you want to rebuild specific tables thereafter you may use all these "cpt" options.
I'd really like to know how to understand what happened - so it doesn't happen again.... as well, of course, fixing it now.
The -v option is, as I understand it, supposed to visit each page, check if there are any properties on it, and, if there are, then recreate them. This should bring the properties back.
The fact that it hasn't, after running it a number of times, is a concern - where should I be looking to see what it's not doing?
The properties themselves are there, and not showing red any more, so it seems to have sorted out the table of properties itself, just not the pointers to where the properties are used.
that's why I thought that the -cpt options, particularly the -p option, might help.
Is there an error log somewhere that might help show what's not working?
The -v option just tells the script to prompt what it is doing while it is doing something. So basically you are deleting the store rebuild specific tables with -cpt and then rebuild the rest of the tables. To me this appears like building a car by adding the seats, trunk and lights etc. and when try to somehow add the chassis at the very end of the process. I doubt that this will work.
That certainly wouldn't work!
Looking at the documentation, it suggested that the standard, with no option, or a -v if you want to see how it is going, rebuilds the properties and so forth by looking at each page in turn from pageID 0000 on to 4000 or however many there are.
The -cpt, on the other hand, seem to rebuild the tables from properties, categories and other indices that it gets from elsewhere, an existing table or log, presumably - because it is much quicker and only looks at the ~500 items.
So the logic, to me, was to make sure the tables for the indices were in place with the -cpt option. Then get it to go through each page adding links to the indices.
The logic behind running it more than once was that there might be links that are not apparent the first time, concealed by parse expressions or similar that it might pickup on another pass.
I was hoping that one of the authors of the script could enlighten me on whether I've misunderstood.
I'm still trying to solve this.
I still have the property list showing all properties as unused -- such as:
Agenda of type Page (0 uses)
To try to fix this, I took all the property names and created a scratch page which declared them as properties. Like this:
[[Agenda::test of property]]
When I save the page, it looks as if it has understood this:
-some of these are accepted and show 'Test_of_property' in black since it is of type 'Text' - some show that they're understood and the property page doesn't exist, by showing read - some give an error '!' because the property is incorrectly set - eg. 'Test_of_property' is not type 'Date' - Some show blue and are a link to 'Test_of_property' (which doesn't, of course, exist.
So it looks as if that part of SMW is working.
However, with a page with properties, if a wiki is working, on the left side-bar, you get the 'Browse Properties' option. When you click on that, you see all the properties.
On my wiki, that option does not appear.
So, in effect, SMW is treating the page as if it has no properties on it.
This seems to be the underlying problem.
Any suggestions about what might be causing this?
I don't know if this will help. I'm posting this here, rather than the mailing list, because it is long and probably only of interest to a specialist. I thought that it might help diagnose the problem.
It's the SMW configuration output:
{
"smwgScriptPath": "/wiki/extensions/SemanticMediaWiki", "smwgIP": "/home/kchcl200/public_html/wiki/extensions/SemanticMediaWiki/", "smwgDefaultStore": "SMWSQLStore3", "smwgSparqlDatabase": "SMWSparqlDatabase", "smwgSparqlQueryEndpoint": "http://localhost:8080/sparql/", "smwgSparqlUpdateEndpoint": "http://localhost:8080/update/", "smwgSparqlDataEndpoint": "http://localhost:8080/data/", "smwgSparqlDefaultGraph": "", "smwgHistoricTypeNamespace": false, "smwgNamespaceIndex": 100, "smwgShowFactbox": 1, "smwgShowFactboxEdit": 3, "smwgToolboxBrowseLink": true, "smwgInlineErrors": true, "smwgUseCategoryHierarchy": true, "smwgCategoriesAsInstances": true, "smwgLinksInValues": true, "smwgDefaultNumRecurringEvents": 100, "smwgMaxNumRecurringEvents": 500, "smwgBrowseShowInverse": false, "smwgBrowseShowAll": true, "smwgSearchByPropertyFuzzy": true, "smwgTypePagingLimit": 200, "smwgConceptPagingLimit": 200, "smwgPropertyPagingLimit": 25, "smwgQEnabled": true, "smwgQMaxLimit": 10000, "smwgIgnoreQueryErrors": true, "smwgQSubcategoryDepth": 10, "smwgQEqualitySupport": 1, "smwgQSortingSupport": true, "smwgQRandSortingSupport": true, "smwgQDefaultNamespaces": null, "smwgQComparators": "<|>|!~|!|~|≤|≥|<<|>>", "smwStrictComparators": false, "smwgQMaxSize": 12, "smwgQMaxDepth": 4, "smwgQFeatures": 63, "smwgQDefaultLimit": 50, "smwgQMaxInlineLimit": 500, "smwgQPrintoutLimit": 100, "smwgQDefaultLinking": "all", "smwgQConceptCaching": 1, "smwgQConceptMaxSize": 20, "smwgQConceptMaxDepth": 8, "smwgQConceptFeatures": 59, "smwgQConceptCacheLifetime": 1440, "smwgResultFormats": { "table": "SMW\\TableResultPrinter", "list": "SMW\\ListResultPrinter", "ol": "SMW\\ListResultPrinter", "ul": "SMW\\ListResultPrinter", "broadtable": "SMW\\TableResultPrinter", "category": "SMWCategoryResultPrinter", "embedded": "SMWEmbeddedResultPrinter", "template": "SMW\\ListResultPrinter", "count": "SMW\\ListResultPrinter", "debug": "SMW\\ListResultPrinter", "feed": "SMW\\FeedResultPrinter", "csv": "SMW\\CsvResultPrinter", "dsv": "SMWDSVResultPrinter", "json": "SMW\\JsonResultPrinter", "rdf": "SMWRDFResultPrinter" }, "smwgResultAliases": { "feed": [ "rss" ] }, "smwgQuerySources": [
], "smwgPDefaultType": "_wpg", "smwgAllowRecursiveExport": false, "smwgExportBacklinks": true, "smwgMaxNonExpNumber": 1000000000000000, "smwgEnableUpdateJobs": true, "smwgNamespacesWithSemanticLinks": { "102": true, "103": false, "104": true, "105": false, "108": true, "109": false, "NS_MAIN": true, "NS_TALK": true, "NS_USER": true, "NS_USER_TALK": true, "NS_PROJECT": true, "NS_PROJECT_TALK": false, "NS_IMAGE": true, "NS_IMAGE_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, "NS_General": true, "NS_Services": true, "NS_Policy": true, "NS_Risk": true, "NS_Procedures": true, "NS_Requirements": true, "NS_Improvements": true, "NS_Ethics": true, "NS_Financials": true, "NS_Documents_of_Record": true, "NS_Hospitality": true, "NS_Incidents": true, "NS_Specialties": true, "NS_Potential_Conflicts": true, "General": true, "Services": true, "Policy": true, "Risk": true, "Procedures": true, "Requirements": true, "Improvements": true, "Ethics": true, "Financials": true, "Documents_of_Record": true, "Hospitality": true, "Incidents": true, "Specialties": true, "Potential_Conflicts": true, "NS_Pharmacy": true, "Pharmacy": true, "NS_Audit": true, "Audit": true, "NS_Purchasing": true, "Purchasing": true, "NS_Lab": true, "Lab": true, "NS_Recruitment": true, "Recruitment": true, "NS_Radiology": true, "Radiology": true, "NS_Family_Medicine": true, "Family_Medicine": true, "NS_Anaesthetics": true, "Anaesthetics": true, "NS_Marketing": true, "Marketing": true, "NS_Gynaecology": true, "Gynaecology": true, "NS_Dietetics": true, "Dietetics": true, "NS_Accounts": true, "Accounts": true, "NS_IT": true, "IT": true, "NS_Nursing": true, "Nursing": true, "NS_Gastroenterology": true, "Gastroenterology": true, "NS_Fetal_medicine": true, "Fetal_medicine": true, "NS_Paediatrics": true, "Paediatrics": true, "NS_HR": true, "HR": true, "NS_Claims": true, "Claims": true, "NS_Internal_Medicine": true, "Internal_Medicine": true, "NS_Hepatology": true, "Hepatology": true, "CATEGORY": true, "CATEGORY-TALK": true, "NS-CATEGORY": true, "NS-CATEGORY-TALK": true, "HELP": true, "HELP-TALK": true, "NS-HELP": true, "NS-HELP-TALK": true, "HR-TALK": true, "NS-HR": true, "NS-HR-TALK": true, "IMAGE": true, "IMAGE-TALK": true, "NS-IMAGE": true, "NS-IMAGE-TALK": true, "IT-TALK": true, "NS-IT": true, "NS-IT-TALK": true, "MAIN": true, "MAIN-TALK": true, "NS-MAIN": true, "NS-MAIN-TALK": true, "MEDIAWIKI": true, "MEDIAWIKI-TALK": true, "NS-MEDIAWIKI": true, "NS-MEDIAWIKI-TALK": true, "PROJECT": true, "PROJECT-TALK": true, "NS-PROJECT": true, "NS-PROJECT-TALK": true, "TALK": true, "TALK-TALK": true, "NS-TALK": true, "NS-TALK-TALK": true, "TEMPLATE": true, "TEMPLATE-TALK": true, "NS-TEMPLATE": true, "NS-TEMPLATE-TALK": true, "USER": true, "USER-TALK": true, "NS-USER": true, "NS-USER-TALK": true, "Accounts-TALK": true, "NS-Accounts": true, "NS-Accounts-TALK": true, "Anaesthetics-TALK": true, "NS-Anaesthetics": true, "NS-Anaesthetics-TALK": true, "Audit-TALK": true, "NS-Audit": true, "NS-Audit-TALK": true, "Claims-TALK": true, "NS-Claims": true, "NS-Claims-TALK": true, "Dietetics-TALK": true, "NS-Dietetics": true, "NS-Dietetics-TALK": true, "Documents_of_Record-TALK": true, "NS-Documents_of_Record": true, "NS-Documents_of_Record-TALK": true, "Ethics-TALK": true, "NS-Ethics": true, "NS-Ethics-TALK": true, "Family_Medicine-TALK": true, "NS-Family_Medicine": true, "NS-Family_Medicine-TALK": true, "Fetal_medicine-TALK": true, "NS-Fetal_medicine": true, "NS-Fetal_medicine-TALK": true, "Financials-TALK": true, "NS-Financials": true, "NS-Financials-TALK": true, "Gastroenterology-TALK": true, "NS-Gastroenterology": true, "NS-Gastroenterology-TALK": true, "General-TALK": true, "NS-General": true, "NS-General-TALK": true, "Gynaecology-TALK": true, "NS-Gynaecology": true, "NS-Gynaecology-TALK": true, "Hepatology-TALK": true, "NS-Hepatology": true, "NS-Hepatology-TALK": true, "Hospitality-TALK": true, "NS-Hospitality": true, "NS-Hospitality-TALK": true, "Improvements-TALK": true, "NS-Improvements": true, "NS-Improvements-TALK": true, "Incidents-TALK": true, "NS-Incidents": true, "NS-Incidents-TALK": true, "Internal_Medicine-TALK": true, "NS-Internal_Medicine": true, "NS-Internal_Medicine-TALK": true, "Lab-TALK": true, "NS-Lab": true, "NS-Lab-TALK": true, "Marketing-TALK": true, "NS-Marketing": true, "NS-Marketing-TALK": true, "Nursing-TALK": true, "NS-Nursing": true, "NS-Nursing-TALK": true, "Paediatrics-TALK": true, "NS-Paediatrics": true, "NS-Paediatrics-TALK": true, "Pharmacy-TALK": true, "NS-Pharmacy": true, "NS-Pharmacy-TALK": true, "Policy-TALK": true, "NS-Policy": true, "NS-Policy-TALK": true, "Potential_Conflicts-TALK": true, "NS-Potential_Conflicts": true, "NS-Potential_Conflicts-TALK": true, "Procedures-TALK": true, "NS-Procedures": true, "NS-Procedures-TALK": true, "Purchasing-TALK": true, "NS-Purchasing": true, "NS-Purchasing-TALK": true, "Radiology-TALK": true, "NS-Radiology": true, "NS-Radiology-TALK": true, "Recruitment-TALK": true, "NS-Recruitment": true, "NS-Recruitment-TALK": true, "Requirements-TALK": true, "NS-Requirements": true, "NS-Requirements-TALK": true, "Risk-TALK": true, "NS-Risk": true, "NS-Risk-TALK": true, "Services-TALK": true, "NS-Services": true, "NS-Services-TALK": true, "Specialties-TALK": true, "NS-Specialties": true, "NS-Specialties-TALK": true, "User": true, "User-TALK": true, "NS-User": true, "NS-User-TALK": true }, "smwgPageSpecialProperties": [ "_MDAT" ], "smwgDeclarationProperties": [ "_PVAL", "_LIST" ], "smwgTranslate": false, "smwgAdminRefreshStore": true, "smwgAutocompleteInSpecialAsk": true, "smwgAutoRefreshSubject": true, "smwgAutoRefreshOnPurge": true, "smwgAutoRefreshOnPageMove": true, "smwgContLang": {
}, "smwgMaxPropertyValues": 3, "smwgQSubpropertyDepth": 10, "smwgNamespace": ".kchclinics.com", "smwgMasterStore": null, "smwgIQRunningNumber": 0, "smwgCacheType": -1, "smwgCacheUsage": { "smwgWantedPropertiesCache": true, "smwgWantedPropertiesCacheExpiry": 3600, "smwgUnusedPropertiesCache": true, "smwgUnusedPropertiesCacheExpiry": 3600, "smwgPropertiesCache": true, "smwgPropertiesCacheExpiry": 3600, "smwgStatisticsCache": true, "smwgStatisticsCacheExpiry": 3600 }, "smwgFixedProperties": [
], "smwgPropertyLowUsageThreshold": 5, "smwgPropertyZeroCountDisplay": true, "smwgShowHiddenCategories": true, "smwgFactboxUseCache": true, "smwgFactboxCacheRefreshOnPurge": true, "smwgQueryProfiler": { "smwgQueryDurationEnabled": false }, "smwgEnabledSpecialPage": [ "Ask", "RunQuery" ], "smwgOnDeleteAction": { "smwgDeleteSubjectAsDeferredJob": false, "smwgDeleteSubjectWithAssociatesRefresh": false }, "smwgCanonicalNames": { "102": "Property", "103": "Property_talk", "104": "Type", "105": "Type_talk", "108": "Concept", "109": "Concept_talk" }
}
Return to Special:SMWAdmin