Help:Mandatory parent datatype inheritance

From semantic-mediawiki.org
Help:Mandatory parent datatype inheritanceMandatory parent datatype inheritance/tr
Shows a warning of the parent property to contain a different type annotation (on disabled enforcement)
Enforced parent type inheritance for a subproperty

Mandatory parent datatype inheritance was introduced with Semantic MediaWiki 3.1.0Released on 23 September 2019 and compatible with MW 1.31.0 - 1.33.x. which added configuration parameter $smwgMandatorySubpropertyParentTypeInheritanceNo description was provided.12 as an option to enforce that a subproperty requires the same datatype as the parent property.

When disabled by setting this configuration parameter to "false" (done by default to ensure legacy behaviour), a warning will appear on the property page to inform the user about the type mismatch.

Yet, if enabled by setting this configuration parameter to "true" and the user added a different datatype (in references to the parent property) then an error message will be shown and the annotated datatype is forcibly removed though the page content is not altered. This is why an error message is shown to ensure the user removes the erroneous datatype or modifies it to match the parent property datatype.

See also[edit]


References

  1. ^  |  Semantic MediaWiki: GitHub issue gh:smw:3528
  2. ^  |  Semantic MediaWiki: GitHub pull request gh:smw:3733