Skip to content

Commit

Permalink
Merge pull request #266708 from hercules-ci/haskell-releaser
Browse files Browse the repository at this point in the history
haskellPackages.releaser + other fixups
  • Loading branch information
maralorn committed Nov 10, 2023
2 parents 136a150 + e2d95f5 commit b75be5d
Show file tree
Hide file tree
Showing 8 changed files with 50 additions and 39 deletions.
44 changes: 22 additions & 22 deletions pkgs/development/haskell-modules/configuration-common.nix
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ with haskellLib;

self: super: {
# Make sure that Cabal 3.10.* can be built as-is
Cabal_3_10_2_0 = doDistribute (super.Cabal_3_10_2_0.override ({
Cabal_3_10_2_1 = doDistribute (super.Cabal_3_10_2_1.override ({
Cabal-syntax = self.Cabal-syntax_3_10_2_0;
} // lib.optionalAttrs (lib.versionOlder self.ghc.version "9.2.5") {
# Use process core package when possible
Expand All @@ -35,11 +35,11 @@ self: super: {
cabalInstallOverlay = cself: csuper:
{
# Needs to be upgraded compared to Stackage LTS 21
cabal-install-solver = cself.cabal-install-solver_3_10_1_0;
cabal-install-solver = cself.cabal-install-solver_3_10_2_1;
# Needs to be downgraded compared to Stackage LTS 21
resolv = cself.resolv_0_1_2_0;
} // lib.optionalAttrs (lib.versionOlder self.ghc.version "9.6") {
Cabal = cself.Cabal_3_10_2_0;
Cabal = cself.Cabal_3_10_2_1;
Cabal-syntax = cself.Cabal-syntax_3_10_2_0;
} // lib.optionalAttrs (lib.versionOlder self.ghc.version "9.4") {
# We need at least directory >= 1.3.7.0. Using the latest version
Expand All @@ -57,15 +57,15 @@ self: super: {
# not solvable short of recompiling GHC. Instead of adding
# allowInconsistentDependencies for all reverse dependencies of hspec-core,
# just upgrade to an hspec version without the offending dependency.
hspec-core = cself.hspec-core_2_11_6;
hspec-discover = cself.hspec-discover_2_11_6;
hspec = cself.hspec_2_11_6;
hspec-core = cself.hspec-core_2_11_7;
hspec-discover = cself.hspec-discover_2_11_7;
hspec = cself.hspec_2_11_7;

# hspec-discover and hspec-core depend on hspec-meta for testing which
# we need to avoid since it depends on ghc as well. Since hspec*_2_11*
# are overridden to take the versioned attributes as inputs, we need
# to make sure to override the versioned attribute with this fix.
hspec-discover_2_11_6 = dontCheck csuper.hspec-discover_2_11_6;
hspec-discover_2_11_7 = dontCheck csuper.hspec-discover_2_11_7;

# Prevent dependency on doctest which causes an inconsistent dependency
# due to depending on ghc which depends on directory etc.
Expand Down Expand Up @@ -194,7 +194,7 @@ self: super: {
# 2023-08-09: Jailbreak because of vector < 0.13
# 2023-11-09: don't check because of https://github.com/tweag/monad-bayes/pull/326
monad-bayes = dontCheck (doJailbreak (super.monad-bayes.override {
hspec = self.hspec_2_11_6;
hspec = self.hspec_2_11_7;
}));

# Disable tests failing on odd floating point numbers generated by QuickCheck 2.14.3
Expand Down Expand Up @@ -295,7 +295,7 @@ self: super: {

# Overriding the version pandoc dependency uses as the latest release has version bounds
# defined as >= 3.1 && < 3.2, can be removed once pandoc gets bumped by Stackage.
patat = super.patat.override { pandoc = self.pandoc_3_1_8; };
patat = super.patat.override { pandoc = self.pandoc_3_1_9; };

# http2 also overridden in all-packages.nix for mailctl.
# twain is currently only used by mailctl, so the .overrideScope shouldn't
Expand Down Expand Up @@ -498,7 +498,7 @@ self: super: {
structures = dontCheck super.structures;

# Requires alex >= 3.4
jacinda = super.jacinda.override { alex = self.alex_3_4_0_0; };
jacinda = super.jacinda.override { alex = self.alex_3_4_0_1; };

# Disable test suites to fix the build.
acme-year = dontCheck super.acme-year; # http://hydra.cryp.to/build/497858/log/raw
Expand Down Expand Up @@ -1176,7 +1176,7 @@ self: super: {
# stack-2.13.1 requires a bunch of the latest packages.
(drv: drv.overrideScope (hfinal: hprev: {
ansi-terminal = hprev.ansi-terminal_1_0; # needs ansi-terminal >= 1.0
crypton = hprev.crypton_0_33; # needs crypton >= 0.33
crypton = hprev.crypton_0_34; # needs crypton >= 0.33
hedgehog = doJailbreak hprev.hedgehog; # has too strict version bound for ansi-terminal
hpack = hprev.hpack_0_36_0; # needs hpack == 0.36.0
http-client-tls = hprev.http-client-tls_0_3_6_3; # needs http-client-tls >= 0.3.6.2
Expand Down Expand Up @@ -1671,19 +1671,19 @@ self: super: {
servant-openapi3 = dontCheck super.servant-openapi3;

# Give latest hspec correct dependency versions without overrideScope
hspec_2_11_6 = doDistribute (super.hspec_2_11_6.override {
hspec-discover = self.hspec-discover_2_11_6;
hspec-core = self.hspec-core_2_11_6;
hspec_2_11_7 = doDistribute (super.hspec_2_11_7.override {
hspec-discover = self.hspec-discover_2_11_7;
hspec-core = self.hspec-core_2_11_7;
});
hspec-meta_2_11_6 = doDistribute (super.hspec-meta_2_11_6.override {
hspec-meta_2_11_7 = doDistribute (super.hspec-meta_2_11_7.override {
hspec-expectations = self.hspec-expectations_0_8_4;
});
hspec-discover_2_11_6 = doDistribute (super.hspec-discover_2_11_6.override {
hspec-meta = self.hspec-meta_2_11_6;
hspec-discover_2_11_7 = doDistribute (super.hspec-discover_2_11_7.override {
hspec-meta = self.hspec-meta_2_11_7;
});
# Need to disable tests to prevent an infinite recursion if hspec-core_2_11_6
# Need to disable tests to prevent an infinite recursion if hspec-core_2_11_7
# is overlayed to hspec-core.
hspec-core_2_11_6 = doDistribute (dontCheck (super.hspec-core_2_11_6.override {
hspec-core_2_11_7 = doDistribute (dontCheck (super.hspec-core_2_11_7.override {
hspec-expectations = self.hspec-expectations_0_8_4;
}));

Expand Down Expand Up @@ -1841,7 +1841,7 @@ self: super: {
inherit (let
pandoc-cli-overlay = self: super: {
# pandoc-cli requires pandoc >= 3.1
pandoc = self.pandoc_3_1_8;
pandoc = self.pandoc_3_1_9;

# pandoc depends on http-client-tls, which only starts depending
# on crypton-connection in http-client-tls-0.3.6.2.
Expand All @@ -1853,11 +1853,11 @@ self: super: {
};
in {
pandoc-cli = super.pandoc-cli.overrideScope pandoc-cli-overlay;
pandoc_3_1_8 = doDistribute (super.pandoc_3_1_8.overrideScope pandoc-cli-overlay);
pandoc_3_1_9 = doDistribute (super.pandoc_3_1_9.overrideScope pandoc-cli-overlay);
pandoc-lua-engine = super.pandoc-lua-engine.overrideScope pandoc-cli-overlay;
})
pandoc-cli
pandoc_3_1_8
pandoc_3_1_9
pandoc-lua-engine
;

Expand Down
4 changes: 2 additions & 2 deletions pkgs/development/haskell-modules/configuration-ghc-9.4.x.nix
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,8 @@ in {
haskell-language-server = allowInconsistentDependencies super.haskell-language-server;
# Tests fail due to the newly-build fourmolu not being in PATH
# https://github.com/fourmolu/fourmolu/issues/231
fourmolu = dontCheck super.fourmolu_0_14_0_0;
ormolu = self.generateOptparseApplicativeCompletions [ "ormolu" ] (enableSeparateBinOutput super.ormolu_0_7_2_0);
fourmolu = dontCheck super.fourmolu_0_14_1_0;
ormolu = self.generateOptparseApplicativeCompletions [ "ormolu" ] (enableSeparateBinOutput super.ormolu_0_7_3_0);
hlint = super.hlint_3_6_1;
stylish-haskell = super.stylish-haskell;
}
Expand Down
4 changes: 2 additions & 2 deletions pkgs/development/haskell-modules/configuration-ghc-9.6.x.nix
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,8 @@ self: super: {

# Tests fail due to the newly-build fourmolu not being in PATH
# https://github.com/fourmolu/fourmolu/issues/231
fourmolu = dontCheck super.fourmolu_0_14_0_0;
ormolu = self.generateOptparseApplicativeCompletions [ "ormolu" ] (enableSeparateBinOutput super.ormolu_0_7_2_0);
fourmolu = dontCheck super.fourmolu_0_14_1_0;
ormolu = self.generateOptparseApplicativeCompletions [ "ormolu" ] (enableSeparateBinOutput super.ormolu_0_7_3_0);
hlint = super.hlint_3_6_1;

# v0.1.6 forbids base >= 4.18
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4627,7 +4627,6 @@ broken-packages:
- reify # failure in job https://hydra.nixos.org/build/233247509 at 2023-09-02
- relacion # failure in job https://hydra.nixos.org/build/233241624 at 2023-09-02
- relation # failure in job https://hydra.nixos.org/build/233244581 at 2023-09-02
- releaser # failure in job https://hydra.nixos.org/build/233239420 at 2023-09-02
- relevant-time # failure in job https://hydra.nixos.org/build/233190794 at 2023-09-02
- reload # failure in job https://hydra.nixos.org/build/233212925 at 2023-09-02
- remark # failure in job https://hydra.nixos.org/build/233240981 at 2023-09-02
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,11 +121,8 @@ dont-distribute-packages:
- Forestry
- FormalGrammars
- Foster
- Frames
- Frames-beam
- Frames-dsv
- Frames-map-reduce
- Frames-streamly
- Frank
- GLFW-OGL
- GLFW-task
Expand Down Expand Up @@ -1019,6 +1016,8 @@ dont-distribute-packages:
- curryer-rpc
- cv-combinators
- cypher
- dahdit-network
- dahdit-test
- daino
- dapi
- darcs-benchmark
Expand Down Expand Up @@ -2031,7 +2030,7 @@ dont-distribute-packages:
- hesql
- heterolist
- hetzner
- hetzner_0_5_0_0
- hetzner_0_6_0_0
- hevolisa
- hevolisa-dph
- hexpat-conduit
Expand Down Expand Up @@ -2678,6 +2677,12 @@ dont-distribute-packages:
- micro-gateway
- microformats2-types
- midimory
- mig
- mig-client
- mig-extra
- mig-server
- mig-swagger-ui
- mig-wai
- mighttpd
- minecraft-data
- minesweeper
Expand Down Expand Up @@ -2810,6 +2815,7 @@ dont-distribute-packages:
- named-servant-client
- named-servant-server
- nanq
- national-australia-bank
- nats-queue
- natural-number
- nemesis-titan
Expand Down Expand Up @@ -3504,6 +3510,7 @@ dont-distribute-packages:
- selda-sqlite
- selenium-server
- semantic-source
- semantic-version
- semi-iso
- semialign-extras
- semiring
Expand Down
15 changes: 10 additions & 5 deletions pkgs/development/haskell-modules/hackage-packages.nix

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions pkgs/development/tools/pandoc/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ in
-t ${haskellPackages.warp} \
$out/bin/pandoc
remove-references-to \
-t ${haskellPackages.pandoc_3_1_8} \
-t ${haskellPackages.pandoc_3_1_9} \
$out/bin/pandoc
'' + lib.optionalString (stdenv.buildPlatform == stdenv.hostPlatform) ''
mkdir -p $out/share/bash-completion/completions
Expand All @@ -48,5 +48,5 @@ in
# lead to a transitive runtime dependency on the whole GHC distribution.
# This should ideally be fixed in haskellPackages (or even Cabal),
# but a minimal pandoc is important enough to patch it manually.
disallowedReferences = [ haskellPackages.pandoc-types haskellPackages.warp haskellPackages.pandoc_3_1_8 ];
disallowedReferences = [ haskellPackages.pandoc-types haskellPackages.warp haskellPackages.pandoc_3_1_9 ];
})
2 changes: 1 addition & 1 deletion pkgs/top-level/release-haskell.nix
Original file line number Diff line number Diff line change
Expand Up @@ -487,7 +487,7 @@ let
cabal-install = lib.subtractLists [
compilerNames.ghc981
] released;
Cabal_3_10_2_0 = lib.subtractLists [
Cabal_3_10_2_1 = lib.subtractLists [
compilerNames.ghc981
] released;
Cabal-syntax_3_10_1_0 = lib.subtractLists [
Expand Down

0 comments on commit b75be5d

Please sign in to comment.