Skip to content

failing with ghc-8.8.1 MonadFail #23

Description

@juhp

For Stackage Nightly:

    Preprocessing test suite 'test-simple' for simple-0.11.3..
    Building test suite 'test-simple' for simple-0.11.3..
    
    <no location info>: warning: [-Wmissing-home-modules]
        These modules are needed for compilation but not listed in your .cabal file's other-modules: 
            Web.Simple.Controller.Trans Web.Simple.Responses
    
    <no location info>: warning: [-Wmissing-home-modules]
        These modules are needed for compilation but not listed in your .cabal file's other-modules: 
            Web.Simple.Controller.Trans Web.Simple.Responses
    Preprocessing library for simple-0.11.3..
    Building library for simple-0.11.3..
    [10 of 10] Compiling Web.Simple.Templates
    
    /var/stackage/work/unpack-dir/unpacked/simple-0.11.3-403f671a4a4d8670cc77557e49a63392abf393e4d092b020574640b534039e4c/src/Web/Simple/Templates.hs:128:17: error:
        • Could not deduce (MonadFail (ControllerT hs m))
            arising from a use of ‘fail’
          from the context: (HasTemplates m hs, MonadIO m)
            bound by the type signature for:
                       defaultGetTemplate :: forall (m :: * -> *) hs.
                                             (HasTemplates m hs, MonadIO m) =>
                                             FilePath -> ControllerT hs m Template
            at src/Web/Simple/Templates.hs:(123,1)-(124,59)
        • In the expression: fail str
          In a case alternative: Left str -> fail str
          In a stmt of a 'do' block:
            case compileTemplate . decodeUtf8 $ contents of
              Left str -> fail str
              Right tmpl -> return tmpl
        |
    128 |     Left str -> fail str
        |                 ^^^^^^^^

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions