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

add msvcp140.dll to the wheel on windows #19062

Merged
merged 4 commits into from
Oct 5, 2021

Conversation

mattip
Copy link
Contributor

@mattip mattip commented Oct 3, 2021

Why are these changes needed?

Closes #13293. As described in the issue, on a minimal windows image the support dll msvcp140.dll is needed to load _raylet.pyd.

Related issue number

Checks

  • I've run scripts/format.sh to lint the changes in this PR.
  • I've included any doc changes needed for https://docs.ray.io/en/master/.
  • I've made sure the tests are passing. Note that there might be a few flaky tests, see the recent failures at https://flakey-tests.ray.io/
  • Testing Strategy
    • Unit tests
    • Release tests
    • This PR is not tested :(

python/setup.py Outdated
Comment on lines 562 to 564
print('copy_file uses', build_ext.build_lib, ROOT_DIR)
shutil.copy(r'c:\Windows\system32\msvcp140.dll',
os.path.join(build_ext.build_lib, 'ray'))
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
print('copy_file uses', build_ext.build_lib, ROOT_DIR)
shutil.copy(r'c:\Windows\system32\msvcp140.dll',
os.path.join(build_ext.build_lib, 'ray'))
print("copy_file uses", build_ext.build_lib, ROOT_DIR)
shutil.copy(r"c:\Windows\system32\msvcp140.dll",
os.path.join(build_ext.build_lib, "ray"))

Copy link
Contributor

Choose a reason for hiding this comment

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

We use double quotes for literals

Copy link
Contributor Author

Choose a reason for hiding this comment

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

thanks, fixed and removed the debug print

@mattip
Copy link
Contributor Author

mattip commented Oct 3, 2021

On the one hand this is a very small change, on the other it is a bit obscure how the dll ends up in the wheel. I guess git grep msvcp140 will find it, is that discoverable enough or should I make a copy_system_dlls() function to emphasize it?

@richardliaw
Copy link
Contributor

richardliaw commented Oct 3, 2021 via email

Copy link
Contributor

@pcmoritz pcmoritz left a comment

Choose a reason for hiding this comment

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

Thanks for doing this, this is great! Looks like the windows tests failed for unrelated reasons, re-running them.

@pcmoritz
Copy link
Contributor

pcmoritz commented Oct 5, 2021

@mattip Looks like there is an unrelated doc building failure, can you merge master into this PR? that should make it go away!

@mattip
Copy link
Contributor Author

mattip commented Oct 5, 2021

rebased off master

@pcmoritz pcmoritz merged commit 63dd22c into ray-project:master Oct 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Include compiled extension binaries into windows wheel
3 participants