Skip to content
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

Fix #9815: fix caching for quick-jobs CI (XDG, cache keys) (backport #9845) #10041

Merged
merged 11 commits into from
May 23, 2024

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented May 21, 2024

Fix #9815:

  • Cache ~/.local/state/cabal instead of ~/.cabal/store
  • ~/.local/bin is used instead of ~/.cabal/bin and is already in the PATH
    (verify this by calling alex after installing it)

As I am passing by:

  • bump cache action to v4
  • double-quote $USER to keep actionlint happy
  • move if from shell-level to job-level
  • allow newest alex

UPDATE: This PR has been extended to

  • use preinstalled GHC and Cabal in this workflow (saves 90sec on each job)
  • clear the remains of the lexer goal in the Makefile (was removed in Add alex to build-tool-depends remove separate code gen #8980)
  • while I am add it, use .PHONY systematically in Makefile
  • fix caching for the quick-jobs
    • Use key from the build plan where possible
    • Use daily key for the doctest job
  • update a generated file to make "Meta checks" pass

This is an automatic backport of pull request #9845 done by [Mergify](https://mergify.com).

Fix #9815:
- Cache `~/.local/state/cabal` instead of `~/.cabal/store`
- `~/.local/bin` is used instead of `~/.cabal/bin` and is already in the PATH
  (verify this by calling `alex` after installing it)

As I am passing by:
- bump cache action to v4
- double-quote `$USER` to keep actionlint happy
- move `if` from shell-level to job-level
- allow newest `alex`

(cherry picked from commit e916cb5)
The `lexer` target was removed in
#8980

(cherry picked from commit e600087)
(cherry picked from commit 56426e4)
Not sure why this was not up to date on master and still CI passed.
Maybe the content of this file is dependent on the GHC version we are
using to build the `get-cabal-macros` tool?

(cherry picked from commit 947860a)
@Mikolaj
Copy link
Member

Mikolaj commented May 23, 2024

This is mutually CI-blocking with #10043 so, if nobody objects, let's merge this manually with red CI.

@ulysses4ever
Copy link
Collaborator

I think merging the other one (#10043) manually is better because that one is simpler.

@ulysses4ever
Copy link
Collaborator

Hopefully, my manual conflict resolution went well...

@ulysses4ever ulysses4ever added the squash+merge me Tell Mergify Bot to squash-merge label May 23, 2024
@ulysses4ever
Copy link
Collaborator

@mergify rebase

Copy link
Contributor Author

mergify bot commented May 23, 2024

rebase

❌ Base branch update has failed

Git reported the following error:

Rebasing (1/9)
Auto-merging .github/workflows/quick-jobs.yml
CONFLICT (content): Merge conflict in .github/workflows/quick-jobs.yml
error: could not apply 387c17d2f... Fix #9815: switch quick-jobs CI to XDG
hint: Resolve all conflicts manually, mark them as resolved with
hint: "git add/rm <conflicted_files>", then run "git rebase --continue".
hint: You can instead skip this commit: run "git rebase --skip".
hint: To abort and get back to the state before "git rebase", run "git rebase --abort".
Could not apply 387c17d2f... Fix #9815: switch quick-jobs CI to XDG

@mergify mergify bot merged commit f2999b3 into 3.12 May 23, 2024
49 checks passed
@mergify mergify bot deleted the mergify/bp/3.12/pr-9845 branch May 23, 2024 18:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport squash+merge me Tell Mergify Bot to squash-merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants