Skip to content

Commit 2990d6b

Browse files
Fix syntax error in nested process test
The grandchild_script was using unescaped triple quotes inside an f-string, causing a syntax error. Fixed by escaping the triple quotes and adjusting indentation.
1 parent dd10fb7 commit 2990d6b

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

tests/client/test_stdio.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -490,12 +490,12 @@ async def test_stdio_client_nested_process_tree():
490490
import time
491491
492492
# Grandchild just writes to file
493-
grandchild_script = """import time
494-
with open({repr(grandchild_file)}, 'a') as f:
495-
while True:
496-
f.write(f"gc {time.time()}")
497-
f.flush()
498-
time.sleep(0.1)"""
493+
grandchild_script = \"\"\"import time
494+
with open({repr(grandchild_file)}, 'a') as f:
495+
while True:
496+
f.write(f"gc {{time.time()}}")
497+
f.flush()
498+
time.sleep(0.1)\"\"\"
499499
500500
# Spawn grandchild
501501
subprocess.Popen([sys.executable, '-c', grandchild_script])

0 commit comments

Comments
 (0)