File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ npm test
2828``` typescript
2929import {PythonShell } from ' python-shell' ;
3030
31- PythonShell .runString (' x=1+1;print(x)' , function (err ) {
31+ PythonShell .runString (' x=1+1;print(x)' , null , function (err ) {
3232 if (err ) throw err ;
3333 console .log (' finished' );
3434});
@@ -41,7 +41,7 @@ If the script exits with a non-zero code, an error will be thrown.
4141``` typescript
4242import {PythonShell } from ' python-shell' ;
4343
44- PythonShell .run (' my_script.py' , function (err ) {
44+ PythonShell .run (' my_script.py' , null , function (err ) {
4545 if (err ) throw err ;
4646 console .log (' finished' );
4747});
@@ -206,7 +206,7 @@ Example:
206206
207207``` typescript
208208// run a simple script
209- PythonShell .run (' script.py' , function (err , results ) {
209+ PythonShell .run (' script.py' , null , function (err , results ) {
210210 // script finished
211211});
212212```
@@ -221,7 +221,7 @@ Example:
221221
222222``` typescript
223223// run a simple script
224- PythonShell .run (' x=1;print(x)' , function (err , results ) {
224+ PythonShell .run (' x=1;print(x)' , null , function (err , results ) {
225225 // script finished
226226});
227227```
You can’t perform that action at this time.
0 commit comments