Skip to content

Commit 38bfd73

Browse files
committed
add required field
1 parent f320f5f commit 38bfd73

File tree

1 file changed

+14
-6
lines changed

1 file changed

+14
-6
lines changed

src/core/jupyter/jupyter-embed.ts

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,13 @@ import {
4343
JupyterCellOutput,
4444
} from "../jupyter/types.ts";
4545

46-
import { dirname, extname, join, basename, isAbsolute } from "../../deno_ral/path.ts";
46+
import {
47+
basename,
48+
dirname,
49+
extname,
50+
isAbsolute,
51+
join,
52+
} from "../../deno_ral/path.ts";
4753
import { languages } from "../handlers/base.ts";
4854
import {
4955
extractJupyterWidgetDependencies,
@@ -62,6 +68,7 @@ import { ProjectContext } from "../../project/types.ts";
6268
import { logProgress } from "../log.ts";
6369
import * as ld from "../../../src/core/lodash.ts";
6470
import { texSafeFilename } from "../tex.ts";
71+
import { ExecuteOptions } from "../../execute/types.ts";
6572

6673
export interface JupyterNotebookAddress {
6774
path: string;
@@ -402,7 +409,7 @@ export async function notebookMarkdown(
402409

403410
// Wrap any injected cells with a div that includes a back link to
404411
// the notebook that originated the cells
405-
const notebookMarkdown = (
412+
const notebookMarkdownInner = (
406413
nbAbsPath: string,
407414
cells: JupyterCellOutput[],
408415
title?: string,
@@ -441,7 +448,7 @@ export async function notebookMarkdown(
441448
return cell;
442449
}
443450
});
444-
return notebookMarkdown(nbAbsPath, theCells, notebookInfo.title);
451+
return notebookMarkdownInner(nbAbsPath, theCells, notebookInfo.title);
445452
} else if (nbAddress.indexes) {
446453
// Filter and sort based upon cell indexes
447454
const theCells = nbAddress.indexes.map((idx) => {
@@ -459,11 +466,11 @@ export async function notebookMarkdown(
459466
return cell;
460467
}
461468
});
462-
return notebookMarkdown(nbAbsPath, theCells, notebookInfo.title);
469+
return notebookMarkdownInner(nbAbsPath, theCells, notebookInfo.title);
463470
} else {
464471
// Return all the cell outputs as there is no addtional
465472
// specification of cells
466-
const notebookMd = notebookMarkdown(
473+
const notebookMd = notebookMarkdownInner(
467474
nbAbsPath,
468475
notebookInfo.outputs,
469476
notebookInfo.title,
@@ -582,7 +589,8 @@ async function getCachedNotebookInfo(
582589

583590
// Get the markdown for the notebook
584591
const format = context.format;
585-
const executeOptions = {
592+
const executeOptions: ExecuteOptions = {
593+
env: {},
586594
target: context.target,
587595
resourceDir: resourcePath(),
588596
tempDir: context.options.services.temp.createDir(),

0 commit comments

Comments
 (0)