Skip to content

Unreliable tests on Windows? #9

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
Thell opened this issue Apr 15, 2023 · 1 comment
Open

Unreliable tests on Windows? #9

Thell opened this issue Apr 15, 2023 · 1 comment

Comments

@Thell
Copy link
Contributor

Thell commented Apr 15, 2023

image

After letting it sit like that while reading docs I figured something isn't right. Putting a few print statements in the tests and running without capturing shows that the tests just aren't terminating... 🤷‍♂️

   Compiling highs-sys v1.5.0 (C:\Users\thell\Workspaces\rust\highs-sys)
    Finished test [unoptimized + debuginfo] target(s) in 0.51s
     Running unittests src\lib.rs (target\debug\deps\highs_sys-3d25d1f33d6abe81.exe)

running 4 tests
test bindgen_test_layout__Lldiv_t ... ok
test bindgen_test_layout___crt_locale_data_public ... ok
test bindgen_test_layout__Mbstatet ... ok
test bindgen_test_layout___crt_locale_pointers ... ok

test result: ok. 4 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

     Running tests\test_highs_call.rs (target\debug\deps\test_highs_call-cc6750e8e836ffd8.exe)

running 1 test
test highs_call ... ok

test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.00s

     Running tests\test_highs_functions.rs (target\debug\deps\test_highs_functions-d5a2d5a05e03bb5a.exe)

running 2 tests
===== multi threading tests ========
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
--- completed a highs_functions test
threads collected...

Then it just spins at 100% of 1 core. After breaking out of that one I altered the number of threads started and tried a bunch more runs and got hangs on test_highs_call a few times and test_highs_functions on the remainder.

Any ideas?
I used winget for the reqs with -i for the cmake to set the env vars and the installs went fine as well as the cargo build... I'm not sure what to check next.

@Thell
Copy link
Contributor Author

Thell commented Apr 17, 2023

Hi again! So, it looks like this happens when threads = 0. According to Julian in the previously linked issue thread this looked to resolve their hanging issue with HiGHS on Windows, and, indeed

        let option_name = CString::new("threads").unwrap();
        Highs_setIntOptionValue(highs, option_name.as_ptr(), 1);

has resolved the issue. I'll leave it open for you to close in case you want to make that a part of highs-sys Windows configs.

Now... on to figuring out the zlip issue on Windows, lol.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant