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

[FEATURE] Internal virtual environment support #14

Open
kjczarne opened this issue Sep 17, 2021 · 3 comments
Open

[FEATURE] Internal virtual environment support #14

kjczarne opened this issue Sep 17, 2021 · 3 comments
Assignees
Labels
enhancement New feature or request minor Not urgent, importance may require monitoring based on context

Comments

@kjczarne
Copy link
Contributor

Is your feature request related to a problem? Please describe.
General purpose automation systems like nox or tox have a way of creating a virtual environment in the background. Adding a similar functionality to Kalash would mean that test suites can depend on specific versions of packages.

Describe the solution you'd like
I would say creating a venv should happen by default and we should have a --no-venv flag when you want to run with the base interpreter.

Describe alternatives you've considered
There are two alternatives:

  • Keep venv creation up to the user - not ideal, would force QA Engineers to create full-on Python packages. From experience I know they rarely want to create valid Python package setups for hardware tests.
  • Flip the default behavior around - use base interpreter by default and have a --venv flag.

Additional context
In any case we should elect not to modify the base interpreter packages and just warn users about version mismatches for the packages. Kalash should not modify the existing setup in any way, unless it uses a self-managed virtual environment.

@kjczarne kjczarne added the enhancement New feature or request label Sep 17, 2021
@kjczarne kjczarne added this to the v5.0.0 Release Milestone milestone Sep 17, 2021
@kjczarne kjczarne self-assigned this Sep 17, 2021
@pprol
Copy link

pprol commented Sep 17, 2021

I would suggest, use base interpreter by default, and if somebody wants to use an specific environment, let the user decide it. Maybe could be added in the .yaml file? Something like "env-packages: something, other...", like dependencies for the virtual environment.

@kjczarne
Copy link
Contributor Author

The intention is to list the packages in the YAML file under the config section. Something like:

config:
  venv:
    packages:
      - 'prost==2.0.0'

Maybe we do as you suggest, so as not to break the current API for the users. I will move this to the 4.1.0 Milestone then, since it would not break the current API if we go this route.

@kjczarne
Copy link
Contributor Author

Pulling this off of the 4.1.0 milestone. Similar solutions can be currently done with projects like pipenv and this is definitely of a very low priority in that context.

@kjczarne kjczarne added the minor Not urgent, importance may require monitoring based on context label May 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request minor Not urgent, importance may require monitoring based on context
Projects
None yet
Development

No branches or pull requests

2 participants