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

SDE should occur when complexType is defined with no content. Instead: crazy OOLAG

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • s10
    • None
    • None

    Description

      According to an errata to the spec:

      2.48. Section 14.1. Spec states that an empty sequence that is the content of a complex type
      is a schema definition error. Many schema processors are not able to distinguish this
      condition from a complex type with no content at all (it is not required to do so by the XML
      Schema specification). As a complex type with no content is not useful in DFDL, change the
      spec to state that both conditions are schema definition errors.

      Note that this case is for complexTypes with NO content, not to be confused (and I confused them at length) with complexTypes with EMPTY content.

      Instead of a neatly packaged SDE I get this error:

      [info] - test_noContentComplexSDE *** FAILED ***
      [info] edu.illinois.ncsa.daffodil.exceptions.Abort: scala.MatchError: List() (of class scala.collection.immutable.Nil$)
      [info] at edu.illinois.ncsa.daffodil.dsom.oolag.OOLAG$OOLAGValue.edu$illinois$ncsa$daffodil$dsom$oolag$OOLAG$OOLAGValue$$oolagTryCatch(OOLAG.scala:501)
      [info] at edu.illinois.ncsa.daffodil.dsom.oolag.OOLAG$OOLAGValue$$anonfun$6.apply(OOLAG.scala:577)
      [info] at edu.illinois.ncsa.daffodil.dsom.oolag.OOLAG$OOLAGHost.circularityDetector(OOLAG.scala:234)
      [info] at edu.illinois.ncsa.daffodil.dsom.oolag.OOLAG$OOLAGValue.valueAsAny(OOLAG.scala:563)
      [info] at edu.illinois.ncsa.daffodil.dsom.oolag.OOLAG$LV.value(OOLAG.scala:659)
      [info] at edu.illinois.ncsa.daffodil.dsom.oolag.OOLAG$OOLAGHost$$anonfun$checkErrors$1$$anonfun$apply$mcV$sp$2$$anonfun$apply$2.apply$mcV$sp(OOLAG.scala:332)
      [info] at edu.illinois.ncsa.daffodil.dsom.oolag.OOLAG$OOLAGHost$$anonfun$checkErrors$1$$anonfun$apply$mcV$sp$2$$anonfun$apply$2.apply(OOLAG.scala:314)
      [info] at edu.illinois.ncsa.daffodil.dsom.oolag.OOLAG$OOLAGHost$$anonfun$checkErrors$1$$anonfun$apply$mcV$sp$2$$anonfun$apply$2.apply(OOLAG.scala:314)
      [info] at edu.illinois.ncsa.daffodil.dsom.oolag.OOLAG$.keepGoing(OOLAG.scala:75)
      [info] at edu.illinois.ncsa.daffodil.dsom.oolag.OOLAG$OOLAGHost$$anonfun$checkErrors$1$$anonfun$apply$mcV$sp$2.apply(OOLAG.scala:314)
      [info] ...

      The test is noContentComplexSDE in the following files:
      daffodil-test/src/test/resources/edu/illinois/ncsa/daffodil/section14/sequence_groups/SequenceGroup.tdml
      daffodil-test/src/test/scala-debug/edu/illinois/ncsa/daffodil/section14/sequence_groups/TestSequenceGroupsDebug.scala
      daffodil-test/src/test/scala/edu/illinois/ncsa/daffodil/section14/sequence_groups/TestSequenceGroups.scala

      Attachments

        Activity

          People

            daffodil-jchab Jessie Chab
            daffodil-jchab Jessie Chab
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: