This question does not relate to coding in Prolog; I am rather asking for directions on how to solve a little annoying issue that is costing me a lot of testing effort.
In a nutshell, I am testing my program for a large set of input problems. My testing script is as simple as this Windows batch file:
swipl -l path/program1.pl -g goal1 -g halt
swipl -l path/program2.pl -g goal2 -g halt
swipl -l path/program341.pl -g goal341 -g halt
Then I will simply run this script in the good-old CMD console. The problem I am getting is that most of the time (in approximately 4 out of 5 runs) the script stops arbitrarily in the middle. When I consult the task manager I see something like this:
Looks like swipl finished but it is kind of hanging there.
My solution is to select “swipl” and end the task. This will immediately start the next line in the testing script, and testing resumes. At this point, the script might finish or might hang again (one or more times).
Eventually, after nudging the script whenever it feels like taking a nap, I can finally get my testing done. Each invocation of swipl in the script produces the intended results i.e. when the script hangs, it is doing so after solving the problem given to it.
The total execution time of swipl to solve the given problems is almost 3 hours, and so far I am unable to run it unattended.
I am trying to figure out why the script hangs at certain random points. Is this a SWI-Prolog issue or a Windows issue?
Any suggestions are appreciated.
I am using Windows 10 with SWI-Prolog developer version 8.1.19.