Skip to content

Commit

Permalink
Upgrade to GHC 9.6.3 (#187)
Browse files Browse the repository at this point in the history
We're upgrading to GHC 9.6.3 because that's what `chainweb-node` currently uses, so that we can reuse the same `/nix/store` paths for our Haskell toolchain.

* Upgrade to GHC 9.6.3

* Update the compiler version in cabal.project

* Use index-state in cabal.project instead of freeze file

* Update CI to GHC 9.6.3

* Add extra-include/lib dirs to ci.yaml

* Revert "Add extra-include/lib dirs to ci.yaml"

This reverts commit ad1cbd8.
  • Loading branch information
enobayram authored May 1, 2024
1 parent 13ee540 commit 8cefb14
Show file tree
Hide file tree
Showing 7 changed files with 66 additions and 32 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:
strategy:
fail-fast: false
matrix:
ghc: ['9.2.8']
ghc: ['9.6.3']
cabal: ['3.10']
os: ['ubuntu-20.04', 'ubuntu-22.04', 'macOS-latest']

Expand Down
3 changes: 1 addition & 2 deletions cabal.project
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
packages: haskell-src/chainweb-data.cabal
with-compiler: ghc-9.2.8
with-compiler: ghc-9.6.3
index-state: 2024-02-01T00:00:00Z

source-repository-package
Expand All @@ -21,5 +21,4 @@ allow-newer: beam-core:aeson
allow-newer: streaming-events:*
allow-newer: postgresql-simple-migration:*
allow-newer: beam-postgres:*
-- allow-newer: *:aeson
allow-newer: *:vector
3 changes: 1 addition & 2 deletions default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,7 @@ let profilingModule = {
};
project = pkgs.haskell-nix.cabalProject' {
src = ./.;
compiler-nix-name = "ghc928";
cabalProjectFreeze = null;
compiler-nix-name = "ghc963";
shell.tools = {
cabal = {};
};
Expand Down
82 changes: 58 additions & 24 deletions flake.lock

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

4 changes: 2 additions & 2 deletions haskell-src/chainweb-data.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ library
, http-client-tls >=0.3
, http-types
, openapi3
, optparse-applicative >=0.14 && <0.17
, optparse-applicative >=0.14
, postgresql-simple-migration
, servant-client
, servant-openapi3
Expand Down Expand Up @@ -198,7 +198,7 @@ benchmark bench
, aeson
, base
, beam-core >=0.8
, beam-postgres >=0.5 && <0.6
, beam-postgres >=0.5
, bytestring
, chainweb-api
, chainweb-data
Expand Down
1 change: 1 addition & 0 deletions haskell-src/exec/Chainweb/Server.hs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ import Chainweb.Api.NodeInfo
import Control.Concurrent
import Control.Error
import Control.Exception (bracket_, throwIO)
import Control.Monad
import Control.Monad.Except
import qualified Control.Monad.Managed as M
import Control.Retry
Expand Down
3 changes: 2 additions & 1 deletion haskell-src/lib/ChainwebDb/Queries.hs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
{-# LANGUAGE StandaloneDeriving #-}
{-# LANGUAGE TypeApplications #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
-- |

module ChainwebDb.Queries where
Expand Down Expand Up @@ -294,7 +295,7 @@ data XChainInfoT f = XChainInfo

joinXChainInfo :: TransferT (PgExpr s) ->
Q Postgres ChainwebDataDb s (XChainInfoT (PgExpr s))
joinXChainInfo tr = pgUnnest $ (customExpr_ $ \fromAcct toAcct idx mdName blk req amt ->
joinXChainInfo tr = pgUnnest $ (customExpr_ $ \fromAcct toAcct idx mdName blk req _amt ->
-- We need the following LATERAL keyword so that it can be used liberally
-- in any Q context despite the fact that it refers to the `tr` coming
-- from the outside scope. The LATERAL helps, because when the expression below
Expand Down

0 comments on commit 8cefb14

Please sign in to comment.