Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Ryan Zeigler
    @rzeigler
    We are a little behind I just hate upgrading those components because grpc has no concept of compatibility from what I can tell
    Rob Norris
    @tpolecat
    Yeah I need to look at how the auto-lens stuff works.
    There are way too many fires burning atm. Between Scala 3 and CE3 there's not a lot of time for extinguishing other things.
    Keir Lawson
    @keirlawson
    Anyone any success combining Natchez with fs2? struggling a little as to how to combine .span which wants a Kleisli[F, Span[F], A] and the type I want to produce which is a fs2.Stream[Kleisli[F, Span[F], *], A]
    Ryan Zeigler
    @rzeigler
    Are you trying to track how long the entire stream runs or individual operations within it?
    Keir Lawson
    @keirlawson
    The entire stream
    Ryan Zeigler
    @rzeigler
    You can stick a span around the compile action.
    i.e. Trace[F].span(“stream”)(s.compile.drain)
    Rob Norris
    @tpolecat
    There is a lingering PR to create a Trace instance for streams but I haven’t had any time to think about it.
    Keir Lawson
    @keirlawson
    @rzeigler I'm wanting to pass back the traced stream elsewhere though, rather than turn it into an F at the point of adding the tracing
    Ryan Zeigler
    @rzeigler
    So, the alternative option (and I haven't really exploded this, is that spans are resources yourself. I think you could probably define a pipe that traces a stream and does something like
    Stream.eval(Kleisli.ask).flatMap(span => Stream.resource(span.subspan("name"))) >> innerStream
    Adam Rosien
    @arosien
    exploding spans are definitely cool
    Ryan Zeigler
    @rzeigler
    I swear, sometimes my brain explodes. I wish I could play that off like phone autocorrect, but I definitely typed it on a keyboard.
    Adam Rosien
    @arosien
    does flatMap prevent exploding spans? nobody knows.
    Keir Lawson
    @keirlawson
    @rzeigler your solution seems (as in it compiles :D ) to work for me with a little sprinkling of mapKs and translates to make everything line up :)
    Keir Lawson
    @keirlawson
    Generalising slightly from the above problem, so far as I can see if I have F[_] : Trace there's no way to have Stream[F, A] that embeds a subspan without wrapping in an F[_] given the present Trace API, unless I specifically assume that F is Kleisli, is this correct? If so this seems to be a bit of a pain point for writing transparent wrappers around other libs that inolve Stream, perhaps the API could be adjusted to accomodate scenarios like this?
    Rob Norris
    @tpolecat
    Trace[F] should imply Trace[Stream[F
    There is a WIP out there somewhere
    Keir Lawson
    @keirlawson
    I find myself copying and pasting convenience code to make Natchez' Trace constraint place nice with munit-cats-effect between various projects and I was wondering if it would make sense to A. add an munit module to Natchez, B. add a Natchez module to munit-cats-effect, C. create a library independent of the two or D. not bother cos its only a wee bit of code
    (asking here as there isn't really a channel for munit-cats-effect)
    Rob Norris
    @tpolecat
    I hesitate to add more stuff to natchez at this point, I was actually thinking of busting it up.
    Maybe I should create a natchez org and add you blokes as maintainers.
    Christopher Davenport
    @ChristopherDavenport
    I've got some stuff for you if you have an org.
    Rob Norris
    @tpolecat
    Of course having different versions and release cycles for every back end is a hassle.
    No easy way to do this.
    Christopher Davenport
    @ChristopherDavenport
    Millions of microlibraries isn't easy enough for you?
    :laughing:
    Andrey Patseev
    @patseev
    Hi everyone! Would anyone be against adding method spanId in a Span? It's easy to retrieve for all OT based backends and is useful specifically for Datadog, combination of span_id + trace_id allows to bind logs and traces together
    Rob Norris
    @tpolecat
    Seems fine.
    Andrey Patseev
    @patseev
    Neat. Will create a PR soonish
    Andrey Patseev
    @patseev
    Hi all! Created a PR that adds spanId to spans + replaced mocked "traceId" in most places.
    tpolecat/natchez#240
    Rob Norris
    @tpolecat
    Thanks I will have a look.
    Andrey Patseev
    @patseev
    Hey! Added support for traceUri in Datadog module. Forgot to include that in previous MR
    tpolecat/natchez#255
    Rob Norris
    @tpolecat
    Hey fyi there's now this https://github.com/tpolecat/natchez-http4s for people trying to get Natchez working with http4s. It works for me, might work for you, who knows.
    Tristan Lohman
    @gatorcse
    Hey, are there plans to update natchez for cats-effect 3 to use IOLocal? Or is that considered out of scope for the library? Or do I misunderstand IOLocal and that won’t work?
    Rob Norris
    @tpolecat
    It will work and I have a branch for it, just haven't pushed it yet. Hang on.
    Tristan Lohman
    @gatorcse
    no worries, was just curious if I should wait or attempt to build it myself
    Rob Norris
    @tpolecat
    Some merge issues I need to fix, looks like, from re-enabling the example project. Anyway that snippet seems to work.
    Tristan Lohman
    @gatorcse
    oh sweet, I’ll take a look, thanks!
    Rob Norris
    @tpolecat
    Hi everyone, we're trying out Discord since Gitter seems to be deteriorating. If you'd like to join up we're at https://discord.gg/3CaVqfxe
    Adam Rosien
    @arosien
    deteriorating?
    Rob Norris
    @tpolecat
    Doesn't work well on mobile, etc.
    Adam Rosien
    @arosien
    i thought we all had to be glued to our laptops, that was the deal
    Adam Rosien
    @arosien
    i now have slack, discord, ring central, zulip and gitter :thumbsup:
    arzig
    @arzig:matrix.org
    [m]
    I use a matrix client now and it has been bearable.
    Rob Norris
    @tpolecat
    General Notice: Typelevel discussions are moving to Discord. There's a Natchez room there. https://sca.la/typeleveldiscord
    Gerry Fletcher
    @gerryfletch

    That was silly of me. I was messaging the Skunk room instead of here... total accident! Sorry.

    At work I do a fair bit of dashboarding and it helps to write out the objects as JSON in the logs to write some more complex queries without regex or other manipulation. Curious what others consider best practise, and also if you use middleware to log all incoming request + response bodies?

    Rob Norris
    @tpolecat
    I have been using natchez-http4s, see the doc there for info on what it logs. I may add more stuff to it.
    Gerry Fletcher
    @gerryfletch
    Yes I'm using it too (thank you for the lib), but it doesn't log any objects. That's the bit I'm curious about