Page MenuHomePhabricator

Troubles creating/using attributes
Closed, DeclinedPublic

Description

Author: Martin.HEIN

Description:
Hello,

On my WinXP box I’m running Apache 2.2.3, MySQL 5.0.27, PHP 5.2.0, MediaWiki 1.10 and Semantic MediaWiki 0.7.

I've create a page called 'Attribute:MyIntVar' which contains 'Has type::Type:Integer'. This worked just as it was supposed to, there's a 'Facts about MyIntVar' box, which states under 'Special properties': 'Has type' 'Type:Integer', and under 'Pages using the attribute "MyIntVar"': Showing 0 pages using this relation.

When creating another page, containing somewhere 'MyIntVar:=4711', the 'Facts about' box displays 'MyIntVar' 'Oops! No type defined for attribute'. When I click 'MyIntVar' I'm taken to the corresponding attribute page.

Under 'Special:Attributes' this attribute doesn't show up, under 'Special:Unused Attributes' it does.

Deleting the pages just created, and re-creating them again, doesn't change anything.

Creating pages and attributes using different names is to no avail, either.

  • Martin

Version: unspecified
Severity: blocker
OS: Windows XP
Platform: PC

Details

Reference
bz10364

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 21 2014, 9:51 PM
bzimport set Reference to bz10364.
bzimport added a subscriber: Unknown Object (MLST).

info wrote:

(I think you also discussed this problem on Semediawiki-user@lists.sourceforge.net.)

SMW knows you've got a MyIntVar page with a "Has type" special property, knows it's in the SMW_NS_ATTRIBUTE namespace (since it shows in Special:Unused Attributes), yet when parsing a page using the MyIntVar attribute, it cannot find the "Has type" special property for the attribute. Weird.

To debug this further you either need to look at the underlying smw_attributes and smw_specialprops tables, or debug SMWTypeHandlerFactory::getTypeHandler in SMW_Datatype.php, or both.

  • If your mediawiki language is not English then you must translate all the special properties, e.g. [[Hat Datentyp::Datentyp:Zeichenkette]]

for German. But I would expect more to go wrong if this were your problem.

  • Do relations work OK?
  • Are you using other custom namespaces? If so see the comment in INSTALL.

I'm setting this WORKSFORME but would love to figure out what is causing the problem for you.