Skip to content

withMPD raises IOException instead of returning Left (ConnectionError e) #114

@crocket

Description

@crocket
*** Exception: Network.Socket.connect: <socket: 41>: does not exist (Connection refused)

I think it's supposed to return Left (ConnectionError e) instead of raising an IOException.

For now, I work around the issue with

import System.IO.Error (catchIOError)
import qualified Network.MPD as M

catchIOError (M.withMPD M.status) $ return . Left . M.ConnectionError

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions