From ac45dab0213489e663c7294653f546abfbd707ba Mon Sep 17 00:00:00 2001 From: Pierre Sassoulas Date: Sun, 26 Feb 2023 16:34:11 +0100 Subject: [PATCH] Example of cyclic import where the cyclic import does not crash python --- doc/data/messages/c/cyclic-import/bad/bad.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/doc/data/messages/c/cyclic-import/bad/bad.py b/doc/data/messages/c/cyclic-import/bad/bad.py index 62c9daade55..d0b681d5c73 100644 --- a/doc/data/messages/c/cyclic-import/bad/bad.py +++ b/doc/data/messages/c/cyclic-import/bad/bad.py @@ -1,9 +1,8 @@ -from .bad2 import count_to_two # [cyclic-import] - - def count_to_one(): return 1 def count_to_three(): + from .bad2 import count_to_two # [cyclic-import] + return count_to_two() + 1