Last modified: 2014-03-06 18:28:59 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 8225 - Problem with ontology import
Problem with ontology import
Status: RESOLVED WONTFIX
Product: MediaWiki extensions
Classification: Unclassified
Semantic MediaWiki (Other open bugs)
unspecified
PC Linux
: Lowest major (vote)
: ---
Assigned To: Nobody - You can work on this!
: easy, testme
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-12-12 10:34 UTC by Vitor
Modified: 2014-03-06 18:28 UTC (History)
2 users (show)

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


Attachments

Description Vitor 2006-12-12 10:34:35 UTC
When trying to import an ontology using the Ontology import page, right after
choosing the statements to import, a blank page with the message:

"Fatal error: Class 'SMWURITypeHandler' not found in
/wiki_path/SemanticMediaWiki/includes/SMW_Datatype.php on line 105"

is shown, and nothing is imported.

The versions of the softwares used are:
Mediawiki 1.7.1,
SMW 0.5,
Php 5.1.6,
Mysql 5.0.24 
Debian OS.

After emailing the smw-user list with this problem, S Page suggested to add a
few lines on the code, as seen in the transcription that follows:

"Here's my guess at what might be happening.
Instead of loading the PHP code for every datatype on every request to
MediaWiki, SMW does lazy-loading of the PHP file implementing each datatype as
needed.  So SMW_Datatype.php tells itself (in 
announceTypeHandler() calls around line 286) that email,uri, url, and annouri
datatypes are implemented by class SMWURITypeHandler in SMW_DT_URI.php , but
doesn't actually include this file.

Somehow the lazy-loading is broken in your case.

A possible fix is to explicit put
	## My temp Workaround for ontology import bug
	global $smwgIP;
	include_once($smwgIP . '/includes/SMW_DT_URI.php');

towards the top of SMW_Datatype.php, just after
	require_once('SMW_DT_Float.php');

to force the code to be loaded.

Good luck,
--
=S"

With that little change the ontology import worked as expected.
Comment 1 Markus Krötzsch 2007-03-24 17:34:54 UTC
Ontology import is currenty not supported. The feature has always been
experimental, but ceased to work since some time. We might implement a new
function for importing existing data at some time, but this time is not now.

We have, however, successfully imported data with simple external scripts, as
described in the SMW documentation.
Comment 2 Andre Klapper 2012-12-20 13:30:02 UTC
[Removing RESOLVED LATER as discussed in http://lists.wikimedia.org/pipermail/wikitech-l/2012-November/064240.html and announced in https://sourceforge.net/mailarchive/forum.php?thread_name=CALFVSbXkiffYy6HkhEWE0RtRrJ%2B2ebPz3g00gsr%2Bdz%2B1nZWsDA%40mail.gmail.com&forum_name=semediawiki-devel . Reopening and setting priority to "Lowest". For future reference, please use either RESOLVED WONTFIX (for issues that will not be fixed), or simply set lowest priority. Thanks a lot!]
Comment 3 Andre Klapper 2014-02-19 10:05:52 UTC
Is this still an issue and something that could be "easily" fixed by newcomers, or should the "easy" keyword be removed and/or the ticket closed?
Comment 4 [[kgh]] 2014-03-06 18:28:59 UTC
Currently there are not plans to support ontology imports what I am aware of. I am not aware of the import scripts either but there is a help page on smw.o [1] about importing vocabularies. Probably the best shot at the moment. Thus closing as RESOLVED WONTFIX. WONTFIX means in the foreseeable future.

[1] https://semantic-mediawiki.org/wiki/Help:Import_vocabulary

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


Navigation
Links