atom / language-python

Python package for Atom
Other
190 stars 146 forks source link

Python long comment highlighting error while there's special character. #45

Closed kxxoling closed 6 years ago

kxxoling commented 9 years ago

I'm not sure what results in this, but it look wrong here: Flask helpers.py

Fast preview: flask code highlight

kevinsawicki commented 9 years ago

So according to https://docs.python.org/2/library/stdtypes.html#string-formatting a space is valid after the percent sign in strings which is why it is parsing % m and % e as placeholders.

screen shot 2014-12-10 at 3 58 21 pm

So I'm not sure how this should be solved since this seems like the "right" highlighting.

mehcode commented 9 years ago

@kevinsawicki I would say that in long (tripe-quoted) comments formatting placeholders should not be highlited

msabramo commented 9 years ago

in long (tripe-quoted) comments formatting placeholders should not be highlited

:+1:

msabramo commented 9 years ago

I looked briefly at taking a stab at fixing this last night but I got confused by the grammar.

msabramo commented 9 years ago

Link to it in Lightshow

Arcanemagus commented 6 years ago

Thanks for taking the time to contribute!

We noticed that this is a duplicate of https://github.com/atom/language-python/issues/40. Although there are a few more comments here, the issue is better described over in #40. You may want to subscribe there for updates.

Because we treat our issues list as the Atom team's backlog, we close duplicates to focus our work and not have to touch the same chunk of code for the same reason multiple times. This is also why we may mark something as duplicate that isn't an exact duplicate but is closely related.

For information on how to use GitHub's search feature to find out if something is a duplicate before filing, see the How Can I Contribute? section of the Atom CONTRIBUTING guide.