lsongdev / lsongdev/input-event
new InputEvent() hangs the terminal after closing node, needs kill -9
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 65
- Forks
- 22
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
I'm trying to use this package for my nodejs project running on an armv7 device with node v8.9.4.
I was amazed that it worked right away, without any problems. I can easily read events from /dev/input following the examples.
However I have one problem, when I close the node script (ctrl+c), my script itself stops working and I can even catch the SIGINT even telling it to stop, however after pressing ctrl+c, I cannot type anything into the terminal (nor press CTRL+C) anymore, it's stuck. The only way to stop is to execute `killall -9 node` and it frees the terminal.
It's caused solely by using `new InputEvent('/dev/input/event0');`, if I comment this line, it's not freezing anymore.
What can be the cause of this? Is there any way to fix it?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the hang with new InputEvent('/dev/input/event0') on the reported ARMv7 setup running Node v8.9.4, then compare behavior when that entry point is omitted. Done means closing the Node script leaves the terminal usable without kill -9; the payload names no source files or tests, so the implementation entry point must be located from the InputEvent constructor.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, linux, nodejs
- Domain
- embedded-iot, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100