packages feed

aeson-value-parser 0.19.2.1 → 0.19.3

raw patch · 2 files changed

+6/−2 lines, 2 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

Files

aeson-value-parser.cabal view
@@ -1,5 +1,5 @@ name: aeson-value-parser-version: 0.19.2.1+version: 0.19.3 synopsis: API for parsing "aeson" JSON tree into Haskell types description:   A flexible parser DSL of JSON AST produced by the \"aeson\" library
library/AesonValueParser.hs view
@@ -271,7 +271,11 @@   Just value -> case run fieldParser value of     Right parsedValue -> return parsedValue     Left error -> lift $ throwE $ Error.named name error-  Nothing -> throwE (Error.Error (pure name) "Object contains no field with this name")+  Nothing -> throwE (Error.Error (pure name) message)+    where+      message =+        "Object contains no field with this name. Fields available: " <>+        fromString (show (HashMap.keys object))  {-# INLINE oneOfFields #-} oneOfFields :: [Text] -> Value a -> Object a