Skip to content

Commit ae55a6a

Browse files
committed
docs(conf) Fix UP031 (printf-string-formatting)
https://docs.astral.sh/ruff/rules/printf-string-formatting/ docs/conf.py:189:16: UP031 Use format specifiers instead of percent format | 187 | lineno = None 188 | 189 | linespec = "#L%d-L%d" % (lineno, lineno + len(source) - 1) if lineno else "" | ^^^^^^^^^^ UP031 190 | 191 | fn = relpath(fn, start=pathlib.Path(vcspull.__file__).parent) | = help: Replace with format specifiers
1 parent f00db16 commit ae55a6a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/conf.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -186,7 +186,7 @@ def linkcode_resolve(domain: str, info: t.Dict[str, str]) -> t.Union[None, str]:
186186
except Exception:
187187
lineno = None
188188

189-
linespec = "#L%d-L%d" % (lineno, lineno + len(source) - 1) if lineno else ""
189+
linespec = f"#L{lineno}-L{lineno + len(source) - 1}" if lineno else ""
190190

191191
fn = relpath(fn, start=pathlib.Path(libtmux.__file__).parent)
192192

0 commit comments

Comments
 (0)