Skip to content

Spec.__contains__ produces wrong results for intel-oneapi-mkl #35597

@alalazo

Description

@alalazo

Steps to reproduce

Reported by @dev-zero in #35584

Spack version 0.20.0.dev0
Python 3.8.10, Linux x86_64
>>> from spack.spec import Spec
>>> s = Spec("cp2k ^intel-oneapi-mkl")
>>> c = s.concretized()
>>> "intel-oneapi-mkl" in c
True
>>> "^intel-oneapi-mkl" in c
False
>>> c["blas"]
intel-oneapi-mkl@2023.0.0%gcc@9.4.0~cluster+envmods~ilp64+shared build_system=generic arch=linux-ubuntu20.04-icelake ^intel-oneapi-tbb@2021.8.0%gcc@9.4.0+envmods build_system=generic arch=linux-ubuntu20.04-icelake
>>> c["lapack"]
intel-oneapi-mkl@2023.0.0%gcc@9.4.0~cluster+envmods~ilp64+shared build_system=generic arch=linux-ubuntu20.04-icelake ^intel-oneapi-tbb@2021.8.0%gcc@9.4.0+envmods build_system=generic arch=linux-ubuntu20.04-icelake

Error message

The entry:

>>> "^intel-oneapi-mkl" in c
False

should return True.

Information on your system

  • Spack: 0.20.0.dev0 (fbd5c5c)
  • Python: 3.8.10
  • Platform: linux-ubuntu20.04-icelake
  • Concretizer: clingo

General information

  • I have run spack debug report and reported the version of Spack/Python/Platform
  • I have searched the issues of this repo and believe this is not a duplicate
  • I have run the failing commands in debug mode and reported the output

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions