2024/10/02

Newest at the top

2024-10-02 16:26:01 +0200 <EvanR_> traverse is doubly generalized mapM
2024-10-02 16:25:49 +0200acidsys(~crameleon@openSUSE/member/crameleon) crameleon
2024-10-02 16:24:10 +0200YaShhhh(~YaShhhh@202.43.120.115)
2024-10-02 16:22:33 +0200merijn(~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 276 seconds)
2024-10-02 16:19:15 +0200machinedgod(~machinedg@d50-99-47-73.abhsia.telus.net) (Ping timeout: 265 seconds)
2024-10-02 16:19:11 +0200codaraxis(~codaraxis@user/codaraxis) Codaraxis
2024-10-02 16:18:39 +0200codaraxis___(~codaraxis@user/codaraxis) (Ping timeout: 246 seconds)
2024-10-02 16:17:13 +0200merijn(~merijn@204-220-045-062.dynamic.caiway.nl) merijn
2024-10-02 16:16:39 +0200lortabac(~lortabac@2a01:e0a:541:b8f0:55ab:e185:7f81:54a4) (Quit: WeeChat 4.2.2)
2024-10-02 16:07:03 +0200merijn(~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 245 seconds)
2024-10-02 16:05:20 +0200athan(~athan@syn-098-153-145-140.biz.spectrum.com) (Ping timeout: 252 seconds)
2024-10-02 16:02:29 +0200merijn(~merijn@204-220-045-062.dynamic.caiway.nl) merijn
2024-10-02 16:02:02 +0200bionade24(~quassel@2a03:4000:33:45b::1) bionade24
2024-10-02 16:02:01 +0200bionade24_(~quassel@2a03:4000:33:45b::1) (Remote host closed the connection)
2024-10-02 16:01:21 +0200acidsys(~crameleon@openSUSE/member/crameleon) (Ping timeout: 248 seconds)
2024-10-02 16:01:09 +0200ljdarj1ljdarj
2024-10-02 16:00:24 +0200morb(~morb@pool-108-41-100-120.nycmny.fios.verizon.net) (Ping timeout: 265 seconds)
2024-10-02 16:00:23 +0200codaraxis(~codaraxis@user/codaraxis) (Ping timeout: 245 seconds)
2024-10-02 15:59:13 +0200 <lortabac> I can't think of a more handwaivy explanation than this one :)
2024-10-02 15:58:51 +0200ljdarj1(~Thunderbi@user/ljdarj) ljdarj
2024-10-02 15:58:43 +0200ljdarj(~Thunderbi@user/ljdarj) (Read error: Connection reset by peer)
2024-10-02 15:58:43 +0200 <lortabac> but since 'fetchUserByID' is an IO action you need (traverse fetchUserByID userIds)
2024-10-02 15:57:50 +0200 <lortabac> if it was a pure computation you would do (map fetchUserByID userIds)
2024-10-02 15:57:20 +0200 <lortabac> immagine you have a list of user ID's and want to fetch the corrisponding users from the database
2024-10-02 15:57:09 +0200codaraxis__(~codaraxis@user/codaraxis) (Ping timeout: 248 seconds)
2024-10-02 15:56:32 +0200codaraxis___(~codaraxis@user/codaraxis) Codaraxis
2024-10-02 15:55:33 +0200morb(~morb@pool-108-41-100-120.nycmny.fios.verizon.net)
2024-10-02 15:54:54 +0200 <lortabac> __monty__: you can think of 'traverse' as an 'fmap' in which the function is not pure but includes an Applicative "effect"
2024-10-02 15:54:01 +0200codaraxis(~codaraxis@user/codaraxis) Codaraxis
2024-10-02 15:52:19 +0200codaraxis(~codaraxis@user/codaraxis) (Ping timeout: 260 seconds)
2024-10-02 15:51:49 +0200merijn(~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 248 seconds)
2024-10-02 15:50:27 +0200codaraxis__(~codaraxis@user/codaraxis) Codaraxis
2024-10-02 15:49:14 +0200 <Rembane> But in a handwavy way: it's fmap and then sequence because I need to change swap f and t
2024-10-02 15:48:32 +0200 <Rembane> That one didn't help. :D
2024-10-02 15:48:21 +0200 <lambdabot> (Traversable ((->) (m a1)), Monad m) => (a1 -> a2) -> m (m a1 -> a2)
2024-10-02 15:48:20 +0200 <Rembane> :t sequence . fmap
2024-10-02 15:48:07 +0200 <lambdabot> Functor f => (a -> b) -> f a -> f b
2024-10-02 15:48:06 +0200 <Rembane> :t fmap
2024-10-02 15:48:02 +0200 <lambdabot> (Traversable t, Monad m) => t (m a) -> m (t a)
2024-10-02 15:48:01 +0200 <Rembane> :t sequence
2024-10-02 15:47:50 +0200 <lambdabot> (Traversable t, Applicative f) => (a -> f b) -> t a -> f (t b)
2024-10-02 15:47:49 +0200 <Rembane> :t traverse
2024-10-02 15:47:04 +0200merijn(~merijn@204-220-045-062.dynamic.caiway.nl) merijn
2024-10-02 15:36:10 +0200 <__monty__> Anyone have a good mental model of what "traverse" does? I think my difficulties with <*> are leaking into my lack of understanding of Traversable.
2024-10-02 15:35:59 +0200merijn(~merijn@204-220-045-062.dynamic.caiway.nl) (Ping timeout: 252 seconds)
2024-10-02 15:31:39 +0200merijn(~merijn@204-220-045-062.dynamic.caiway.nl) merijn
2024-10-02 15:26:10 +0200ljdarj1ljdarj
2024-10-02 15:26:09 +0200ljdarj(~Thunderbi@user/ljdarj) (Ping timeout: 248 seconds)
2024-10-02 15:24:52 +0200ljdarj1(~Thunderbi@user/ljdarj) ljdarj
2024-10-02 15:24:25 +0200AlexZenon(~alzenon@178.34.162.53)