Uploaded image for project: 'Daffodil'
  1. Daffodil
  2. DAFFODIL-2377

Abort instead of diagnostic message

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.6.0
    • 3.0.0
    • Front End
    • None

    Description

      Unparsing the following DFDL schema resulted in the below error.
       
       <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
           xmlns:dfdl="http://www.ogf.org/dfdl/dfdl-1.0/"
           xmlns:fn="http://www.w3.org/2005/xpath-functions"
           elementFormDefault="qualified">
           
           <xs:annotation>
               <xs:appinfo source="http://www.ogf.org/dfdl/">
                   <dfdl:format
                       textBidi="no"
                       floating="no"
                       encodingErrorPolicy="replace"
                       leadingSkip="0" 
                       alignmentUnits="bytes"
                       alignment="1" 
                       trailingSkip="0"
                       textPadKind="none"
                       escapeSchemeRef=""
                       truncateSpecifiedLengthString="no"
                       textTrimKind="none" 
                       binaryNumberRep="binary"
                       
                       representation="binary"
                       byteOrder="littleEndian"
                       encoding="ISO-8859-1"
                       sequenceKind="ordered"
                       initiator=""
                       terminator=""
                       separator=""
                       ignoreCase = "yes"
                       initiatedContent="no"
                       
                   />
               </xs:appinfo>
           </xs:annotation>
           
           <xs:element name="input"
               dfdl:lengthKind="implicit"
               dfdl:lengthUnits="bytes"
               >
               <xs:complexType>
                   <xs:sequence dfdl:fillByte="%NUL;">
                       <xs:element name="A" type="xs:unsignedInt" 
                           dfdl:lengthKind="explicit"
                           dfdl:length="1"
                           dfdl:lengthUnits="bytes"
                           dfdl:alignment="1"
                           dfdl:alignmentUnits="bytes"
                       />
                       <xs:element name="B" type="xs:unsignedInt" 
                           dfdl:lengthKind="explicit"
                           dfdl:length="1"
                           dfdl:lengthUnits="bytes"
                           dfdl:alignment="2"
                           dfdl:alignmentUnits="bytes"
                       />
                       <xs:element name="C" type="xs:unsignedInt" 
                           dfdl:lengthKind="explicit"
                           dfdl:length="1"
                           dfdl:lengthUnits="bytes"
                           dfdl:alignment="2"
                           dfdl:alignmentUnits="bytes"
                       />
                   </xs:sequence>
               </xs:complexType>
           </xs:element>
           
       </xs:schema>
       
       !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
       !!   An unexpected exception occurred. This is a bug!   !!
       !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
       
        Please report this bug and help us fix it:
       
         https://daffodil.apache.org/community/#issue-tracker
       
        Please include the following exception, the command you
        ran, and any input, schema, or tdml files used that led
        to this bug.
       
       
       java.util.NoSuchElementException: Nope.get
               at org.apache.daffodil.util.Maybe$.noneGet$extension(Maybe.scala:39)
               at org.apache.daffodil.util.Maybe$.get$extension(Maybe.scala:36)
               at org.apache.daffodil.processors.ParseOrUnparseState.fillByte(ProcessorStateBases.scala:288)
               at org.apache.daffodil.io.DataOutputStreamImplMixin.skip(DataOutputStreamImplMixin.scala:998)
               at org.apache.daffodil.io.DataOutputStreamImplMixin.skip$(DataOutputStreamImplMixin.scala:991)
               at org.apache.daffodil.io.DirectOrBufferedDataOutputStream.skip(DirectOrBufferedDataOutputStream.scala:177)
               at org.apache.daffodil.io.DataOutputStreamImplMixin.align(DataOutputStreamImplMixin.scala:1100)
               at org.apache.daffodil.io.DataOutputStreamImplMixin.align$(DataOutputStreamImplMixin.scala:1096)
               at org.apache.daffodil.io.DirectOrBufferedDataOutputStream.align(DirectOrBufferedDataOutputStream.scala:177)
               at org.apache.daffodil.processors.unparsers.AlignmentFillUnparserSuspendableOperation.continuation(FramingUnparsers.scala:54)
               at org.apache.daffodil.processors.SuspendableOperation.doTask(SuspendableOperation.scala:86)
               at org.apache.daffodil.processors.SuspendableOperation.doTask$(SuspendableOperation.scala:57)
               at org.apache.daffodil.processors.unparsers.AlignmentFillUnparserSuspendableOperation.doTask(FramingUnparsers.scala:38)
               at org.apache.daffodil.processors.Suspension.run(Suspension.scala:104)
               at org.apache.daffodil.processors.Suspension.run$(Suspension.scala:103)
               at org.apache.daffodil.processors.unparsers.AlignmentFillUnparserSuspendableOperation.run(FramingUnparsers.scala:38)
               at org.apache.daffodil.processors.unparsers.SuspendableUnparser.unparse(Unparser.scala:139)
               at org.apache.daffodil.processors.unparsers.SuspendableUnparser.unparse$(Unparser.scala:136)
               at org.apache.daffodil.processors.unparsers.AlignmentFillUnparser.unparse(FramingUnparsers.scala:65)
               at org.apache.daffodil.processors.unparsers.Unparser.unparse1(Unparser.scala:73)
               at org.apache.daffodil.processors.unparsers.Unparser.unparse1$(Unparser.scala:39)
               at org.apache.daffodil.processors.unparsers.AlignmentFillUnparser.unparse1(FramingUnparsers.scala:65)
               at org.apache.daffodil.processors.unparsers.ElementUnparserBase.doBeforeContentUnparser(ElementUnparser.scala:169)
               at org.apache.daffodil.processors.unparsers.ElementUnparserBase.unparse(ElementUnparser.scala:192)
               at org.apache.daffodil.processors.unparsers.Unparser.unparse1(Unparser.scala:73)
               at org.apache.daffodil.processors.unparsers.Unparser.unparse1$(Unparser.scala:39)
               at org.apache.daffodil.processors.unparsers.CombinatorUnparser.unparse1(Unparser.scala:128)
               at org.apache.daffodil.processors.unparsers.ScalarOrderedUnseparatedSequenceChildUnparser.unparse(UnseparatedSequenceUnparsers.scala:37)
               at org.apache.daffodil.processors.unparsers.Unparser.unparse1(Unparser.scala:73)
               at org.apache.daffodil.processors.unparsers.Unparser.unparse1$(Unparser.scala:39)
               at org.apache.daffodil.processors.unparsers.CombinatorUnparser.unparse1(Unparser.scala:128)
               at org.apache.daffodil.processors.unparsers.OrderedUnseparatedSequenceUnparser.unparseOne(UnseparatedSequenceUnparsers.scala:68)
               at org.apache.daffodil.processors.unparsers.OrderedUnseparatedSequenceUnparser.unparse(UnseparatedSequenceUnparsers.scala:169)
               at org.apache.daffodil.processors.unparsers.Unparser.unparse1(Unparser.scala:73)
               at org.apache.daffodil.processors.unparsers.Unparser.unparse1$(Unparser.scala:39)
               at org.apache.daffodil.processors.unparsers.CombinatorUnparser.unparse1(Unparser.scala:128)
               at org.apache.daffodil.processors.unparsers.ElementUnparserBase.runContentUnparser(ElementUnparser.scala:181)
               at org.apache.daffodil.processors.unparsers.ElementUnparserBase.unparse(ElementUnparser.scala:202)
               at org.apache.daffodil.processors.unparsers.Unparser.unparse1(Unparser.scala:73)
               at org.apache.daffodil.processors.unparsers.Unparser.unparse1$(Unparser.scala:39)
               at org.apache.daffodil.processors.unparsers.CombinatorUnparser.unparse1(Unparser.scala:128)
               at org.apache.daffodil.processors.DataProcessor.doUnparse(DataProcessor.scala:394)
               at org.apache.daffodil.processors.DataProcessor.unparse(DataProcessor.scala:334)
               at org.apache.daffodil.processors.DataProcessor.unparse(DataProcessor.scala:308)
               at org.apache.daffodil.Main$.$anonfun$run$15(Main.scala:1160)
               at org.apache.daffodil.util.Timer$.getTimeResult(Timer.scala:76)
               at org.apache.daffodil.util.Timer$.getResult(Timer.scala:35)
               at org.apache.daffodil.Main$.run(Main.scala:1160)
               at org.apache.daffodil.Main$.main(Main.scala:1388)
               at org.apache.daffodil.Main.main(Main.scala)

      Attachments

        1. s2377-1.xsd
          2 kB
          Shashi Ramaka
        2. s2377.xsd
          2 kB
          Shashi Ramaka
        3. d2377.xml
          0.1 kB
          Shashi Ramaka

        Activity

          People

            sramaka Shashi Ramaka
            mbeckerle Mike Beckerle
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: