Don't bail on fetchBuildAllInfo if fetchBuildManifest fails
If we fail to fetch an expected manifest (eg, it returns a 404), then currently the fetch of the build info is marked as a failure and the ui says that the build does not exist. This is misleading and we should actually display as much build info as we have even if we weren't able to fetch the manifest. This change will cause, in the case of a 404 for the manifest, a toast to display the error regarding the fetch manifest failure, but underneath it the rest of the build page will display as normal. The line being removed was intended to avoid a failure which can happen if the user visits a log page and the manifest has not been fetched. However, the user is only likely to visit the log url if the manifest has been fetched since the manifest is required to supply the index of log files. So this case does not need to be specially handled. Change-Id: If87a8de8895c4556306cd7145f4a235b6f786a6a
This commit is contained in:
parent
8be15d9aad
commit
d27062c99f
|
@ -370,10 +370,9 @@ export function fetchBuildManifest(buildId, state) {
|
|||
const response = await Axios.get(artifact.url)
|
||||
return dispatch(receiveBuildManifest(buildId, response.data))
|
||||
} catch(error) {
|
||||
// Show the error since we expected a manifest but did not
|
||||
// receive it.
|
||||
dispatch(failedBuildManifest(buildId, error, artifact.url))
|
||||
// Raise the error again, so fetchBuildAllInfo() doesn't call
|
||||
// fetchLogFile which needs an existing manifest file.
|
||||
throw error
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue