You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was trying to build an application depending on glib 2.56.4 and I was having many problems with the concretization. After some research I found out that this version is not installable on its own and after some debugging I think I've found the cause.
The problem can be reproduced in develop-2024-04-07 with a simple package like this:
from spack.package import *
import spack.builder
import spack.package_base
from spack.directives import build_system
from spack.build_systems._checks import BaseBuilder
class FooPackage(spack.package_base.PackageBase):
build_system_class = "FooPackage"
build_system("foo")
@spack.builder.builder("foo")
class FooBuilder(BaseBuilder):
pass
class BarPackage(spack.package_base.PackageBase):
build_system_class = "BarPackage"
build_system("bar")
@spack.builder.builder("bar")
class BarBuilder(BaseBuilder):
pass
class Test(FooPackage, BarPackage):
version("2")
version("1", deprecated=True)
build_system(
conditional("foo", when="@2:"),
conditional("bar", when="@:1"),
default="foo",
)
Trying to concretize test@1 gives an error that is not actionable and even looks wrong. If deprecated=True is removed from the version directive, the command works as expected. Adding --deprecated to the command line also works. This may be a duplicate of #42037, but the error is not exactly the same and the bit about variant ... when [,,] looks weird.
Error message
$ spack spec test@1==> Error: concretization failed for the following reasons: 1. Cannot satisfy 'test@1' 2. Cannot satisfy 'test@1' required because test@1 requested explicitly 3. Cannot satisfy 'test@2:' and 'test@1 required because test@1 requested explicitly required because test variant build_system value foo when [, , ] required because test@1 requested explicitly
I did not add -d because it does not seems to provide additional hints and it should be easy to reproduce.
alalazo
changed the title
Concretization fails with strange error in multi-build system package with deprecated version
Concretization fails with strange error with deprecated versions
May 21, 2024
Steps to reproduce
I was trying to build an application depending on glib 2.56.4 and I was having many problems with the concretization. After some research I found out that this version is not installable on its own and after some debugging I think I've found the cause.
The problem can be reproduced in develop-2024-04-07 with a simple package like this:
Trying to concretize
test@1
gives an error that is not actionable and even looks wrong. Ifdeprecated=True
is removed from theversion
directive, the command works as expected. Adding--deprecated
to the command line also works. This may be a duplicate of #42037, but the error is not exactly the same and the bit aboutvariant ... when [,,]
looks weird.Error message
I did not add -d because it does not seems to provide additional hints and it should be easy to reproduce.
Information on your system
General information
spack debug report
and reported the version of Spack/Python/PlatformThe text was updated successfully, but these errors were encountered: