You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Mar 3, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Mar 3, 2026. It is now read-only.
file.delete returns a wrong value when the files doesn't exist #2182
api: storageIssues related to the googleapis/nodejs-storage API.next major: breaking changethis is a change that we should wait to bundle into the next major versionpriority: p3Desirable enhancement or fix. May not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.
Hi @vicb thank you for opening this issue. Can you explain further why you think the first element should not be here? The first element is the raw response and the second element is the response body. Both of these adhere to the type of [r.Response].
@vicb thank you for clarifying (and nice catch!), I see the problem now. It looks like the first item is actually of type ResponseBody which is set to any. Let me see if there is a decent way to fix this without making signature changes or type changes as these would necessitate a major version bump of the library.
api: storageIssues related to the googleapis/nodejs-storage API.next major: breaking changethis is a change that we should wait to bundle into the next major versionpriority: p3Desirable enhancement or fix. May not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.
Activity
ddelgrosso1 commentedon Apr 18, 2023
Hi @vicb thank you for opening this issue. Can you explain further why you think the first element should not be here? The first element is the raw response and the second element is the response body. Both of these adhere to the type of [r.Response].
vicb commentedon Apr 18, 2023
Thanks @ddelgrosso1 for your quick attention to that bug.
I see
nodejs-storage/src/nodejs-common/service-object.ts
Line 275 in b122e18
with
r.Responsebeing (node_modules/teeny-request/build/src/index.d.ts):You can see that
Does not match that type, i.e. it has no
statusCode.Also if the response is supposed to be a tuple then a
[Response, Response]type would be more appropriate.ddelgrosso1 commentedon Apr 18, 2023
@vicb thank you for clarifying (and nice catch!), I see the problem now. It looks like the first item is actually of type
ResponseBodywhich is set toany. Let me see if there is a decent way to fix this without making signature changes or type changes as these would necessitate a major version bump of the library.ddelgrosso1 commentedon Aug 3, 2023
Released with 7.0