Skip to content

Conversation

@neko-kai
Copy link
Member

Seems to be working: cats-effect laws pass, but there may still be problems they don't reveal

@neko-kai neko-kai requested a review from pshirshov as a code owner July 27, 2022 21:04
@codecov-commenter
Copy link

codecov-commenter commented Jul 27, 2022

Codecov Report

Merging #1766 (1c1553e) into develop (1623459) will decrease coverage by 1.80%.
Report is 2 commits behind head on develop.
The diff coverage is 61.03%.

❗ Current head 1c1553e differs from pull request most recent head 8a1c2ec. Consider uploading reports for the commit 8a1c2ec to get more accurate results

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

@@             Coverage Diff             @@
##           develop    #1766      +/-   ##
===========================================
- Coverage    65.39%   63.59%   -1.80%     
===========================================
  Files          557      479      -78     
  Lines        11061     9636    -1425     
  Branches         0      491     +491     
===========================================
- Hits          7233     6128    -1105     
+ Misses        3828     3508     -320     

@mucaho
Copy link

mucaho commented Jul 28, 2022

Would it be possible to generalize this even further?

Namely, given any monofunctor F[_] and a corresponding cats type class instance e.g. cats.Applicative[F], generate the respective BIO type class instance [+E, +A] => izumi.functional.bio.Applicative2[Bifunctorized[F, E, A]] for it.

Repeat that for all conversions in izumi.functional.bio.CatsConversions, just the other way around

@neko-kai
Copy link
Member Author

neko-kai commented Jul 29, 2022

@mucaho
Sure, just need to make sure it's sound first.

@pshirshov pshirshov force-pushed the develop branch 2 times, most recently from be4d382 to 6dda1f0 Compare February 1, 2023 19:22
@mucaho
Copy link

mucaho commented Oct 6, 2023

Great to see this is still being worked on, thanks!

While this was being worked on, I have created my own two conversions I needed in the meantime, not sure if they are completely sound though, in case anyone needs: https://bitbucket.org/mucaho/ceffbanx/src/8986109fb7e9e97c7ae5a71ba311ff9d915634b8/src/main/scala/org/bitbucket/mucaho/ceffbanx/Util.scala#lines-130:180

@neko-kai
Copy link
Member Author

cats-mtl added "submarine error handling" in similar vein - typelevel/cats-mtl#619 associated blogpost
The distinction between cats.Submarine and bio.TypedError is that Submarine uses an additional AnyRef to ensure valid nesting of handlers. Not sure whether that's a relevant addition for bifunctors.

@neko-kai
Copy link
Member Author

NB: nesting of handlers may not be relevant for bifunctorization. But distinguishing between different bifunctorized effect types may be. (we could just use TagK instead of path-dependency?)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants