Skip to content
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

fix invalid args type on node v14 #361

Merged
merged 1 commit into from
Oct 23, 2023

Conversation

alanlima
Copy link
Contributor

@alanlima alanlima commented May 6, 2020

Hi all,

This PR fixes a breaking change with node v14 where number is no longer a valid entry for fs.writeFileSync.

In reason of that, on node v14, we will receive the error below when the daemon attempts to register the process.pid.

TypeError [ERR_INVALID_ARG_TYPE]: The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView. Received type number (32716)

The quick fix is to change the file hotel/lib/pid-file.js to parse the process.pid to string.

I am happy to receive any feedback on this PR.
I tested the changes on node v13, and it works just fine, so I am not expecting that machine running old versions of node will be impacted.

😁

@ahallicks
Copy link

Any chance of getting this merged?

@j-f1
Copy link
Contributor

j-f1 commented Jul 12, 2020

cc @typicode can you merge and release this quick change so Hotel works on the latest Node?

@exah
Copy link
Contributor

exah commented Feb 22, 2021

@typicode please, release new version :)

@raphaeleidus
Copy link

this appears to still be an issue in node16 and this fix is still good. Please merge

@quinn
Copy link

quinn commented Dec 1, 2021

merged this fix and published to https://www.npmjs.com/package/@qshan/hotel if you want merge/publish access lmk

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants