| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
This is also deprecating the symbols in the pythons_hub and the other parts as was suggested in #2565. If this is not (yet) desirable, please comment on this PR. I personally think that we might be able to do this, but I am not sure if there are no problems (e.g. with using 3.10 in non-root modules). If we want to start printing deprecation messages in 3.10 or add a flag that is controlling this behaviour via rules_python_internal or some other method, I am happy to amend to this PR. Maybe the with_deprecation symbol should be in //python/private:with_deprecacion? I ran out of time today, so that is it for today. |
Sorry, something went wrong.
|
This now only warns if RULES_PYTHON_DEPRECATION_WARNINGS is 1, which defaults to 0. I am fine with defaulting it to 1 if we want to default to a more noisy default. |
Sorry, something went wrong.
There was a problem hiding this comment.
Just nits/style, otherwise LGTM
Sorry, something went wrong.
|
This is great, thank you! I didn't realized I missed so many other spots, sorry about that. re: deprecating pythons_hub symbols: Yes, deprecating those also makes sense re: move deprecation helper elsewhere: yes, I agree re: environment variable: Thanks for creating this. I like this idea a lot. |
Sorry, something went wrong.
|
addendum: I've approved, but not queued for merge, in case you want to move with_deprecated elsewhere before merging. I'm OK with that being done in a separate PR, too. |
Sorry, something went wrong.
|
OK, extra changes that I needed to do:
I think this makes the change much more robust and we have a single place for the deprecated symbols. If we wanted we could add a buildozer command for the migration, but I think we can merge as is right now. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
This goes together with #2565 to remove the internal usage of the deprecated
symbols. This also fixes the compile_pip_requirements symbol to print the
correct deprecation message.
Builds on top of 611eda8
The example message that would be printed is as follows:
The 'py_test' symbol in '@+python+python_3_11//:defs.bzl' is deprecated. It is an alias to the regular rule; use it directly instead: load("@rules_python//python:py_test.bzl", "py_test") py_test( name = "versioned_py_test", srcs = ["dummy.py"], main = "dummy.py", python_version = "3.11.11", )