[opam-devel] pin and constraints

Thomas Leonard talex5 at gmail.com
Thu Jun 18 10:10:37 BST 2015


On 18 June 2015 at 00:10, Daniel Bünzli <daniel.buenzli at erratique.ch> wrote:
> Hello,
>
> I thought that a pin would satisfy any constraint. This doesn't seem to be the case for example here I have:
>> opam pin list | grep "uucp\|uuseg"
> uucp.0.9.1 git /Users/dbuenzli/sync/repos/uucp#HEAD
> uuseg.0.8.0 git /Users/dbuenzli/sync/repos/uuseg
>
> Now in my uuseg pin's opam file I have the constraint "uucp" {>= "1.0.0"} if I do a `opam reinstall uuseg` I get:
>
> The following dependencies couldn't be met:
> - uuseg -> uucp >= 1.0.0
> Your request can't be satisfied:
>
> - uucp>=1.0.0 is not available because the package is pinned to /Users/dbuenzli/sync/repos/uucp#HEAD, version 0.9.1.
>
> which is somehow annoying. Is there any way out from that situation ?

You can add whatever version you want to the pin, e.g.

  opam pin add foo.1.2.3 ...

or

  opam pin add foo.dev ...


-- 
Dr Thomas Leonard        http://roscidus.com/blog/
GPG: DA98 25AE CAD0 8975 7CDA  BD8E 0713 3F96 CA74 D8BA


More information about the opam-devel mailing list