Skip to content

Commit

Permalink
Improve error message for failures when invalidating a workflow snaps…
Browse files Browse the repository at this point in the history
  • Loading branch information
maggie-lou committed Jun 10, 2024
1 parent c9d5d40 commit ab20137
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/invocation/workflow_rerun_button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,9 @@ export default class WorkflowRerunButton extends React.Component<WorkflowRerunBu
try {
await this.invalidateSnapshot();
} catch (e) {
errorService.handleError(`Failed to invalidate snapshot: ${e}`);
errorService.handleError(`Failed to invalidate snapshot: ${e}.
To work around this, you can invalidate snapshots for ALL workflows by
clicking "Invalidate all workflow VM snapshots" in the 3-dot menu on the Workflows page`);
this.setState({ isLoading: false });
return;
}
Expand Down Expand Up @@ -145,9 +147,7 @@ export default class WorkflowRerunButton extends React.Component<WorkflowRerunBu
const executeResponseBuffer = await rpcService
.fetchBytestreamFile(executeResponseUrl, this.props.model.getInvocationId(), "arraybuffer")
.catch((e) => {
throw new Error(
`workflow execute response does not exist in the cache. Try invalidating from a more recent workflow run`
);
throw new Error(`workflow execute response does not exist in the cache`);
});

const actionResult = build.bazel.remote.execution.v2.ActionResult.decode(new Uint8Array(executeResponseBuffer));
Expand Down

0 comments on commit ab20137

Please sign in to comment.