diff --git a/CHANGES b/CHANGES
--- a/CHANGES
+++ b/CHANGES
@@ -1,3 +1,7 @@
+1.2.3 (2020/7/3)
+
+* GHC 8.8 and 8.10 support (Ben Franksen)
+
 1.2.2 (2015/5/6)
 
 * Change of maintainer
diff --git a/CouchDB.cabal b/CouchDB.cabal
--- a/CouchDB.cabal
+++ b/CouchDB.cabal
@@ -1,6 +1,6 @@
 Name:           CouchDB
-Version:        1.2.2
-Cabal-Version:	>= 1.8
+Version:        1.2.3
+Cabal-Version:	>= 1.10
 Copyright:      Copyright (c) 2008-2012.
 License:        BSD3
 License-file:   LICENSE
@@ -26,30 +26,31 @@
 
 Test-Suite test-couchdb
   Hs-Source-Dirs: src
+  default-language: Haskell2010
   Type: exitcode-stdio-1.0
   Main-Is: Tests.hs
   Build-Depends:
-    base >= 4 && < 5, mtl, containers, HTTP>=4000.0.4, json>=0.4.3, utf8-string >= 0.3.6 && <= 1.1, HUnit, bytestring
+    base, mtl, containers, HTTP>=4000.0.4, json>=0.4.3, utf8-string >= 0.3.6 && <= 1.1, HUnit, bytestring
   if flag(network-uri)
     build-depends: network >= 2.6, network-uri >= 2.6
   else
     build-depends: network < 2.6, network-uri < 2.6
-  Extensions:
+  default-extensions:
     FlexibleInstances
   ghc-options:
     -fwarn-incomplete-patterns
  
 Library
   Hs-Source-Dirs: src
+  default-language: Haskell2010
   Build-Depends:
-    base >= 4 && < 5, mtl, containers, network, network-uri, HTTP>=4000.0.4, json>=0.4.3, utf8-string >= 0.3.6 && <= 1.1, bytestring
+    base >= 4 && < 4.15, mtl, containers, network, network-uri, HTTP>=4000.0.4, json>=0.4.3, utf8-string >= 0.3.6 && <= 1.1, bytestring
   if flag(network-uri)
     build-depends: network >= 2.6, network-uri >= 2.6
   else
     build-depends: network < 2.6, network-uri < 2.6
   ghc-options:
     -fwarn-incomplete-patterns
-  Extensions:     
   Exposed-Modules:
     Database.CouchDB Database.CouchDB.JSON
   Other-Modules:
diff --git a/src/Database/CouchDB/HTTP.hs b/src/Database/CouchDB/HTTP.hs
--- a/src/Database/CouchDB/HTTP.hs
+++ b/src/Database/CouchDB/HTTP.hs
@@ -2,6 +2,7 @@
 -- CouchDB enjoys closing the connection if there is an error (document
 -- not found, etc.)  In such cases, 'CouchMonad' will automatically
 -- reestablish the connection.
+{-# LANGUAGE CPP #-}
 module Database.CouchDB.HTTP 
   ( request
   , RequestMethod (..)
@@ -64,6 +65,9 @@
     let (CouchMonad m') = k a
     m' conn'
 
+#if MIN_VERSION_base(4,13,0)
+instance MonadFail CouchMonad where
+#endif
   fail msg = CouchMonad $ \conn -> do
     fail $ "internal error: " ++ msg   
 
diff --git a/src/Tests.hs b/src/Tests.hs
--- a/src/Tests.hs
+++ b/src/Tests.hs
@@ -93,15 +93,19 @@
 testNamedDocs = testWithDB "add named documents" $ \mydb -> do
   newNamedDoc mydb (doc "arjun") (people !! 0)
   newNamedDoc mydb (doc "alex") (people !! 1)
-  Just (_,_,v1) <- getDoc mydb (doc "arjun")
-  Just (_,_,v2) <- getDoc mydb (doc "alex") 
-  return $ (v1 == people !! 0) && (v2 == people !! 1)
+  jv1 <- getDoc mydb (doc "arjun")
+  jv2 <- getDoc mydb (doc "alex")
+  case (jv1,jv2) of
+    (Just (_,_,v1), Just (_,_,v2)) ->
+      return $ (v1 == people !! 0) && (v2 == people !! 1)
+    _ -> error "impossible"
 
 testUTF8 = testWithDB "test UTF8 characters" $ \db -> do
   newNamedDoc db (doc "d0") (Age "äöüß" 900)
-  Just (_, _, d) <- getDoc db (doc "d0")
-  return (ageName d == "äöüß")
-
+  jd <- getDoc db (doc "d0")
+  case jd of
+    Just (_, _, d) -> return (ageName d == "äöüß")
+    _ -> error "impossible"
   
 allTests = TestList [ testCreate, testNamedDocs, testUTF8 ]
 
