diff options
author | Jordan Galby <67924449+Jordan474@users.noreply.github.com> | 2023-08-09 17:47:43 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-08-09 17:47:43 +0200 |
commit | c36617f9da61c7993c0867084fa039a610949837 (patch) | |
tree | b9e9907f6e471e5db2ced12f265433189a70b65e /lib | |
parent | deadb64206da2d93662ce52e2f45e32966b38428 (diff) | |
download | spack-c36617f9da61c7993c0867084fa039a610949837.tar.gz spack-c36617f9da61c7993c0867084fa039a610949837.tar.bz2 spack-c36617f9da61c7993c0867084fa039a610949837.tar.xz spack-c36617f9da61c7993c0867084fa039a610949837.zip |
Fix package.py error handling bug (#39017)
Diffstat (limited to 'lib')
-rw-r--r-- | lib/spack/spack/build_environment.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/spack/spack/build_environment.py b/lib/spack/spack/build_environment.py index f0b95ab7de..28df13771e 100644 --- a/lib/spack/spack/build_environment.py +++ b/lib/spack/spack/build_environment.py @@ -1256,9 +1256,8 @@ def get_package_context(traceback, context=3): func = getattr(obj, tb.tb_frame.f_code.co_name, "") if func: typename, *_ = func.__qualname__.partition(".") - - if isinstance(obj, CONTEXT_BASES) and typename not in basenames: - break + if isinstance(obj, CONTEXT_BASES) and typename not in basenames: + break else: return None |