Skip to content

Commit 9607cb2

Browse files
committed
update highs and jsquery
1 parent 0cec581 commit 9607cb2

File tree

2 files changed

+11
-6
lines changed

2 files changed

+11
-6
lines changed

docs/python-mip_theme/static/lib/jquery/jquery.min.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

mip/highs.py

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,21 @@
3030
# need library matching operating system
3131
platform = sys.platform.lower()
3232
if "linux" in platform:
33-
pattern = "highs_bindings.*.so"
33+
patterns = ["highs_bindings.*.so", "_core.*.so"]
3434
elif platform.startswith("win"):
35-
pattern = "highs_bindings.*.pyd"
35+
patterns = ["highs_bindings.*.pyd", "_core.*.pyd"]
3636
elif any(platform.startswith(p) for p in ("darwin", "macos")):
37-
pattern = "highs_bindings.*.so"
37+
patterns = ["highs_bindings.*.so", "_core.*.so"]
3838
else:
3939
raise NotImplementedError(f"{sys.platform} not supported!")
4040

4141
# there should only be one match
42-
[libfile] = glob.glob(os.path.join(pkg_path, pattern))
42+
matched_files = []
43+
for pattern in patterns:
44+
matched_files.extend(glob.glob(os.path.join(pkg_path, pattern)))
45+
if len(matched_files) != 1:
46+
raise FileNotFoundError(f"Could not find HiGHS library in {pkg_path}.")
47+
[libfile] = matched_files
4348
logger.debug("Choosing HiGHS library {libfile} via highspy package.")
4449

4550
highslib = ffi.dlopen(libfile)

0 commit comments

Comments
 (0)