Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

⬆️ UPGRADE: myst-parser to 0.15.2 #353

Merged
merged 5 commits into from
Aug 29, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,6 @@
"dollarmath",
"html_image",
]
myst_url_schemes = ("http", "https", "mailto")
panels_add_bootstrap_css = False


Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ install_requires =
ipywidgets>=7.0.0,<8
jupyter-cache~=0.4.1
jupyter_sphinx~=0.3.2
myst-parser~=0.14.0
myst-parser~=0.15.2
nbconvert>=5.6,<7
nbformat~=5.0
pyyaml
Expand Down
2 changes: 1 addition & 1 deletion tests/test_execute/test_allow_errors_auto.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.8"
"version": "3.8.10"
},
"test_name": "notebook1"
},
Expand Down
2 changes: 1 addition & 1 deletion tests/test_execute/test_allow_errors_auto.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<document source="basic_failing">
<section ids="a-title" names="a\ title">
<section classes="tex2jax_ignore mathjax_ignore" ids="a-title" names="a\ title">
<title>
a title
<paragraph>
Expand Down
2 changes: 1 addition & 1 deletion tests/test_execute/test_allow_errors_cache.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.8"
"version": "3.8.10"
},
"test_name": "notebook1"
},
Expand Down
2 changes: 1 addition & 1 deletion tests/test_execute/test_allow_errors_cache.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<document source="basic_failing">
<section ids="a-title" names="a\ title">
<section classes="tex2jax_ignore mathjax_ignore" ids="a-title" names="a\ title">
<title>
a title
<paragraph>
Expand Down
2 changes: 1 addition & 1 deletion tests/test_execute/test_basic_failing_auto.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.1"
"version": "3.8.10"
},
"test_name": "notebook1"
},
Expand Down
2 changes: 1 addition & 1 deletion tests/test_execute/test_basic_failing_auto.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<document source="basic_failing">
<section ids="a-title" names="a\ title">
<section classes="tex2jax_ignore mathjax_ignore" ids="a-title" names="a\ title">
<title>
a title
<paragraph>
Expand Down
2 changes: 1 addition & 1 deletion tests/test_execute/test_basic_failing_cache.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<document source="basic_failing">
<section ids="a-title" names="a\ title">
<section classes="tex2jax_ignore mathjax_ignore" ids="a-title" names="a\ title">
<title>
a title
<paragraph>
Expand Down
2 changes: 1 addition & 1 deletion tests/test_execute/test_basic_unrun_auto.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.7"
"version": "3.8.10"
},
"test_name": "notebook1"
},
Expand Down
2 changes: 1 addition & 1 deletion tests/test_execute/test_basic_unrun_auto.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<document source="basic_unrun">
<section ids="a-title" names="a\ title">
<section classes="tex2jax_ignore mathjax_ignore" ids="a-title" names="a\ title">
<title>
a title
<paragraph>
Expand Down
2 changes: 1 addition & 1 deletion tests/test_execute/test_basic_unrun_cache.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.1"
"version": "3.8.10"
},
"test_name": "notebook1"
},
Expand Down
2 changes: 1 addition & 1 deletion tests/test_execute/test_basic_unrun_cache.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<document source="basic_unrun">
<section ids="a-title" names="a\ title">
<section classes="tex2jax_ignore mathjax_ignore" ids="a-title" names="a\ title">
<title>
a title
<paragraph>
Expand Down
4 changes: 2 additions & 2 deletions tests/test_execute/test_complex_outputs_unrun_auto.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@
"execution_count": 5,
"metadata": {
"filenames": {
"image/png": "/private/var/folders/t2/xbl15_3n4tsb1vr_ccmmtmbr0000gn/T/pytest-of-chrisjsewell/pytest-679/test_complex_outputs_unrun_aut0/source/_build/jupyter_execute/complex_outputs_unrun_22_0.png"
"image/png": "/private/var/folders/_w/bsp9j6414gs4gdlnhhcnqm9c0000gn/T/pytest-of-matthewmckay/pytest-37/test_complex_outputs_unrun_aut0/source/_build/jupyter_execute/complex_outputs_unrun_22_0.png"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there any way we can configure tests to not be person-specific? otherwise I think this will be re-written any time somebody has to update the tests who didn't update them in the past.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@choldgraf I just updated a whole bunch of metadata in the tests in upgrade to sphinx 4 and the tests actually ignore the metadata

set_notebook_diff_targets(metadata=False)

I don't see an easy way to generate these fixtures with generic values.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

as mentioned, the actual tests ignore these values when diffing.
if you wanted to reduce the diff though, it would be possible to add a pre-commit hook, which replaces all the "non-deterministic" content with deterministic ones

}
},
"output_type": "execute_result"
Expand Down Expand Up @@ -560,7 +560,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.8"
"version": "3.8.10"
},
"latex_envs": {
"LaTeX_envs_menu_present": true,
Expand Down
12 changes: 6 additions & 6 deletions tests/test_execute/test_complex_outputs_unrun_auto.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
sym.init_printing(use_latex=True)
import numpy as np
from IPython.display import Image, Latex
<section ids="markdown" names="markdown">
<section classes="tex2jax_ignore mathjax_ignore" ids="markdown" names="markdown">
<title>
Markdown
<section ids="general" names="general">
Expand Down Expand Up @@ -84,7 +84,7 @@
\todo[inline]{an inline todo}
<paragraph>
Some text.\todo{a todo in the margins}
<section ids="text-output" names="text\ output">
<section classes="tex2jax_ignore mathjax_ignore" ids="text-output" names="text\ output">
<title>
Text Output
<CellNode cell_type="code" classes="cell">
Expand All @@ -96,7 +96,7 @@
""")
<CellOutputNode classes="cell_output">
<CellOutputBundleNode output_count="1">
<section ids="images-and-figures" names="images\ and\ figures">
<section classes="tex2jax_ignore mathjax_ignore" ids="images-and-figures" names="images\ and\ figures">
<title>
Images and Figures
<section ids="displaying-a-plot-with-its-code" names="displaying\ a\ plot\ with\ its\ code">
Expand All @@ -106,7 +106,7 @@
A matplotlib figure, with the caption set in the markdowncell above the figure.
<paragraph>
The plotting code for a matplotlib figure (\cref{fig:example_mpl}).
<section ids="tables-with-pandas" names="tables\ (with\ pandas)">
<section classes="tex2jax_ignore mathjax_ignore" ids="tables-with-pandas" names="tables\ (with\ pandas)">
<title>
Tables (with pandas)
<paragraph>
Expand All @@ -122,7 +122,7 @@
df.round(3)
<CellOutputNode classes="cell_output">
<CellOutputBundleNode output_count="1">
<section ids="equations-with-ipython-or-sympy" names="equations\ (with\ ipython\ or\ sympy)">
<section classes="tex2jax_ignore mathjax_ignore" ids="equations-with-ipython-or-sympy" names="equations\ (with\ ipython\ or\ sympy)">
<title>
Equations (with ipython or sympy)
<CellNode cell_type="code" classes="cell">
Expand All @@ -142,7 +142,7 @@
sym.rsolve(f,y(n),[1,4])
<CellOutputNode classes="cell_output">
<CellOutputBundleNode output_count="1">
<section ids="interactive-outputs" names="interactive\ outputs">
<section classes="tex2jax_ignore mathjax_ignore" ids="interactive-outputs" names="interactive\ outputs">
<title>
Interactive outputs
<section ids="ipywidgets" names="ipywidgets">
Expand Down
4 changes: 2 additions & 2 deletions tests/test_execute/test_complex_outputs_unrun_cache.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -430,7 +430,7 @@
"execution_count": 5,
"metadata": {
"filenames": {
"image/png": "/private/var/folders/t2/xbl15_3n4tsb1vr_ccmmtmbr0000gn/T/pytest-of-chrisjsewell/pytest-679/test_complex_outputs_unrun_cac0/source/_build/jupyter_execute/complex_outputs_unrun_22_0.png"
"image/png": "/private/var/folders/_w/bsp9j6414gs4gdlnhhcnqm9c0000gn/T/pytest-of-matthewmckay/pytest-37/test_complex_outputs_unrun_cac0/source/_build/jupyter_execute/complex_outputs_unrun_22_0.png"
}
},
"output_type": "execute_result"
Expand Down Expand Up @@ -560,7 +560,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.8"
"version": "3.8.10"
},
"latex_envs": {
"LaTeX_envs_menu_present": true,
Expand Down
12 changes: 6 additions & 6 deletions tests/test_execute/test_complex_outputs_unrun_cache.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
sym.init_printing(use_latex=True)
import numpy as np
from IPython.display import Image, Latex
<section ids="markdown" names="markdown">
<section classes="tex2jax_ignore mathjax_ignore" ids="markdown" names="markdown">
<title>
Markdown
<section ids="general" names="general">
Expand Down Expand Up @@ -84,7 +84,7 @@
\todo[inline]{an inline todo}
<paragraph>
Some text.\todo{a todo in the margins}
<section ids="text-output" names="text\ output">
<section classes="tex2jax_ignore mathjax_ignore" ids="text-output" names="text\ output">
<title>
Text Output
<CellNode cell_type="code" classes="cell">
Expand All @@ -96,7 +96,7 @@
""")
<CellOutputNode classes="cell_output">
<CellOutputBundleNode output_count="1">
<section ids="images-and-figures" names="images\ and\ figures">
<section classes="tex2jax_ignore mathjax_ignore" ids="images-and-figures" names="images\ and\ figures">
<title>
Images and Figures
<section ids="displaying-a-plot-with-its-code" names="displaying\ a\ plot\ with\ its\ code">
Expand All @@ -106,7 +106,7 @@
A matplotlib figure, with the caption set in the markdowncell above the figure.
<paragraph>
The plotting code for a matplotlib figure (\cref{fig:example_mpl}).
<section ids="tables-with-pandas" names="tables\ (with\ pandas)">
<section classes="tex2jax_ignore mathjax_ignore" ids="tables-with-pandas" names="tables\ (with\ pandas)">
<title>
Tables (with pandas)
<paragraph>
Expand All @@ -122,7 +122,7 @@
df.round(3)
<CellOutputNode classes="cell_output">
<CellOutputBundleNode output_count="1">
<section ids="equations-with-ipython-or-sympy" names="equations\ (with\ ipython\ or\ sympy)">
<section classes="tex2jax_ignore mathjax_ignore" ids="equations-with-ipython-or-sympy" names="equations\ (with\ ipython\ or\ sympy)">
<title>
Equations (with ipython or sympy)
<CellNode cell_type="code" classes="cell">
Expand All @@ -142,7 +142,7 @@
sym.rsolve(f,y(n),[1,4])
<CellOutputNode classes="cell_output">
<CellOutputBundleNode output_count="1">
<section ids="interactive-outputs" names="interactive\ outputs">
<section classes="tex2jax_ignore mathjax_ignore" ids="interactive-outputs" names="interactive\ outputs">
<title>
Interactive outputs
<section ids="ipywidgets" names="ipywidgets">
Expand Down
Loading