Skip to content
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

[FR]: include (de)activation scripts in venvs #344

Open
tnielens opened this issue May 13, 2024 · 1 comment
Open

[FR]: include (de)activation scripts in venvs #344

tnielens opened this issue May 13, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@tnielens
Copy link

What is the current behavior?

I've a repository with multiple python distribution packages. I have this rule at the root of my repo meant to create a venv for use by my IDE:

py_venv(
    name = "venv",
    deps = [ 
        ...
    ]
)

The venv produced by rules_py does not include (de)activation scripts. I'm using version 0.7.3 of the rules.

Describe the feature

Add activate/deactivate scripts in the venv as per regular venv creation.

@tnielens tnielens added the enhancement New feature or request label May 13, 2024
@github-actions github-actions bot added the untriaged Requires traige label May 13, 2024
@mattem
Copy link
Member

mattem commented May 23, 2024

They are somewhat intentionally left out, as it adds extra maintenance overhead for each shell that needs its own activation script.

"activate" doesn't really do anything apart from put the interpreter first on the PATH, you can call the interpreter directly in the bin folder and it'll do the right thing without needing any "activation".

I can see how it could be useful however if other applications expect the just run "python", I'll see how much overhead this really adds.

@mattem mattem removed the untriaged Requires traige label May 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants