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

jupyterlab (version 4.0.8 ) can't treat markdown properly #15411

Closed
vivisol opened this issue Nov 15, 2023 · 10 comments
Closed

jupyterlab (version 4.0.8 ) can't treat markdown properly #15411

vivisol opened this issue Nov 15, 2023 · 10 comments
Labels

Comments

@vivisol
Copy link

vivisol commented Nov 15, 2023

Description

jupyterlab (version 4.0.8 ) can't treat markdown properly.
here is the bug:
jupyterlab version is :
image

browser version:
image

markdown is as follows:
image

but render result is :
image

Reproduce

  1. Go to '...'
  2. Click on '...'
  3. Scroll down to '...'
  4. See error '...'

Expected behavior

Context

  • Operating System and version: win11 for home 22621.2428
  • Browser and version: Google Chrome Version 119.0.6045.124 (Official Build) (64-bit)
  • JupyterLab version: 4.0.8
Troubleshoot Output
Paste the output from running `jupyter troubleshoot` from the command line here.
You may want to sanitize the paths in the output.
Command Line Output
Paste the output from your command line running `jupyter lab` here, use `--debug` if possible.
Browser Output
Paste the output from your browser Javascript console here, if applicable.
@vivisol vivisol added the bug label Nov 15, 2023
Copy link

welcome bot commented Nov 15, 2023

Thank you for opening your first issue in this project! Engagement like this is essential for open source projects! 🤗

If you haven't done so already, check out Jupyter's Code of Conduct. Also, please try to follow the issue template as it helps other other community members to contribute more effectively.
welcome
You can meet the other Jovyans by joining our Discourse forum. There is also an intro thread there where you can stop by and say Hi! 👋

Welcome to the Jupyter community! 🎉

@jupyterlab-probot jupyterlab-probot bot added the status:Needs Triage Applied to new issues that need triage label Nov 15, 2023
@krassowski
Copy link
Member

Can you paste the full markdown text to make it easy to reproduce?

@vivisol
Copy link
Author

vivisol commented Nov 16, 2023

Can you paste the full markdown text to make it easy to reproduce?

Sure, something like this :

image

File D:\ProgramData\miniconda3\envs\pyautogen\lib\site-packages\requests\models.py:975, in Response.json(self, **kwargs)
    971     return complexjson.loads(self.text, **kwargs)
    972 except JSONDecodeError as e:
    973     # Catch JSON-related errors and raise as requests.JSONDecodeError
    974     # This aliases json.JSONDecodeError and simplejson.JSONDecodeError
--> 975     raise RequestsJSONDecodeError(e.msg, e.doc, e.pos)

JSONDecodeError: Expecting value: line 1 column 1 (char 0)

@RRosio
Copy link
Contributor

RRosio commented Nov 21, 2023

Thank you for providing the markdown @vivisol! Can you paste the entire content of the cell, including the text at the top (it looks like some text is missing from the top of the markdown cell, in your last post)? Does this error with the markdown also happen when the cell only contains the triple backtick code section, not any additional text?

@magitz
Copy link

magitz commented Dec 1, 2023

I am having a similar issue in 4.0.6. It is most noticeable with the quoted text syntax ">".

Here's an example Markdown cell. This is the only cell in the notebook:

image

This is rendered as:

image

  • Characters that are not there are added (the "a." at the end).
  • Some lines that should be part of the quoted text block are not ("Maecenas maximus...")
  • The issues are not consistent or always there, unfortunately.

Here's another example:
image

Rendered as:

image

In this case, only the "a." at the end is there.

I tried pasting text into a text editor to look for special characters and could not find anything.

From my testing, it seems like this only impacts Markdown edited on Jupyter 4+. When the notebook is opened in Jupyter 3.6.6, the actual Markdown corresponds to what 4+ displayed--ie. the Markdown is broken in the render process and changed to the incorrect text. But viewing it in 4+ looks correct.

@krassowski
Copy link
Member

@magitz do you use Windows? If so, I have a strong suspicion that is different and it is down to line endings not being normalized on paste in Chrome. But this is just guessing without knowing your OS/browser and having a notebook to test it.

@magitz
Copy link

magitz commented Dec 1, 2023

Ah...I do use Windows and Chrome...Is that a different issue? Any suggested work around (other than different browser/OS). I'll test in Edge/Firefox in a sec.

@magitz
Copy link

magitz commented Dec 1, 2023

It does seem to work better in Firefox.

@krassowski
Copy link
Member

This is tracked in #14752. I think we can close this as a duplicate of the other.

@JasonWeill
Copy link
Contributor

Closing as a duplicate of #14752 — thanks @krassowski for finding the original issue!

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

No branches or pull requests

6 participants