mirror of
https://github.com/enpaul/tox-poetry-installer.git
synced 2024-10-29 19:47:00 +00:00
parent
62f90de297
commit
fdaee670c4
@ -37,7 +37,7 @@ try:
|
||||
from poetry.installation.operations.install import Install
|
||||
from poetry.poetry import Poetry
|
||||
from poetry.utils.env import VirtualEnv
|
||||
except ImportError:
|
||||
except ImportError as err:
|
||||
raise exceptions.PoetryNotInstalledError(
|
||||
f"No version of Poetry could be imported under the current environment for '{sys.executable}'"
|
||||
f"Failed to import a supported version of Poetry under the current environment '{sys.executable}': {err}"
|
||||
) from None
|
||||
|
@ -46,9 +46,9 @@ def check_preconditions(venv: ToxVirtualEnv) -> "_poetry.Poetry":
|
||||
#
|
||||
# ``RuntimeError`` is dangerous to blindly catch because it can be (and in Poetry's case,
|
||||
# is) raised in many different places for different purposes.
|
||||
except RuntimeError:
|
||||
except RuntimeError as err:
|
||||
raise exceptions.SkipEnvironment(
|
||||
"Project does not use Poetry for env management, skipping installation of locked dependencies"
|
||||
f"Skipping installation of locked dependencies due to a Poetry error: {err}"
|
||||
) from None
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user