forked from pool/python-nbval
Markéta Machová
81c4862395
- Add nbval-filter-mpldeprecation.patch for new Matplotlib 3.4 deprecation warnings -- gh#computationalmodelling/nbval#167 OBS-URL: https://build.opensuse.org/request/show/885382 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:jupyter/python-nbval?expand=0&rev=17
33 lines
1.2 KiB
Diff
33 lines
1.2 KiB
Diff
Index: nbval-0.9.6/tests/ipynb-test-samples/test-latex-pass-correctouput.ipynb
|
|
===================================================================
|
|
--- nbval-0.9.6.orig/tests/ipynb-test-samples/test-latex-pass-correctouput.ipynb
|
|
+++ nbval-0.9.6/tests/ipynb-test-samples/test-latex-pass-correctouput.ipynb
|
|
@@ -37,6 +37,9 @@
|
|
}
|
|
],
|
|
"source": [
|
|
+ "import warnings\n",
|
|
+ "from matplotlib import MatplotlibDeprecationWarning\n",
|
|
+ "warnings.filterwarnings(\"ignore\", category=MatplotlibDeprecationWarning)\n",
|
|
"x**2 + y**3"
|
|
]
|
|
}
|
|
Index: nbval-0.9.6/tests/latex-example.ipynb
|
|
===================================================================
|
|
--- nbval-0.9.6.orig/tests/latex-example.ipynb
|
|
+++ nbval-0.9.6/tests/latex-example.ipynb
|
|
@@ -15,6 +15,13 @@
|
|
},
|
|
"outputs": [],
|
|
"source": [
|
|
+ "try:\n",
|
|
+ " import warnings\n",
|
|
+ " from matplotlib import MatplotlibDeprecationWarning\n",
|
|
+ " warnings.filterwarnings(\"ignore\", category=MatplotlibDeprecationWarning)\n",
|
|
+ "except ImportError:\n",
|
|
+ " # no matplotlib, no problem\n",
|
|
+ " pass\n",
|
|
"import sympy\n",
|
|
"sympy.init_printing()\n",
|
|
"x, y = sympy.symbols([\"x\", \"y\"])"
|