MiniZinc / mzn-bench

A framework to performing benchmark testing on MiniZinc models, solvers, and/or the compiler itself.
https://www.minizinc.org
5 stars 5 forks source link

Use configuration's driver to instantiate Solver #16

Closed hbierlee closed 3 years ago

hbierlee commented 3 years ago

Otherwise, the default driver (on the user's PATH) might not have that particular solver configuration.

I'm not 100% sure how to solve this except setting the default driver for each instance. The load function does not support a driver argument.

Dekker1 commented 3 years ago

Yes, I believe you are right that this is necessary. This problem likely originates from when I changed the system to not always send the full configuration in the environmental variable.

There is two things that I'm left wondering:

hbierlee commented 3 years ago
hbierlee commented 3 years ago

Oh wait, I see now that you are probably right that we're not done yet, because on my system where my PATH's minizinc is different from my selected driver, it's using both now:

DEBUG:minizinc:CLIDriver:run -> command: "/usr/bin/minizinc --allow-multiple-assignments --version", timeout None
DEBUG:minizinc:CLIDriver:run -> command: "/home/hbierlee/Projects/libminizinc/release --allow-multiple-assignments --version", timeout None
Dekker1 commented 3 years ago

No, I think you are right. We do run using the right version of MiniZinc. The initial use of the other MiniZinc is merely to initial the MiniZinc Package, this will always use the version on the PATH. You then use set_default to change it.

Dekker1 commented 3 years ago

Okay, so it look like you are right that this is the only real solution that currently works. There is a remaining problem that if one configuration uses the system default and another is set explicitly, then by setting default, it would be unable to find the system default.

I'll add a quick fix for this and then merge that back

Dekker1 commented 3 years ago

Hey! I think I found a better workaround (#17). Could you give that one a quick try? Then I'll merge that into the repository