Description
With PEP 751 accepted, a new, better, standard (than requirements.txt) for locked requirements is available.
We should support it as an input format for pip.parse et al.
Unfortunately, it's in toml format, so consuming it in Starlark is a bit non-trivial. We either need a Starlark-native toml parser, or a repo-rule phase tool that can convert it to a format for pip.parse to consume (e.g. toml -> json).
Solution ideas:
- In pip.parse's repo phase, run a python script to convert toml to json.
- Make compile_pip_requirements et al able to produce a JSON equivalent to pylock.toml, which gets fed into pip.parse directly.
- Have a prebuilt binary, run during repo phase, convert toml to json
- Have a native Starlark parser to parse the toml.
(1) is the simplest, most expedient, solution, but any would suffice.