File tree 2 files changed +7
-2
lines changed
2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -9,7 +9,11 @@ const DENO_PYTHON_PATH = Deno.env.get("DENO_PYTHON_PATH");
9
9
if ( DENO_PYTHON_PATH ) {
10
10
searchPath . push ( DENO_PYTHON_PATH ) ;
11
11
} else {
12
- if ( Deno . build . os === "windows" || Deno . build . os === "linux" || Deno . build . os === "windows_nt" ) {
12
+ if (
13
+ Deno . build . os === "windows" || Deno . build . os === "linux" ||
14
+ // @ts -ignore: users reported that `windows_nt` exists at runtime
15
+ Deno . build . os === "windows_nt"
16
+ ) {
13
17
searchPath . push (
14
18
...SUPPORTED_VERSIONS . map ( ( [ major , minor ] ) =>
15
19
`${ Deno . build . os === "linux" ? "lib" : "" } python${ major } ${
Original file line number Diff line number Diff line change @@ -824,7 +824,7 @@ export class PyObject {
824
824
825
825
/** Python-related error. */
826
826
export class PythonError extends Error {
827
- name = "PythonError" ;
827
+ override name = "PythonError" ;
828
828
829
829
constructor (
830
830
public type : PyObject ,
@@ -947,6 +947,7 @@ export class Python {
947
947
. handle ,
948
948
) ;
949
949
if ( module === null ) {
950
+ maybeThrowError ( ) ;
950
951
throw new EvalError ( "Failed to run python module" ) ;
951
952
}
952
953
return new PyObject ( module ) ?. proxy ;
You can’t perform that action at this time.
0 commit comments