I’m getting strange results from API endpoint /deploys/{deploy_id}/files/{path} when I deploy a new file. The issue occurs randomly and I have not found any particular pattern. I am currently seeing this issue on site name: eager-einstein-2aea9b.netlify.app
, but it is not restricted to this site.
I am programmatically deploying files over this endpoint using the js-client, so a typical call looks like:
const result = await api.uploadDeployFile({
deployId,
path: path,
body: bufferStream,
})
In case everything works as expected, I get the following result:
[
{
id: '/static/2dbe958e293a5bfe4e082ba42c55086176d3830d/photo-1597321764372-3c0162f1fb8f.jpg',
path: '/static/2dbe958e293a5bfe4e082ba42c55086176d3830d/photo-1597321764372-3c0162f1fb8f.jpg',
sha: '2dbe958e293a5bfe4e082ba42c55086176d3830d',
mime_type: 'image/jpeg',
size: 91693,
site_id: 'e3e9fb6b-14cc-48c7-9f24-fdafda8c9b7e',
deploy_id: '5f539fc098946635d9b6e1cb'
}
]
However, sometimes I get the following result instead, which is completely out of spec:
[
{
ID: '/static/2555efdf6712bc438581a141651552c2eb423ab6/photo-1598454242110-0744560ec77e.jpg',
Path: '/static/2555efdf6712bc438581a141651552c2eb423ab6/photo-1598454242110-0744560ec77e.jpg',
SHA: '2555efdf6712bc438581a141651552c2eb423ab6',
MimeType: 'image/jpeg',
Size: 170443
}
]
Note that the ‘deploy_id’ is missing and that the variable names are capitalized. I do not get an error (no promise is thrown) which makes exception handling difficult.
Could you please investigate what is going on here as it currently inhibits proper deployments? Thanks!