JeremyYao commented on code in PR #1403:
URL: https://github.com/apache/daffodil-vscode/pull/1403#discussion_r2349146476


##########
src/launchWizard/launchWizard.ts:
##########
@@ -510,11 +518,11 @@ class LaunchWizard {
 

Review Comment:
   > If I have a launch config with 'none' set, and I copy it using the Launch 
Wizard, then change 'none' to 'execute' in the copy, the defaults are empty 
strings. If we set the default values here ("Default Test Case" and 
"${AskForValidatedTDMLPath}"), they'll get picked up on the switch.
   > 
   > I got here by looking at a change made in this PR in script.js where the 
Path value is set to an empty string. I suspect that should probably be updated 
as well, but I don't know exactly how to make that empty string show up.
   
   Here's what I'm seeing if I'm following the description
   
   1. Create a laucnh.json config w/ `none`
   
   Result: 
   
   ```JSON
   {
       "version": "0.2.0",
       "configurations": [
           {
               "request": "launch",
               "type": "dfdl",
               "name": "Wizard Config",
               "schema": {
                   "path": "${command:AskForSchemaName}",
                   "rootName": null,
                   "rootNamespace": null
               },
               "data": "${command:AskForDataName}",
               "debugServer": 4711,
               "infosetFormat": "xml",
               "infosetOutput": {
                   "type": "file",
                   "path": "${workspaceFolder}/target/infoset.xml"
               },
               "tdmlConfig": {
                   "action": "none"
               },
               "trace": true,
               "stopOnEntry": true,
               "useExistingServer": false,
               "openDataEditor": false,
               "openInfosetView": false,
               "openInfosetDiffView": false,
               "daffodilDebugClasspath": [],
               "dataEditor": {
                   "port": 9000,
                   "logging": {
                       "file": 
"${workspaceFolder}/dataEditor-${omegaEditPort}.log",
                       "level": "info"
                   }
               },
               "dfdlDebugger": {
                   "logging": {
                       "file": "${workspaceFolder}/daffodil-debugger.log",
                       "level": "INFO"
                   }
               }
           }
       ]
   }
   ```
   
   2. Copy the config
   
   <img width="988" height="1273" alt="image" 
src="https://github.com/user-attachments/assets/92c38378-cc9e-4373-8730-7c641bc3c261";
 />
   
   3. In the above copy, set none to executed
   
   <img width="475" height="237" alt="image" 
src="https://github.com/user-attachments/assets/ace134de-1710-4e00-8c7e-11a66cd318e5";
 />
   
   
   4. Resulting launch.json config
   
   ```JSON
   {
       "version": "0.2.0",
       "configurations": [
           {
               "request": "launch",
               "type": "dfdl",
               "name": "Wizard Config",
               "schema": {
                   "path": "${command:AskForSchemaName}",
                   "rootName": null,
                   "rootNamespace": null
               },
               "data": "${command:AskForDataName}",
               "debugServer": 4711,
               "infosetFormat": "xml",
               "infosetOutput": {
                   "type": "file",
                   "path": "${workspaceFolder}/target/infoset.xml"
               },
               "tdmlConfig": {
                   "action": "none"
               },
               "trace": true,
               "stopOnEntry": true,
               "useExistingServer": false,
               "openDataEditor": false,
               "openInfosetView": false,
               "openInfosetDiffView": false,
               "daffodilDebugClasspath": [],
               "dataEditor": {
                   "port": 9000,
                   "logging": {
                       "file": 
"${workspaceFolder}/dataEditor-${omegaEditPort}.log",
                       "level": "info"
                   }
               },
               "dfdlDebugger": {
                   "logging": {
                       "file": "${workspaceFolder}/daffodil-debugger.log",
                       "level": "INFO"
                   }
               }
           },
           {
               "request": "launch",
               "type": "dfdl",
               "name": "Wizard Config Copy",
               "schema": {
                   "path": "${command:AskForSchemaName}",
                   "rootName": null,
                   "rootNamespace": null
               },
               "data": "${command:AskForDataName}",
               "debugServer": 4711,
               "infosetFormat": "xml",
               "infosetOutput": {
                   "type": "file",
                   "path": "${workspaceFolder}/target/infoset.xml"
               },
               "tdmlConfig": {
                   "action": "execute",
                   "path": "${AskForValidatedTDMLPath}",
                   "name": "Default Test Case"
               },
               "trace": true,
               "stopOnEntry": true,
               "useExistingServer": false,
               "openDataEditor": false,
               "openInfosetView": false,
               "openInfosetDiffView": false,
               "daffodilDebugClasspath": [],
               "dataEditor": {
                   "port": 9000,
                   "logging": {
                       "file": 
"${workspaceFolder}/dataEditor-${omegaEditPort}.log",
                       "level": "info"
                   }
               },
               "dfdlDebugger": {
                   "logging": {
                       "file": "${workspaceFolder}/daffodil-debugger.log",
                       "level": "INFO"
                   }
               }
           }
       ]
   }
   ```
   
   



-- 
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

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

Reply via email to