Skip to content

haskell.packages.ghc9122.cabal2nix-unstable: fix build#400177

Merged
maralorn merged 3 commits intoNixOS:haskell-updatesfrom
wolfgangwalther:haskell-cabal2nix-ghc9122
Apr 23, 2025
Merged

haskell.packages.ghc9122.cabal2nix-unstable: fix build#400177
maralorn merged 3 commits intoNixOS:haskell-updatesfrom
wolfgangwalther:haskell-cabal2nix-ghc9122

Conversation

@wolfgangwalther
Copy link
Contributor

Dependencies build now, but the test-suite of cabal2nix itself fails with this:

Building test suite 'regression-test' for cabal2nix-2.20.0...
[1 of 1] Compiling Main             ( test/Main.hs, dist/build/regression-test/regression-test-tmp/Main.o )
test/Main.hs:77:6: error: [8;;https://errors.haskell.org/messages/GHC-83865GHC-838658;;]
    • Couldn't match expected type: IO GenericPackageDescription
                  with actual type: Distribution.Utils.Path.SymbolicPath
                                      Distribution.Utils.Path.Pkg Distribution.Utils.Path.File
                                    -> IO GenericPackageDescription
    • Probable cause: ‘readGenericPackageDescription’ is applied to too few arguments
      In the first argument of ‘(>>=)’, namely
        ‘readGenericPackageDescription silent cabalFile’
      In the fifth argument of ‘goldenVsFileDiff’, namely
        ‘(readGenericPackageDescription silent cabalFile
            >>= writeFileLn nixFile . prettyShow . cabal2nix)’
      In a stmt of a 'do' block:
        goldenVsFileDiff
          nixFile (\ ref new -> ["diff", "-u", ref, ....]) goldenFile nixFile
          (readGenericPackageDescription silent cabalFile
             >>= writeFileLn nixFile . prettyShow . cabal2nix)
   |
77 |     (readGenericPackageDescription silent cabalFile >>= writeFileLn nixFile . prettyShow . cabal2nix)
   |      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

test/Main.hs:77:43: error: [8;;https://errors.haskell.org/messages/GHC-83865GHC-838658;;]
    • Couldn't match type: [Char]
                     with: Maybe
                             (Distribution.Utils.Path.SymbolicPath
                                Distribution.Utils.Path.CWD
                                (Distribution.Utils.Path.Dir Distribution.Utils.Path.Pkg))
      Expected: Maybe
                  (Distribution.Utils.Path.SymbolicPath
                     Distribution.Utils.Path.CWD
                     (Distribution.Utils.Path.Dir Distribution.Utils.Path.Pkg))
        Actual: String
    • In the second argument of ‘readGenericPackageDescription’, namely
        ‘cabalFile’
      In the first argument of ‘(>>=)’, namely
        ‘readGenericPackageDescription silent cabalFile’
      In the fifth argument of ‘goldenVsFileDiff’, namely
        ‘(readGenericPackageDescription silent cabalFile
            >>= writeFileLn nixFile . prettyShow . cabal2nix)’
   |
77 |     (readGenericPackageDescription silent cabalFile >>= writeFileLn nixFile . prettyShow . cabal2nix)

Things done

  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • Fits CONTRIBUTING.md.

Add a 👍 reaction to pull requests you find important.

@github-actions github-actions bot added the 6.topic: haskell General-purpose, statically typed, purely functional programming language label Apr 19, 2025
@nix-owners nix-owners bot requested review from maralorn and sternenseemann April 19, 2025 21:01
@github-actions github-actions bot added 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux. labels Apr 19, 2025
@sternenseemann
Copy link
Member

I personally don't really think it's worth / urgent working around these test suite problem?! I'd rather wait for 9.12.3 or look into it in the next cycle.

The cabal2nix failure is a good shout, need to get on compat with the new Cabal in the next days.

@wolfgangwalther
Copy link
Contributor Author

I personally don't really think it's worth / urgent working around these test suite problem?! I'd rather wait for 9.12.3 or look into it in the next cycle.

Yeah, no objection. I just wanted to get cabal2nix to build, but as long as it's failing we don't need to merge these fixes either.

@wolfgangwalther wolfgangwalther force-pushed the haskell-cabal2nix-ghc9122 branch from e76819c to a7ab1a4 Compare April 23, 2025 16:33
@wolfgangwalther wolfgangwalther changed the title haskell.packages.ghc9122.cabal2nix: fix dependencies haskell.packages.ghc9122.cabal2nix: fix build Apr 23, 2025
@github-actions github-actions bot added 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-linux: 1 This PR causes 1 package to rebuild on Linux. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. and removed 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 0 This PR does not cause any packages to rebuild on Linux. labels Apr 23, 2025
@maralorn
Copy link
Member

Nice, anything holding this back now?

@wolfgangwalther wolfgangwalther marked this pull request as ready for review April 23, 2025 21:16
@wolfgangwalther
Copy link
Contributor Author

anything holding this back now?

Not for me!

Copy link
Member

@maralorn maralorn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@maralorn maralorn merged commit 062c56e into NixOS:haskell-updates Apr 23, 2025
42 of 45 checks passed
@wolfgangwalther wolfgangwalther deleted the haskell-cabal2nix-ghc9122 branch April 23, 2025 21:32
@wolfgangwalther wolfgangwalther changed the title haskell.packages.ghc9122.cabal2nix: fix build haskell.packages.ghc9122.cabal2nix-unstable: fix build Apr 23, 2025
@wolfgangwalther
Copy link
Contributor Author

Uhm, I guess I forgot to check the build output. In fact cabal2nix doesn't build, yet here. That's because I only updated the -unstable version, but that doesn't change the version 2.20 used in haskell.packages.ghc9122.cabal2nix. Fixed the PR title accordingly ;).

The hydra build for haskell.packages.ghc9122.cabal2nix will only succeed once we make a release and the next bump.

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 10.rebuild-darwin: 1-10 This PR causes between 1 and 10 packages to rebuild on Darwin. 10.rebuild-darwin: 1 This PR causes 1 package to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 10.rebuild-linux: 1 This PR causes 1 package to rebuild on Linux.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants