From b796021357a87067527760f81509f07e23999ea2 Mon Sep 17 00:00:00 2001 From: yage Date: Tue, 7 May 2024 23:18:43 -0600 Subject: [PATCH] upgrade max supported python version to 3.12; drop support for python 3.9 (>3.10 required) --- py/lib/scwrypts/env.py | 2 +- zsh/lib/scwrypts/virtualenv.module.zsh | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/py/lib/scwrypts/env.py b/py/lib/scwrypts/env.py index 1003932..b4715ac 100644 --- a/py/lib/scwrypts/env.py +++ b/py/lib/scwrypts/env.py @@ -4,7 +4,7 @@ from .scwrypts.exceptions import MissingVariableError def getenv(name, required=True): - value = os_getenv(name, None) + value = os_getenv(f'{name}__override', os_getenv(name)) if required and not value: raise MissingVariableError(name) diff --git a/zsh/lib/scwrypts/virtualenv.module.zsh b/zsh/lib/scwrypts/virtualenv.module.zsh index 223cdf0..2a70ebe 100644 --- a/zsh/lib/scwrypts/virtualenv.module.zsh +++ b/zsh/lib/scwrypts/virtualenv.module.zsh @@ -74,6 +74,8 @@ _VIRTUALENV__GET_PATH() { local ENV_PATH="$(eval echo '$SCWRYPTS_VIRTUALENV_PATH__'$GROUP 2>/dev/null)" [ ! $ENV_PATH ] && ENV_PATH="$SCWRYPTS_VIRTUALENV_PATH__scwrypts" + mkdir -p "$ENV_PATH/$TYPE" &>/dev/null + echo $ENV_PATH/$TYPE } @@ -95,7 +97,7 @@ CREATE_VIRTUALENV__scwrypts__py() { } done [ ! $PYTHON ] && { - ERROR 'python>=3.9 not available; skipping python env' + ERROR 'python>=3.10 not available; skipping python env' return 1 }