Skip to content

Automate browser based workflows with AI

guess at the issue with broken code tab for wpid_445917468972674652 w… (#3621)

Jonathan Dobsona3e5e278528f
diff --git a/skyvern-frontend/src/routes/workflows/workflowRun/WorkflowRunCode.tsx b/skyvern-frontend/src/routes/workflows/workflowRun/WorkflowRunCode.tsx
index 0b07f3d2c..2faeef491 100644
--- a/skyvern-frontend/src/routes/workflows/workflowRun/WorkflowRunCode.tsx
+++ b/skyvern-frontend/src/routes/workflows/workflowRun/WorkflowRunCode.tsx
@@ -164,31 +164,33 @@ function WorkflowRunCode(props?: Props) {
}
/>
</div>
- <Select
- disabled={!isFinalized}
- value={cacheKeyValue}
- onValueChange={(v: string) => setCacheKeyValue(v)}
- >
- <SelectTrigger className="max-w-[15rem] [&>span]:text-ellipsis">
- <SelectValue placeholder="Code Key Value" />
- </SelectTrigger>
- <SelectContent>
- {Array.from(cacheKeyValueSet)
- .sort()
- .map((value) => {
- return (
- <SelectItem key={value} value={value}>
- {value === cacheKeyValueForWorkflowRun &&
- isFinalized === true ? (
- <span className="underline">{value}</span>
- ) : (
- value
- )}
- </SelectItem>
- );
- })}
- </SelectContent>
- </Select>
+ {cacheKeyValueSet.size > 0 ? (
+ <Select
+ disabled={!isFinalized}
+ value={cacheKeyValue}
+ onValueChange={(v: string) => setCacheKeyValue(v)}
+ >
+ <SelectTrigger className="max-w-[15rem] [&>span]:text-ellipsis">
+ <SelectValue placeholder="Code Key Value" />
+ </SelectTrigger>
+ <SelectContent>
+ {Array.from(cacheKeyValueSet)
+ .sort()
+ .map((value) => {
+ return (
+ <SelectItem key={value} value={value}>
+ {value === cacheKeyValueForWorkflowRun &&
+ isFinalized === true ? (
+ <span className="underline">{value}</span>
+ ) : (
+ value
+ )}
+ </SelectItem>
+ );
+ })}
+ </SelectContent>
+ </Select>
+ ) : null}
</div>
<CodeEditor
className={cn("h-full w-full overflow-y-scroll", {