-
Notifications
You must be signed in to change notification settings - Fork 352
Description
We decided to promote myst-nb
(I assume because they are used by Jupyter books) but is ther any other rational behind it ?I think it is not the prefered notebook interpreter in the sphinx community and I don't see why we should decide.
This descision is currently leading to many issues related to nbsphinx
compatibility like #1338 that we should see from our side when testing the documentation.
Note as well that our documentation is currently blocked with sphinx 5.3 (current version is 7) because they have hard pinned it in their deps. Sphinx
is changing a lot lately and being bound to 5.3 prevents us to see the future deprecation in our docs build. On the other hand nbsphinx
is fully compatible.
here are some numbers to illustrate my thoughts:
nbsphinx | myst-nb | |
---|---|---|
users | 34.2k | 4.2k |
stars | 423 | 175 |
supported sphinx version | any | <6 |
The other point that I would like to raise is what these libs are made for ?
by reading the following thread spatialaudio/nbsphinx#420, I have the feeling that nbsphinx
and myst-nb
are following 2 different approaches:
myst-nb
is extending themyst
parser tools inside the notebooks cells, making it possible to create admonitions and all types of directives. It's extremely useful when you need to build a Jupyter Book because you can simply write down codes in a notebook and publish it directly using the Sphinx extention with richer interfaces. These directives will downgrade disgraccefully as code block in a normal Jupyter notebook as the rich directives are not part of the current markdown. in shortmyst-nb
is publication driven.nbsphinx
, don't add anything to markdown, it simply interprete the cells. They decided to go down that route because the main purpose is to render Jupyter notebook that you can then execute as they are: jupyterlab, google colab, visual studiocode, you name it. It's extremely useful in documentations when you build reproducable examples. nbsphinx is execution driven.
What are we ?
To me pydata-sphinx-theme
only make sense to document big libs with many document pages and huge API. It overcomes the problem of having all the toctree in the left bar which would be overwelming for numpy
, pandas
, geopandas
, xarray
etc ....
So to my knowledge a documentation based on pydata-sphinx-theme
will require these execution libs mainly for examples like:
- opensar toolkit: https://opensartoolkit.readthedocs.io/en/latest/example/latest_S1_scene.html
- or from mkdoc: https://geemap.org/notebooks/00_geemap_key_features/#use-drawing-tools
So (again according to me) promoting nbsphinx
seems like the natural choice for a documentation theme instead of myst-nb
(which on the other hand is the right choice for jupyterbooks).
Happy to read your thoughts !