-
Notifications
You must be signed in to change notification settings - Fork 30.2k
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
http.request TypeError: "listener" argument must be a function #30765
Comments
After switching to use the |
Can you share the stack, as well as the value of |
Stack:
Code snippet with options: let req = http.request(url, {
headers: {
'Transfer-Encoding': 'chunked'
},
method: 'POST'
}, () => console.log('Made it to callback')) |
Are you sure you're running version 12.13.1? If so, how did you install it? Is it an official build installed from nodejs.org, nvm, etc.? The reason I ask is because the first stack frame you've provided is:
But, looking at at the code for v12.13.1, that line appears to be: Line 164 in 525fd9c
|
This is correct, this issue can be closed. |
Error:
TypeError: "listener" argument must be a function
Code to reproduce:
The stack points to
let req = http.request(url, options)
as the problem lineThe text was updated successfully, but these errors were encountered: