Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Syntax highlighting broke in certain cases #196

Closed
1 task done
kingbuzzman opened this issue Apr 27, 2017 · 4 comments
Closed
1 task done

Syntax highlighting broke in certain cases #196

kingbuzzman opened this issue Apr 27, 2017 · 4 comments

Comments

@kingbuzzman
Copy link

kingbuzzman commented Apr 27, 2017

Prerequisites

Description

Syntax color is breaking.

Steps to Reproduce

  1. Have language-python installed
  2. Have a file with comments like this
import sys
import os


class A(object):
    """
    * 'sectionstatus': { }  # something something something something something something something something
                            # something somethingsomething something POST & DELETE something something.
        * section_id1: { }
            * 'something': 123,  # something something something something something something
            * 'something': int or null,  # Number  something something something something is null if
                                           # Something.property=true.
            * 'something': null/SOMETHING/SOMETHING/SOMETHING,  #  something something in something something.
            * 'something': true/false,  # something something something something something something something
            * 'something': true/false  #  something something in something something's campus 
    """

    a = 1234

    def method(self):
        print "this color is no good"

Pictures are worth 1000 words: broken, -> without the "'s"

Expected behavior: a and the def method and the print should be syntax highlighted

Actual behavior: color breaks after the 's

Reproduces how often: Every single time

Versions

You can get this information from copy and pasting the output of atom --version and apm --version from the command line. Also, please include the OS and what version of the OS you're running.

I have the latest language-python

Electron: 1.3.13
Chrome  : 52.0.2743.82
Node    : 6.5.0
npm  3.10.5
node 6.9.5 x64
python 2.7.13
git 2.12.2
@mercutiodesign
Copy link

I can confirm this issue of docstrings not ending at the closing quotes.
A very short test case is the following:

def test():
    """
    test `WITH` test
    """
    print('hello')

test()

which will display incorrectly as follows:
screen shot 2017-05-11 at 11 26 41

@rsese
Copy link

rsese commented May 11, 2017

I think this is a dupe of #143? E.g. in both examples, if I disable language-sql as mentioned in #143 (comment), then the highlighting is ok.

@kingbuzzman
Copy link
Author

Confirmed, yes, you're right, if i disable language-sql it works. Sorry for the trouble.

@rsese
Copy link

rsese commented May 12, 2017

No problem at all, it took me a bit to put them together 🙇

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

No branches or pull requests

3 participants