From 4833ab09ca9e94ea2cbe3129a3b18c04ba72192e Mon Sep 17 00:00:00 2001 From: dcollins Date: Wed, 11 May 2022 12:54:54 +0100 Subject: [PATCH] split long cython import lines --- isort/wrap.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/isort/wrap.py b/isort/wrap.py index 5fb4631f7..c89cfa536 100644 --- a/isort/wrap.py +++ b/isort/wrap.py @@ -69,7 +69,7 @@ def line(content: str, line_separator: str, config: Config = DEFAULT_CONFIG) -> comment = None if "#" in content: line_without_comment, comment = content.split("#", 1) - for splitter in ("import ", ".", "as "): + for splitter in ("import ", "cimport ", ".", "as "): exp = r"\b" + re.escape(splitter) + r"\b" if re.search(exp, line_without_comment) and not line_without_comment.strip().startswith( splitter