You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@daffodil.apache.org by "Dave Thompson (Jira)" <ji...@apache.org> on 2023/03/14 16:04:00 UTC

[jira] [Closed] (DAFFODIL-2800) appinfo annotations with distinct source are being misinterpreted as DFDL annotations.

     [ https://issues.apache.org/jira/browse/DAFFODIL-2800?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dave Thompson closed DAFFODIL-2800.
-----------------------------------

Verified the specified commit (commit 1dbea8e930e440ce5c80d7d363811fc4ca63db3d) is included in the latest pull from the daffodil repository.

Verified, via review, changes identified in the commit comment were implemented. 

Verified the affected daffodil subproject sbt test suites executed successfully.

> appinfo annotations with distinct source are being misinterpreted as DFDL annotations.
> --------------------------------------------------------------------------------------
>
>                 Key: DAFFODIL-2800
>                 URL: https://issues.apache.org/jira/browse/DAFFODIL-2800
>             Project: Daffodil
>          Issue Type: Bug
>          Components: Front End
>    Affects Versions: 3.4.0
>            Reporter: Mike Beckerle
>            Assignee: Steve Lawrence
>            Priority: Major
>             Fix For: 3.5.0
>
>
> This bug prevents use of annotations other than DFDL annotations in schemas. 
> This makes it impossible for me to use my XSAT2 schema scanner to check for problems in DFDL schemas because the special annotations XSAT2 supports are not being ignored by Daffodil. 
> I have this type which carries a special annotation that is NOT a DFDL annotation:
> ```xml
> <xs:simpleType name="tHexBinary" dfdl:lengthKind="explicit">
>   <xs:restriction base="xs:hexBinary">
>     <xs:annotation>
>       <xs:appinfo source="urn:com.owlcyberdefense.xsat2">
>         <xsat2>
>           <nonRemediation>
>             This type is used only by DFI 9100 and DFI 4242 which are
>             defined to be opaque fixed length byte strings by the VMF specification.
>           </nonRemediation>
>         </xsat2>
>       </xs:appinfo>
>     </xs:annotation>
>   </xs:restriction>
> </xs:simpleType>
> ```
> The source attribute indicates this is about something that is NOT DFDL. 
>  
> Note that the xsat2 and nonRemediation attributes do NOT carry a namespace prefix. That may or may not be important. 
>  
> I get compilation errors like:
> ```
> [error] Schema Definition Error: Error loading schema due to org.xml.sax.SAXParseException; lineNumber: 56; columnNumber: 24; cvc-complex-type.2.4.a: Invalid content was found starting with element 'xsat2'. One of '\{"http://www.ogf.org/dfdl/dfdl-1.0/":assert, "http://www.ogf.org/dfdl/dfdl-1.0/":choice, "http://www.ogf.org/dfdl/dfdl-1.0/":defineEscapeScheme, "http://www.ogf.org/dfdl/dfdl-1.0/":defineFormat, "http://www.ogf.org/dfdl/dfdl-1.0/":defineVariable, "http://www.ogf.org/dfdl/dfdl-1.0/":discriminator, "http://www.ogf.org/dfdl/dfdl-1.0/":element, "http://www.ogf.org/dfdl/dfdl-1.0/":enumeration, "http://www.ogf.org/dfdl/dfdl-1.0/":format, "http://www.ogf.org/dfdl/dfdl-1.0/":group, "http://www.ogf.org/dfdl/dfdl-1.0/":newVariableInstance, "http://www.ogf.org/dfdl/dfdl-1.0/":sequence, "http://www.ogf.org/dfdl/dfdl-1.0/":setVariable, "http://www.ogf.org/dfdl/dfdl-1.0/":simpleType, WC[##other:"http://www.ogf.org/dfdl/dfdl-1.0/"]}' is expected.
> ```
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)