Can't stack build because of bytestring-progress / terminal-progress-bar incompatibility

Create issue
Issue #58 new
John Lee created an issue

Seems like arbtt somehow switched to a newer terminal-progress-bar even though bytestring-progress depends on an earlier version of that library:

https://github.com/acw/bytestring-progress/blob/fd1da00d4f63bed9ea6d8bd324336e51dfa7238d/bytestring-progress.cabal#L32

I've tried shuffling those dependencies around in various ways but have so far been unable to build using stack.

Here's the output I get:

```$ stack build

Error: While constructing the build plan, the following exceptions were encountered:

In the dependencies for arbtt-0.10.2: terminal-progress-bar-0.2 from stack configuration does not match >=0.4 && <0.5 (latest matching version is 0.4.0.1) needed since arbtt is a build target.

Some different approaches to resolving this:

  • Set 'allow-newer: true' in /home/john/.stack/config.yaml to ignore all version constraints and build anyway.

  • Consider trying 'stack solver', which uses the cabal-install solver to attempt to find some working build configuration. This can be convenient when dealing with many complicated constraint errors, but results may be unpredictable.

  • Recommended action: try adding the following to your extra-deps in /home/john/dev/arbtt/stack.yaml:

terminal-progress-bar-0.4.0.1@sha256:ef97018e0a6cf496e2c14f93f29e0c343ff3ffee647505f0fa01e310983a9723

Plan construction failed. ```

Comments (3)

  1. nomeata repo owner

    Which version of arbtt are you trying to build. The one in git?

    And can you build with cabal? Or can you not build at all?

  2. John Lee reporter

    Yes, current git: 6bb0d0b

    I went back to an earlier git revision and was able to build and run that using stack.

    I haven't tried using cabal. I guess because 1. I wanted to make a small change and 2. It seems like the advice for some years has been "use stack". Especially since my Haskell is very limited, I'm wary of learning anything about another build system: for example, I don't even happen to remember whether "cabal install" will keep arbtt strictly separate from other software, nor whether it will insist on installing it in some particular directory. If I'm honest, if I didn't know stack, I might not even be trying to use arbtt, for that reason.

  3. nomeata repo owner

    Problem is that I don’t use stack, and I know little about it :-/ Interestingly, according to https://travis-ci.org/nomeata/arbtt this builds with stack.

    Does this work for you?

    RESOLVER="$(HEAD -S https://www.stackage.org/$STACK|grep HEAD|tail -n1|cut -d/ -f4)"
    stack setup --resolver $RESOLVER
    echo "resolver: $RESOLVER" > stack.yaml
    stack solver --update-config
    stack build
    

    I should maybe start providing static executables for arbtt, as I started to do for a different project of mine recently.

  4. Log in to comment