-
Notifications
You must be signed in to change notification settings - Fork 660
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
grpc-js: stream.push() after EOF #752
Comments
Has there ever been any thoughts around using the |
I've never seen that before. I think we have to weigh the value of stream changes exposing bugs in our code vs the downside of stream changes potentially breaking otherwise non-buggy code. I don't know yet which category this issue is in, and I don't know which I would expect to be more common. |
I've been testing a change on PubSub and so far it looks promising. Our issue looks like a call to |
Problem description
When trying to replace
grpc
with@grpc/grpc-js
in GAPIC client libraries, many libraries' system tests randomly fail on Node 8 with the following stack trace:Reproduction steps
The problem is flaky. I was only able to reproduce it on Node 8.15.0 (never on Node 10) (which may be related to the fact that
_stream_readable.js
was refactored in Node 10). I see this problem when I run system tests for Google Cloud Pub/Sub package, so to repro that, you'll need to have a service account key (contact me and I'll give you one).The
mocha
error you'll likely see will beError: done() called multiple times
but the actual exception (not printed) will be the one I pasted above.Environment
node:8
Docker image (e.g. the one we use in Kokoro)Additional details
I'm pretty sure the error might be related to the fact that Pub/Sub client library destroys the stream and this code is executed in the test:
https://github.com/googleapis/nodejs-pubsub/blob/eee4f5de6bd83be687422c5ccef8781fa5ac7af0/src/subscriber.ts#L244-L256
but (a) this code never fails in native gRPC, and (b) throwing internal Node exception is not good.
The text was updated successfully, but these errors were encountered: