[wpkg-users] [Bug 251] Added correct validation strings to templates

bugzilla-daemon at bugzilla.wpkg.org bugzilla-daemon at bugzilla.wpkg.org
Sun Oct 30 15:44:25 CET 2011


http://bugzilla.wpkg.org/show_bug.cgi?id=251

--- Comment #8 from Rainer Meier <r.meier at wpkg.org>  ---
In eclipse this does not validate properly. For packages.xml:

<packages:packages
  xmlns:packages="http://www.wpkg.org/packages"
  xmlns:wpkg="http://www.wpkg.org/wpkg"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://www.wpkg.org/packages"
  xsi:noNamespaceSchemaLocation="xsd/packages.xsd">

Yields the following error:

Multiple annotations found at this line:
- cvc-elt.1: Cannot find the declaration of element 'packages:packages'.
- SchemaLocation: schemaLocation value = 'http://www.wpkg.org/packages' must
have even number of URI's.

If I get the specification correctly the schemaLocation attribute shall be used
to specify location of schema via namespace hinting in the format "<urn>
<location>" Which is what I've used:

<packages:packages
  xmlns:packages="http://www.wpkg.org/packages"
  xmlns:wpkg="http://www.wpkg.org/wpkg"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://www.wpkg.org/packages xsd/packages.xsd">


The "noNamespaceSchemaLocation" is a hinting where to find elements without
namespace. But here all nodes belong to the "http://www.wpkg.org/packages" and
not to "no namespace" and therefore I think eclipse is correct by complaining
that the specification of the "packages" element in "packages" namespace is not
found even if noNamespaceSchemaLocation is specified.

As the XSD files use unqualified notation all elements used within <packages>
belong to the "http://www.wpkg.org/packages" namespace too (if I am not
mistaken here).

So I really think the correct way is to specify
"xsi:schemaLocation="http://www.wpkg.org/packages xsd/packages.xsd" only.

-- 
Configure bugmail: http://bugzilla.wpkg.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.



More information about the wpkg-users mailing list