-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add github actions for CI #91
Conversation
Strange, the pull-request didn't trigger the action in this repo... Perhaps it's a security issue ? |
a8ad865
to
3945cf8
Compare
Ok, needed to add "pull_request". |
Doesn't build with ghc 9.2, some constraints would have to be relaxed I think. See here: https://github.com/miguel-negrao/essence-of-live-coding/runs/4780786282?check_suite_focus=true |
Ok, it builds with cabal with 8.8 . I'll add that. |
Does adding GHC 9.0 work? |
No. I think the constraints on some packages probably need to be changed. Check the logs here: https://github.com/miguel-negrao/essence-of-live-coding/runs/4780786282?check_suite_focus=true |
Ok, I have 8.8.4 and 8.10.7 working: https://github.com/miguel-negrao/essence-of-live-coding/runs/4781303652?check_suite_focus=true |
f365388
to
97e4328
Compare
9.0.2 also fails, with problems in eolc code: https://github.com/turion/essence-of-live-coding/runs/4781676336?check_suite_focus=true I suggest for now start with 8.8 and 8.10. |
97e4328
to
0e526e7
Compare
Added a cabal flag to show the result of the tests |
.github/workflows/ci.yml
Outdated
uses: freckle/stack-cache-action@v1.0.1 | ||
with: | ||
stack-yaml: stack.yaml | ||
- name: Stack build and test (lts-18.21 - ghc 8.10.7) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does it make sense to have a matrix over different stack versions as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't have a lot insight into that, but I don't think it is needed. If we did that then we should also have a matrix over cabal versions. For instance on this repo they use a single cabal and stack version each. Our stack files don't use anything advanced only available on the latest version, it should work fine on older versions I believe, but if we want to be sure we can always run it once with a matrix over stack and see what is the result.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I actually meant different stackage versions (i.e. not only lts-18.21, but also the older ones).
0e526e7
to
99d9f14
Compare
There's an issue with the version of base in the |
4c26fb3
to
d80af4e
Compare
I think the issue is that we need a different cabal.project and cabal.project.freeze file for each version of ghc, similarly to stack. That can be done as explained here (edit: changed the linked, copy-past problem). Will try to look at it tomorrow. Curiously the freeze files can be created from stackage for the required ghc version. |
Maybe I was wrong about the freeze files then. Maybe they simply shouldn't be committed. I asked that on reddit now: https://www.reddit.com/r/haskell/comments/s4fcoy/should_i_commit_cabal_freeze_files_to_my_repo/? For now, is it possible to simply overwrite the freeze file by calling
Hmm, that issue doesn't seem to talk about |
2eb369f
to
b4aaf6f
Compare
Sorry, the link was wrong, copy-paste issue, fixed it. The freeze file will also pin the base version to the exact version used by the solver, therefore it will only work with a specific version of ghc. I've added two project and freeze files for the two ghc versions, and they build correctly. I didn't add a cabal.project.freeze file because then people trying to build the library with Does this look good ? |
6a0b954
to
afe7003
Compare
Squashed commits and cache seems to be working. The eolc libraries are always rebuilt but the dependencies are not. |
The freeze files were created on my machine with cabal freeze --project-file=cabal.project.8.8.4 -w ghc-8.8.4
cabal freeze --project-file=cabal.project.8.10.7 -w ghc-8.10.7 |
afe7003
to
5d3bdc5
Compare
Removed |
Currently the CI doesn't build on windows or macos as we would need to conditionally build |
Yes, definitely! |
Ideally, there would only be one |
- Build and test with cabal and stack for GHC 8.8.4 and 8.10.7 - update vivid to 0.5.2.0 in order to build with latest hashable. This version adds an Eq instance for SynthDef, which therefore doesn't need to be defined in this repo.
5d3bdc5
to
6155a35
Compare
Done. |
Awesome! |
Solves #87