tidalcycles / Tidal

Pattern language
http://tidalcycles.org/
GNU General Public License v3.0
2.22k stars 254 forks source link

`tidal-parse` not resolving in Stack #1069

Closed matthewkaney closed 7 months ago

matthewkaney commented 8 months ago

Another build issue, this time with the Stack resolver.

Our CI action does a test run of Stack against the latest resolver version. As of Stackage releasing LTS Haskell 22.0, the version of Haskell got updated, which updated mtl, which broke tidal-parse because haskellish depends on an old version of mtl.

@yaxu, do you know anything about the Stack build/resolver and/or who might use it or have opinions on it? I don't know Stack at all, but is there a reason to not try and resolve it against a fixed version of LTS Haskell? ndr_brt (not tagging because I already chatting with them about it on Discord) did the last editing on the code in question, but doesn't remember any of the specifics.

@dktr0, do you depend on the Stack build of tidal-parse or have any thoughts on the mtl dependency issues? Estuary is the only major user of tidal-parse if I'm not mistaken.

The relevant error, for what's it worth:

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

In the dependencies for haskellish-0.3.2.1:
    mtl-2.3.1 from stack configuration does not match >=2.2.2 && <2.3  (latest matching version
              is 2.2.2)
    template-haskell-2.20.0.0 from stack configuration does not match >=2.10.0.0 && <2.20  (latest
                              matching version is 2.19.0.0)
needed due to tidal-parse-0.0.1 -> haskellish-0.3.2.1

In the dependencies for tidal-parse-0.0.1:
    mtl-2.3.1 from stack configuration does not match >=2.2.2 && <2.3  (latest matching version
              is 2.2.2)
needed since tidal-parse is a build target.

Some different approaches to resolving this:

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

  * Recommended action: try adding the following to your extra-deps
    in /home/runner/work/Tidal/Tidal/stack.yaml:

- mtl-2.2.2@sha256:1050fb71acd9f5d67da7d992583f5bd0eb14407b9dc7acc122af1b738b706ca3,2261
- template-haskell-2.19.0.0@sha256:3e06c10b5813e88[503](https://github.com/tidalcycles/Tidal/actions/runs/7545310193/job/20540624118#step:6:504)196093e094140c6871ae3703a12a70024da755820b4d1a,2723

Plan construction failed.
dktr0 commented 8 months ago

@mindofmatthew thanks for getting in touch about this. I've put out a 0.3.2.2 update of Haskellish that widens the bounds on template-haskell and mtl and appears to build just fine with LTS 22.8. I think it should now suffice just to change the haskellish reference in Tidal's top level stack.yaml to 0.3.2.2. (Estuary doesn't depend on a stack build of tidal-parse, though, FWIW.)

yaxu commented 7 months ago

@mindofmatthew I don't know too much about it either and don't use stack myself. I think it is good for tidal to compile against the latest LTS though. I maintain the tidal package on stackage which involves making sure tidal works with the particular set of hackage libraries in each stackage release (basically I get a github notification when a library version is bumped and I have to increase tidal's upper bounds for that dependency). One win from this is tidal eventually makes it to debian.