sphinx-needs icon indicating copy to clipboard operation
sphinx-needs copied to clipboard

Incorrect html rendering of math stuff with needextract

Open adegroote opened this issue 2 years ago • 3 comments

When using needextract, the math stuff is not properly rendered (cf both images) original_need_good_render extract_bad_render

Associated rst code

.. spec:: A spec with math stuff
   :id: MATH_STUFF

   A spec with nice math stuff :math:`x = y^2`

Note that if the needextract is on the same page, it is well rendered, but it is not the case as long as it is on a different page

adegroote avatar Mar 09 '23 16:03 adegroote

Thanks for the bug report.

We had similar problems in the past with other sphinx functions and needextract. Reason for this was, that we need to trigger the related sphinx feature on our own for the page, as sphinx has not noticed that this is needed for this additional page.

Fix should be a one liner, after I figured out the internal function which deals with math expressions.

danwos avatar Mar 10 '23 06:03 danwos

Hi @danwos is there any quick fix, to display the :math: function correct in a needsextract until the bugfix is done?

dns93-eng avatar Jun 05 '23 13:06 dns93-eng