interop-cats
interop-cats copied to clipboard
def realTime: F[FiniteDuration] only provides millisecond precision
I'm debugging an issue with a tracing library which works with cats.effect.kernel.Clock.realTime: F[FiniteDuration]
. In services which use this tracing library and Cats Effect, traces have nanosecond accuracy. In the service I'm working on, which uses ZIO and interop-cats, I'm only getting millisecond accuracy, and I've tracked it to this:
https://github.com/zio/interop-cats/blob/bf24db580870f23ef1a8493335b340ac43ba0e71/zio-interop-cats/shared/src/main/scala/zio/interop/cats.scala#L559
Could it be changed to provide nanosecond precision?