unlhcc / HCCGo

A GUI application for submitting and managing jobs at the Holland Computing Center
5 stars 4 forks source link

Added data to the notification #268

Open adamfitzgibbon opened 7 years ago

adamfitzgibbon commented 7 years ago

addresses #155

djw8605 commented 7 years ago

Does the runCommand actually return stderr? Or just stdout?

adamfitzgibbon commented 7 years ago

Isn't stderr piped to stdout when a command directly fails?

djw8605 commented 7 years ago

I don't think so. I think the runCommand has to do it:

 }).on('data', function(data) {
      console.log('STDOUT: ' + data);
    }).stderr.on('data', function(data) {
      console.log('STDERR: ' + data);
    });
adamfitzgibbon commented 7 years ago

Is that meant to be chained onto the push function in runCommand?

adamfitzgibbon commented 7 years ago

It looks like it already rejects and spits out an error, so any command using runCommand should be able to just chain a failure function to get that the error text.

if (err) {
              deferred.reject("Error running command " + command + ": " + err);
          } else {
              deferred.resolve(cumulData);
          }
djw8605 commented 7 years ago

No. It needs to be on the exec in the run command queue.

-Derek

On Apr 25, 2017, at 4:25 PM, Adam Fitzgibbon notifications@github.com wrote:

Is that meant to be chained onto the push function in runCommand?

— You are receiving this because your review was requested. Reply to this email directly, view it on GitHub, or mute the thread.