log-warper
log-warper copied to clipboard
Logging library to provide more convenient, extremely configurable but simple monadic interface with pretty output
Required for https://github.com/serokell/yt-utilities/pull/176
- Add following line to any file that use logging: `logWarning $ toText $ map chr [128]` - Build, run Expected: Program not crashes Actual: Program crashes with `play-log: :...
Basically rewrite this module into new interface using new `Configuration` type: * https://github.com/serokell/log-warper/blob/fb0ea8451db9a832baf619f59d937b723c983415/log-warper/src/Logw/IOLogger.hs **NOTE:** Update logging tutorial and playground after this is done.
Currently only terminal action is implemented in `log-warper-2.0`. Would be great to implement file handler as well. **NOTE:** Update logging tutorial and playground after this is done.
Currently logger rotation is not implemented in `log-warper-2.0`.
This module: * https://github.com/serokell/log-warper/blob/fb0ea8451db9a832baf619f59d937b723c983415/log-warper/src/Logw/Pure.hs **NOTE:** Update pure logging tutorial and playground after this is done.
Current approach for logging extensions is not externally extensible. It's great to have more flexible logging configuration: * https://github.com/serokell/log-warper/blob/fb0ea8451db9a832baf619f59d937b723c983415/log-warper/src/Logw/Configuration/Type.hs#L68 For reference see discussion here: * https://github.com/serokell/log-warper/pull/108#discussion_r183030304
https://github.com/serokell/log-warper/tree/fb0ea8451db9a832baf619f59d937b723c983415/log-warper/test
This module: * https://github.com/serokell/log-warper/blob/fb0ea8451db9a832baf619f59d937b723c983415/log-warper/src/Logw/Exception.hs It contains useful functions.