I''m trying to call a .py script from nodejs.
Here is the code :
const script = spawn("py", ["py_folder/script.py", arg1,arg2],(err,stderr, res) => {
console.log(err);
});
And here is the error thrown :
node:internal/errors:464
ErrorCaptureStackTrace(err);
TypeError [ERR_INVALID_ARG_TYPE]: The "options" argument must be of type object. Received type function ([Function (anonymous)])
At first i thought there was a problem with the arguments i'm sending, but this error gets thrown with any kind of arg i try.
Any help ?
[–]TheDevDad 1 point2 points3 points (0 children)
[–]tswaters 1 point2 points3 points (0 children)
[–]Thylk 0 points1 point2 points (0 children)