bugsnag-haskell: Bugsnag error reporter for Haskell

[ library, mit, web ] [ Propose Tags ]

Please see README.md


[Skip to Readme]
Versions 0.0.1.1, 0.0.1.2, 0.0.1.3, 0.0.2.0, 0.0.2.1, 0.0.2.2
Change log CHANGELOG.md
Dependencies aeson (>=1.3.0.0), base (>=4.8.0 && <5), bugsnag-haskell, bytestring, case-insensitive, containers, exceptions, Glob (>=0.9.0), http-client, http-client-tls, http-conduit, http-types, iproute, network, parsec, template-haskell, text, th-lift-instances, time, ua-parser, unliftio, wai, warp, yesod-core [details]
License MIT
Author Patrick Brisbin
Maintainer pbrisbin@gmail.com
Category Web
Home page https://github.com/pbrisbin/bugsnag-haskell#readme
Uploaded by PatrickBrisbin at Wed Nov 7 20:25:41 UTC 2018
Distributions NixOS:0.0.2.2, Stackage:0.0.2.2
Executables example-yesod, example-warp, example-simple, example-cli
Downloads 293 total (49 in the last 30 days)
Rating (no votes yet) [estimated by rule of succession]
Your Rating
  • λ
  • λ
  • λ
Status Docs available [build log]
Last success reported on 2018-11-07 [all 1 reports]
Hackage Matrix CI

Modules

[Index] [Quick Jump]

Flags

NameDescriptionDefaultType
examples

Build the examples

DisabledAutomatic

Use -f <flag> to enable a flag, or -f -<flag> to disable that flag. More info

Downloads

Maintainer's Corner

For package maintainers and hackage trustees


Readme for bugsnag-haskell-0.0.2.2

[back to package description]

Bugsnag error reporter for Haskell

Catch and report exceptions in your Haskell code.

Configuration

settings <- newBugsnagSettings "BUGSNAG_API_KEY"

See Network.Bugsnag.Settings.

Reporting an Error

notifyBugsnag settings $ toException
    $ bugsnagException "Error" "message"
        [ $(currentStackFrame) "myFunction"
        ]

See Network.Bugsnag.Notify.

Throwing & Catching

Throw a BugsnagException yourself:

throw
    $ bugsnagException "Error" "message" [$(currentStackFrame) "myFunction"]

Catch any exceptions, notify, and re-throw it:

myFunction `catch` \ex -> do
    notifyBugsnag settings ex
    throw ex

Examples

Examples can be built locally with:

stack build --flag bugsnag-haskell:examples

Contributing

See CONTRIBUTING.


CHANGELOG | LICENSE