Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show file location of errors in cells #179

Open
SeanDS opened this issue Apr 20, 2021 · 2 comments
Open

Show file location of errors in cells #179

SeanDS opened this issue Apr 20, 2021 · 2 comments

Comments

@SeanDS
Copy link

SeanDS commented Apr 20, 2021

If there is an uncaught exception in a cell, there appears to be no information as to the real file line location where the error occurred:

Extension error:
Cell raised uncaught exception:
---------------------------------------------------------------------------
Exception                                 Traceback (most recent call last)
<ipython-input-14-703b9bbf0f60> in <module>
      9 )
     10 """)
---> 11 sol = model.run()
     12 print(sol['xaxis1']['P'])
     13 print(sol['xaxis2']['P'])

[stack trace from imported library code]

Exception: The property <l1.P=1 @ 0x7f5c045fe2c0> cannot be changed

All I see for the source of the cell that had the error is <ipython-input-14-703b9bbf0f60> in <module>. I can search my project for the code shown in the error, but this is not ideal. Can Jupyter-Sphinx figure out the real file and line number corresponding to the error location and report this when an error occurs?

@akhmerov
Copy link
Member

Sounds good, we should inspect how nbclient reports errors and show more details.

@caenrigen
Copy link

before a solution is available, perhaps running python -msphinx -M html . _build -vv with the -vv option for verbose output might help identify the cause

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants