Skip to content

Regression: @google-cloud/logging unhandled rejections during auth #2238

@ofrobots

Description

@ofrobots

I wanted to try a performance benchmark now that 1.0.0 of @google-cloud/logging is now. The very basic example I started with seems to not work at all. Fails with unhandled rejections.

(node:44617) TypeError: Cannot read property 'config' of undefined
    at Auth.getAuthClient (/Users/ofrobots/tmp/log-t/node_modules/google-gax/node_modules/google-auto-auth/index.js:38:20)
    at /Users/ofrobots/tmp/log-t/node_modules/google-gax/lib/grpc.js:90:5
    at GrpcClient._getCredentials (/Users/ofrobots/tmp/log-t/node_modules/google-gax/lib/grpc.js:89:10)
    at GrpcClient.createStub (/Users/ofrobots/tmp/log-t/node_modules/google-gax/lib/grpc.js:172:15)
    at new LoggingServiceV2Client (/Users/ofrobots/tmp/log-t/node_modules/@google-cloud/logging/src/v2/logging_service_v2_client.js:122:38)
    at Object.LoggingServiceV2ClientBuilder.loggingServiceV2Client (/Users/ofrobots/tmp/log-t/node_modules/@google-cloud/logging/src/v2/logging_service_v2_client.js:832:12)
    at /Users/ofrobots/tmp/log-t/node_modules/@google-cloud/logging/src/index.js:603:52
    at Immediate.<anonymous> (/Users/ofrobots/tmp/log-t/node_modules/google-auto-auth/index.js:146:7)
    at runCallback (timers.js:672:20)
    at tryOnImmediate (timers.js:645:5)

A PR with the fix is here: googleapis/gax-nodejs#132.

This is a pretty big regression. How can we avoid such regressions going forward?

Metadata

Metadata

Labels

api: loggingIssues related to the Cloud Logging API.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions