Skip to content

Commit bfbc1aa

Browse files
committed
fix path resolve
1 parent 0e869cf commit bfbc1aa

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

cpkernel/src/kernel.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -914,7 +914,7 @@ export async function createKernel({ lang, sessionId, socket }) {
914914
// FIXME this path is outside the cpkernel package
915915
// const kernel_dir = "../../api/kernels";
916916
// const kernel_dir = "/Users/hebi/Documents/GitHub/codepod/api/kernels";
917-
const kernel_dir = path.join(__dirname, "../../api/kernels");
917+
const kernel_dir = path.join(path.resolve(), "../api/kernels");
918918
export class JuliaKernel extends CodePodKernel {
919919
startupFile = `${kernel_dir}/julia/codepod.jl`;
920920
startupCode = readFileSync(this.startupFile, "utf8");
@@ -948,7 +948,7 @@ export class PythonKernel extends CodePodKernel {
948948
fname = `${kernel_dir}/python/conn.json`;
949949
lang = "python";
950950
image = "python_kernel";
951-
nativeKernelJson = os.path.join(
951+
nativeKernelJson = path.join(
952952
os.homedir(),
953953
"Library/Jupyter/kernels/python/kernel.json"
954954
);
@@ -1012,7 +1012,7 @@ export class JavascriptKernel extends CodePodKernel {
10121012
fname = `${kernel_dir}/javascript/conn.json`;
10131013
lang = "javascript";
10141014
image = "javascript_kernel";
1015-
nativeKernelJson = os.path.join(
1015+
nativeKernelJson = path.join(
10161016
os.homedir(),
10171017
"Library/Jupyter/kernels/javascript/kernel.json"
10181018
);

0 commit comments

Comments
 (0)