Extension talk:Semantic MediaWiki

Jump to navigation Jump to search

About this board

The best way for getting support for Semantic MediaWiki is to post to its user mailing list. Comments made below are not very well monitored by the developers. There are various options for making yourself heard:

  • If you have a usage question, please post them to the SMW support mailing lists (archives).
  • If you found a bug or want to propose a new feature, please file it at GitHub. Bugs and requests are regularly considered by core developers and have a great impact on the future development of SMW.
  • If you want to contribute to the development, please contact the development community at the SMW developers' mailing list (archives).

When asking for help or describing bugs, do not forget to provide necessary details about your configuration, version details for all relevant components, information about other extensions that are used, and, if possible, a URL where the problem can be seen. See the help page on reporting bugs for detailed information.

The below talk page is most useful for comments regarding the wiki page, but of course you may do as you like (it's a wiki, after all).

previous talk on this page


Which Version of Semantic with which Version of MediaWiki

5
213.61.254.67 (talkcontribs)

I don't understand, which version are compatible.


I use Composer, composer.local.json:

"require": {"mediawiki/semantic-media-wiki": "~2.5", ....


I have checked out MediaWiki REL1_31 and composer install --no-dev --> Result: remove mediawiki/core dev-REL1_31|remove mediawiki/semantic-media-wiki 2.5.8


I have checked out MediaWiki REL1_32 and composer install --no-dev --> Result: remove mediawiki/core dev-REL1_31|remove mediawiki/semantic-media-wiki 2.5.8

213.61.254.67 (talkcontribs)

I have the same problem with Semantic Version 3:

remove mediawiki/core dev-REL1_31|remove mediawiki/semantic-media-wiki 3.0.1

Kghbln (talkcontribs)
213.61.254.68 (talkcontribs)

My problem was in the file composer.local.json the line:

       "extra": {

               "merge-plugin": {

                       "include": [

                               "extensions/*/composer.json"

composer are not understand this recursively... I don't know why.

Kghbln (talkcontribs)

Good to know what the issue was. Admittedly I only explicitly call extension's "composer.json" files here, e.g. by adding "extensions/SyntaxHighlight_GeSHi/composer.json". The issue is probably that not every extension provides such a file and Composer errors out when not finding one.

How to get all future ''end'' dates of a recurring event?

2
Summary by Kghbln
Andreas Plank (talkcontribs)

I know how to get the beginning date time of a recurring event (a usual #ask will do so) but I did not figure out how to get the end of date times of future recurring events. How can I #ask for recurring end dates that come in the future? Is it possible? Or do I have to program a work around by let’s say using Unix timestamps, and add it to the #ask result to get the corresponding end time of the future event?

Kghbln (talkcontribs)

Trouble installing SMW 3.0

2
Summary by Kghbln

See the respective mailing list thread.

Amagnien2 (talkcontribs)

Hello,

I have installed SMW 3.0 on top of MW 1.27.5 (PHP 5.6.38, MySQL 5.6.39-log, ICU 52.1)

Installation went fine. I ran PHP update in the local directory, and got in return "Your composer.lock file is up to date with current dependencies! Set $wgShowExceptionDetails = true; in LocalSettings.php to show detailed debugging information."

... from which I infer that no updates were made. The Mediawiki stuff is in the subdirectory '/mw'

When I add the instruction enableSemantics( 'www.railwayobjects.eu/mw' ) at the end of LocalSettings.php in the file on the server, and try to reload my wiki, all I get is a blank page. The Firefox console only says:

______________________________

Promise rejected after context unloaded: Promised response from onMessage listener went out of scope

page_performance.js:18

Unchecked lastError value: Error: Promised response from onMessage listener went out of scope page_performance.js:18

______________________________

I'm sorry to say, I am stuck... any help is more than welcome.

~~~~

Kghbln (talkcontribs)

Which version to install for MW 1.31?

6
Alzi24 (talkcontribs)

Hello there, I have recently upgraded our wiki to MW 1.31. Now I want to install SMW and therefore I downloaded the extension from github. I chose branch 3.0.x. Now I receive the following message via Apache error log:

[Mon Dec 10 13:44:09.696457 2018] [php7:error] [pid 26447] [client 79.226.0.171:53406] PHP Fatal error:  Uncaught UnexpectedValueException: callback 'SemanticMediaWiki::initExtension' is not callable in /var/www/test/mediawiki/includes/registration/ExtensionRegistry.php:360\nStack trace:
#0 /var/www/test/mediawiki/includes/registration/ExtensionRegistry.php(159): ExtensionRegistry->exportExtractedData(Array)
#1 /var/www/test/mediawiki/includes/Setup.php(116): ExtensionRegistry->loadFromQueue()\n#2 /var/www/test/mediawiki/includes/WebStart.php(88): require_once('/var/www/test/m...')
#3 /var/www/test/mediawiki/index.php(39): require('/var/www/test/m...')
#4 {main}\n  thrown in /var/www/test/mediawiki/includes/registration/ExtensionRegistry.php on line 360, referer: https://test.perrypedia.proc.org/wiki/Spezial:Spezialseiten

So the question is, which version (branch) should I use?

Kghbln (talkcontribs)

Note that SMW gets invoked like this only, e.g.:

enableSemantics( test.perrypedia.proc.org );

No requrire_once, no wfLoadExtension etc. Also note that you cannot install it using some tarball etc. To use Composer is imperative.

You may use 2.5.x or 3.0.x (preferred)

Alzi24 (talkcontribs)

Not very easy and not very user-friendly, but finally I got it.

Now the setupStore script is running and I am a little bit worried. The current step is "Checking smw_hash field ... missing 232626 rows". Running for more than one hour now it shows "updating document no. 3045 (1%)"

Does it mean I will have to watch that job for more than four days?

Alzi24 (talkcontribs)

I cancelled the job now. 3 hrs, 3 %, sorry: unbearable.

Alzi24 (talkcontribs)

Much better, the database is corrupted now. I can no longer run the regular update.php, nor is it possible to uninstall SMW and/or the composer. Luckily it is just the test wiki. I now am considering of never trying it again.

Kghbln (talkcontribs)

Sorry that it does not work out for you.

mediawiki smw-editpage-annotation-enabled editform to large

2
213.61.254.68 (talkcontribs)

Hello,

my EditForm is to large and the save button is out of my screen. I must scroll down, to press the button.

After installing SmenaticMediaWiki there is a smw-editpage-annotation-enabled-section in the Firefox DebugConsole, that push the EditForm a little bit down.

I need a option to reduce the size of the editform, OR i need the option to collapsible the smw-editpage-annotation-enabled-section.

Can anyone help me?

Kghbln (talkcontribs)

There is a configuration parameter called $smwgEnabledEditPageHelp to disable the info alltogether. Perhaps there is also a way to make it collapsible via CSS

Bastor de (talkcontribs)

I have update from MW 1.26.4 to

Software Version
MediaWiki 1.29.1
PHP 5.6.30-nmm1 (fpm-fcgi)
MySQL 5.7.15-nmm5-log
ICU 55.1

I have install the last version of all Semantic extensions. Now i get this Semantic Errors:

http://kubb290.kubbwiki.de/

Warning: Class 'SMW\Updater\DeferredCallableUpdate' not found in /www/htdocs/w0101624/kubb290/extensions/SemanticMediaWiki/src/Aliases.php on line 8

Warning: Class 'SMW\Parser\InTextAnnotationParser' not found in /www/htdocs/w0101624/kubb290/extensions/SemanticMediaWiki/src/Aliases.php on line 9

Warning: Class 'SMW\Encoder' not found in /www/htdocs/w0101624/kubb290/extensions/SemanticMediaWiki/src/Aliases.php on line 10

Warning: Class 'SMW\Query\ResultPrinter' not found in /www/htdocs/w0101624/kubb290/extensions/SemanticMediaWiki/src/Aliases.php on line 11

Warning: Class 'SMW\Query\ResultPrinter' not found in /www/htdocs/w0101624/kubb290/extensions/SemanticMediaWiki/src/Aliases.php on line 12

Warning: Class 'SMW\Query\ExportPrinter' not found in /www/htdocs/w0101624/kubb290/extensions/SemanticMediaWiki/src/Aliases.php on line 13

Warning: Class 'SMW\Query\ResultPrinters\ResultPrinter' not found in /www/htdocs/w0101624/kubb290/extensions/SemanticMediaWiki/src/Aliases.php on line 14

Warning: Class 'SMW\Query\ResultPrinters\ResultPrinter' not found in /www/htdocs/w0101624/kubb290/extensions/SemanticMediaWiki/src/Aliases.php on line 15

Warning: Class 'SMW\Query\ResultPrinters\FileExportPrinter' not found in /www/htdocs/w0101624/kubb290/extensions/SemanticMediaWiki/src/Aliases.php on line 16

Warning: Class 'SMW\Query\Parser' not found in /www/htdocs/w0101624/kubb290/extensions/SemanticMediaWiki/src/Aliases.php on line 17

Fatal error: Interface 'SMW\QueryEngine' not found in /www/htdocs/w0101624/kubb290/extensions/SemanticMediaWiki/includes/storage/SMW_Store.php on line 34

All Pathe are correct and all Files are exist.

Idea what is wrong?

thank's

Bastor

Kghbln (talkcontribs)

I the files are not loaded than it does not matter if they are existing or not. I guess you did not install and upgrade via command line. You used one of the tarballs with dependencies? If yes there may be some issue mashing this up with MediaWiki. In this case I recommend to install MW on a machine with command line add SMW to it and after this is done move the files all over.

Bastor de (talkcontribs)

MMh, thanks for tip.

After my first test i get the same error :-(

Think you my database have a error or the file structur a wrong?

Kghbln (talkcontribs)

I think the issue is that the files are not being loaded properly. So installing MW on a machine with command line adding SMW to it and after this moving the files all over did not work? This has nothing to do with the database.

77.180.154.2 (talkcontribs)

Thanks for help, You were right

Kghbln (talkcontribs)

Glad it worked out!

How to rebuild semantic mediawiki information?

3
Summary by Kghbln

The script is located at "/../extensions/SemanticMediaWiki/maintenance/"

Naramoksu (talkcontribs)

I have a page A and page B. Both page does not have properties which link each page. But page A show me B have a property which linked to A. I can not find a property of page B which link to page A.

Maybe something wrong on database. I'd like to clear this. I run /maintenance/rebuildall.php but not fixed.

Would you recommend me how to fix this? Thanks.

my private wiki have mediawiki 1.28.2, SMW 1.25.1, Apache PHP MySql on debian linux.

Kghbln (talkcontribs)

I am not sure if I understand the issue correctly. However if you would like to rebuild semantic data you will have to use the "rebuildData.php" script which is located in "/extensions/SemanticMediaWiki/maintenance". The "rebuildall.php" script has a different scope and is provided by MediaWiki core.

Naramoksu (talkcontribs)

Thanks for your information. I just looked at the maintenance directory.

MyISAM support is blocking use of Azure Database for MySql

2
Lsilverman (talkcontribs)

I just attempted to move my mediawiki DB into Azure Database for MySql (their new hosted MySql offering). Got blocked on the use of MyISAM fulltext search on smw_ft_search.

Can this be migrated to InnoDB soon? Latest MySQLs have support for fulltext in InnoDB.

Kghbln (talkcontribs)

Resources fail to load with non-default extensions setup (e.g. symlinks)

2
Summary by Kghbln

SMW 2.4.0 brought a solution

Andreas Plank (talkcontribs)

I configured a shared wiki setup with different extension features per wiki. In SMW 2.3.1 when debug=true in the URL some resources issue an error not to be loaded. With MW 1.25+ it is considered to set up a different extension directory (Manual:$wgExtensionDirectory) but it is not taken into account for SMW resources. I checked out and see why: SemanticMediaWiki/res/Resources.php assumes folder extensions to be there but allowing a different $wgExtensionDirectory this assumption is proven wrong. So if I add debug=true to the URL I get http://offene-naturfuehrer.de/w/extensions//usr/share/mediawiki26/extensions-rich-features/SemanticMediaWiki/res/smw/util/ext.smw.util.tooltip.js it becomes 404 and does not get loaded. Is there any fix I can do, LocalSettings or so? See also https://phabricator.wikimedia.org/T130520

Kghbln (talkcontribs)

Semantic queries aren't showing all the results

3
Summary by Kghbln

SMW 2.5.0 brought full-text search

85.54.29.115 (talkcontribs)

Hi,

For some reasons, semantic queries aren't showing all the results on my wiki.

On Wikifab.org, the property "Material" of the page "ZipStick Chair..." contains the terms "Plywood" and "strong". However:

  • this query correctly have "ZipStich Chair..." in the results
  • But this query dont...

Do you know why? Is it a known issue?

Thanks in advance for your help.

Kghbln (talkcontribs)
83.47.139.142 (talkcontribs)

Thanks for your reply. I have subscribe to the notifications and asked a developer of our team to see if he can help.