Skip to content

opam admin check --cycle --ignore-test-doc does not give accurate results #4541

@kit-ty-kate

Description

@kit-ty-kate

In ocaml/opam-repository#18124 an attempt has been made to remove every cycle in opam-repository detected by opam admin check --cycle --ignore-test-doc.
However this command does not seem to give correct results. For example on top of ocaml/opam-repository@019b3aa, if I remove the {!= "1.3"} constraint from the result in dune-configurator.2.8.1, I get:

$ opam admin check --cycle --ignore-test-doc
[ERROR] Dependency cycles detected:
  * graphics = 5.1.0 → dune-configurator = 2.8.1 → result = 1.3 → jbuilder (>= 1.0+beta11 & < 1.0+beta19) → ocamlfind < 1.8.1
  * dune-configurator = 2.8.1 → result = 1.3 → jbuilder (>= 1.0+beta11 & < 1.0+beta19) → ocamlfind < 1.8.1 → graphics = 5.1.1
  * ocamlfind = 1.8.1 → graphics = 5.1.0 → dune-configurator = 2.8.1 → result = 1.3 → jbuilder (>= 1.0+beta11 & < 1.0+beta19)
Summary: out of 17092 packages (3210 distinct names)
- 32 packages part of dependency cycles

However this should not appear, as opam install --update-invariant rightfully points out:

$ opam install graphics.5.1.0 dune-configurator.2.8.1 result.1.3 jbuilder.1.0+beta11 ocamlfind.1.8.0 --update-invariant
[WARNING] Opam package conf-ncurses.1 depends on the following system package that can no longer be found: ncurses-dev
The following dependencies couldn't be met:
  - dune-configurator → csexp >= 1.3.0 → result >= 1.5

Is there a bug in the cycle detection by any chance?


opam version: 2.1.0~beta4

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions