Last modified: 2009-08-01 19:03: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 12922 - Smw_import_ doesn't work with canonical namespace names
Smw_import_ doesn't work with canonical namespace names
Status: RESOLVED INVALID
Product: MediaWiki extensions
Classification: Unclassified
Semantic MediaWiki (Other open bugs)
unspecified
All All
: Normal normal (vote)
: ---
Assigned To: Markus Krötzsch
http://wikis2.pruebas.madrimasd.org:8...
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2008-02-05 14:30 UTC by S Page
Modified: 2009-08-01 19:03 UTC (History)
0 users

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


Attachments

Description S Page 2008-02-05 14:30:49 UTC
In "[Semediawiki-user] problem foaf import in Es-MW" e-mail, user David reports that MediaWiki:Smw_import_foaf doesn't work when used on a Spanish wiki, e.g. in the page Atributo:Nombre.

The error I currently see is 'smw_wrong_importtype'.  What I think is happening is SMW_Factbox.php lines 147-156 only test the 
namespace from the element's line in MediaWiki:Smw_import_Xxxx page against the translated namespace names.  So a Spanish site won't work with 
  name|Type:String
because "Type" does not match the translated wgContLang->getNsText(SMW_NS_TYPE).

If I'm right, the workaround is to use translated names in the MediaWiki:Smw_import_Xxxx page, e.g. 
  name|Tipos de datos:String

The fix is to change those lines in SMW_Factbox.php to work with namespace IDs, something like:
  $elem_ns_index = wgContLang->getNsIndex($namespace)
  switch ($elem_ns_index) {
    case SMW_NS_TYPE:
      $elemtype = ...
    case SMW_NS_PROPERTY
      ...
    etc.

This should be faster code, too ;-)
Comment 1 Markus Krötzsch 2009-08-01 19:03:59 UTC
Various changes have happened to the import code since this bug was filed. Currently, the type of the imported elements is not actually checked any more, which is not really a good solution either. Based on the observation that there are usually only few imported vocabulary terms in any wiki, I would like to have a redesigned import mechanism that allows for "vocabulary extensions" that provide their own predefined page names to which they are mapped as soon as the extension is enabled. This would be a future project, however ... interested contributors should contact me.

I close this bug now as "INVALID" (which it has become over time -- shame on us ;-). 

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


Navigation
Links