···1diff --git a/server/src-lib/Data/HashMap/Strict/Extended.hs b/server/src-lib/Data/HashMap/Strict/Extended.hs
2-index eaff0dfba..5047a0e9d 100644
3--- a/src-lib/Data/HashMap/Strict/Extended.hs
4+++ b/src-lib/Data/HashMap/Strict/Extended.hs
5-@@ -17,7 +17,7 @@ import qualified Data.Align as A
6- import qualified Data.Foldable as F
0000078- import Data.Function
9--import Data.HashMap.Strict as M
10-+import Data.HashMap.Strict as M hiding (mapKeys)
11- import Data.Hashable
12- import Data.List.NonEmpty (NonEmpty (..))
13- import Data.These
000000000000000
···1diff --git a/server/src-lib/Data/HashMap/Strict/Extended.hs b/server/src-lib/Data/HashMap/Strict/Extended.hs
2+index eaff0dfba..9902cadd0 100644
3--- a/src-lib/Data/HashMap/Strict/Extended.hs
4+++ b/src-lib/Data/HashMap/Strict/Extended.hs
5+@@ -7,7 +7,6 @@ module Data.HashMap.Strict.Extended
6+ , groupOnNE
7+ , differenceOn
8+ , lpadZip
9+- , mapKeys
10+ , unionsWith
11+ ) where
1213+@@ -54,20 +53,6 @@ lpadZip left = catMaybes . flip A.alignWith left \case
14+ That b -> Just (Nothing, b)
15+ These a b -> Just (Just a, b)
16+17+--- | @'mapKeys' f s@ is the map obtained by applying @f@ to each key of @s@.
18+---
19+--- The size of the result may be smaller if @f@ maps two or more distinct
20+--- keys to the same new key. In this case the value at the greatest of the
21+--- original keys is retained.
22+---
23+--- > mapKeys (+ 1) (fromList [(5,"a"), (3,"b")]) == fromList [(4, "b"), (6, "a")]
24+--- > mapKeys (\ _ -> 1) (fromList [(1,"b"), (2,"a"), (3,"d"), (4,"c")]) == singleton 1 "c"
25+--- > mapKeys (\ _ -> 3) (fromList [(1,"b"), (2,"a"), (3,"d"), (4,"c")]) == singleton 3 "c"
26+---
27+--- copied from https://hackage.haskell.org/package/containers-0.6.4.1/docs/src/Data.Map.Internal.html#mapKeys
28+-mapKeys :: (Ord k2, Hashable k2) => (k1 -> k2) -> HashMap k1 a -> HashMap k2 a
29+-mapKeys f = fromList . foldrWithKey (\k x xs -> (f k, x) : xs) []
30+-
31+ -- | The union of a list of maps, with a combining operation:
32+ -- (@'unionsWith' f == 'Prelude.foldl' ('unionWith' f) 'empty'@).
33+ --
+33
pkgs/development/misc/haskell/hasura/ekg-core.nix
···000000000000000000000000000000000
···1+# This has been automatically generated by the script
2+# ./update.sh. This should not be changed by hand.
3+{ mkDerivation, async, atomic-primops, base, containers, criterion
4+, fetchgit, generic-random, ghc-prim, hashable, hspec
5+, hspec-smallcheck, HUnit, inspection-testing, lib, markdown-unlit
6+, primitive, QuickCheck, smallcheck, text, unordered-containers
7+}:
8+mkDerivation {
9+ pname = "ekg-core";
10+ version = "0.1.1.7";
11+ src = fetchgit {
12+ url = "https://github.com/hasura/ekg-core.git";
13+ sha256 = "1s58kjg1kbhsyfyj0zwhnnws9hg9zwj9jylpwicg54yi78w962ys";
14+ rev = "9fc8f94685c149a909b66bad4167455d8ae1002c";
15+ fetchSubmodules = true;
16+ };
17+ libraryHaskellDepends = [
18+ atomic-primops base containers ghc-prim hashable inspection-testing
19+ primitive text unordered-containers
20+ ];
21+ testHaskellDepends = [
22+ async atomic-primops base containers generic-random ghc-prim
23+ hashable hspec hspec-smallcheck HUnit inspection-testing
24+ markdown-unlit primitive QuickCheck smallcheck text
25+ unordered-containers
26+ ];
27+ testToolDepends = [ markdown-unlit ];
28+ benchmarkHaskellDepends = [ base criterion ];
29+ doHaddock = false;
30+ homepage = "https://github.com/tibbe/ekg-core";
31+ description = "Tracking of system metrics";
32+ license = lib.licenses.bsd3;
33+}
+21
pkgs/development/misc/haskell/hasura/ekg-json.nix
···000000000000000000000
···1+# This has been automatically generated by the script
2+# ./update.sh. This should not be changed by hand.
3+{ mkDerivation, aeson, base, ekg-core, fetchgit, lib, text
4+, unordered-containers, vector
5+}:
6+mkDerivation {
7+ pname = "ekg-json";
8+ version = "0.1.0.7";
9+ src = fetchgit {
10+ url = "https://github.com/hasura/ekg-json.git";
11+ sha256 = "1yf9x7gh66q27c3wv5m00ijf2qpiwm53jjlhrj2yc1glv684wf4v";
12+ rev = "f25b9ddb7aae18059ef707a5ce30d6a54a63db13";
13+ fetchSubmodules = true;
14+ };
15+ libraryHaskellDepends = [
16+ aeson base ekg-core text unordered-containers vector
17+ ];
18+ homepage = "https://github.com/tibbe/ekg-json";
19+ description = "JSON encoding of ekg metrics";
20+ license = lib.licenses.bsd3;
21+}
···19ciinfo_derivation_file="${script_dir}/ci-info.nix"
20pgclient_derivation_file="${script_dir}/pg-client.nix"
21pool_derivation_file="${script_dir}/pool.nix"
002223# TODO: get current revision of graphql-engine in Nixpkgs.
24# old_version="$(sed -En 's/.*\bversion = "(.*?)".*/\1/p' "$engine_derivation_file")"
···31echo "# This has been automatically generated by the script" > "$engine_derivation_file"
32echo "# ./update.sh. This should not be changed by hand." >> "$engine_derivation_file"
3334-# 2.0.5 hardcoded for now, because 2.0.6 failed to build. should be removed when updating
35-# cabal2nix --revision "$new_version" --subpath server --maintainer lassulus "https://github.com/hasura/graphql-engine.git" >> "$engine_derivation_file"
36-cabal2nix --revision "v2.0.5" --subpath server --maintainer lassulus --no-check "https://github.com/hasura/graphql-engine.git" >> "$engine_derivation_file"
3738echo "Running cabal2nix and outputting to ${parser_derivation_file}..."
39···62echo "# ./update.sh. This should not be changed by hand." >> "$pool_derivation_file"
6364cabal2nix "https://github.com/hasura/pool.git" >> "$pool_derivation_file"
000000000000006566echo "###################"
67echo "please update pkgs/servers/hasura/cli.nix vendorSha256"
···19ciinfo_derivation_file="${script_dir}/ci-info.nix"
20pgclient_derivation_file="${script_dir}/pg-client.nix"
21pool_derivation_file="${script_dir}/pool.nix"
22+ekgcore_derivation_file="${script_dir}/ekg-core.nix"
23+ekgjson_derivation_file="${script_dir}/ekg-json.nix"
2425# TODO: get current revision of graphql-engine in Nixpkgs.
26# old_version="$(sed -En 's/.*\bversion = "(.*?)".*/\1/p' "$engine_derivation_file")"
···33echo "# This has been automatically generated by the script" > "$engine_derivation_file"
34echo "# ./update.sh. This should not be changed by hand." >> "$engine_derivation_file"
3536+cabal2nix --revision "$new_version" --subpath server --maintainer lassulus --no-check "https://github.com/hasura/graphql-engine.git" >> "$engine_derivation_file"
003738echo "Running cabal2nix and outputting to ${parser_derivation_file}..."
39···62echo "# ./update.sh. This should not be changed by hand." >> "$pool_derivation_file"
6364cabal2nix "https://github.com/hasura/pool.git" >> "$pool_derivation_file"
65+66+echo "Running cabal2nix and outputting to ${ekgcore_derivation_file}..."
67+68+echo "# This has been automatically generated by the script" > "$ekgcore_derivation_file"
69+echo "# ./update.sh. This should not be changed by hand." >> "$ekgcore_derivation_file"
70+71+cabal2nix "https://github.com/hasura/ekg-core.git" >> "$ekgcore_derivation_file"
72+73+echo "Running cabal2nix and outputting to ${ekgjson_derivation_file}..."
74+75+echo "# This has been automatically generated by the script" > "$ekgjson_derivation_file"
76+echo "# ./update.sh. This should not be changed by hand." >> "$ekgjson_derivation_file"
77+78+cabal2nix "https://github.com/hasura/ekg-json.git" >> "$ekgjson_derivation_file"
7980echo "###################"
81echo "please update pkgs/servers/hasura/cli.nix vendorSha256"