packages feed

yesod 1.6.0.1 → 1.6.0.2

raw patch · 4 files changed

+14/−8 lines, 4 files

Files

ChangeLog.md view
@@ -1,3 +1,7 @@+## 1.6.0.2++* Replace deprecated decodeFile with decodeFileEither. This should have no semantic impact, but silences a deprecation warning. [#1658](https://github.com/yesodweb/yesod/pull/1658)+ ## 1.6.0.1  * Remove unnecessary deriving of Typeable
Yesod/Default/Config.hs view
@@ -179,8 +179,8 @@            -> IO (AppConfig environment extra) loadConfig (ConfigSettings env parseExtra getFile getObject) = do     fp <- getFile env-    mtopObj <- decodeFile fp-    topObj <- maybe (fail "Invalid YAML file") return mtopObj+    etopObj <- decodeFileEither fp+    topObj <- either (const $ fail "Invalid YAML file") return etopObj     obj <- getObject env topObj     m <-         case obj of@@ -232,9 +232,10 @@                     -> (Value -> Parser a) -- ^ what to do with the mapping                     -> IO a withYamlEnvironment fp env f = do-    mval <- decodeFile fp+    mval <- decodeFileEither fp     case mval of-        Nothing -> fail $ "Invalid YAML file: " ++ show fp-        Just (Object obj)+        Left err ->+          fail $ "Invalid YAML file: " ++ show fp ++ " " ++ prettyPrintParseException err+        Right (Object obj)             | Just v <- M.lookup (T.pack $ show env) obj -> parseMonad f v         _ -> fail $ "Could not find environment: " ++ show env
Yesod/Default/Main.hs view
@@ -77,7 +77,7 @@   where     shouldLog' = Warp.defaultShouldDisplayException --- | Run your application continously, listening for SIGINT and exiting+-- | Run your application continuously, listening for SIGINT and exiting --   when received -- --   > withYourSite :: AppConfig DefaultEnv -> Logger -> (Application -> IO a) -> IO ()
yesod.cabal view
@@ -1,5 +1,5 @@ name:            yesod-version:         1.6.0.1+version:         1.6.0.2 license:         MIT license-file:    LICENSE author:          Michael Snoyman <michael@snoyman.com>@@ -8,12 +8,13 @@ description:     API docs and the README are available at <http://www.stackage.org/package/yesod> category:        Web, Yesod stability:       Stable-cabal-version:   >= 1.6+cabal-version:   >= 1.10 build-type:      Simple homepage:        http://www.yesodweb.com/ extra-source-files: README.md ChangeLog.md  library+    default-language: Haskell2010     if os(windows)         cpp-options: -DWINDOWS