diff options
author | Matthew Brett <matthew.brett@gmail.com> | 2021-10-16 16:04:25 +0100 |
---|---|---|
committer | Xavier Claessens <xclaesse@gmail.com> | 2021-10-16 12:41:02 -0400 |
commit | 67185565717fc768fb35bbf8605d040d816862fc (patch) | |
tree | c57ef490c9e2a9f2798a4649e13d979c6ec34587 /mesonbuild/mesonlib | |
parent | f52a5a7cd3f30645c1b746488ec921451545d9b6 (diff) | |
download | meson-67185565717fc768fb35bbf8605d040d816862fc.zip meson-67185565717fc768fb35bbf8605d040d816862fc.tar.gz meson-67185565717fc768fb35bbf8605d040d816862fc.tar.bz2 |
Add missing but expected as exception clause
The `except` line was missing its `as e` clause.
As a result, when erroring out, after not finding a compiler, Meson
gives an error ending:
```
File "C:\Users\Matthew\AppData\Roaming\Python\Python39\site-packages\mesonbuild\mesonlib\vsenv.py",
line 100, in setup_vsenv
mlog.warning('Failed to activate VS environment:', str(e))
```
Diffstat (limited to 'mesonbuild/mesonlib')
-rw-r--r-- | mesonbuild/mesonlib/vsenv.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mesonbuild/mesonlib/vsenv.py b/mesonbuild/mesonlib/vsenv.py index 1966634..6532970 100644 --- a/mesonbuild/mesonlib/vsenv.py +++ b/mesonbuild/mesonlib/vsenv.py @@ -94,7 +94,7 @@ def _setup_vsenv(force: bool) -> bool: def setup_vsenv(force: bool = False): try: _setup_vsenv(force) - except MesonException: + except MesonException as e: if force: raise mlog.warning('Failed to activate VS environment:', str(e)) |