Skip to content

Fix whl.py for Windows #195

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

Closed
wants to merge 1 commit into from

Conversation

meteorcloudy
Copy link
Contributor

Related #2

@meteorcloudy
Copy link
Contributor Author

I did some investigation on enabling rules_python on Windows.
Building ... was still failing with:

pcloudy@pcloudy0-w MSYS ~/workspace/rules_python
$ bazel build ...
DEBUG: C:/src/tmp/i6sxytkk/external/bazel_skylib/skylark_library.bzl:23:1: WARNING: skylark_library.bzl is deprecated and will go away in the future, please use bzl_library.bzl instead.
ERROR: C:/tools/msys64/home/pcloudy/workspace/rules_python/examples/extras/BUILD:21:1: Traceback (most recent call last):
        File "C:/tools/msys64/home/pcloudy/workspace/rules_python/examples/extras/BUILD", line 21
                py_test(name = "extras_test", srcs = ["ext..."], <2 more arguments>)
        File "C:/tools/msys64/home/pcloudy/workspace/rules_python/examples/extras/BUILD", line 27, in py_test
                requirement("googleapis-common-protos[grpc]")
        File "C:/src/tmp/i6sxytkk/external/examples_extras/requirements.bzl", line 218, in requirement
                fail(("Could not find pip-provided de...))
Could not find pip-provided dependency: 'googleapis-common-protos[grpc]'
ERROR: package contains errors: examples/extras
ERROR: error loading package 'examples/extras': Package 'examples/extras' contains errors
INFO: Elapsed time: 21.908s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (0 packages loaded)

The root cause is googleapis_common_protos-1.6.0-py2-none-any.whl doesn't contain a metadata.json file so that it fell back to parsing the METADATA file, which didn't implement parsing for extras. This PR solves this for extras, but as the comment said, we probably need to deal with other attributes as well.

@mattmoor @brandjon

@meteorcloudy
Copy link
Contributor Author

I didn't strictly build the par files in the docker. If that is required, I can revert the binaries change and someone else can help me update them. ;)

@github-actions
Copy link

This Pull Request has been automatically marked as stale because it has not had any activity for 180 days. It will be closed if no further activity occurs in 30 days.
Collaborators can add an assignee to keep this open indefinitely. Thanks for your contributions to rules_python!

@github-actions github-actions bot added the Can Close? Will close in 30 days if there is no new activity label Apr 14, 2021
@github-actions
Copy link

This PR was automatically closed because it went 30 days without a reply since it was labeled "Can Close?"

@github-actions github-actions bot closed this May 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Can Close? Will close in 30 days if there is no new activity cla: yes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants