-
Notifications
You must be signed in to change notification settings - Fork 542
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
feature(py_wheel) Resolve wheel props from user defined properties file #1807
base: main
Are you sure you want to change the base?
Conversation
dfb729e
to
e79fea6
Compare
I personally liked the suggested version_file attribute in the rule. I am wondering what other problems would this more generic templating rule solve? Since expand_template rules already exist in bazel-skylib or aspect's bazel lib, I am not sure if rules_python should be doing templating here. What do you think? |
ad1. My initial idea also was to use simpler approach with Right now I don't see any other use cases for custom_properties than passing version. I decided to implement feature this way to be consistent with stamping implementation. ad2. skylib Right now I see three potential solutions, please advise which is most suitable for you :
|
Hi @aignas any advices how I can improve this PR to get it merged |
My initial thoughts are that having a bigger API surface may add extra maintenance to the rule set. Having the version taken from a file sounds like something that has precedent, e.g. rules_oci is doing this - it can only support a file for remote tags when pushing an artifact. The bazel-skylib expand_template does not support templating based on the stamp value, but aspect's library does, similarly to how it is documented in rules_oci documentation here. A similar thing can be done with a simple Does this change your thoughts about how this should be implemented? |
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. |
I got hit by the dynamic output filename (depends on the version) as well and I think the best way would be to use a dir artifact. I think that would be the cleanest approach. |
Resolves #1804
Adds new
custom_properties
param topy_wheel
. This feature allow to inject version generated by other target.Tested with integration tests:
bazel build examples/wheel:version_from_other_target.dist