Giter VIP home page Giter VIP logo

Comments (9)

emillon avatar emillon commented on September 22, 2024 2

the issue here is that do_common will read gsl_include.sexp at init time (IO happens outside of a function), so running do_sf.exe will read that file. The correct fix is to add gsl_include.sexp as a dependency to force an ordering in the dependency graph. otherwise, this will depend on the order in which the modules of the library are built: if Sf is built before Cdf or Const, it will fail. It's true that -j 1 will prevent rules from firing in parallel but dune can not guarantee anything about the order in which the modules are built. This has probably changed several times between dune versions.

from opam-repository.

kit-ty-kate avatar kit-ty-kate commented on September 22, 2024

Mmh, I can't reproduce it locally and it was supposed to be fixed by #19244
Is this deterministically reproducible with your setup?

from opam-repository.

glondu avatar glondu commented on September 22, 2024

It is strange. It seems deterministically reproducible when I (try to) install all these packages (except ppx_globalize) at once in an empty 4.13.1 switch. However, installing orpie alone in an empty switch, or installing it after all the others are installed, succeds.

from opam-repository.

kit-ty-kate avatar kit-ty-kate commented on September 22, 2024

I've tried to reproduce locally with all those packages at once but it worked for me

from opam-repository.

glondu avatar glondu commented on September 22, 2024

I just remembered that I applied a patch in Debian. A similar fix was applied upstream, but not released yet. A kind of race condition does exist in the package in its current form. Maybe the patch should be applied in the opam package as well?

from opam-repository.

kit-ty-kate avatar kit-ty-kate commented on September 22, 2024

I was under the impression that dune build -j1 (from #19244) would be an alternative fix for this. Does -j not make the build order deterministic in dune? cc dune devs @rgrinberg @emillon @Leonidas-from-XIV @gridbugs

from opam-repository.

kit-ty-kate avatar kit-ty-kate commented on September 22, 2024

This has probably changed several times between dune versions.

ah, I see. Very unfortunate. Thanks a lot!

@glondu could you open a PR to add your patch to the relevant versions? (and maybe restore "-j" jobs at the same time)
@mmottl could you do a release when you have some spare time?

from opam-repository.

emillon avatar emillon commented on September 22, 2024

I mean, on the other side I can't tell you for sure it has changed, but the build engine has changed enough that I'd say this kind of thing is likely to have changed.

from opam-repository.

rgrinberg avatar rgrinberg commented on September 22, 2024

With the introduction of background threads, not even -j 1 guarantees a deterministic order of actions. There's some environment variables to disable the various background threads if this desirable.

from opam-repository.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.