This repository was archived by the owner on Jan 30, 2023. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix a bug in patching jupyter-sphinx
- Loading branch information
Showing
4 changed files
with
7 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
From 1f1a767cf51627ac5bf2cf3209f44bdb32f4af46 Mon Sep 17 00:00:00 2001 | ||
From f93e4ea3eaedd549b56bc86f27225aee2f4c847d Mon Sep 17 00:00:00 2001 | ||
From: Kwankyu Lee <[email protected]> | ||
Date: Sun, 27 Mar 2022 13:33:56 -0700 | ||
Subject: [PATCH 1/4] Fix a bug and suppress a warning | ||
|
@@ -8,7 +8,7 @@ Subject: [PATCH 1/4] Fix a bug and suppress a warning | |
1 file changed, 8 insertions(+), 5 deletions(-) | ||
|
||
diff --git a/jupyter_sphinx/execute.py b/jupyter_sphinx/execute.py | ||
index e6cc5db..7514cff 100644 | ||
index e6cc5db..ef41337 100644 | ||
--- a/jupyter_sphinx/execute.py | ||
+++ b/jupyter_sphinx/execute.py | ||
@@ -147,11 +147,14 @@ class ExecuteJupyterCells(SphinxTransform): | ||
|
@@ -25,7 +25,7 @@ index e6cc5db..7514cff 100644 | |
+ warnings.simplefilter("ignore") | ||
+ notebook = execute_cells( | ||
+ kernel_name, | ||
+ [nbformat.v4.new_code_cell(node.astext() if node["execute"] else "") for node in nodes], | ||
+ [nbformat.v4.new_code_cell(node.astext() if not "execute" in node or node["execute"] else "") for node in nodes], | ||
+ self.config.jupyter_execute_kwargs, | ||
+ ) | ||
|
||
|
2 changes: 1 addition & 1 deletion
2
build/pkgs/jupyter_sphinx/patches/0002-Use-latest-thebe-for-interact-to-work.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
From e5bedf302361f6208817cd5b656b02888feaaa8d Mon Sep 17 00:00:00 2001 | ||
From e134aeddc5df1fe421325202a867048c04ee00ed Mon Sep 17 00:00:00 2001 | ||
From: Kwankyu Lee <[email protected]> | ||
Date: Sun, 3 Apr 2022 21:24:36 +0900 | ||
Subject: [PATCH 2/4] Use latest thebe for interact to work | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
From af16bbccc1e1e1a586fe86371a9437d9342bfa6f Mon Sep 17 00:00:00 2001 | ||
From 1c8bbceae278fb43c985c4daeadcfd52338df7c6 Mon Sep 17 00:00:00 2001 | ||
From: Kwankyu Lee <[email protected]> | ||
Date: Tue, 5 Apr 2022 13:49:03 +0900 | ||
Subject: [PATCH 3/4] Use SageExecuteJupyterCells for faster processing | ||
|
@@ -35,7 +35,7 @@ index c493685..5c8a32c 100644 | |
|
||
# For syntax highlighting | ||
diff --git a/jupyter_sphinx/execute.py b/jupyter_sphinx/execute.py | ||
index 7514cff..1aca4fd 100644 | ||
index ef41337..d907633 100644 | ||
--- a/jupyter_sphinx/execute.py | ||
+++ b/jupyter_sphinx/execute.py | ||
@@ -323,3 +323,36 @@ def setup(app): | ||
|
2 changes: 1 addition & 1 deletion
2
build/pkgs/jupyter_sphinx/patches/0004-Prevent-unnecessary-js-injections.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
From 43d677000707b136c6cd0079356677e6408627f2 Mon Sep 17 00:00:00 2001 | ||
From 227864ac59a536b91ce8aa6cc40a8fb30c967963 Mon Sep 17 00:00:00 2001 | ||
From: Kwankyu Lee <[email protected]> | ||
Date: Tue, 12 Apr 2022 14:42:44 +0900 | ||
Subject: [PATCH 4/4] Prevent unnecessary js injections | ||
|