Skip to content

Commit

Permalink
Fix extraction of 'kernelInfo' from the document
Browse files Browse the repository at this point in the history
pkese authored and jonsequitur committed Oct 8, 2024
1 parent 1500144 commit 30b4f7e
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
@@ -96,7 +96,7 @@ export function getNotebookCellMetadataFromNotebookCellElement(notebookCell: vsc

export function getNotebookDocumentMetadataFromInteractiveDocument(interactiveDocument: commandsAndEvents.InteractiveDocument): NotebookDocumentMetadata {
const notebookMetadata = createDefaultNotebookDocumentMetadata();
const kernelInfo = interactiveDocument.metadata.kernelInfo;
const kernelInfo = interactiveDocument.metadata.kernelInfo || interactiveDocument.metadata.plyglot_notebook.kernelInfo
if (typeof kernelInfo === 'object') {
if (typeof kernelInfo.defaultKernelName === 'string') {
notebookMetadata.kernelInfo.defaultKernelName = kernelInfo.defaultKernelName;

0 comments on commit 30b4f7e

Please sign in to comment.