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

Escape character in GPT response is swallowed by the Markdown renderer #169

Closed
BenceSzalai opened this issue Jul 31, 2023 · 4 comments
Closed

Comments

@BenceSzalai
Copy link

Basically when ChatGPT writes a code segment and it tries to use escape characters in it, e.g. for a RegEx, it get lost while the API response is rendered.

An image tells it better:

CleanShot 2023-07-31 at 13 52 50

@efstathiosntonas
Copy link

efstathiosntonas commented Apr 1, 2024

same happens for this:

.replace(/\//g, '-');

converts to this in markdown:

.replace(///g, '-');

@mehanoid
Copy link

I have also noticed many times that CodeGPT gives invalid regular expressions. And when you fix them, it rewrites them to invalid ones again.

@BenceSzalai
Copy link
Author

Meanwhile as a workaround the original response can be accessed with the [Open in Editor] button on the top toolbar. Still very inconvenient.

@carlrobertoh
Copy link
Owner

This will be fixed in the next release. I'm not yet entirely sure why it was added in the first place.

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

No branches or pull requests

4 participants