We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 45fabec commit 6afac14Copy full SHA for 6afac14
1 file changed
src/minizinc/instance.py
@@ -661,9 +661,9 @@ async def solutions(
661
# an unexpected Python exception occurred
662
# First, terminate the process
663
if sys.platform == "win32":
664
- import signal
665
-
666
- proc.send_signal(signal.CTRL_C_EVENT)
+ with open(f"\\\\.\\pipe\\minizinc-{proc.pid}", mode="w") as named_pipe:
+ # Trigger MiniZinc termination
+ named_pipe.write("")
667
else:
668
proc.terminate()
669
_ = await proc.wait()
0 commit comments