Closed ghost closed 8 months ago
what does ls -lrt /dev/tty
show?
On kali linux it shows like
ls -lrt /dev/tty
crw-rw-rw 1 root tty 5, 0 Aug 30 03:57 /dev/tty
what does
ls -lrt /dev/tty
show?
It shows crw-rw-rw- 1 root tty5, 0 Aug 30
ok - that means you have the device, and it is accessible.
can you run strace -f node app.js
where app.js is your program name and paste the output here?
ok - that means you have the device, and it is accessible.
can you run
strace -f node app.js
where app.js is your program name and paste the output here?
I run but output is way tooo lengthy something like error
I run but output is way tooo lengthy something like error
@luvkapur4 - thanks for running it. Yes, it is expected to be lengthy. Can you post the output in gist ( https://gist.github.com ) and share the link here?
Details
when ever i am using Prompt in js on Vscode it is throwing error again and again.I have also installed npm and all stuff and had also added code that is Prompt sync.....
Node.js version
v18.17.1
Example code
const prompt = require('prompt-sync')();
let name = prompt("what is your name"); console.log(name);
Operating system
Linux MInt
Scope
Error: ENXIO: no such device or address, open '/dev/tty' at Object.openSync (node:fs:603:3)
errno: -6, syscall: 'open', code: 'ENXIO', path: '/dev/tty' }
Node.js v18.17.1
[Done] exited with code=1 in 0.127 seconds
Module and version
Not applicable.