QuantEcon / sphinxcontrib-jupyter

A Sphinx Extension for Generating Jupyter Notebooks
BSD 3-Clause "New" or "Revised" License
76 stars 23 forks source link

Equation's label sometimes doesn't display equation number in Julia's jupyter notebook #136

Closed pooyaravari closed 5 years ago

mmcky commented 5 years ago

thanks @PooyaFa -- if you can drop the file here that would be great. thanks.

pooyaravari commented 5 years ago

Thank you. Yes, here is the file: https://github.com/QuantEcon/lecture-source-jl/blob/pooya/rst_files/julia_by_example.rst

look at the line 462 and 478.

issue

jlperla commented 5 years ago

@PooyaFa Thanks. Were you using Jupyter lab or jupyter notebook for this? Also, the line numbers do not line up with the current source, and I am not sure which commit you meant. Can you check with a compiled version from master now?

pooyaravari commented 5 years ago

@jlperla I used Jupyter lab. Now line: 485 and 501 in the most updated master. 1

jlperla commented 5 years ago

Thanks! Are you still seeing the issue with the latest master? I get the following image

Which has terrible formatting in jupyter lab (a known bug, see https://github.com/QuantEcon/sphinxcontrib-jupyter/issues/117 ) but it does seem to have the equation numbers?

pooyaravari commented 5 years ago

I have the same issue in formatting as https://github.com/QuantEcon/sphinxcontrib-jupyter/issues/117 now (which I didn't have before). And still I don't see equation numbers (for both equation 1 and 2 as you can see here): 2

jlperla commented 5 years ago

Great, thanks! Try it in jupyter notebook instead of jupyter lab. Regardless of the result, that might be as far as you can go now with the bug report.

arnavs commented 5 years ago

Just to update on this, it looks like equation numbers are in if and only if we explicitly tag the equation with a

.. math::
    :label: foo

    {equation}

If that is expected behavior, I think this can be closed.

mmcky commented 5 years ago

Hi All. Thanks for the report. The jupyterlab issue is really disappointing.

@arnavs is correct -- the numbering will automatically appear for labelled math only. If there is no label then it is not numbered.

mmcky commented 5 years ago

@PooyaFa is this still an issue. The default is not to label equations unless a :label: is specified. Do you mind if I close this issue?

arnavs commented 5 years ago

@mmcky I think this can be closed.

(So long as the right approach is documented (and works), then that should be good enough. Anything else would require too much rejiggering.)

pooyaravari commented 5 years ago

Hi. Sure. Thank you.

On Thu, Jul 11, 2019 at 9:18 AM Arnav Sood notifications@github.com wrote:

@mmcky https://github.com/mmcky I think this can be closed.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/QuantEcon/sphinxcontrib-jupyter/issues/136?email_source=notifications&email_token=AKSTQPUVQH3IXT2QQ66JPXTP65MN7A5CNFSM4GBST42KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODZXHC2Y#issuecomment-510554475, or mute the thread https://github.com/notifications/unsubscribe-auth/AKSTQPQNIWMZ3FDI7FSFKYDP65MN7ANCNFSM4GBST42A .

-- Pooya R. Ravari PhD student in Economics at UBC https://sites.google.com/view/pooyarravari

mmcky commented 5 years ago

thanks for the report @PooyaFa.