16073: Correctly fetch raw inputs wihtout processing
authorStephen Smith <stephen@curii.com>
Thu, 29 Sep 2022 21:22:34 +0000 (17:22 -0400)
committerStephen Smith <stephen@curii.com>
Fri, 30 Sep 2022 02:22:34 +0000 (22:22 -0400)
Arvados-DCO-1.1-Signed-off-by: Stephen Smith <stephen@curii.com>

src/store/processes/processes-actions.ts
src/views/process-panel/process-panel-root.tsx

index dbca03ab6387c069993f80c3423f2d5881ac3507..eb04ed676f7644026cb8462760b47c064336dc87 100644 (file)
@@ -133,6 +133,11 @@ export const reRunProcess = (processUuid: string, workflowUuid: string) =>
         }
     };
 
+export const getRawInputs = (data: any): CommandInputParameter[] | undefined => {
+    if (!data || !data.mounts || !data.mounts[MOUNT_PATH_CWL_INPUT]) { return undefined; }
+    return (data.mounts[MOUNT_PATH_CWL_INPUT].content);
+}
+
 export const getInputs = (data: any): CommandInputParameter[] => {
     if (!data || !data.mounts || !data.mounts[MOUNT_PATH_CWL_WORKFLOW]) { return []; }
     const inputs = getWorkflowInputs(data.mounts[MOUNT_PATH_CWL_WORKFLOW].content);
index 1651b63a539cc56b5182ad0e36f8fef15cc89853..9fc043d9e0a4aa4db20294fe821c3995da75c0cb 100644 (file)
@@ -17,7 +17,7 @@ import { getIOParamDisplayValue, ProcessIOCard, ProcessIOCardType, ProcessIOPara
 import { getProcessPanelLogs, ProcessLogsPanel } from 'store/process-logs-panel/process-logs-panel';
 import { ProcessLogsCard } from './process-log-card';
 import { FilterOption } from 'views/process-panel/process-log-form';
-import { getInputs, getInputCollectionMounts, getOutputParameters } from 'store/processes/processes-actions';
+import { getInputs, getInputCollectionMounts, getOutputParameters, getRawInputs } from 'store/processes/processes-actions';
 import { CommandInputParameter, getIOParamId } from 'models/workflow';
 import { CommandOutputParameter } from 'cwlts/mappings/v1.0/CommandOutputParameter';
 import { AuthState } from 'store/auth/auth-reducer';
@@ -97,9 +97,11 @@ export const ProcessPanelRoot = withStyles(styles)(
 
     React.useEffect(() => {
         if (process) {
-            const rawInputs = getInputs(process.containerRequest);
+            const rawInputs = getRawInputs(process.containerRequest);
             setInputs(rawInputs);
-            setProcessedInputs(formatInputData(rawInputs, auth));
+
+            const inputs = getInputs(process.containerRequest);
+            setProcessedInputs(formatInputData(inputs, auth));
         }
     }, [requestUuid, auth, process]);