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

process.send is broken with pm2 #16132

Open
Micnubinub opened this issue Jan 3, 2025 · 0 comments
Open

process.send is broken with pm2 #16132

Micnubinub opened this issue Jan 3, 2025 · 0 comments
Labels
bug Something isn't working confirmed bug We can reproduce this issue node:process

Comments

@Micnubinub
Copy link

What version of Bun is running?

1.1.42

What platform is your computer?

Darwin 24.2.0 arm64 arm

What steps can reproduce the bug?

When you make a file that uses process.send it crashes

setInterval( () => {
   process.send({message: 'test'}, (a) => {
     console.log('send handle', a)
   }, undefined, console.error);
}, 4000 );

This runs just fine: pm2 start --name test --no-autorestart --no-daemon app.js -i 2
This crashes: pm2 start --interpreter /opt/homebrew/bin/bun --name test --no-autorestart --no-daemon tmo.js -i 2
crashes with strings, json, stringified json

What is the expected behavior?

Send message

What do you see instead?

Error:

undefined:1
{"message":"test"}
^
SyntaxError: Unexpected token '', "{"message":"test"}" is not valid JSON

Additional information

No response

@Micnubinub Micnubinub added bug Something isn't working needs triage labels Jan 3, 2025
@DonIsaac DonIsaac added node:process confirmed bug We can reproduce this issue and removed needs triage labels Jan 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working confirmed bug We can reproduce this issue node:process
Projects
None yet
Development

No branches or pull requests

2 participants