From 8a617a73ae63233332f5788c90f173d6cd5e1283 Mon Sep 17 00:00:00 2001 From: Mihajlo Date: Mon, 13 Jun 2022 14:01:12 +0200 Subject: [PATCH 1/2] fix: execution controller better error handling --- api/src/controllers/internal/Execution.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/src/controllers/internal/Execution.ts b/api/src/controllers/internal/Execution.ts index b4d8b4c..9c46601 100644 --- a/api/src/controllers/internal/Execution.ts +++ b/api/src/controllers/internal/Execution.ts @@ -43,7 +43,7 @@ export class ExecutionController { session?: Session ) { if (!(await fileExists(programPath))) - throw 'ExecutionController: SAS file does not exist.' + throw `ExecutionController: SAS file (${programPath}) does not exist.` const program = await readFile(programPath) From 3fa2a7e2e32f90050f6b09e30ce3ef725eb0b15f Mon Sep 17 00:00:00 2001 From: Mihajlo Medjedovic Date: Mon, 13 Jun 2022 12:25:06 +0000 Subject: [PATCH 2/2] fix: execution controller error details --- api/src/controllers/internal/Execution.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/src/controllers/internal/Execution.ts b/api/src/controllers/internal/Execution.ts index 9c46601..141942a 100644 --- a/api/src/controllers/internal/Execution.ts +++ b/api/src/controllers/internal/Execution.ts @@ -43,7 +43,7 @@ export class ExecutionController { session?: Session ) { if (!(await fileExists(programPath))) - throw `ExecutionController: SAS file (${programPath}) does not exist.` + throw `The Stored Program at (${vars._program}) does not exist, or you do not have permission to view it.` const program = await readFile(programPath)