From f5536149557e611a8f8b6503bd51cb2e62306a2a Mon Sep 17 00:00:00 2001 From: sternenseemann Date: Tue, 15 Mar 2022 12:26:32 +0100 Subject: [PATCH] haskellPackages.graphql-engine: 2.0.10 -> 2.3.1 haskellPackages.kriti-lang: init at 0.3.1 Towards getting hasura-related packages to work with Stackage Nightly / GHC 9.0. --- .../haskell-modules/configuration-common.nix | 47 ++++--- .../haskell-modules/non-hackage-packages.nix | 1 + .../patches/graphql-engine-mapkeys.patch | 33 ----- .../misc/haskell/hasura/ekg-core.nix | 17 ++- .../misc/haskell/hasura/ekg-json.nix | 9 +- .../misc/haskell/hasura/graphql-engine.nix | 115 ++++++++++-------- .../misc/haskell/hasura/graphql-parser.nix | 23 ++-- .../misc/haskell/hasura/kriti-lang.nix | 41 +++++++ .../misc/haskell/hasura/pg-client.nix | 35 +++--- pkgs/development/misc/haskell/hasura/pool.nix | 2 +- .../development/misc/haskell/hasura/update.sh | 12 +- pkgs/servers/hasura/cli.nix | 2 +- pkgs/top-level/all-packages.nix | 2 +- 13 files changed, 194 insertions(+), 145 deletions(-) delete mode 100644 pkgs/development/haskell-modules/patches/graphql-engine-mapkeys.patch create mode 100644 pkgs/development/misc/haskell/hasura/kriti-lang.nix diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/development/haskell-modules/configuration-common.nix index 54366201b1dd..2b64c549f18b 100644 --- a/pkgs/development/haskell-modules/configuration-common.nix +++ b/pkgs/development/haskell-modules/configuration-common.nix @@ -1484,35 +1484,48 @@ self: super: { # hasura packages need some extra care graphql-engine = overrideCabal (drv: { - patches = [ ./patches/graphql-engine-mapkeys.patch ]; + patches = [ + # Compat with unordered-containers >= 0.2.15.0 + (fetchpatch { + name = "hasura-graphql-engine-updated-deps.patch"; + url = "https://github.com/hasura/graphql-engine/commit/d50aae87a58794bc1fc66c7a60acb0c34b5e70c7.patch"; + stripLen = 1; + excludes = [ "cabal.project.freeze" ]; + sha256 = "0lb5l9vfynr85i9xs53w4mpgczp04ncxz7846n3y91ri34fa87v3"; + }) + # Compat with hashable >= 1.3.4.0 + (fetchpatch { + name = "hasura-graphql-engine-hashable-1.3.4.0.patch"; + url = "https://github.com/hasura/graphql-engine/commit/e48b2287315fb09005ffd52c0a686dc321171ae2.patch"; + sha256 = "1jppnanmsyl8npyf59s0d8bgjy7bq50vkh5zx4888jy6jqh27jb6"; + stripLen = 1; + }) + # Compat with unordered-containers >= 0.2.17.0 + (fetchpatch { + name = "hasura-graphql-engine-unordered-containers-0.2.17.0.patch"; + url = "https://github.com/hasura/graphql-engine/commit/3a1eb3128a2ded2da7c5fef089738890828cce03.patch"; + sha256 = "0vz7s8m8mjvv728vm4q0dvvrirvydaw7xks30b5ddj9f6a72a2f1"; + stripLen = 1; + }) + ]; doHaddock = false; - version = "2.0.10"; - }) (super.graphql-engine.overrideScope (self: super: { + version = "2.3.1"; + }) (super.graphql-engine.override { immortal = self.immortal_0_2_2_1; resource-pool = self.hasura-resource-pool; ekg-core = self.hasura-ekg-core; ekg-json = self.hasura-ekg-json; - hspec = dontCheck self.hspec_2_9_4; - hspec-core = dontCheck self.hspec-core_2_9_4; - hspec-discover = dontCheck super.hspec-discover_2_9_4; - })); - hasura-ekg-core = doJailbreak (super.hasura-ekg-core.overrideScope (self: super: { - hspec = dontCheck self.hspec_2_9_4; - hspec-core = dontCheck self.hspec-core_2_9_4; - hspec-discover = dontCheck super.hspec-discover_2_9_4; - })); - hasura-ekg-json = super.hasura-ekg-json.overrideScope (self: super: { - ekg-core = self.hasura-ekg-core; - hspec = dontCheck self.hspec_2_9_4; - hspec-core = dontCheck self.hspec-core_2_9_4; - hspec-discover = dontCheck super.hspec-discover_2_9_4; }); + hasura-ekg-json = super.hasura-ekg-json.override { + ekg-core = self.hasura-ekg-core; + }; pg-client = overrideCabal (drv: { librarySystemDepends = with pkgs; [ postgresql krb5.dev openssl.dev ]; # wants a running DB to check against doCheck = false; }) (super.pg-client.override { resource-pool = self.hasura-resource-pool; + ekg-core = self.hasura-ekg-core; }); # https://github.com/bos/statistics/issues/170 diff --git a/pkgs/development/haskell-modules/non-hackage-packages.nix b/pkgs/development/haskell-modules/non-hackage-packages.nix index e06f9d30d2da..beb81a58d863 100644 --- a/pkgs/development/haskell-modules/non-hackage-packages.nix +++ b/pkgs/development/haskell-modules/non-hackage-packages.nix @@ -30,6 +30,7 @@ self: super: { pg-client = self.callPackage ../misc/haskell/hasura/pg-client.nix {}; graphql-parser = self.callPackage ../misc/haskell/hasura/graphql-parser.nix {}; graphql-engine = self.callPackage ../misc/haskell/hasura/graphql-engine.nix {}; + kriti-lang = self.callPackage ../misc/haskell/hasura/kriti-lang.nix {}; hasura-resource-pool = self.callPackage ../misc/haskell/hasura/pool.nix {}; hasura-ekg-core = self.callPackage ../misc/haskell/hasura/ekg-core.nix {}; hasura-ekg-json = self.callPackage ../misc/haskell/hasura/ekg-json.nix {}; diff --git a/pkgs/development/haskell-modules/patches/graphql-engine-mapkeys.patch b/pkgs/development/haskell-modules/patches/graphql-engine-mapkeys.patch deleted file mode 100644 index 9035185dc2d5..000000000000 --- a/pkgs/development/haskell-modules/patches/graphql-engine-mapkeys.patch +++ /dev/null @@ -1,33 +0,0 @@ -diff --git a/server/src-lib/Data/HashMap/Strict/Extended.hs b/server/src-lib/Data/HashMap/Strict/Extended.hs -index eaff0dfba..9902cadd0 100644 ---- a/src-lib/Data/HashMap/Strict/Extended.hs -+++ b/src-lib/Data/HashMap/Strict/Extended.hs -@@ -7,7 +7,6 @@ module Data.HashMap.Strict.Extended - , groupOnNE - , differenceOn - , lpadZip -- , mapKeys - , unionsWith - ) where - -@@ -54,20 +53,6 @@ lpadZip left = catMaybes . flip A.alignWith left \case - That b -> Just (Nothing, b) - These a b -> Just (Just a, b) - ---- | @'mapKeys' f s@ is the map obtained by applying @f@ to each key of @s@. ---- ---- The size of the result may be smaller if @f@ maps two or more distinct ---- keys to the same new key. In this case the value at the greatest of the ---- original keys is retained. ---- ---- > mapKeys (+ 1) (fromList [(5,"a"), (3,"b")]) == fromList [(4, "b"), (6, "a")] ---- > mapKeys (\ _ -> 1) (fromList [(1,"b"), (2,"a"), (3,"d"), (4,"c")]) == singleton 1 "c" ---- > mapKeys (\ _ -> 3) (fromList [(1,"b"), (2,"a"), (3,"d"), (4,"c")]) == singleton 3 "c" ---- ---- copied from https://hackage.haskell.org/package/containers-0.6.4.1/docs/src/Data.Map.Internal.html#mapKeys --mapKeys :: (Ord k2, Hashable k2) => (k1 -> k2) -> HashMap k1 a -> HashMap k2 a --mapKeys f = fromList . foldrWithKey (\k x xs -> (f k, x) : xs) [] -- - -- | The union of a list of maps, with a combining operation: - -- (@'unionsWith' f == 'Prelude.foldl' ('unionWith' f) 'empty'@). - -- diff --git a/pkgs/development/misc/haskell/hasura/ekg-core.nix b/pkgs/development/misc/haskell/hasura/ekg-core.nix index 6a9b1157021e..2d1b62bc16c7 100644 --- a/pkgs/development/misc/haskell/hasura/ekg-core.nix +++ b/pkgs/development/misc/haskell/hasura/ekg-core.nix @@ -1,17 +1,17 @@ # This has been automatically generated by the script # ./update.sh. This should not be changed by hand. { mkDerivation, async, atomic-primops, base, containers, criterion -, fetchgit, generic-random, ghc-prim, hashable, hspec -, hspec-smallcheck, HUnit, inspection-testing, lib, markdown-unlit -, primitive, QuickCheck, smallcheck, text, unordered-containers +, fetchgit, ghc-prim, hashable, hspec, hspec-smallcheck, HUnit +, inspection-testing, lib, markdown-unlit, primitive, QuickCheck +, smallcheck, text, unordered-containers }: mkDerivation { pname = "ekg-core"; version = "0.1.1.7"; src = fetchgit { url = "https://github.com/hasura/ekg-core.git"; - sha256 = "1s58kjg1kbhsyfyj0zwhnnws9hg9zwj9jylpwicg54yi78w962ys"; - rev = "9fc8f94685c149a909b66bad4167455d8ae1002c"; + sha256 = "1syb87iav3fgj6vqjh1izdvw4g0l4mngcyhvcg2nazisw3l685z6"; + rev = "b0cdc337ca2a52e392d427916ba3e28246b396c0"; fetchSubmodules = true; }; libraryHaskellDepends = [ @@ -19,10 +19,9 @@ mkDerivation { primitive text unordered-containers ]; testHaskellDepends = [ - async atomic-primops base containers generic-random ghc-prim - hashable hspec hspec-smallcheck HUnit inspection-testing - markdown-unlit primitive QuickCheck smallcheck text - unordered-containers + async atomic-primops base containers ghc-prim hashable hspec + hspec-smallcheck HUnit inspection-testing markdown-unlit primitive + QuickCheck smallcheck text unordered-containers ]; testToolDepends = [ markdown-unlit ]; benchmarkHaskellDepends = [ base criterion ]; diff --git a/pkgs/development/misc/haskell/hasura/ekg-json.nix b/pkgs/development/misc/haskell/hasura/ekg-json.nix index e115e2c40b9d..bb71aef27970 100644 --- a/pkgs/development/misc/haskell/hasura/ekg-json.nix +++ b/pkgs/development/misc/haskell/hasura/ekg-json.nix @@ -1,6 +1,6 @@ # This has been automatically generated by the script # ./update.sh. This should not be changed by hand. -{ mkDerivation, aeson, base, ekg-core, fetchgit, lib, text +{ mkDerivation, aeson, base, ekg-core, fetchgit, hspec, lib, text , unordered-containers, vector }: mkDerivation { @@ -8,13 +8,16 @@ mkDerivation { version = "0.1.0.7"; src = fetchgit { url = "https://github.com/hasura/ekg-json.git"; - sha256 = "1yf9x7gh66q27c3wv5m00ijf2qpiwm53jjlhrj2yc1glv684wf4v"; - rev = "f25b9ddb7aae18059ef707a5ce30d6a54a63db13"; + sha256 = "17kd2f1695dmf5l95iz1w86hapc4f1gfrd0ld3ivffa2q5vxbi70"; + rev = "d1c5031b49a5559cf4b4f6beb0238b872890a48c"; fetchSubmodules = true; }; libraryHaskellDepends = [ aeson base ekg-core text unordered-containers vector ]; + testHaskellDepends = [ + aeson base ekg-core hspec text unordered-containers + ]; homepage = "https://github.com/tibbe/ekg-json"; description = "JSON encoding of ekg metrics"; license = lib.licenses.bsd3; diff --git a/pkgs/development/misc/haskell/hasura/graphql-engine.nix b/pkgs/development/misc/haskell/hasura/graphql-engine.nix index d5d8e693ab41..646c57671362 100644 --- a/pkgs/development/misc/haskell/hasura/graphql-engine.nix +++ b/pkgs/development/misc/haskell/hasura/graphql-engine.nix @@ -1,39 +1,44 @@ # This has been automatically generated by the script # ./update.sh. This should not be changed by hand. -{ mkDerivation, aeson, aeson-casing, ansi-wl-pprint, asn1-encoding -, asn1-types, async, attoparsec, attoparsec-iso8601, auto-update -, base, base16-bytestring, base64-bytestring, binary, byteorder -, bytestring, case-insensitive, ci-info, connection, containers -, cron, cryptonite, data-default-class, data-has, deepseq -, dependent-map, dependent-sum, directory, ekg-core, ekg-json -, exceptions, fast-logger, fetchgit, file-embed, filepath -, ghc-heap-view, graphql-parser, hashable, hashable-time, hspec -, hspec-core, hspec-expectations, hspec-expectations-lifted -, http-api-data, http-client, http-client-tls, http-conduit +{ mkDerivation, aeson, aeson-casing, aeson-qq, ansi-wl-pprint +, asn1-encoding, asn1-types, async, attoparsec, attoparsec-iso8601 +, auto-update, base, base16-bytestring, base64-bytestring, binary +, byteorder, bytestring, case-insensitive, ci-info, conduit +, connection, containers, cron, cryptonite, data-default-class +, data-has, deepseq, dependent-map, dependent-sum, directory +, either, ekg-core, ekg-json, exceptions, fast-logger, fetchgit +, file-embed, filepath, ghc-heap-view, graphql-parser, hashable +, hashable-time, haskell-src-meta, hedgehog, hspec, hspec-core +, hspec-discover, hspec-expectations, hspec-expectations-lifted +, hspec-hedgehog, hspec-wai, hspec-wai-json, http-api-data +, http-client, http-client-tls, http-conduit, http-media , http-types, immortal, insert-ordered-containers, jose -, kan-extensions, lens, lens-aeson, lib, lifted-async, lifted-base -, list-t, memory, mime-types, mmorph, monad-control, monad-loops -, monad-validate, mtl, mustache, mysql, mysql-simple -, natural-transformation, network, network-uri, odbc -, optparse-applicative, pem, pg-client, postgresql-binary -, postgresql-libpq, pretty-simple, process, profunctors, psqueues -, QuickCheck, quickcheck-instances, random, regex-tdfa -, resource-pool, retry, safe, safe-exceptions, scientific -, semialign, semigroups, semver, shakespeare, some, split -, Spock-core, stm, stm-containers, tagged, template-haskell, text -, text-builder, text-conversions, these, time, tls, transformers -, transformers-base, unix, unordered-containers, uri-encode +, kan-extensions, kriti-lang, lens, lens-aeson, lib, libyaml +, lifted-async, lifted-base, list-t, memory, mime-types, mmorph +, monad-control, monad-logger, monad-loops, monad-validate, mtl +, mustache, mysql, mysql-simple, natural-transformation, network +, network-uri, odbc, openapi3, optparse-applicative +, optparse-generic, parsec, pem, pg-client, postgresql-binary +, postgresql-libpq, postgresql-simple, pretty-simple, process +, profunctors, psqueues, QuickCheck, quickcheck-instances, random +, regex-tdfa, resource-pool, resourcet, retry, safe +, safe-exceptions, scientific, semialign, semigroups, semver +, shakespeare, some, split, Spock-core, stm, stm-containers, tagged +, template-haskell, text, text-builder, text-conversions, th-lift +, th-lift-instances, these, time, tls, tmp-postgres, transformers +, transformers-base, typed-process, unix, unliftio-core +, unordered-containers, uri-bytestring, uri-encode, url , utf8-string, uuid, validation, vector, vector-instances, wai -, warp, websockets, wreq, x509, x509-store, x509-system -, x509-validation, yaml, zlib +, wai-extra, warp, websockets, witch, wreq, x509, x509-store +, x509-system, x509-validation, yaml, zlib }: mkDerivation { pname = "graphql-engine"; version = "1.0.0"; src = fetchgit { url = "https://github.com/hasura/graphql-engine.git"; - sha256 = "04ns40wk1760pxi18pyqzgrk8h28mw6402zkjc1g52ny6afchs05"; - rev = "8be851c2a1326b2caada13a3c43becd2e848db6c"; + sha256 = "1r19qw2wxzmngb6sjpin3dk6i5r491brcb0ir4g8kw9d0ic90hpy"; + rev = "1349e6cdcfdef4b06593b48fe8e2e51b9f9c94e9"; fetchSubmodules = true; }; postUnpack = "sourceRoot+=/server; echo source root reset to $sourceRoot"; @@ -44,22 +49,23 @@ mkDerivation { attoparsec attoparsec-iso8601 auto-update base base16-bytestring base64-bytestring binary byteorder bytestring case-insensitive ci-info connection containers cron cryptonite data-default-class - data-has deepseq dependent-map dependent-sum directory ekg-core - ekg-json exceptions fast-logger file-embed filepath ghc-heap-view - graphql-parser hashable hashable-time http-api-data http-client - http-client-tls http-conduit http-types immortal - insert-ordered-containers jose kan-extensions lens lens-aeson - lifted-async lifted-base list-t memory mime-types mmorph - monad-control monad-loops monad-validate mtl mustache mysql - mysql-simple network network-uri odbc optparse-applicative pem - pg-client postgresql-binary postgresql-libpq pretty-simple process - profunctors psqueues QuickCheck quickcheck-instances random - regex-tdfa resource-pool retry safe-exceptions scientific semialign - semigroups semver shakespeare some split Spock-core stm - stm-containers tagged template-haskell text text-builder - text-conversions these time tls transformers transformers-base unix - unordered-containers uri-encode utf8-string uuid validation vector - vector-instances wai warp websockets wreq x509 x509-store + data-has deepseq dependent-map dependent-sum directory either + ekg-core ekg-json exceptions fast-logger file-embed filepath + ghc-heap-view graphql-parser hashable hashable-time http-api-data + http-client http-client-tls http-conduit http-media http-types + immortal insert-ordered-containers jose kan-extensions kriti-lang + lens lens-aeson lifted-async lifted-base list-t memory mime-types + mmorph monad-control monad-loops monad-validate mtl mustache mysql + mysql-simple network network-uri odbc openapi3 optparse-applicative + optparse-generic parsec pem pg-client postgresql-binary + postgresql-libpq pretty-simple process profunctors psqueues + QuickCheck quickcheck-instances random regex-tdfa resource-pool + retry safe-exceptions scientific semialign semigroups semver + shakespeare some split Spock-core stm stm-containers tagged + template-haskell text text-builder text-conversions these time tls + transformers transformers-base unix unordered-containers + uri-bytestring uri-encode url utf8-string uuid validation vector + vector-instances wai warp websockets witch wreq x509 x509-store x509-system x509-validation yaml zlib ]; executableHaskellDepends = [ @@ -67,15 +73,24 @@ mkDerivation { text-conversions time unix ]; testHaskellDepends = [ - aeson base bytestring containers cron dependent-map dependent-sum - graphql-parser hspec hspec-core hspec-expectations - hspec-expectations-lifted http-client http-client-tls http-types - insert-ordered-containers jose kan-extensions lens lifted-base - mmorph monad-control mtl natural-transformation network-uri - optparse-applicative pg-client process QuickCheck safe scientific - split template-haskell text time transformers-base - unordered-containers vector + aeson aeson-casing aeson-qq async base bytestring case-insensitive + conduit containers cron dependent-map dependent-sum ekg-core + exceptions graphql-parser haskell-src-meta hedgehog hspec + hspec-core hspec-discover hspec-expectations + hspec-expectations-lifted hspec-hedgehog hspec-wai hspec-wai-json + http-client http-client-tls http-conduit http-types + insert-ordered-containers jose kan-extensions lens lens-aeson + libyaml lifted-base mmorph monad-control monad-logger mtl mysql + mysql-simple natural-transformation network network-uri odbc + optparse-applicative parsec pg-client postgresql-libpq + postgresql-simple process QuickCheck resource-pool resourcet safe + safe-exceptions scientific shakespeare split Spock-core stm + template-haskell text text-conversions th-lift th-lift-instances + time tmp-postgres transformers transformers-base typed-process unix + unliftio-core unordered-containers utf8-string vector wai wai-extra + warp websockets yaml ]; + testToolDepends = [ hspec-discover ]; doCheck = false; homepage = "https://www.hasura.io"; description = "GraphQL API over Postgres"; diff --git a/pkgs/development/misc/haskell/hasura/graphql-parser.nix b/pkgs/development/misc/haskell/hasura/graphql-parser.nix index a447ac015401..70024ce732c4 100644 --- a/pkgs/development/misc/haskell/hasura/graphql-parser.nix +++ b/pkgs/development/misc/haskell/hasura/graphql-parser.nix @@ -1,30 +1,29 @@ # This has been automatically generated by the script # ./update.sh. This should not be changed by hand. -{ mkDerivation, aeson, attoparsec, base, bytestring, containers -, criterion, deepseq, fetchgit, filepath, hashable, hedgehog, lib -, prettyprinter, scientific, template-haskell, text, text-builder -, th-lift-instances, unordered-containers, vector +{ mkDerivation, aeson, attoparsec, base, bytestring, deepseq +, fetchgit, hashable, hedgehog, lib, prettyprinter, scientific +, tasty-bench, template-haskell, text, text-builder +, th-lift-instances, unordered-containers }: mkDerivation { pname = "graphql-parser"; version = "0.2.0.0"; src = fetchgit { url = "https://github.com/hasura/graphql-parser-hs.git"; - sha256 = "0zqrh7y0cjjrscsw2hmyhdcm4nzvb5pw394pcxk8q19xx13jp9xd"; - rev = "43562a5b7b41d380e3e31732b48637702e5aa97d"; + sha256 = "1xprr5wdhcfnbggkygz71v3za1mmkqv5mbm7h16kpsrhm1m9mpx8"; + rev = "c311bc15b8d8cef28a846d1d81b0bcc1d59bd956"; fetchSubmodules = true; }; libraryHaskellDepends = [ - aeson attoparsec base bytestring containers deepseq filepath - hashable hedgehog prettyprinter scientific template-haskell text - text-builder th-lift-instances unordered-containers vector + aeson attoparsec base bytestring deepseq hashable hedgehog + prettyprinter scientific template-haskell text text-builder + th-lift-instances unordered-containers ]; testHaskellDepends = [ - attoparsec base bytestring hedgehog prettyprinter scientific text - text-builder + attoparsec base bytestring hedgehog prettyprinter text text-builder ]; benchmarkHaskellDepends = [ - base bytestring criterion prettyprinter text text-builder + base bytestring prettyprinter tasty-bench text text-builder ]; homepage = "https://github.com/hasura/graphql-parser-hs"; description = "A native Haskell GraphQL parser"; diff --git a/pkgs/development/misc/haskell/hasura/kriti-lang.nix b/pkgs/development/misc/haskell/hasura/kriti-lang.nix new file mode 100644 index 000000000000..7e22aff40d7b --- /dev/null +++ b/pkgs/development/misc/haskell/hasura/kriti-lang.nix @@ -0,0 +1,41 @@ +# This has been automatically generated by the script +# ./update.sh. This should not be changed by hand. +{ mkDerivation, aeson, aeson-pretty, alex, array, base, bytestring +, containers, directory, fetchgit, filepath, generic-arbitrary +, happy, hspec, hspec-core, hspec-golden, lens, lens-aeson, lib +, megaparsec, mtl, network-uri, optparse-applicative, parsec +, parser-combinators, pretty-simple, prettyprinter, QuickCheck +, raw-strings-qq, safe-exceptions, scientific, text +, unordered-containers, utf8-string, vector +}: +mkDerivation { + pname = "kriti-lang"; + version = "0.3.1"; + src = fetchgit { + url = "https://github.com/hasura/kriti-lang.git"; + sha256 = "09v31xp8gkc0p0gfysxyd8yb7lyb1vpgzq8550h3s3msjbapr7pj"; + rev = "0f0b153b93af5dc6c6e995c016ca4562e8438cec"; + fetchSubmodules = true; + }; + isLibrary = true; + isExecutable = true; + libraryHaskellDepends = [ + aeson array base bytestring containers lens megaparsec mtl + network-uri optparse-applicative parser-combinators prettyprinter + scientific text unordered-containers utf8-string vector + ]; + libraryToolDepends = [ alex happy ]; + executableHaskellDepends = [ + aeson base bytestring containers mtl optparse-applicative + prettyprinter text utf8-string + ]; + testHaskellDepends = [ + aeson aeson-pretty base bytestring containers directory filepath + generic-arbitrary hspec hspec-core hspec-golden lens lens-aeson mtl + optparse-applicative parsec pretty-simple prettyprinter QuickCheck + raw-strings-qq safe-exceptions scientific text unordered-containers + utf8-string vector + ]; + license = lib.licenses.asl20; + maintainers = with lib.maintainers; [ lassulus ]; +} diff --git a/pkgs/development/misc/haskell/hasura/pg-client.nix b/pkgs/development/misc/haskell/hasura/pg-client.nix index 52f179f9923c..92d556824dbd 100644 --- a/pkgs/development/misc/haskell/hasura/pg-client.nix +++ b/pkgs/development/misc/haskell/hasura/pg-client.nix @@ -1,10 +1,10 @@ # This has been automatically generated by the script # ./update.sh. This should not be changed by hand. -{ mkDerivation, aeson, aeson-casing, attoparsec, base, bytestring -, Cabal, criterion, ekg-core, fetchgit, file-embed, hashable -, hashtables, hasql, hasql-pool, hasql-transaction, hspec, lib -, mmorph, monad-control, mtl, postgresql, postgresql-binary -, postgresql-libpq, resource-pool, retry, scientific +{ mkDerivation, aeson, aeson-casing, async, attoparsec, base +, bytestring, ekg-core, fetchgit, file-embed, hashable, hashtables +, hasql, hasql-pool, hasql-transaction, hspec, lib, mmorph +, monad-control, mtl, postgresql-binary, postgresql-libpq +, resource-pool, retry, safe-exceptions, scientific, tasty-bench , template-haskell, text, text-builder, time, transformers-base , uuid, vector }: @@ -13,24 +13,25 @@ mkDerivation { version = "0.1.0"; src = fetchgit { url = "https://github.com/hasura/pg-client-hs.git"; - sha256 = "00h9hskv3p4mg35php5wsr2d2rjahcv29rqidb2lxl11r05psr4m"; - rev = "5e8a2d7ebe8b96518e5a70f4d61be2550eaa4e70"; + sha256 = "0ga2bj0mfng25c8kxsvi8i13pnanbnhahxvbq8ijl0bysd41g7zi"; + rev = "09b40ad8e5d16a78f5d91fe2306676f52caadbc8"; fetchSubmodules = true; }; - setupHaskellDepends = [ base Cabal ]; libraryHaskellDepends = [ - aeson aeson-casing attoparsec base bytestring ekg-core hashable - hashtables mmorph monad-control mtl postgresql-binary - postgresql-libpq resource-pool retry scientific template-haskell - text text-builder time transformers-base uuid vector + aeson aeson-casing async attoparsec base bytestring ekg-core + hashable hashtables mmorph monad-control mtl postgresql-binary + postgresql-libpq resource-pool retry safe-exceptions scientific + template-haskell text text-builder time transformers-base uuid + vector + ]; + testHaskellDepends = [ + async base bytestring hspec mtl safe-exceptions time ]; - librarySystemDepends = [ postgresql ]; - testHaskellDepends = [ base bytestring hspec mtl ]; benchmarkHaskellDepends = [ - base bytestring criterion file-embed hashable hasql hasql-pool - hasql-transaction mtl postgresql-libpq text text-builder + base bytestring file-embed hasql hasql-pool hasql-transaction mtl + tasty-bench text ]; homepage = "https://github.com/hasura/platform"; - license = lib.licenses.bsd3; + license = lib.licenses.asl20; maintainers = with lib.maintainers; [ lassulus ]; } diff --git a/pkgs/development/misc/haskell/hasura/pool.nix b/pkgs/development/misc/haskell/hasura/pool.nix index c03b1fb88121..48954114a4a1 100644 --- a/pkgs/development/misc/haskell/hasura/pool.nix +++ b/pkgs/development/misc/haskell/hasura/pool.nix @@ -17,7 +17,7 @@ mkDerivation { vector ]; testHaskellDepends = [ base hspec ]; - homepage = "https://github.com/bos/pool"; + homepage = "http://github.com/bos/pool"; description = "A high-performance striped resource pooling implementation"; license = lib.licenses.bsd3; maintainers = with lib.maintainers; [ lassulus ]; diff --git a/pkgs/development/misc/haskell/hasura/update.sh b/pkgs/development/misc/haskell/hasura/update.sh index 77a5d5fc6dea..f4286ea6b831 100755 --- a/pkgs/development/misc/haskell/hasura/update.sh +++ b/pkgs/development/misc/haskell/hasura/update.sh @@ -21,12 +21,13 @@ pgclient_derivation_file="${script_dir}/pg-client.nix" pool_derivation_file="${script_dir}/pool.nix" ekgcore_derivation_file="${script_dir}/ekg-core.nix" ekgjson_derivation_file="${script_dir}/ekg-json.nix" +kritilang_derivation_file="${script_dir}/kriti-lang.nix" # TODO: get current revision of graphql-engine in Nixpkgs. # old_version="$(sed -En 's/.*\bversion = "(.*?)".*/\1/p' "$engine_derivation_file")" # This is the latest release version of graphql-engine on GitHub. -new_version=$(curl --silent "https://api.github.com/repos/hasura/graphql-engine/releases" | jq '.[0].tag_name' --raw-output) +new_version=$(curl --silent "https://api.github.com/repos/hasura/graphql-engine/releases" | jq 'map(select(.prerelease | not)) | .[0].tag_name' --raw-output) echo "Running cabal2nix and outputting to ${engine_derivation_file}..." @@ -77,6 +78,15 @@ echo "# ./update.sh. This should not be changed by hand." >> "$ekgjson_derivati cabal2nix --maintainer lassulus "https://github.com/hasura/ekg-json.git" >> "$ekgjson_derivation_file" +echo "Running cabal2nix and outputting to ${kritilang_derivation_file}..." + +echo "# This has been automatically generated by the script" > "$kritilang_derivation_file" +echo "# ./update.sh. This should not be changed by hand." >> "$kritilang_derivation_file" + +new_kritilang_version=$(curl --silent "https://api.github.com/repos/hasura/kriti-lang/tags" | jq '.[0].name' --raw-output) + +cabal2nix --revision "$new_kritilang_version" --maintainer lassulus "https://github.com/hasura/kriti-lang.git" >> "$kritilang_derivation_file" + echo "###################" echo "please update pkgs/servers/hasura/cli.nix vendorSha256" echo "please update pkgs/development/haskell-modules/configuration-common.nix graphql-engine version" diff --git a/pkgs/servers/hasura/cli.nix b/pkgs/servers/hasura/cli.nix index a19a2773ce96..48bcfe39eabd 100644 --- a/pkgs/servers/hasura/cli.nix +++ b/pkgs/servers/hasura/cli.nix @@ -9,7 +9,7 @@ buildGoModule rec { subPackages = [ "cmd/hasura" ]; - vendorSha256 = "0c0zn3a3bq3g13zj1b7hz1gfd9mcc5wlch80vjgp31vgm23vvd8d"; + vendorSha256 = "0rjh4rs92jj56il3hg8msjz0w0iv25lydnh9v1kxmvdzy1x75b2b"; doCheck = false; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 60ae4faa4391..5abbb198fbaf 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -21485,7 +21485,7 @@ with pkgs; hashi-ui = callPackage ../servers/hashi-ui {}; - hasura-graphql-engine = haskell.lib.compose.justStaticExecutables haskellPackages.graphql-engine; + hasura-graphql-engine = haskell.lib.compose.justStaticExecutables haskell.packages.ghc8107.graphql-engine; hasura-cli = callPackage ../servers/hasura/cli.nix { };