log package:co-log

Logs the message with given severity sev.
Action that prints ByteString to Handle. This action does not flush the output buffer. If buffering mode is block buffering, the effect of this action can be delayed.
Action that prints ByteString to stderr. This action does not flush the output buffer. If buffering mode is block buffering, the effect of this action can be delayed.
Action that prints ByteString to stdout. This action does not flush the output buffer. If buffering mode is block buffering, the effect of this action can be delayed.
Action that prints Text to Handle. This action does not flush the output buffer. If buffering mode is block buffering, the effect of this action can be delayed.
Action that prints Text to stderr. This action does not flush the output buffer. If buffering mode is block buffering, the effect of this action can be delayed.
Action that prints Text to stdout. This action does not flush the output buffer. If buffering mode is block buffering, the effect of this action can be delayed.
Logs the message with the Debug severity.
Logs the message with the Error severity.
Logs Exception message with the Error severity.
Logs the message with the Info severity.
Logs SimpleMsg without severity, only CallStack and Text body message.
Logs the message with the Warning severity.
Lens for LogAction inside the environment.
Perform logging action with given message msg. This function works for monads that have access to LogAction. You can use this function like this:
example :: WithLog env String m => m ()
example = do
logMsg "First message..."
logMsg "Second message..."
Logs multiple messages.
LogAction that prints msg by appending it to the end of the sequence.
newtype wrapper ReaderT that keeps LogAction in its context.
Composable Contravariant Comonadic Logging Library The default implementation of logging based on co-log-core. The ideas behind this package are described in the following blog post:
This package contains mtl implementation of composable, contravariant and comonadic logging based on co-log-core.
Action that prints ByteString to file. See withLogStringFile for details.
Action that prints Text to file. See withLogStringFile for details.
This types class contains simple pair of getter-setter and related functions. It also provides the useful lens logActionL with the default implementation using type class methods. The default one could be easily overritten under your instances. Every instance of the this typeclass should satisfy the following laws:
  1. Set-Get: getLogAction (setLogAction l env) ≡ l
  2. Get-Set: setLogAction (getLogAction env) env ≡ env
  3. Set-Set: setLogAction l2 (setLogAction l1 env) ≡ setLogAction l2 env
  4. Set-Over: overLogAction f env ≡ setLogAction (f $ getLogAction env) env
Type alias for constraint for:
  1. Monad m have access to environment env.
  2. Environment env contains LogAction that can log messages of type msg.
  3. Function call stack.
If you use this constraint, function call stack will be propagated and you will have access to code lines that log messages.