ocaml / opam-repository

Main public package repository for opam, the source package manager of OCaml.
https://opam.ocaml.org
Creative Commons Zero v1.0 Universal
516 stars 1.12k forks source link

URGENT: OPAM Forgets Dependencies #865

Closed dsheets closed 11 years ago

dsheets commented 11 years ago

Something about the presence of e06693a330374013b3d40750eacc9dfb8fa8a6c8 in the opam-repository causes OPAM to forget dependencies in totally unrelated packages. Subsequently, OPAM will fail with ocamlfind dependency errors in very strange ways because it does not order the packages correctly.

I found this commit with a git bisect looking at the output of the command opam install async_inotify.109.15.00. This OPAM bug appears to be present in both 1.0.0 and the master branch.

Here's what a 'good' output looks like:

$ opam install async_inotify.109.15.00
The following actions will be performed:
 - install ocamlfind.1.3.3 [required by async_inotify]
 - install herelib.109.15.00 [required by async_inotify]
 - install inotify.1.2 [required by async_inotify]
 - install ounit.1.1.2 [required by async_inotify]
 - install pcre-ocaml.7.0.2 [required by async_inotify]
 - install pipebang.109.28.00 [required by async_inotify]
 - install res.4.0.3 [required by async_inotify]
 - install type_conv.109.28.00 [required by async_inotify]
 - install bin_prot.109.30.00 [required by async_inotify]
 - install comparelib.109.27.00 [required by async_inotify]
 - install fieldslib.109.20.00 [required by async_inotify]
 - install pa_ounit.109.27.00 [required by async_inotify]
 - install sexplib.109.20.00 [required by async_inotify]
 - install variantslib.109.15.00 [required by async_inotify]
 - install custom_printf.109.27.00 [required by async_inotify]
 - install core_kernel.109.31.00 [required by async_inotify]
 - install core.109.31.00 [required by async_inotify]
 - install async_core.109.30.00 [required by async_inotify]
 - install textutils.109.24.00 [required by async_inotify]
 - install async_unix.109.31.00 [required by async_inotify]
 - install core_extended.109.31.00 [required by async_inotify]
 - install async_extra.109.31.00 [required by async_inotify]
 - install async.109.31.00 [required by async_inotify]
 - install async_find.109.15.00 [required by async_inotify]
 - install async_inotify.109.15.00
25 to install | 0 to reinstall | 0 to upgrade | 0 to downgrade | 0 to remove
Do you want to continue ? [Y/n] n

And here's what a bad output looks like:

$ opam install async_inotify.109.15.00
The following actions will be performed:
 - install comparelib.109.27.00
 - install ocamlfind.1.3.3 [required by async, async_core, core_extended, fieldslib, inotify, ounit]
 - install async_extra.109.31.00
 - install bin_prot.109.30.00
 - install async_inotify.109.15.00
 - install async_find.109.15.00
 - install custom_printf.109.27.00
 - install sexplib.109.20.00
 - install pa_ounit.109.27.00
 - install type_conv.109.28.00
 - install pipebang.109.28.00
 - install variantslib.109.15.00
 - install textutils.109.24.00
 - install herelib.109.15.00
 - install async_core.109.30.00
 - install fieldslib.109.20.00
 - install inotify.1.2
 - install ounit.1.1.2
 - install pcre-ocaml.7.0.2 [required by core_extended]
 - install res.4.0.3 [required by async, core_extended]
 - install core_kernel.109.31.00 [required by async, core_extended]
 - install core.109.31.00 [required by async, core_extended]
 - install async_unix.109.31.00 [required by async]
 - install core_extended.109.31.00
 - install async.109.31.00
25 to install | 0 to reinstall | 0 to upgrade | 0 to downgrade | 0 to remove
Do you want to continue ? [Y/n] n
dsheets commented 11 years ago

Specifically, the issue is with the depopts clause (and it's not the lack of newline).

dsheets commented 11 years ago

Even more specifically, the issue appears to be with the version constraint on coq not matching any version string in the repository.