log the status code in the build reporting warning (#30)

pull/1358/head
Aayush Shah 10 months ago committed by GitHub
parent fc356a7e65
commit 4e686a61f2
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -319,7 +319,9 @@ async function reportBuild(dockerfilePath: string) {
stateHelper.setBlacksmithDockerBuildId(response.data.docker_build_id);
return response.data;
} catch (error) {
core.warning('Error reporting build to Blacksmith API:', error);
const statusCode = (error as AxiosError)?.response?.status;
core.warning(`Error reporting build to Blacksmith API (status: ${statusCode || 'unknown'}):`);
core.warning(error);
return null;
}
}

Loading…
Cancel
Save