You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 3, 2023. It is now read-only.
diff --git i/src/pydocstyle/checker.py w/src/pydocstyle/checker.py
index 41e3f35..2ec3e9d 100644
--- i/src/pydocstyle/checker.py+++ w/src/pydocstyle/checker.py@@ -332,10 +332,12 @@ class ConventionChecker:
"""
if docstring:
indent = self._get_docstring_indent(definition, docstring)
+ is_raw = docstring.startswith('r')
lines = docstring.split('\n')
if len(lines) > 1:
- # First line and line continuations need no indent.- lines = [+ # First line and (for non-raw strings) line continuations need+ # no indent.+ lines = lines[1:] if is_raw else [
line
for i, line in enumerate(lines)
if i and not lines[i - 1].endswith('\\')
I have a docstring with an ASCII-tree-drawing like this:
Since pydocstyle 5.1.0, I get:
According to git bisect, #472 / b0f7d62 is causing this - cc @anntzer
Given that this is marked as a raw string (
r"""..."""
), I don't think this should be interpreted as a line continuation - Python doesn't do so either:The text was updated successfully, but these errors were encountered: