Thread
#stdlib
    gsala

    gsala

    1 year ago
    Hey. I'm seeing a strange behavior where even though a
    Result
    is wrapping a failure, the
    isSuccess
    checks return
    true
    . The behavior matches the debugger output there. What could be going on?
    wasyl

    wasyl

    1 year ago
    I think you’re hitting https://youtrack.jetbrains.com/issue/KT-44527. The
    result
    should not be another
    Result
    instance I think, so your result is
    Result.Success(Result.Failure)
    ?
    Unless you’re using 1.5.0 already which should have it fixed
    gsala

    gsala

    1 year ago
    I'm using 1.5.0. The
    Result
    I have is the outcome of a
    runCatching {}
    but it actually seems like
    isSuccess() = false
    at first, then
    isSuccess() = true
    when I send/receive it through a channel 🤔
    I tried this in the Playground and it just outputs
    Result 1 is false
    Result 2 is false
    as expected. But in my case, Result 2 is true. It must be something on my end then