Gentoo Archives: gentoo-catalyst

From: Brian Dolbec <dolsen@g.o>
To: gentoo-catalyst@l.g.o
Subject: Re: [gentoo-catalyst] [PATCH] lint: fix anomalous-backslash-in-string
Date: Tue, 06 Oct 2015 06:23:53
Message-Id: 20151005232301.745c2dea.dolsen@gentoo.org
In Reply to: [gentoo-catalyst] [PATCH] lint: fix anomalous-backslash-in-string by Mike Frysinger
1 On Mon, 5 Oct 2015 23:47:55 -0400
2 Mike Frysinger <vapier@g.o> wrote:
3
4 > All strings using escape sequences should be raw strings.
5 > This way we don't end up with accidental misbehavior.
6 > ---
7 > catalyst/config.py | 2 +-
8 > 1 file changed, 1 insertion(+), 1 deletion(-)
9 >
10 > diff --git a/catalyst/config.py b/catalyst/config.py
11 > index 67d4e77..5d74dce 100644
12 > --- a/catalyst/config.py
13 > +++ b/catalyst/config.py
14 > @@ -42,7 +42,7 @@ class ParserBase:
15 > values = {}
16 > cur_array = []
17 >
18 > - trailing_comment=re.compile('\s*#.*$')
19 > + trailing_comment=re.compile(r'\s*#.*$')
20 > #white_space=re.compile('\s+')
21 >
22 > for x, myline in enumerate(self.lines):
23
24 good :)
25
26 --
27 Brian Dolbec <dolsen>