vprusso / toqito

|toqito> (Theory of Quantum Information Toolkit) in Python :snake:
https://toqito.readthedocs.io/en/latest/
MIT License
155 stars 61 forks source link

Add `macos` to Github Actions #341

Closed purva-thakre closed 10 months ago

purva-thakre commented 10 months ago
FAILED toqito/perms/tests/test_antisymmetric_projection.py::test_antisymmetric_projection[3-3-True-expected_result3] - IndexError: boolean index did not match indexed array along dimension 0; dimension is 1 but corresponding boolean dimension is 27

If toqito is tested on macos, one of the tests fails.

https://github.com/vprusso/toqito/actions/runs/7173291207/job/19532340600?pr=339#step:5:1540

This issue is to understand:

https://stackoverflow.com/a/54339833

The behavior observed here is the opposite of what was seen in this issue: https://github.com/DevExpress/testcafe/issues/3956

purva-thakre commented 10 months ago

Appears to be fixed by https://github.com/vprusso/toqito/pull/339/commits/a8349e5dea05cf1a168d5c845ccbb88e3d2f29ff. Based on linked SO discussions, there is no need to install BLAS and LAPACK for macos.

https://stackoverflow.com/a/54339833

https://stackoverflow.com/a/54339868

purva-thakre commented 10 months ago

Reopening this.

As observed in https://github.com/vprusso/toqito/pull/339/commits/d1a621344607729fa87e7aaff23f45b7ffeec1e8, I forgot to change the os even though the job was labeled as a test builder for macos. The previous comment refers to the tests passing on ubuntu with the job labeled for macos.

purva-thakre commented 10 months ago

It might be better to skip the failing test for now and create an issue so that we remember this. I am not too familiar with macOS and installations.

I think this is a bug related to numpy (there is now an issue on this in their repo: https://github.com/numpy/numpy/issues/25395). If we search for mac in open issues, there are quite a few open discussions about some build failures and AssertionErrors on Mac. Maybe these are related.

The macOS version being installed in the Github actions run is 12.7.1.