[Bug 586] - resolve validation problem with missing keys
bugzilla-daemon@ecoinformatics.org
bugzilla-daemon at ecoinformatics.org
Wed Sep 11 11:51:59 PDT 2002
http://bugzilla.ecoinformatics.org/show_bug.cgi?id=586
------- Additional Comments From jones at nceas.ucsb.edu 2002-09-11 11:51 -------
OK, here's the deal as far as I can tell with the key validity problems. These
surfaced when we upgraded Xerces, which became more sensitive to these schema
validity problems. When you define a key, you define a set of nodes to be
checked using the "selector" xpath expression. This produces a node set, and
for each field in that node set, it checks that the "field" selector contains a
unique value AND is not nil.
This means two things for us:
1) id attributes can not be optional, because we have to have a value to pass
the validation test
2) our selectors can't look at every node (as they currently do by using
something like ".//*"), because such a broad selector will return nodes that
don't allow the id attribute, and thus would not have a value for the key
The only solution that I can see right now is:
1) change all id attributes from optional to required
2) change our xpath selectors to only select eml fields that contain an id attribute
This is a pretty major change, but as it stands now the key/keyref stuff
prevents us from ever creating a valid document. Comments appreciated.
More information about the Eml-dev
mailing list