-
Notifications
You must be signed in to change notification settings - Fork 290
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
TypeError: Cannot read property 'write' of null at Zlib.callback (zlib.js:499:33) for Nodejs 14.5 #3397
Comments
Could you provide a minimal repro? Can you reproduce this in latest LTS |
Hi @naren0021, from what I can see of the error stack you copied (BTW, it's usually better to copy the whole output if you want someone to help you to have the correct info), it seems you have a module called myObject.write('data'); It either means that you need to add a check before trying to call the method: if (myObject != null) myObject.write('data'); Or that there's somewhere else in your app, in which case there's not much I can do to help you... I see in the issue title that you are using Node.js 14.5, kindly consider upgrading to the latest version, lots of bugs are fixed simply by keeping up-to-date with the tools you're using. |
correct error is this @Ayase-252
yes sure I will update the Node version and will update you @aduh95 |
@aduh95 this looks like a case of nodejs/node#36421 :( |
This issue is not as simple as since Zlib is a submodule of core node js and is used internally when web sockets are used. so if we write something on websocket i.e. socket.emit we dont have access to zlib. so cannot do the check mentioned by @aduh95 . |
@KRAUS1203 I didn't realize Line 499 of |
I wouldn't think so — you can see in nodejs/node#36421 that three different people have the same line ( |
That looks like node 8 actually https://github.com/nodejs/node/blob/v8.x/lib/zlib.js#L499❓ |
@naren0021 you said:
but this appears to be like @KRAUS1203's problem, and in nodejs/node#36421 they said that they were using 8.9.4 🤔 |
It seems there has been no activity on this issue for a while, and it is being closed in 30 days. If you believe this issue should remain open, please leave a comment. |
It seems there has been no activity on this issue for a while, and it is being closed. If you believe this issue should remain open, please leave a comment. |
I have recently experienced the issue on node 14.x on the production
The text was updated successfully, but these errors were encountered: