Home freenode/#haskell: Logs Calendar

Logs: freenode/#haskell

←Prev  Next→ 502,152 events total
2020-11-11 09:48:30 <dminuoso> I've had half a dozen "delete dist-newstyle and rebuild, and then it compiles" bugs already
2020-11-11 09:48:30 hackage casa-types 0.0.2 - Types for Casa https://hackage.haskell.org/package/casa-types-0.0.2 (MichaelSnoyman)
2020-11-11 09:48:32 <dminuoso> this week
2020-11-11 09:48:35 <asheshambasta> this is with dist* nuked: https://gist.github.com/asheshambasta/3597d25f179fc2729286c4b02387f282#file-cabal-full2-err
2020-11-11 09:48:51 <merijn> dminuoso: Really? I've not had that in...months, possibly years
2020-11-11 09:49:21 ensyde joins (~ensyde@99-185-235-117.lightspeed.chrlnc.sbcglobal.net)
2020-11-11 09:49:25 × jedws quits (~jedws@101.184.150.81) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-11-11 09:49:25 <dminuoso> merijn: Yeah
2020-11-11 09:49:46 <dminuoso> merijn: Yesterday I had a much much worse bug
2020-11-11 09:50:07 <maerwald> just never switch branches, ever, then you have less cache bugs
2020-11-11 09:50:32 <maerwald> IME, stack was wores when switching branches though
2020-11-11 09:50:44 <dminuoso> merijn: bunch of servant endpoints. in the tests using servant-client I called endpoint A, then B, then A again. On the second A call it *hung* inside of servant mysteriously.
2020-11-11 09:50:47 <dminuoso> Here comes the real beauty now:
2020-11-11 09:51:10 <dminuoso> recompiling my library with -threaded, it worked again
2020-11-11 09:51:14 <dminuoso> removing -threaded, it still worked.
2020-11-11 09:51:43 <dminuoso> So I have a piece of software with a real quantum mechanical weirdness bug that I dont know whether its fixed
2020-11-11 09:51:55 invaser1 joins (~Thunderbi@178-133-97-114.mobile.vf-ua.net)
2020-11-11 09:52:05 <maerwald> have you tried turning it on and off again? :D
2020-11-11 09:52:35 <bqv> Dipping my nose into arrows (again). I have a decent understanding, this time, but the static/dynamic example intrigues me. What precisely is different between such a static arrow and e.g. the state monad
2020-11-11 09:52:41 <dminuoso> Perhaps cabal 3.2 is just buggy and brittle?
2020-11-11 09:52:52 <maerwald> I'm running 3.4 rc since a while
2020-11-11 09:52:55 <maerwald> it's better
2020-11-11 09:53:04 × da39a3ee5e6b4b0d quits (~da39a3ee5@cm-171-98-69-111.revip7.asianet.co.th) (Ping timeout: 265 seconds)
2020-11-11 09:53:19 <bqv> dminuoso: test using nix, for hermeticity?
2020-11-11 09:53:31 <dminuoso> bqv: We have a large dependency footprint
2020-11-11 09:53:39 <bqv> Ah
2020-11-11 09:53:51 <dminuoso> After the nth conflict and fixing numerous haskell packages, I was just sick of it.
2020-11-11 09:54:11 × ensyde quits (~ensyde@99-185-235-117.lightspeed.chrlnc.sbcglobal.net) (Ping timeout: 258 seconds)
2020-11-11 09:54:14 × invaser quits (~Thunderbi@31.148.23.125) (Ping timeout: 256 seconds)
2020-11-11 09:54:14 invaser1 is now known as invaser
2020-11-11 09:54:17 <dminuoso> Updating dependencies in such a scenario is just really painful
2020-11-11 09:54:31 <dminuoso> So we build with cabal v2-* instead
2020-11-11 09:55:01 × invaser quits (~Thunderbi@178-133-97-114.mobile.vf-ua.net) (Client Quit)
2020-11-11 09:55:19 <dminuoso> asheshambasta: out of curiosity, can you share your cabal config?
2020-11-11 09:56:04 <merijn> dminuoso: eh
2020-11-11 09:56:12 <merijn> dminuoso: -threaded is a no-op for libraries
2020-11-11 09:57:07 <dminuoso> merijn: Isn't it great?
2020-11-11 09:57:09 <merijn> bqv: tbh, I'd consider Arrows pretty much obsolete and not really worth investing too much time in :)
2020-11-11 09:57:18 × jonatanb quits (~jonatanb@83.24.9.26.ipv4.supernova.orange.pl) (Remote host closed the connection)
2020-11-11 09:57:26 <dminuoso> Yesterday was not good for my trust in cabal/ghc.
2020-11-11 09:57:29 <bqv> merijn: oh? Obsoleted by what?
2020-11-11 09:57:34 <dminuoso> bqv: profunctors
2020-11-11 09:57:37 <dminuoso> largely
2020-11-11 09:57:40 <dminuoso> and applicative
2020-11-11 09:57:40 <merijn> bqv: A mix of Applicative/Profunctor/Category
2020-11-11 09:57:46 <bqv> Huh, cool
2020-11-11 09:58:10 jonatanb joins (~jonatanb@83.24.9.26.ipv4.supernova.orange.pl)
2020-11-11 09:58:11 <dminuoso> judging from the past 12 months, the only use case for arrow seems to be using some older frp libraries
2020-11-11 09:58:12 <merijn> bqv: basically, unlike Applicative/Monad which were useful in tons of places, Arrow just never turned out to be very useful
2020-11-11 09:58:34 <bqv> fair enough
2020-11-11 09:58:54 <dminuoso> asheshambasta: can you share the output of `ghc-pkg list` inside the nix-shell?
2020-11-11 09:59:02 <merijn> bqv: Consider this: Arrow predates Applicative by a few years, yet Applicative is *everywhere* and Arrow is not ;)
2020-11-11 09:59:13 <dminuoso> asheshambasta: Im a bit clueless, so this is just poking for information.
2020-11-11 09:59:25 <bqv> Wait it does?
2020-11-11 09:59:28 <bqv> Woe
2020-11-11 09:59:34 <dminuoso> Applicative is relatively new
2020-11-11 09:59:47 <merijn> bqv: The first Arrow paper is from 2000, the first Applicative paper is from 2004, iirc
2020-11-11 09:59:55 <dminuoso> (Though to be absolutely fair, there isnt a lot of purely applicative code)
2020-11-11 10:00:04 <dminuoso> most applicative code is just monadic in disguise
2020-11-11 10:00:07 ubert joins (~Thunderbi@p200300ecdf1e530ce6b318fffe838f33.dip0.t-ipconnect.de)
2020-11-11 10:00:15 <bqv> Mm
2020-11-11 10:00:31 Rudd0 joins (~Rudd0@185.189.115.98)
2020-11-11 10:00:42 <dminuoso> like, from a consumer perspective you might opt to use the applicative interface of some type, that happens to also be a monad
2020-11-11 10:00:50 <dminuoso> And coherence laws ensures they are the same for that
2020-11-11 10:00:54 × coco quits (~coco@212-51-146-87.fiber7.init7.net) (Quit: WeeChat 2.9)
2020-11-11 10:00:58 <merijn> bqv: Similarly, monadic IO didn't make it into Haskell until (I think?) the 5th revision of the report, something like 6 years into the language's existence
2020-11-11 10:01:06 <dminuoso> e.g. writing `Foo <$> parserA <*> parserB` is often just monadic
2020-11-11 10:01:13 <asheshambasta> dminuoso: https://gist.github.com/asheshambasta/3597d25f179fc2729286c4b02387f282#file-ghc-pkg_list-txt
2020-11-11 10:01:40 <bqv> merijn: ha, that's astonishing
2020-11-11 10:01:48 <dminuoso> asheshambasta: that looks very wrong.
2020-11-11 10:02:04 <merijn> bqv: but monadic IO and Applicative spread like wildfire, because they're objectively great at solving very common problems. Arrow was envisioned as doing the same, but it never really caught on practically
2020-11-11 10:02:14 <dminuoso> asheshambasta: ghc-pkg should be largely empty
2020-11-11 10:02:23 <dminuoso> No idea why cabal new-* even picks those up
2020-11-11 10:02:25 <dminuoso> (is that by design)
2020-11-11 10:02:36 <dminuoso> asheshambasta: if you empty that, your package will compile again
2020-11-11 10:02:56 <merijn> bqv: In the first versions of Haskell you had "main :: [IOResponse] -> [IORequest]", where you got a lazy list of IOResponse as input while you generated a lazy list of IORequests as output
2020-11-11 10:03:04 <asheshambasta> I ran this inside the nix-shell, did you mean that I run this outside?
2020-11-11 10:03:06 <bqv> I mean the part of arrows that was interesting was the static/dynamic thing that apparently saves on space complexity - but I think you can basically do that with a tuple anyway, its just syntax sugar
2020-11-11 10:03:11 × mputz quits (~Thunderbi@dslb-084-058-211-084.084.058.pools.vodafone-ip.de) (Quit: mputz)
2020-11-11 10:03:25 <bqv> merijn: sheesh
2020-11-11 10:04:08 <merijn> bqv: So you'd insert something like 'ReadFile "foo"' as result and that'd result in (eventually) appending 'FileRead "foo" {- data here -}' to the input, which is a massive pain to work with, obviously :p
2020-11-11 10:04:35 <bqv> Yeah :|
2020-11-11 10:04:43 <merijn> bqv: Well, the idea with Arrow was that you can "inspect" stuff without running any code, but Applicative gives you the same
2020-11-11 10:04:53 <merijn> :t (<*>)
2020-11-11 10:04:54 <lambdabot> Applicative f => f (a -> b) -> f a -> f b
2020-11-11 10:05:18 <merijn> bqv: Note that both arguments of <*> are 'f ?', so you can inspect the 'f' part of both sides
2020-11-11 10:05:22 <merijn> :t (>>=)
2020-11-11 10:05:23 <lambdabot> Monad m => m a -> (a -> m b) -> m b
2020-11-11 10:05:55 <merijn> As opposed to >>= where the 'm' is on only the left side (you need to call a function and do stuff first, before you get an 'm' back)
2020-11-11 10:07:17 <bqv> Huh... that doesn't seem all that innovative
2020-11-11 10:08:12 × Maxdamantus quits (~Maxdamant@unaffiliated/maxdamantus) (Quit: brb)
2020-11-11 10:08:31 <dminuoso> asheshambasta: no
2020-11-11 10:08:59 <merijn> bqv: http://www.staff.city.ac.uk/~ross/papers/Applicative.pdf :)
2020-11-11 10:09:28 <bqv> Nah I get applicative, I just thought there was more to Arrow
2020-11-11 10:09:53 <merijn> bqv: I mean there is, but the typeclass definition ruins it by having 'arr'
2020-11-11 10:09:54 × knupfer quits (~Thunderbi@dynamic-046-114-147-079.46.114.pool.telefonica.de) (Read error: Connection reset by peer)
2020-11-11 10:09:55 <merijn> :t arr
2020-11-11 10:09:56 <lambdabot> Arrow a => (b -> c) -> a b c
2020-11-11 10:10:21 <merijn> bqv: Requiring the ability to lift arbitrary functions into the arrow ruins like half the interesting usecases
2020-11-11 10:10:29 <bqv> Heh

All times are in UTC.