Skip to content

How to get IDE support #317

Answered by mattem
hofbi asked this question in Q&A
Discussion options

You must be logged in to vote

A venv can be created for any py_test or py_binary target, via bazel run //the/binary.venv, rules_py will create a venv for that target in the directory next to the target.

Would the idea then be to have a py_venv target for the entire repo to provide the IDE venv?

This really depends on a number of factors. If there is multiple Python dependency closures in the repo, or Python versions, then a single venv will cause conflicts. It also depends on the size of the repo, perhaps, as opening the root of a repo and attempting to install all of the dependencies would be too large, so a finer grained "per service" and "per target" approach is needed.

Replies: 4 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by mattem
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
4 participants