Skip to content

Commit c4fce6f

Browse files
committed
Resolve warning about "never awaited" solve_async in test cases
1 parent 71837e2 commit c4fce6f

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/minizinc/instance.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -192,6 +192,8 @@ def solve(
192192
)
193193
return asyncio.run(coroutine)
194194
except RuntimeError as r:
195+
coroutine.close()
196+
del coroutine
195197
if "called from a running event loop" in r.args[0]:
196198
raise RuntimeError(
197199
"the synchronous MiniZinc Python `solve()` method was called from"

0 commit comments

Comments
 (0)