Skip to content
This repository was archived by the owner on Mar 17, 2026. It is now read-only.
This repository was archived by the owner on Mar 17, 2026. It is now read-only.

No error returned for invalid private_key #1063

@ibmappcon

Description

@ibmappcon

Hi,

We are using nodejs-pubsub package v2.2.0 for one of our connector and it was observed that the endpoint does not return any error when the client is created with invalid private_key. Also, when this client was used to get topics, it did not return autentication error. However, after waiting for the default timeout, it returned an error with code 4 as below:

{ Error: Total timeout of API google.pubsub.v1.Publisher exceeded 600000 milliseconds before any response was received.
    at repeat (C:\Users\Ms\Documents\Connectors\GooglePubSub\poc_scripts\node_modules\google-gax\build\src\normalCalls\retries.js:66:31)
    at Timeout.setTimeout [as _onTimeout] (C:\Users\Ms\Documents\Connectors\GooglePubSub\poc_scripts\node_modules\google-gax\build\src\normalCalls\retries.js:101:25)
    at ontimeout (timers.js:436:11)
    at tryOnTimeout (timers.js:300:5)
    at listOnTimeout (timers.js:263:5)
    at Timer.processTimers (timers.js:223:10) code: 4 }

We expect authentication error in the above error case. Could you please help in understanding how to get correct error in such case.

Metadata

Metadata

Assignees

Labels

api: pubsubIssues related to the googleapis/nodejs-pubsub API.priority: p2Moderately-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.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions