Details
-
Improvement
-
Resolution: Fixed
-
Major
-
17.10.14
-
None
Description
A wiki page XML file declares the version of the XAR format it follows in the version attribute of its xwikidoc root element. Some elements only exist since a given format version, but nothing checks that a page using them declares that version: for example a page with enforceRequiredRights can declare format 1.2 and pass both mvn xar:format and mvn xar:verify, while claiming a format that does not contain the element it uses.
Proposed change
- xar:verify fails a page whose declared format version is lower than the one introducing an element it uses:
- attachment/revisions: 1.4
- originalMetadataAuthor: 1.5
- enforceRequiredRights: 1.6
- the type attribute of an object property: 1.7
- xar:format raises the declared format version to the one required, so that formatting a page fixes it.
The reference/locale root attributes (1.2) and the XML 1.1 declaration (1.3) are not checked: xar:format writes the XML 1.1 declaration on every page, and many existing pages declaring an older version carry these attributes with no effect on their import.
Extensions with pages in that situation will see their build fail once they use this version of the plugin; running mvn xar:format fixes them.
Attachments
Issue Links
- relates to
-
XCOMMONS-3102 Increase the XAR format version to 1.6 for required rights support
-
- Closed
-
-
XCOMMONS-3588 Increase the XAR format version to 1.7 for missing properties support
-
- Closed
-