Skip to content

haskellPackages.ghc: 8.10.7 -> 9.0.2#160733

Merged
maralorn merged 308 commits intomasterfrom
haskell-updates
Mar 30, 2022
Merged

haskellPackages.ghc: 8.10.7 -> 9.0.2#160733
maralorn merged 308 commits intomasterfrom
haskell-updates

Conversation

@sternenseemann
Copy link
Copy Markdown
Member

@sternenseemann sternenseemann commented Feb 18, 2022

This Merge

This is not your usual haskell-updates rotation! We're bumping the default GHC by one major release.

This branch is being continually built and tested by hydra at https://hydra.nixos.org/jobset/nixpkgs/haskell-updates. You may be able to find an up-to-date Hydra build report at cdepillabout/nix-haskell-updates-status.

Since this is quite a big change, cleaning up regressions and merging may take longer than usual.

haskellPackages Workflow Summary

Our workflow is currently described in pkgs/development/haskell-modules/HACKING.md.

The short version is this:

  • We regularly update the Stackage and Hackage pins on haskell-updates (normally at the beginning of a merge window).
  • The community fixes builds of Haskell packages on that branch.
  • We aim at at least one merge of haskell-updates into master every two weeks.
  • We only do the merge if the mergeable job is succeeding on hydra.
  • If a maintained package is still broken at the time of merge, we will only merge if the maintainer has been pinged 7 days in advance. (If you care about a Haskell package, become a maintainer!)

This is the follow-up to #160015. Come to #haskell:nixos.org if you have any questions.

Rough order of business:

  • Update GHC
  • Switch to Stackage Nightly, update hackage2nix config
  • Fix evaluation of package sets
    • 8.8.4
    • 8.10.7
    • 9.0.2
    • 9.2.1
  • Try to get all packages that are new dependencies and marked as broken to work (see eval errors tab)
  • Check for and fix Regressions
  • Figure out regressions in 8.10.7 set and what to try and keep working (Suggestions on the how very welcome!)
    • Enable all available plugins in HLS for GHC < 9.0.2
  • Empty broken.yaml and see what has fixed itself

Closes #163329

@github-actions github-actions bot added the 6.topic: haskell General-purpose, statically typed, purely functional programming language label Feb 18, 2022
@ofborg ofborg bot added 8.has: clean-up This PR removes packages or removes other cruft 8.has: package (new) This PR adds a new package labels Feb 20, 2022
@ofborg ofborg bot requested a review from DamienCassou February 20, 2022 11:36
@ofborg ofborg bot added 10.rebuild-darwin: 501+ This PR causes many rebuilds on Darwin and should normally target the staging branches. 10.rebuild-darwin: 5001+ This PR causes many rebuilds on Darwin and must target the staging branches. 10.rebuild-linux: 501+ This PR causes many rebuilds on Linux and should normally target the staging branches. 10.rebuild-linux: 5001+ This PR causes many rebuilds on Linux and must target the staging branches. labels Feb 20, 2022
@sternenseemann sternenseemann linked an issue Feb 20, 2022 that may be closed by this pull request
@DamienCassou DamienCassou removed their request for review February 21, 2022 08:17
@ofborg ofborg bot requested a review from DamienCassou February 21, 2022 10:19
@DamienCassou DamienCassou removed their request for review February 21, 2022 11:19
@ofborg ofborg bot requested a review from DamienCassou February 22, 2022 00:23
@DamienCassou DamienCassou removed their request for review February 22, 2022 06:55
@nixos-discourse
Copy link
Copy Markdown

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:

https://discourse.nixos.org/t/call-for-contributions-we-are-updating-to-ghc-9-0-2/17844/1

@sternenseemann
Copy link
Copy Markdown
Member Author

sternenseemann commented Feb 22, 2022

We are updating to Stackage Nightly again! The main changes are GHC 9.0.2 and aeson 2.0. Naturally, this has been quite a big disruption and we'd appreciate help from package maintainers getting the most important packages to work again.


haskell-updates build report from hydra

evaluation 1745231 of nixpkgs commit eb29acf as of 2022-02-22 06:18 UTC

🔴 Branch not mergeable

  • mergeable jobset failed.
  • maintained jobset failed.

Build summary

Platform Failed ❌ DependencyFailed ❗ TimedOut ⌛🚫 Success ✔️
aarch64-linux 📱 722 929 4 5590
x86_64-darwin 🍎 626 1410 2 5142
x86_64-linux 🐧 708 927 1 5641

Maintained packages with build failure

Maintained packages with failed dependency

Full build report.

@turboMaCk
Copy link
Copy Markdown
Member

I don't think we could be able to update elmPackages.elm to build with 9.x.x We will need to explicitly set ghc 8.10.7 there.

@sternenseemann
Copy link
Copy Markdown
Member Author

I don't think we could be able to update elmPackages.elm to build with 9.x.x We will need to explicitly set ghc 8.10.7 there.

That's a good hint, thanks! Also has the benefit that it'll enforce some base packages to work in the 8.10.7 set, so it'll stay usable longer hopefully. Do you know if there's any plans to migrate to 9.0 at some point on upstream's side?

This commit has been generated by maintainers/scripts/haskell/update-hackage.sh
This commit has been generated by maintainers/scripts/haskell/update-stackage.sh
This commit has been generated by maintainers/scripts/haskell/regenerate-hackage-packages.sh
@turboMaCk
Copy link
Copy Markdown
Member

turboMaCk commented Feb 22, 2022

@sternenseemann unfortunately compiler work is rather opaque. The last version of compiler was released in 2019 https://github.com/elm/compiler/releases/tag/0.19.1 and the most recent information from the end of last year is that new version won't be ready soon even though it's being worked on https://discourse.elm-lang.org/t/status-update-3-nov-2021/7870

I think pinning the ghc 8 for elm will be more reasonable than trying to patch around it. I can try to look into this in separate PR if you want me to since fixing ghc just for elm can be done and merged separately.

edit: also we build elm as static binary so I think there is no significant disadvantage to decoupling it from default Haskell package set.

@sternenseemann
Copy link
Copy Markdown
Member Author

@turboMaCk That'd be appreciated! I tried the following patch locally just now and it seems some dependencies of elm will need looking at still (e.g. currently it's failing of something claiming to not support attoparsec 0.14):

diff --git a/pkgs/development/compilers/elm/default.nix b/pkgs/development/compilers/elm/default.nix
index 149d8115054..e302ef51809 100644
--- a/pkgs/development/compilers/elm/default.nix
+++ b/pkgs/development/compilers/elm/default.nix
@@ -7,7 +7,7 @@ let
 
   fetchElmDeps = pkgs.callPackage ./fetchElmDeps.nix { };
 
-  hsPkgs = self: pkgs.haskellPackages.override {
+  hsPkgs = self: pkgs.haskell.packages.ghc8107.override {
     overrides = self: super: with pkgs.haskell.lib.compose; with lib;
     let elmPkgs = rec {
       elm = overrideCabal (drv: {

@turboMaCk
Copy link
Copy Markdown
Member

@sternenseemann no worries I can tackle that independently of the rest of the work. It will be more sane way to proceed with this anyway. You can skip elm for now I'll report the status back in here once I know more.

taffybar's GHC 9.0 patches are unreleased and not easy to backport.
@maralorn
Copy link
Copy Markdown
Member

maralorn commented Mar 28, 2022

Dear all,

as of today the following builds are still broken. As promised I will not merge this PR until Tuesday evening (which permitting for timezone differences means a merge on Wednesday.)

Nevertheless I will go ahead and mark failing builds broken now. If any fixes get merged in the next 48h we will simply remove the broken flag again. The list of builds I am marking broken is here.

haskell-updates build report from hydra

evaluation 1751708 of nixpkgs commit 6da0212 as of 2022-03-28 15:10 UTC

🟡 Potential issues

  • maintained jobset failed.

Build summary

Platform Failed ❌ DependencyFailed ❗ TimedOut ⌛🚫 Unfinished ⏳ Success ✔️
aarch64-linux 📱 58 101 8 1 6190
x86_64-linux 🐧 37 74 5 10 6268

Maintained packages with build failure

Maintained packages with failed dependency

Unmaintained packages with build failure

47 job(s)

Unmaintained packages with failed dependency

101 job(s)

Top 50 broken packages, sorted by number of reverse dependencies

50 job(s)

amazonka-core ⤴️ 186
gogol-core ⤴️ 184
haskell98 ⤴️ 153
enumerator ⤴️ 56
derive ⤴️ 48
amazonka ⤴️ 44
accelerate ⤴️ 42
parseargs ⤴️ 42
syb-with-class ⤴️ 42
MonadCatchIO-transformers ⤴️ 41
data-lens ⤴️ 33
rank1dynamic ⤴️ 33
distributed-static ⤴️ 31
language-ecmascript ⤴️ 31
distributed-process ⤴️ 30
ip ⤴️ 29
iteratee ⤴️ 29
jmacro ⤴️ 29
autodocodec ⤴️ 28
mmsyn3 ⤴️ 27
crypto-numbers ⤴️ 26
either-unwrap ⤴️ 25
validity-aeson ⤴️ 25
web-routes-th ⤴️ 24
autodocodec-schema ⤴️ 23
crypto-pubkey ⤴️ 23
ixset-typed ⤴️ 23
autodocodec-yaml ⤴️ 22
haskelldb ⤴️ 22
wxdirect ⤴️ 22
amazonka-s3 ⤴️ 21
mmsyn2 ⤴️ 21
subG ⤴️ 21
userid ⤴️ 21
wxc ⤴️ 21
biocore ⤴️ 20
sydtest ⤴️ 20
wxcore ⤴️ 20
attoparsec-enumerator ⤴️ 19
bytestring-show ⤴️ 19
fay ⤴️ 19
harp ⤴️ 19
hsx2hs ⤴️ 19
ixset ⤴️ 19
wx ⤴️ 19
asn1-data ⤴️ 18
dbus-core ⤴️ 18
gtksourceview2 ⤴️ 18
ukrainian-phonetics-basic ⤴️ 18
HGamer3D-Data ⤴️ 17

⤴️: The number of packages that depend (directly or indirectly) on this package (if any). If two numbers are shown the first (lower) number considers only packages which currently have enabled hydra jobs, i.e. are not marked broken. The second (higher) number considers all packages.

Report generated with maintainers/scripts/haskell/hydra-report.hs

maralorn and others added 4 commits March 28, 2022 17:56
This commit has been generated by maintainers/scripts/haskell/mark-broken.sh
Luckily, all build failures where just related to type checking changes
in GHC 9.0 (and maybe base changes?), so we can just use GHC 8.10.7 with
the Stackage version of packages and keep Yi working. I feel like we
dodged a bullet here, as upstream maintenance doesn't seem to be too
proactive these days.
Possibly updating the compiler will make it possible to build it with
GHC 9.0.2 out of the box or patching it to work with it would be
trivial (only errors so far are whitespace-related), but I couldn't be
bothered at this time. Sadly the maintainer of the package has
disappeared since adding it.
@Profpatsch
Copy link
Copy Markdown
Member

I just released yarn2nix 0.10.1 https://hackage.haskell.org/package/yarn2nix which has support for aeson-2.0 (it’s been rebased onto this branch).

sternenseemann and others added 5 commits March 28, 2022 19:40
Cheese in a package update while keeping the old expression in
hackage-packages.nix, so we can avoid any regressions updating our
hackage snapshot might introduce.
pkgs.taffybar stays working because taffybar is marked unbroken in
configuration-ghc810x.nix
@sternenseemann
Copy link
Copy Markdown
Member Author

@rnhmjoj Seems like the pkgsStatic fix didn't last long: https://hydra.nixos.org/build/170015577. Not sure what broke it exactly. Only 8.10.7 seems to be affected, so it's maybe not the biggest deal.

@rnhmjoj
Copy link
Copy Markdown
Contributor

rnhmjoj commented Mar 29, 2022

@sternenseemann I tested native-bignum.ghc{902,922} but never integer-simple.ghc8107: in fact it has been broken since the beginning (a503a02). This is strange: the -fexternal-dynamic-refs trick seems to work for GHC ≥ 9 only, but in the tweag blog post they were most certainly using GHC 8.10.

Anyway, if the test failing is a problem you can replace 8.10 with 9.0.2 or remove the case altogether.

@sternenseemann
Copy link
Copy Markdown
Member Author

@rnhmjoj A if it's not a regression, we can probably just drop the case. If I recall correctly, you didn't alter the 8.10 expression which would explain it?

@rnhmjoj
Copy link
Copy Markdown
Contributor

rnhmjoj commented Mar 30, 2022

If I recall correctly, you didn't alter the 8.10 expression which would explain it?

Oh, you're right. I would change the test case to use GHC 9.0.2, then.

We should only make use of asserts to assert a property about the
*current* attribute in order to make it possible for downstream users to
change versions of packages: When a downstream user changes the package
an attribute points to, the assert is removed as the attribute is
swapped out, so asserting something about itself is okay. However, when
it asserts a property about another package, changing that other package
may break the package unexpectedly, with no better workaround then
passing in an empty `configurationCommon` overlay.

See also: #166425
@maralorn
Copy link
Copy Markdown
Member

Thank you, to everyone who contributed! This was much more work than we had expected.
Special thanks go to @sternenseemann who definitely did the largest number of commits on this one!

Enjoy your GHC 9.0 with all the updates!

@NorfairKing
Copy link
Copy Markdown
Contributor

NorfairKing commented Apr 4, 2022

Great job @maralorn and @sternenseemann !!

@jvanbruegge
Copy link
Copy Markdown
Contributor

Hi, I just stumbled across this. I maintain the naproche package which is a Haskell executable that broke with this update. But I was not notified and only saw it when trying to update my nixpkgs and seeing that isabelle does not build any more (because of its dependency on naproche).
Is there somewhere I need to register naproche so it will get caught here in the next round of updates? I fixed the issue now in upstream and created a PR to update the version in nixpkgs: #169400
Next time this could be done earlier

@Artturin
Copy link
Copy Markdown
Member

Artturin commented May 3, 2022

renaming the streamly_0_8_1_1 attribute to streamly broke some nix-env command because it was still used in configuration-darwin.nix
https://github.com/Mic92/nix-index-database/runs/6244309208?check_suite_focus=true

fix in #171438

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

6.topic: haskell General-purpose, statically typed, purely functional programming language 6.topic: nixos Issues or PRs affecting NixOS modules, or package usability issues specific to NixOS 8.has: changelog This PR adds or changes release notes 8.has: clean-up This PR removes packages or removes other cruft 8.has: documentation This PR adds or changes documentation 8.has: package (new) This PR adds a new package 10.rebuild-darwin: 501+ This PR causes many rebuilds on Darwin and should normally target the staging branches. 10.rebuild-darwin: 5001+ This PR causes many rebuilds on Darwin and must target the staging branches. 10.rebuild-linux: 501+ This PR causes many rebuilds on Linux and should normally target the staging branches. 10.rebuild-linux: 5001+ This PR causes many rebuilds on Linux and must target the staging branches.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Pandoc update to 2.17 haskellPackages.http2 not building on aarch64-darwin