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 python zip file to a output group #9453

Closed
wants to merge 3 commits into from

Conversation

meteorcloudy
Copy link
Member

@meteorcloudy meteorcloudy commented Oct 1, 2019

After this change, users can get the python zip file of a certain
target without using --build_python_zip by

bazel build //foo:bar --output_groups=python_zip_file

or

filegroup(
  name = "bar_zip",
  srcs = ["//foo:bar"],
  output_group = "python_zip_file",
)

Fixes #3530

After this change, users can get the python zip file of a certain
target without using --build_python_zip_file by

bazel build //foo:bar --output_groups=python_zip_file

or

filegroup(
  name = "bar_zip",
  srcs = ["//foo:bar"],
  output_group = "python_zip_file",
)
@groodt
Copy link
Contributor

groodt commented Oct 1, 2019

This feels like a very promising alternative to subpar executables inside Docker containers. 👍

@meteorcloudy meteorcloudy removed the request for review from hlopko October 2, 2019 07:23
@meteorcloudy
Copy link
Member Author

/cc @brandjon

@aiuto aiuto added the team-Rules-Python Native rules for Python label Oct 4, 2019
@meteorcloudy
Copy link
Member Author

Ping @brandjon !

@brandjon brandjon self-assigned this Oct 17, 2019
Copy link
Member

@brandjon brandjon left a comment

Choose a reason for hiding this comment

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

This all looks good. Thanks for breaking it into three commits for easier reviewing. Recording my comment wording nits below but I'll apply them in the merge.

@meteorcloudy
Copy link
Member Author

Thanks for the review and importing!

Copy link
Member

@brandjon brandjon left a comment

Choose a reason for hiding this comment

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

Other changes in internal merge:

  • make createStubFile static
  • add log line to test
  • move test from .../shell/integration/ to .../shell/bazel/

@bazel-io bazel-io closed this in 6e71b5f Oct 18, 2019
bmclarnon added a commit to google-parfait/confidential-federated-compute that referenced this pull request Mar 25, 2024
All new images should be built with bazel, so we don't anticipate
needing the loop any more.

Also add a filegroup so that we don't need a separate bazel
invocation with `--build_python_zip`; see
bazelbuild/bazel#9453.

Change-Id: I7e2203ac4efbfada7fa69565f6b0f27bf6979f25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes team-Rules-Python Native rules for Python
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Make py_binary have zipped binary as implicit output
5 participants