echoing-farmer-15630
03/30/2022, 1:15 PMpython_requirements
in a top-level BUILD
file which sourced a constraints.txt
for the entire package, which had entries like
module_mapping={..."setuptools: ["pkg_resources"]...},
overrides={"torch": {"dependencies": [":setuptools"]}
so far so good (I know the pkg_resources should probably have been sorted automatically but we were having difficulties there).
This used to work... but when I turn on use_deprecated_python_macros=false
, it tells me I need to name that stanza of requirements. But if I give it a name (name="root_requirements"
or some such) when I try to do anything like generate lockfiles I get
ResolveError: 'setuptools' was not found in namespace ''. Did you mean one of:
Okay, but if I try to name it (say, replace every instance of setuptools
there with //root_requirements:setuptools
) then I get
ResolveError: The file or directory 'root_requirements' does not exist on disk in the workspace, so the address 'root_requirements:setuptools' cannot be resolved.
... presumably because the requirements haven't been created yet or..?
Just baffled; this worked fine earlier but presumably it was wrong then too. What's the right way to do this?