diff options
author | Jussi Pakkanen <jpakkane@gmail.com> | 2022-04-09 12:37:44 +0300 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2022-04-09 12:37:44 +0300 |
commit | 5751f7b89a2402c582fbd03a136a25a1a0cf6e6e (patch) | |
tree | 8a5fe884a1a254f462cdd205b11d660b88dde59a | |
parent | e5aa47d8af917282794a8da3956ce444b8d8378d (diff) | |
download | meson-pylogfix.zip meson-pylogfix.tar.gz meson-pylogfix.tar.bz2 |
Validate that introspection command exited cleanly.pylogfix
-rw-r--r-- | mesonbuild/modules/python.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/mesonbuild/modules/python.py b/mesonbuild/modules/python.py index 3bbccd1..864d7ab 100644 --- a/mesonbuild/modules/python.py +++ b/mesonbuild/modules/python.py @@ -410,6 +410,8 @@ class PythonExternalProgram(ExternalProgram): # Sanity check, we expect to have something that at least quacks in tune cmd = self.get_command() + ['-c', INTROSPECT_COMMAND] p, stdout, stderr = mesonlib.Popen_safe(cmd) + if p.returncode != 0: + raise mesonlib.MesonException('Trying to introspect Python configuration failed.\n\n' + stdout + stderr) try: info = json.loads(stdout) except json.JSONDecodeError: |