conan: [bug] Assertion error self.binary == node.binary

Environment details

  • Operating System+version: Macos 13.4.1
  • Compiler+version: apple-clang 14.0.3
  • Conan version: 2.0.9
  • Python version: 3.11.4

Steps to reproduce

Not completely sure, but happens sometimes when I conan test package with --build missing where multiple binaries should be build by dependency.

The usual workaround is to first conan install --requires --build missing those packages and then conan test. I didn’t find a pattern or minimal reproducer. Hopefully the stack trace will help discovering the issue.

Logs

Stack trace:

Traceback (most recent call last):
  File "/Users/dodo/Desktop/conan2-venv/lib/python3.11/site-packages/conan/cli/cli.py", line 272, in main
    cli.run(args)
  File "/Users/dodo/Desktop/conan2-venv/lib/python3.11/site-packages/conan/cli/cli.py", line 172, in run
    command.run(self._conan_api, args[0][1:])
  File "/Users/dodo/Desktop/conan2-venv/lib/python3.11/site-packages/conan/cli/command.py", line 125, in run
    info = self._method(conan_api, parser, *args)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/dodo/Desktop/conan2-venv/lib/python3.11/site-packages/conan/cli/commands/test.py", line 40, in test
    deps_graph = run_test(conan_api, path, ref, profile_host, profile_build, remotes, lockfile,
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/dodo/Desktop/conan2-venv/lib/python3.11/site-packages/conan/cli/commands/test.py", line 74, in run_test
    conan_api.install.install_binaries(deps_graph=deps_graph, remotes=remotes)
  File "/Users/dodo/Desktop/conan2-venv/lib/python3.11/site-packages/conan/api/subapi/install.py", line 20, in install_binaries
    installer.install_system_requires(deps_graph)  # TODO: Optimize InstallGraph computation
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/dodo/Desktop/conan2-venv/lib/python3.11/site-packages/conans/client/installer.py", line 196, in install_system_requires
    install_graph = InstallGraph(graph)
                    ^^^^^^^^^^^^^^^^^^^
  File "/Users/dodo/Desktop/conan2-venv/lib/python3.11/site-packages/conans/client/graph/install_graph.py", line 190, in __init__
    self._initialize_deps_graph(deps_graph)
  File "/Users/dodo/Desktop/conan2-venv/lib/python3.11/site-packages/conans/client/graph/install_graph.py", line 230, in _initialize_deps_graph
    existing.add(node)
  File "/Users/dodo/Desktop/conan2-venv/lib/python3.11/site-packages/conans/client/graph/install_graph.py", line 129, in add
    install_pkg_ref.add(node)
  File "/Users/dodo/Desktop/conan2-venv/lib/python3.11/site-packages/conans/client/graph/install_graph.py", line 51, in add
    assert self.binary == node.binary
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError

ERROR:

About this issue

  • Original URL
  • State: closed
  • Created a year ago
  • Comments: 16 (16 by maintainers)

Most upvoted comments

Maybe non-release branches should have -dev in their version, to distinguish them from “the official ones” from PyPi

yes, we have tradionally have this -dev, it seems an error that has been dropped now in Conan 2.0.X patches releases, we will recover it.