Open automation-stack opened 7 years ago
Hello! Just want to check if this is the issue i'm hitting. I have a simple app just trying to test out electron-sudo. Here is my code and the output. Running on MacOS Sierra.
var Sudoer = require('electron-sudo').default;
let options = {name: 'electron sudo application'};
var sudoer = new Sudoer(options);
sudoer.spawn('ls', ['/']).then(function (cp) {
cp.stdout.on('data', (msg) => {
console.log('Looks like we have a message on STDOUT');
console.log(err.toString('utf8'));
});
cp.stderr.on('data',(err) => {
console.log('Looks like we have a message on STDERR');
console.log(err.toString('utf8'));
});
cp.on('close',() => {
console.log('Processed Finished!');
});
});
$ electron launcher.js
Looks like we have a message on STDERR
sudo: a password is required
Processed Finished!
@automation-stack Hi Aleksandr. Do you have any ideas how to fix that?
@igor-lemon yes, it will be fixed soon, sudo
will become not required for electron-sudo
Cool. Thank you. I'm looking forward changes. :)
@automation-stack So is this completely broken on MacOS Sierra or can it still be used? Do you have an ETA on the fix?
@justechn working hard on this issues, details will follow
Any chance this is fixed? I have been using sudo-prompt but it is actually quite poor in that it doesn't give you access to the underlying child process after it is created.
Same issue here. macOS Sierra 10.12.5.
Would also love to see this working again. If there's anything we can do to help, let us know! I'd jump in to fix it, but I have little idea where to start.
@DSBalaban the idea is to refuse to use sudo
in this package, I'm working on this
I ran into the same issue and made it work on Sierra at least by using osascript
.
The change is hacky but might help someone running into this problem, https://github.com/eriklarko/electron-sudo/commit/f71134f86541b15359f4813715d721818fb2b1f4
@eriklarko i think you should post a PR to @automation-stack :)
Personally I feel the osascript
idea is a bit too hack-ish. Really looking forward to @automation-stack 's fix.
@imdreamrunner yeah but how's that any different from using sudo and what difference does it make if electron-sudo is broken for over 6 months..
Is electron-sudo still maintaining? any updates for this issue?
https://derflounder.wordpress.com/2016/09/21/tty_tickets-option-now-on-by-default-for-macos-sierras-sudo-tool/