conan: Problem with resolving OpenSSL version using version ranges mechanism

I have recently updated conan from version 0.24 to 0.27 Now I have problem with downloading OpenSSL package using version ranges [~=1.0.2] mechanism. Here is example of my conanfile.py:

from conans import ConanFile

class Test(ConanFile):
    requires = "OpenSSL/[~=1.0.2]@conan/stable"
    generators = "qmake", "txt"
    default_options = "OpenSSL:shared=True"

    settings = {"os": ["Windows", "Linux", "Macos"],
                "compiler": {"Visual Studio": {"version": None, "runtime": None},
                            "gcc": {"version": None},
                            "apple-clang": {"version": None}},
                "arch": ["x86", "x86_64"],
                "build_type": ["Release", "Debug"]}

After calling command: conan install I receive an error: ERROR: The version in '~=1.0.2' from requirement 'OpenSSL/[~=1.0.2]@conan/stable' could not be resolved

On conan 0.24 everything was running fine. Were there any changes with version ranges mechanism? I’ve checked with changelog and I couldn’t find anything about that.

About this issue

  • Original URL
  • State: closed
  • Created 7 years ago
  • Reactions: 1
  • Comments: 41 (27 by maintainers)

Commits related to this issue

Most upvoted comments

I recently updated from 0.26.1 to 0.27 as well, and our projects cannot resolve some version ranges with wildcards. When we downgrade to 0.26.1, everything works as intended.

Our packages were created using >0.25, so I’m confused as to what is happening as well.