sunpy / sunpy.org

The SunPy website
https://sunpy.org
Other
19 stars 35 forks source link

Intersphinx mapping is broken for notebook blog posts #256

Open wtbarnes opened 4 years ago

wtbarnes commented 4 years ago

The posts written as Jupyter notebooks (e.g. modeling coronal loops) do not respect links to the docs via intersphinx mapping. Posts written as normal reStructured text don't seem to have this issue.

I think this has something to do with how nbsphinx converts the markdown in the cells to reST. This may possibly be related to spatialaudio/nbsphinx#89.

As an example of what this looks like in the rendered raw html, this is an intersphinx mapping `~ndcube.NDCube` rendered (incorrectly) in the notebook,

<p><code class="docutils literal notranslate"><span class="pre">~ndcube.NDCube</span></code></p>

and rendered correctly in the case of a post written in pure reST,

<a class="reference external" href="https://docs.sunpy.org/projects/ndcube/en/stable/api/ndcube.NDCube.html#ndcube.NDCube" title="(in ndcube v1.3.2)"><code class="xref py py-obj docutils literal notranslate"><span class="pre">NDCube</span></code></a> 

This is really an upstream issue for nbsphinx I guess, but it does mean all of the links in those notebook blog posts do not work.

Cadair commented 4 years ago

:sob:

nabobalis commented 4 years ago

We aren't fixing that tho? Should we just add a comment to the readme and close this?

wtbarnes commented 4 years ago

🤷‍♂️🤷‍♂️🤷‍♂️ Maybe? If there is some sort of workaround, we should use that though.

I don't know how I didn't notice this before.

nabobalis commented 4 years ago

If there is a workaround lets do it.

Cadair commented 4 years ago

Would MyST fix this?