-
Notifications
You must be signed in to change notification settings - Fork 221
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fs2 EncodeStream for both ConcurrentEffect and Effect monads #1082
Conversation
It works just fine on 2.12 😞 |
9e98d4e
to
167b689
Compare
Codecov Report
@@ Coverage Diff @@
## master #1082 +/- ##
==========================================
- Coverage 80.62% 80.15% -0.48%
==========================================
Files 54 54
Lines 1017 1028 +11
Branches 59 59
==========================================
+ Hits 820 824 +4
- Misses 197 204 +7
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this @joroKr21! Does this slow down compilation at all? We've been trying to be careful with introducing more complexity that could potentially slow down the implicit resolution.
@rpless @sergeykolbasov Mind taking a look?
I'm not too concerned about compile times. After scala/scala#7067 implicits in Scala 2.12 and 2.13 are not that expensive anymore. I'm more concerned about:
|
@joroKr21 Mind rebasing this? |
The `ConcurrentEffect` instances are prioritized higher. This means users can benefit from cancellation when possible without loss of generality.
167b689
to
71c006a
Compare
👍 I just solved the On cancellation test topic, could we get some inspiration from cats-effect laws: https://github.com/typelevel/cats-effect/blob/master/laws/shared/src/test/scala/cats/effect/IOCancelableTests.scala#L76-L89 ? |
FWIW, I'm happy if we decide to add a specific cancelation test later, in the upcoming commit. Let's merge this, it's been on review for quite some time. |
First we have to migrate the tests to use a |
The
ConcurrentEffect
instances are prioritized higher.This means users can benefit from cancellation when possible
without loss of generality.
@vkostyukov this is what I had in mind with providing both versions and prioritizing them. But I don't know how to test that cancellation actually works. Any ideas?