-
-
Notifications
You must be signed in to change notification settings - Fork 16
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
Support option for environment activation #52
Comments
before this line https://github.com/osl-incubator/makim/blob/main/src/makim/core.py#L94C1-L107C1 we could have something like this: venv = self.global_data.get('virtual-environment'. {})
venv_app = venv.get({'application', ''})
venv_name = venv.get({'name', ''})
self.shell_app(
*self.shell_args,
f"{venv_app} activate {venv_name}",
_in=sys.stdin,
_out=sys.stdout,
_err=sys.stderr,
_bg=False,
_bg_exc=False,
_no_err=True,
_env=os.environ,
_new_session=False,
) |
It doesn't work, gives no such file or directory error, when try to activate the environment. |
I see . but that is the general idea ... you can try different things there sh_venv = getattr(sh, venv_app)
sh_venv(
f"activate {venv_name}",
_in=sys.stdin,
_out=sys.stdout,
_err=sys.stderr,
_bg=False,
_bg_exc=False,
_no_err=True,
_env=os.environ,
_new_session=False,
) but cretes a jupyter notebook and play a bit with that |
this is a bit more complex than we expected ... |
We need to add support for conda environment activation that will activate the environment beforehand before executing the environment.
for now, let's just support conda.
this option should be defined just in the global scope.
we need to investigate it later if we would like to have it for group and target scope as well.
for now, we don't need to implement
source
, but it would be nice to have that, so it could create an environment in the case it doesn't exist.The text was updated successfully, but these errors were encountered: