- Version: v9.2.1 and v9.3.0
- Platform: Ubuntu 16.04
I am using createWriteStream in my code which throws the following error on Ubuntu:
events.js:180
throw new errors.TypeError('ERR_INVALID_ARG_TYPE', 'listener', 'Function');
^
TypeError [ERR_INVALID_ARG_TYPE]: The "listener" argument must be of type Function
Adding the autoClose option solves this error. The docs mention that autoClose=true by default so not sure why I had to explicitly specify it again.
The code does not throw error when running on mac 10.12.6 with node 9.2.1 and 9.3.0.
The code works without any errors on Ubuntu 16.04 when using node 8.9.3. Looks like something changed after 8.9.3 for the Ubuntu build which is causing this issue.
I am using
createWriteStreamin my code which throws the following error on Ubuntu:Adding the
autoCloseoption solves this error. The docs mention thatautoClose=trueby default so not sure why I had to explicitly specify it again.The code does not throw error when running on mac 10.12.6 with node 9.2.1 and 9.3.0.
The code works without any errors on Ubuntu 16.04 when using node 8.9.3. Looks like something changed after 8.9.3 for the Ubuntu build which is causing this issue.