Uploaded image for project: 'Daffodil'
  1. Daffodil
  2. DFDL-1038

Strange interaction of DPath expression compilation and Trace/Debug

XMLWordPrintableJSON

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Normal Normal
    • s15
    • s15
    • Back End, Debugger
    • None

      This bug is currently happening on the serialization-with-dpath branch, but I'm parking it here because it is so strange, and very well may move with the eventual integration of this branch back into the mainline.

      The below is in scala-debug section14.sequence-groups.

      /**
         * The test_baseline() below fails if you have dbg on it as here. 
         * It passes if you don't have dbg on it.
         * 
         * The problem is some interaction of the try/catch surrounding expression
         * evaluation at compile time and the InteractiveDebugger/Trace
         * 
         * We run the expression and catch errors if it
         * ISNT constant, as a way of determining whether it is a constant. The 
         * expression is { .. } which is NOT constant, and a throw of IllegalStateException
         * occurs which is caught (supposed to be anyway) very nearby where it is
         * thrown. But somehow, we end up exiting as if the exception was not caught.
         * 
         * This happens on the final, 26th such throw. All earlier throws/catch work
         * fine. (If you set a breakpoint on IllegalStateException caught and uncaught
         * you can set the hit count to 26 and watch what happens here.
         * 
         * I am mystified by this. -mikeb 2014-09-26
         */
        def dbg = {
          Debugger.withTracing(false)
          // LoggingDefaults.setLoggingLevel(LogLevel.Debug)
        }
        @Test def test_baseline() { dbg; runner_01.runOneTest("initiatedContentSeqBaseline") }
       

              jchab Jessie Chab
              mbeckerle.dfdl Mike Beckerle
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: