Skip to content

Add functions for working with Colog.Message #1

Description

@srid

co-log itself provides these:

Image

Whereas, co-log-effectful only provides:

Image

In my application, I'm creating a wrapper function to mimic the co-log wrappers:

log :: forall es. (HasCallStack, Log Message :> es) => Severity -> Text -> Eff es ()
log msgSeverity msgText =
  withFrozenCallStack $ logMsg $ Msg {msgStack = callStack, ..}

In context: https://github.com/juspay/vira/blob/b600377d7e271fb600a544c00625e0a232086feb/packages/vira/src/Vira/App/Logging.hs#L41-L48

Would it make sense to upstream that function to this library in some form?

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