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

Unwanted conversion of html entities in md notes #27

Open
RandyVogel opened this issue Oct 10, 2018 · 6 comments
Open

Unwanted conversion of html entities in md notes #27

RandyVogel opened this issue Oct 10, 2018 · 6 comments

Comments

@RandyVogel
Copy link

It seems to me as if QuickSimpleNote is changing some special characters into their html entities such as:
"&" ampersand gets changed into "&"
">" greater than gets changed into ">"
"<" less than gets changed into "<"

might be more, but those are three that I use and see getting changed frequently.
The annoying thing is that the change happens inconsistently.

It never happens with notes that I use solely with the SimpleNote web app or the SimpleNote android app.

It frequently happens when I open a note in ST3 via QuickSimpleNote after having edited that note in the android app.
When this entity replacement happens, if I look at the note via the SimpleNote android or web client, I can see that the characters have not been replaced there (which is why I think this plug-in is causing the trouble).

And if I go back and forth between the two, the ampersand will be multiply replaced, eg: & -> & -> &amp; -> &amp;amp; etc.

How can I stop this from happening?

@RandyVogel
Copy link
Author

RandyVogel commented Oct 11, 2018

Looking at things a little more, in my current problematic sample file, the characters that are getting mis-converted are all html-like things present in the raw md file that adjacent to other non-alpha chars.
Eg: the html entity "&#9784;" gets changed into "&amp;#9784;"
or "<(wip)>" gets changed into "&lt;(wip)&gt;"
or "{{tag>music" gets changed into "{{tag&gt;music"

@sickmartian
Copy link
Owner

Thanks for the report, I just noticed this myself as well on a note I use quite often... but it never happened before today for me and I've been unable to trigger it now.. have you been experiencing this for a while?

@sickmartian
Copy link
Owner

Also, when you say markdown, you mean you are using the note_syntax setting? if so, with which value?
Or are you using the title_extension_map to map a title to the "md" extension?

@sickmartian
Copy link
Owner

Nevermind, was able to replicate it with the web client as well... gonna take a look hopefully over the weekend.

@sickmartian
Copy link
Owner

sickmartian commented Oct 12, 2018

Seems to be related to a quite old bug which the API library we use worked around here simplenote-vim/simplenote.py@0c37fb4

The newest version of the library is working fine for me right now, although I would like to take some time testing it, as a workaround if you know where the plugin lives you can try to replace the content of the file simplenote.py with the ones here https://raw.githubusercontent.com/mrtazz/simplenote.py/master/simplenote/simplenote.py (or let me know your ST version and OS and maybe I can help)

@RandyVogel
Copy link
Author

RandyVogel commented Oct 12, 2018 via email

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

2 participants