diff options
Diffstat (limited to 'examples')
-rw-r--r-- | examples/custom_raw.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/examples/custom_raw.py b/examples/custom_raw.py index da576a2..30e90bf 100644 --- a/examples/custom_raw.py +++ b/examples/custom_raw.py @@ -10,6 +10,7 @@ class MyRawChecker(BaseChecker): name = 'custom_raw' msgs = {'W9901': ('use \\ for line continuation', + 'backslash-line-continuation', ('Used when a \\ is used for a line continuation instead' ' of using triple quoted string or parenthesis.')), } @@ -23,7 +24,8 @@ class MyRawChecker(BaseChecker): with module.stream() as stream: for (lineno, line) in enumerate(stream): if line.rstrip().endswith('\\'): - self.add_message('W9901', line=lineno) + self.add_message('backslash-line-continuation', + line=lineno) def register(linter): |