Skip to content

Commit

Permalink
exec_log_card: download execution log with ext (#6467)
Browse files Browse the repository at this point in the history
  • Loading branch information
sluongng committed Apr 30, 2024
1 parent 615c78b commit 78792e6
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
10 changes: 8 additions & 2 deletions app/invocation/invocation_exec_log_card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,9 @@ export default class InvocationExecLogCardComponent extends React.Component<Prop
getExecutionLogFile(): build_event_stream.File | undefined {
return this.props.model.buildToolLogs?.log.find(
(log: build_event_stream.File) =>
log.name == "execution.log" && log.uri && Boolean(log.uri.startsWith("bytestream://"))
(log.name == "execution.log" || log.name == "execution_log.binpb.zstd") &&
log.uri &&
Boolean(log.uri.startsWith("bytestream://"))
);
}

Expand Down Expand Up @@ -112,7 +114,11 @@ export default class InvocationExecLogCardComponent extends React.Component<Prop
}

try {
rpcService.downloadBytestreamFile("execution.log", profileFile.uri, this.props.model.getInvocationId());
rpcService.downloadBytestreamFile(
"execution_log.binpb.zstd",
profileFile.uri,
this.props.model.getInvocationId()
);
} catch {
console.error("Error downloading execution log");
}
Expand Down
5 changes: 3 additions & 2 deletions app/invocation/invocation_model.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -459,8 +459,9 @@ export default class InvocationModel {

getIsExecutionLogEnabled() {
return (
this.buildToolLogs?.log.find((l) => l.name == "execution.log" && l.uri.startsWith("bytestream://")) &&
this.stringCommandLineOption("remote_build_event_upload") == "all"
this.buildToolLogs?.log.find(
(l) => (l.name == "execution.log" || l.name == "execution_log.binpb.zstd") && l.uri.startsWith("bytestream://")
) && this.stringCommandLineOption("remote_build_event_upload") == "all"
);
}

Expand Down

0 comments on commit 78792e6

Please sign in to comment.