This is an automated email from the ASF dual-hosted git repository.
arosien pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/daffodil-vscode.git
The following commit(s) were added to refs/heads/main by this push:
new a03c7ba Fix issue where functionality was missing when using
useExistingServer
a03c7ba is described below
commit a03c7baff8e7e6102be8ab22983511c627796f47
Author: Shane Dell <[email protected]>
AuthorDate: Tue Aug 8 16:54:14 2023 -0400
Fix issue where functionality was missing when using useExistingServer
- Whenever useExistingServer was set to true a bunch of code didn't get
executed.
- However, the only code that shouldn't have been executed was running
the debubbger.
- This updates fixes that so that only the debugger isn't ran and all
other functionality is still available when useExistingServer is set to true.
Closes #747
---
src/daffodilDebugger/debugger.ts | 50 ++++++++++++++++++++--------------------
1 file changed, 25 insertions(+), 25 deletions(-)
diff --git a/src/daffodilDebugger/debugger.ts b/src/daffodilDebugger/debugger.ts
index 129cee2..5bd7bef 100644
--- a/src/daffodilDebugger/debugger.ts
+++ b/src/daffodilDebugger/debugger.ts
@@ -152,36 +152,36 @@ export async function getDebugger(
): Promise<vscode.DebugConfiguration | undefined> {
config = getConfig(config) // make sure all config attributes are set
- if (!config.useExistingServer) {
- if (vscode.workspace.workspaceFolders !== undefined) {
- await stopDebugger()
-
- // Get program file before debugger starts to avoid timeout
- if (config.program.includes('${command:AskForProgramName}')) {
- config.program = await vscode.commands.executeCommand(
- 'extension.dfdl-debug.getProgramName'
- )
- }
+ if (vscode.workspace.workspaceFolders !== undefined) {
+ await stopDebugger()
- // Get data file before debugger starts to avoid timeout
- if (config.data.includes('${command:AskForDataName}')) {
- config.data = await vscode.commands.executeCommand(
- 'extension.dfdl-debug.getDataName'
- )
- }
+ // Get program file before debugger starts to avoid timeout
+ if (config.program.includes('${command:AskForProgramName}')) {
+ config.program = await vscode.commands.executeCommand(
+ 'extension.dfdl-debug.getProgramName'
+ )
+ }
- if (!(await getTDMLConfig(config))) {
- return await stopDebugging().then((_) => undefined)
- }
+ // Get data file before debugger starts to avoid timeout
+ if (config.data.includes('${command:AskForDataName}')) {
+ config.data = await vscode.commands.executeCommand(
+ 'extension.dfdl-debug.getDataName'
+ )
+ }
- let workspaceFolder = vscode.workspace.workspaceFolders[0].uri.fsPath
+ if (!(await getTDMLConfig(config))) {
+ return await stopDebugging().then((_) => undefined)
+ }
- // Get daffodilDebugger class paths to be added to the debugger
- const daffodilDebugClasspath = await getDaffodilDebugClasspath(
- config,
- workspaceFolder
- )
+ let workspaceFolder = vscode.workspace.workspaceFolders[0].uri.fsPath
+
+ // Get daffodilDebugger class paths to be added to the debugger
+ const daffodilDebugClasspath = await getDaffodilDebugClasspath(
+ config,
+ workspaceFolder
+ )
+ if (!config.useExistingServer) {
await runDebugger(
context.asAbsolutePath('./'),
daffodilDebugClasspath,