packages feed

hpqtypes-extras 1.18.0.0 → 1.19.0.0

raw patch · 6 files changed

+18/−19 lines, 6 filesdep ~basedep ~cryptondep ~hpqtypes

Dependency ranges changed: base, crypton, hpqtypes

Files

CHANGELOG.md view
@@ -1,3 +1,6 @@+# hpqtypes-extras-1.19.0.0 (2025-11-27)+* Compatibility with `hpqtypes` >= 0.13.0.0.+ # hpqtypes-extras-1.18.0.0 (2025-06-02) * Don't consider invalid indexes when checking consistency of the database. * Improve handling of lock failures during migrations.
README.md view
@@ -1,7 +1,9 @@ # hpqtypes-extras -[![Build Status](https://github.com/scrive/hpqtypes-extras/workflows/Haskell-CI/badge.svg?branch=master)](https://github.com/scrive/hpqtypes-extras/actions?query=branch%3Amaster)+[![CI](https://github.com/scrive/hpqtypes-extras/actions/workflows/haskell-ci.yml/badge.svg?branch=master)](https://github.com/scrive/hpqtypes-extras/actions/workflows/haskell-ci.yml) [![Hackage](https://img.shields.io/hackage/v/hpqtypes-extras.svg)](https://hackage.haskell.org/package/hpqtypes-extras)+[![Stackage LTS](https://www.stackage.org/package/hpqtypes-extras/badge/lts)](https://www.stackage.org/lts/package/hpqtypes-extras)+[![Stackage Nightly](https://www.stackage.org/package/hpqtypes-extras/badge/nightly)](https://www.stackage.org/nightly/package/hpqtypes-extras)  The following extras for [hpqtypes](http://hackage.haskell.org/package/hpqtypes) library:
hpqtypes-extras.cabal view
@@ -1,6 +1,6 @@ cabal-version:       3.0 name:                hpqtypes-extras-version:             1.18.0.0+version:             1.19.0.0 synopsis:            Extra utilities for hpqtypes library description:         The following extras for hpqtypes library:                      .@@ -20,7 +20,7 @@ copyright:           Scrive AB category:            Database build-type:          Simple-tested-with:         GHC == { 8.10.7, 9.0.2, 9.2.8, 9.4.8, 9.6.6, 9.8.4, 9.10.2, 9.12.2 }+tested-with:         GHC == { 9.2.8, 9.4.8, 9.6.7, 9.8.4, 9.10.3, 9.12.2, 9.14.1 }  Source-repository head   Type:     git@@ -82,8 +82,8 @@   other-modules:   Database.PostgreSQL.PQTypes.Checks.Util                  , Database.PostgreSQL.PQTypes.Utils.NubList -  build-depends: base              >= 4.13     && < 5-               , hpqtypes          >= 1.8.0.0+  build-depends: base              >= 4.16     && < 5+               , hpqtypes          >= 1.13.0.0                , base16-bytestring >= 0.1                , bytestring        >= 0.10                , containers        >= 0.5
src/Database/PostgreSQL/PQTypes/Checks.hs view
@@ -855,9 +855,6 @@   -> [Migration m]   -> m () checkDBConsistency options domains enums tablesWithVersions migrations = do-  autoTransaction <- tsAutoTransaction <$> getTransactionSettings-  unless autoTransaction $ do-    error "checkDBConsistency: tsAutoTransaction setting needs to be True"   -- Check the validity of the migrations list.   validateMigrations   validateDropTableMigrations@@ -1135,7 +1132,7 @@           -- because using 'commit' function automatically starts another           -- transaction. We don't want that as concurrent creation of index           -- won't run inside a transaction.-          bracket_ (runSQL_ "COMMIT") (runSQL_ "BEGIN") $ do+          unsafeWithoutTransaction $ do             -- If migration was run before but creation of an index failed, index             -- will be left in the database in an inactive state, so when we             -- rerun, we need to remove it first (see@@ -1151,7 +1148,7 @@           -- because using 'commit' function automatically starts another           -- transaction. We don't want that as concurrent dropping of index           -- won't run inside a transaction.-          bracket_ (runSQL_ "COMMIT") (runSQL_ "BEGIN") $ do+          unsafeWithoutTransaction $ do             runQuery_ (sqlDropIndexConcurrently tname idx)           updateTableVersion         ModifyColumnMigration tableName cursorSql updateSql batchSize -> do
src/Database/PostgreSQL/PQTypes/Model/Trigger.hs view
@@ -28,7 +28,7 @@   ) where  import Data.Bits (testBit)-import Data.Foldable (foldl')+import Data.Foldable qualified as F import Data.Int import Data.Monoid.Utils import Data.Set (Set)@@ -320,7 +320,7 @@         -- the same bit set in the underlying tgtype bit field.         trgEvents :: Set TriggerEvent         trgEvents =-          foldl'+          F.foldl'             ( \set (mask, event) ->                 if testBit tgtype mask                   then
test/Main.hs view
@@ -1839,13 +1839,10 @@       sqlSetList "name" $ (\i -> "bank" <> show i) <$> numbers       sqlSetList "location" $ (\i -> "location" <> show i) <$> numbers -    -- Explicitly vacuum to update the catalog so that getting the row number estimates-    -- works. The bracket_ trick is here because vacuum can't run inside a transaction-    -- block, which every test runs in.-    bracket_-      (runSQL_ "COMMIT")-      (runSQL_ "BEGIN")-      (runSQL_ "VACUUM bank")+    -- Explicitly vacuum to update the catalog so that getting the row number+    -- estimates works. Note that vacuum can't run inside a transaction block,+    -- which every test runs in.+    unsafeWithoutTransaction $ runSQL_ "VACUUM bank"      forM_ (zip4 tables migrations steps assertions) $       \(table, migration, step', assertion) -> do