ocaml / ocaml/dune

Dune finds non existing library conflict without (implicit_transitive_deps false)

Open
#3,913 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

build needs-investigation
Dominant language
OCaml
Stars
1.9k
Forks
500
Avg merge
15h 17m
Merged PRs (30d)
287

Description

Expected Behavior

Dune should not fail due to the conflict, even with (implicit_transitive_deps true).

Actual Behavior

In a very specific context, here on tezos/tezos, dune seems to find a conflict between a vendored library and the opam installed counterpart, even though the package I'm trying to build with dune build -p doesn't not directly depend on said library.
Setting (implicit_transitive_deps false) fixes the issue.

Reproduction

I haven't managed to reproduce this behavior in a smaller example but I wrote down reproduction instructions here:
https://github.com/NathanReb/tezos/tree/branch-v8.0-rc1

Follow the instruction in the README to reproduce the bug.

Specifications

  • Version of dune (output of dune --version): 2.7.1
  • Version of ocaml (output of ocamlc --version): 4.09.1
  • Operating system (distribution and version): Debian GNU/Linux bullseye/sid

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by following the reproduction instructions in the linked tezos branch README and run the specified dune build -p command with Dune 2.7.1 and OCaml 4.09.1. Investigate why implicit_transitive_deps true reports a conflict for a library that is not a direct dependency, then verify that the build no longer fails while preserving the behavior of implicit_transitive_deps false.

Written by the indexing model from the issue text.

Assessment

Tech stack
ocaml
Domain
build-system
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.