JeremyYao opened a new issue, #1297:
URL: https://github.com/apache/daffodil-vscode/issues/1297

   ### Description
   
   When executing a TDML test case. Breakpoints from the schema don't carry 
over. Breakpoints are hit if you run a DFDL debugging session normally, but 
running a DFDL debugging session from a TDML test case seems to ignore the set 
breakpoints. 
   
   ### How to replicate
   
   1. Download 
https://github.com/DFDLSchemas/JPEG/blob/master/src/main/resources/com/mitre/jpeg/xsd/jpeg.dfdl.xsd
 and https://negativespace.co/wp-content/uploads/2017/04/curious-cat-thumb.jpg 
and move them into your sampleWorkspace folder
   2. Create a launch.json configuration to run a debugging session. My 
launch.json looks like 
   
   ```JSON
   {
       "version": "0.2.0",
       "configurations": [
           {
               "request": "launch",
               "type": "dfdl",
               "name": "Cat_DFDL",
               "schema": {
                   "path": "${workspaceFolder}/jpeg.dfdl.xsd",
                   "rootName": null,
                   "rootNamespace": null
               },
               "data": "${workspaceFolder}/test_images/curious-cat-thumb.jpg",
               "debugServer": 4712,
               "infosetFormat": "xml",
               "infosetOutput": {
                   "type": "file",
                   "path": "${workspaceFolder}/target/infoset.xml"
               },
               "tdmlConfig": {
                   "action": "generate",
                   "name": "undefined",
                   "description": "undefined",
                   "path": "undefined"
               },
               "trace": true,
               "stopOnEntry": true,
               "useExistingServer": false,
               "openDataEditor": true,
               "openInfosetView": true,
               "openInfosetDiffView": true,
               "daffodilDebugClasspath": [],
               "dataEditor": {
                   "port": 9000,
                   "logging": {
                       "file": 
"${workspaceFolder}/dataEditor-${omegaEditPort}.log",
                       "level": "info"
                   }
               },
               "dfdlDebugger": {
                   "logging": {
                       "file": "${workspaceFolder}/daffodil-debugger.log",
                       "level": "INFO"
                   }
               }
           }
       ]
   }
   ```
   
   3. Don't click on continue. Set breakpoints on lines 489, 491, 524. Click 
continue. You should hit the breakpoint 489. 
   
   
![Image](https://github.com/user-attachments/assets/f97bb5cc-b500-40f2-a955-f484f8ddca26)
   
   4. Click on continue until the debugging session is over. 
   5. Open jpeg.dfdl.xsd and copy the TDML to sampleWorkspace 
   
   
![Image](https://github.com/user-attachments/assets/26e5495c-453c-493f-8e18-681c11fb799d)
   
   6. Execute the TDML file and click on continue
   
   
![Image](https://github.com/user-attachments/assets/70d81e17-94fd-4930-81dc-fe55d645a166)
   
   7. You should notice that breakpoint 489 didn't get hit even though there's 
still a red dot on the line. 
   
   
![Image](https://github.com/user-attachments/assets/ed1ee943-f25a-4b8c-b9aa-6d208e16e9b1)
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@daffodil.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to