zio-query icon indicating copy to clipboard operation
zio-query copied to clipboard

Implement some missing ZIO combinators

Open nbenns opened this issue 4 years ago • 9 comments

Combinators we are used to in ZIO don't yet exist in ZQuery.

ZQuery.access ZQuery.accessM

There are definitely more.

This is a ticket to these specific combinators and perhaps some more.

nbenns avatar May 19 '20 00:05 nbenns

Totally agree. So far I have tried to be a fast follower and just add combinators very quickly when anyone needs them but could be worth a more comprehensive effort to implement all the ZIO combinators that make sense so users have all the tools they are used to from ZIO when working with ZQuery. Will try to put together a comprehensive list that we can work through but if there are any particular ones you are looking for can add them immediately..

adamgfraser avatar May 19 '20 12:05 adamgfraser

I recently had a need for ensuring. Someone on Discord was also looking for someOrFail.

ghostdogpr avatar Jul 11 '20 04:07 ghostdogpr

someOrFail would be helpful to me!

aappddeevv avatar Aug 15 '20 19:08 aappddeevv

@aappddeevv Just added someOrFail in #108.

ensuring will take a little more work since I think that will require changes to the underlying representation but will work on that.

If anyone has other operators that would be helpful to them please comment here and I will start a list.

adamgfraser avatar Oct 07 '20 17:10 adamgfraser

@adamgfraser gonna take this on for the hackathon

paulpdaniels avatar Nov 21 '20 02:11 paulpdaniels

@adamgfraser timeoutTo, timeoutFail and other timeout combinators would be immensely helpful!

voidconductor avatar Jun 15 '21 08:06 voidconductor

@voidconductor Will add!

adamgfraser avatar Jun 15 '21 13:06 adamgfraser

ZQuery.collectAll(Option) would be nice. I think it would be very easy to implement since there is already a ZQuery.foreach(Option).

Maybe some other overloads of ZQuery.collectAll as well (Set, Array).

mikaelstaldal avatar Nov 26 '21 15:11 mikaelstaldal

@mikaelstaldal Will add!

adamgfraser avatar Nov 26 '21 20:11 adamgfraser