-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Labels
priority: p2Moderately-important priority. Fix may not be included in next release.Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.
Description
Environment details
- OS: Alpine
- Node.js version: 18.12.0
- npm version: 8.19.2
@googleapis/google-auth-library-nodejsversion: 8.7.0
Steps to reproduce
- Create an empty
gcp_credentials.jsonfile for yourgcloud_projectwith yourgcloud_storage_bucket. - Use, e.g.:
const storage = new Storage({
projectId: gcloud_project,
keyFilename: 'gcp_credentials.json'
});
const bucket = storage.bucket(gcloud_storage_bucket);
const [metadata] = await bucket.getMetadata();
- Receive unhelpful error message "TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received type boolean (true)"
It would be reasonable to sanity-check the key file and return a more illuminating error message.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
priority: p2Moderately-important priority. Fix may not be included in next release.Moderately-important priority. Fix may not be included in next release.type: bugError or flaw in code with unintended results or allowing sub-optimal usage patterns.Error or flaw in code with unintended results or allowing sub-optimal usage patterns.