Skip to content
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

Update setuptools and fix m1 mac dev build #35832

Merged
merged 7 commits into from
Jul 24, 2023

Conversation

MialLewis
Copy link
Contributor

@MialLewis MialLewis commented Jul 21, 2023

Description of work
This PR enables the update of setuptools within the mantid developer environments. It also fixes an issue which was causing the build and test portion of the PR/package build pipeline to fail on our M1 macs.

Following this PR, 4 unit tests still fail when ran on M1 macs. These tests will be fixed in a subsequent PR.

  • Use the SUB_DIR variable when creating a mantid developer env on M1 macs to ensure an x64/86 build takes place.
  • Reinstates some previously removed cmake code that circumvents the fact that recent versions of setuptools do not make use of egg-link files.
  • Removed a couple of setuptools files from the cxxtest directory that are redundant.
  • Added paths to python packages to the Visual Studio debug environment variables - this allows us to move past setuptools v47, where we have been stuck for a while because of Mantid doesn't work with latest setuptools on Windows #33118.

To test:

Successful build on M1 macs will be fully tested once the failing unit tests are fixed in the subsequent PR.

On Windows check that you can launch a debug build in Visual Studio:

  1. Update your conda env with mamba env update -f mantid-developer-win.yml --prune (this will update your setuptools)
  2. Activate your mantid-developer environment
  3. Remove your build folder
  4. Run e.g. cmake --preset=win-vs-2019 depending on which VS version you're using
  5. Open Visual Studio using the visual-studio.bat that was generated in the build folder
  6. Build the solution
  7. Launch workbench and check that it works correctly.

On Linux

  1. Update your mantid-developer conda env, as above
  2. Clean build
  3. Check that you can launch mantidworkbench

Fixes #33118


Reviewer

Please comment on the points listed below (full description).
Your comments will be used as part of the gatekeeper process, so please comment clearly on what you have checked during your review. If changes are made to the PR during the review process then your final comment will be the most important for gatekeepers. In this comment you should make it clear why any earlier review is still valid, or confirm that all requested changes have been addressed.

Code Review
  • Is the code of an acceptable quality?
  • Does the code conform to the coding standards?
  • Are the unit tests small and test the class in isolation?
  • If there is GUI work does it follow the GUI standards?
  • If there are changes in the release notes then do they describe the changes appropriately?
  • Are the release notes saved in a separate file, using Issue or PR number for file name and in the correct location?
Functional Tests
  • Do changes function as described? Add comments below that describe the tests performed?
  • Do the changes handle unexpected situations, e.g. bad input?
  • Has the relevant (user and developer) documentation been added/updated?

Does everything look good? Mark the review as Approve. A member of @mantidproject/gatekeepers will take care of it.

Gatekeeper

If you need to request changes to a PR then please add a comment and set the review status to "Request changes". This will stop the PR from showing up in the list for other gatekeepers.

This reverts commit 7abf534.

This is required as the sitecustomize.py script is required to
add several directories to the PYTHONPATH.
@MialLewis MialLewis force-pushed the 0_update_sut_and_fix_m1_mac_dev_build branch from bc36b71 to b9d46b8 Compare July 21, 2023 15:58
@MialLewis MialLewis marked this pull request as ready for review July 24, 2023 08:28
@cailafinn cailafinn self-assigned this Jul 24, 2023
Copy link
Contributor

@cailafinn cailafinn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Workbench launches properly and the code changes look good. Good to get another step closer to running our ARM macs.

@SilkeSchomann SilkeSchomann merged commit b2591d2 into main Jul 24, 2023
@SilkeSchomann SilkeSchomann deleted the 0_update_sut_and_fix_m1_mac_dev_build branch July 24, 2023 13:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

Mantid doesn't work with latest setuptools on Windows
4 participants