2021/08/22

2021-08-22 00:02:09 +0200aab(~aab@193.56.116.154)
2021-08-22 00:05:27 +0200Guest4623(~Guest46@182.64.179.3)
2021-08-22 00:05:43 +0200markpythonicbtc(~textual@2601:647:5a00:35:697a:eb38:2e9e:dc30) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2021-08-22 00:11:10 +0200 <Guest4623> Hey, I have a function `f :: a -> b -> c` . I want to memoize `f a` but `a` is not know at compile time (and also it is not Memoizable), however it is constant. How should I memoize it? Obviously I can't create `f' :: a -> b -> c` and call `memoize2` on it
2021-08-22 00:14:32 +0200silver_(~silver@37.214.30.4) (Quit: Leaving)
2021-08-22 00:15:38 +0200 <hpc> what does "not known at compile time but consistent" mean in this context?
2021-08-22 00:15:55 +0200takuan(~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
2021-08-22 00:17:11 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Remote host closed the connection)
2021-08-22 00:18:34 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt)
2021-08-22 00:22:50 +0200jtomas_(~jtomas@233.red-83-34-2.dynamicip.rima-tde.net)
2021-08-22 00:24:19 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Ping timeout: 252 seconds)
2021-08-22 00:24:38 +0200acidjnk_new(~acidjnk@p200300d0c72b954921d359bc9986b356.dip0.t-ipconnect.de) (Ping timeout: 250 seconds)
2021-08-22 00:25:40 +0200Tuplanolla(~Tuplanoll@91-159-69-50.elisa-laajakaista.fi) (Quit: Leaving.)
2021-08-22 00:25:48 +0200 <Guest4623> essentially it reads the value of `a` from a file
2021-08-22 00:26:04 +0200 <dminuoso> And you want this memoized how exactly?
2021-08-22 00:26:10 +0200 <hpc> it reads the type from a file?
2021-08-22 00:27:10 +0200xff0x(~xff0x@2001:1a81:523e:7200:987e:5abc:19e1:66f6) (Ping timeout: 240 seconds)
2021-08-22 00:27:15 +0200jtomas_(~jtomas@233.red-83-34-2.dynamicip.rima-tde.net) (Remote host closed the connection)
2021-08-22 00:27:26 +0200 <Guest4623> oops, bad notation, sorry. `a` refers to both type and the variable. The type is not memoizable and the variable is read from the file
2021-08-22 00:29:02 +0200 <Guest4623> I want to memoize it wrt the second parameter
2021-08-22 00:29:52 +0200enoq(~enoq@2a05:1141:1f5:5600:b9c9:721a:599:bfe7)
2021-08-22 00:30:49 +0200Guest2130(~Guest21@2a02:8109:a080:6368:d5d2:328b:373c:5b57) (Quit: Client closed)
2021-08-22 00:36:39 +0200Lycurgus(~juan@cpe-45-46-140-49.buffalo.res.rr.com)
2021-08-22 00:39:36 +0200derelict(~derelict@user/derelict)
2021-08-22 00:40:24 +0200lavaman(~lavaman@98.38.249.169)
2021-08-22 00:43:27 +0200 <Lycurgus> leitz, this title https://www.amazon.com/Software-development-rigorous-approach-Jones/dp/0138218846 occured to me after our exchange earlier
2021-08-22 00:43:41 +0200 <Lycurgus> as it's on the pile of books I'm discarding
2021-08-22 00:44:29 +0200 <Lycurgus> it does predate the current situation where FB has split into more or less non communication magistries
2021-08-22 00:44:38 +0200 <Lycurgus> and is about FP
2021-08-22 00:44:46 +0200derelict(~derelict@user/derelict) (Quit: WeeChat 3.2)
2021-08-22 00:44:49 +0200lavaman(~lavaman@98.38.249.169) (Ping timeout: 248 seconds)
2021-08-22 00:45:32 +0200 <Lycurgus> s/non communication/contending/
2021-08-22 00:47:04 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-08-22 00:47:24 +0200 <Lycurgus> s/FB/FP/
2021-08-22 00:48:31 +0200haasn(~nand@haasn.dev) (Quit: ZNC 1.7.5+deb4 - https://znc.in)
2021-08-22 00:48:54 +0200haasn(~nand@haasn.dev)
2021-08-22 00:49:57 +0200xff0x(~xff0x@2001:1a81:5267:2d00:60:bdd1:fa4d:cbd0)
2021-08-22 00:55:40 +0200severen(~severen@202.36.179.72) (Ping timeout: 252 seconds)
2021-08-22 00:56:09 +0200shapr(~user@pool-100-36-247-68.washdc.fios.verizon.net)
2021-08-22 00:58:23 +0200raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2021-08-22 01:11:04 +0200pretty_dumm_guy(trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655) (Ping timeout: 252 seconds)
2021-08-22 01:12:41 +0200Lycurgus(~juan@cpe-45-46-140-49.buffalo.res.rr.com) (Quit: Exeunt)
2021-08-22 01:14:54 +0200raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 250 seconds)
2021-08-22 01:15:46 +0200wroathe(~wroathe@96-88-30-181-static.hfc.comcastbusiness.net) (Ping timeout: 250 seconds)
2021-08-22 01:21:24 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 250 seconds)
2021-08-22 01:22:30 +0200xlei(znc@pool-68-129-84-118.nycmny.fios.verizon.net) (Quit: ZNC - https://znc.in)
2021-08-22 01:25:42 +0200derelict(~derelict@user/derelict)
2021-08-22 01:26:45 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-08-22 01:26:45 +0200gentauro(~gentauro@user/gentauro) (Read error: Connection reset by peer)
2021-08-22 01:27:15 +0200gentauro(~gentauro@user/gentauro)
2021-08-22 01:27:25 +0200raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2021-08-22 01:30:27 +0200lavaman(~lavaman@98.38.249.169)
2021-08-22 01:31:02 +0200markpythonicbtc(~textual@2601:647:5a00:35:ed7b:d29e:3bfe:71d0)
2021-08-22 01:31:08 +0200xlei(znc@pool-68-129-84-118.nycmny.fios.verizon.net)
2021-08-22 01:38:01 +0200fresheyeball(~fresheyeb@c-71-237-105-37.hsd1.co.comcast.net)
2021-08-22 01:38:06 +0200 <fresheyeball> I have a build that dies saying I have missing-home-modules
2021-08-22 01:38:11 +0200 <fresheyeball> but I have them in my cabal file!
2021-08-22 01:39:59 +0200 <sm> so you say.. you know what we're gonna ask..
2021-08-22 01:41:06 +0200 <sm> let's see it, etc. Maybe they're not in all the right places ?
2021-08-22 01:41:31 +0200 <monochrom> No rectification without 3rd-party reproduction.
2021-08-22 01:41:43 +0200 <fresheyeball> sec
2021-08-22 01:41:50 +0200 <fresheyeball> http://ix.io/3wCL
2021-08-22 01:42:06 +0200 <sm> I'm sorry sir or madam but we have strict procedures in these cases, our hands our tied, if only we could help.. oh, damn
2021-08-22 01:42:26 +0200 <fresheyeball> http://ix.io/3wCM
2021-08-22 01:42:36 +0200 <fresheyeball> ok so there is the build output and the cabal file
2021-08-22 01:42:44 +0200 <fresheyeball> These modules are needed for compilation but not listed in your .cabal file's other-modules:
2021-08-22 01:42:45 +0200 <fresheyeball> Ageto.Types.Login Ageto.Types.LoginSpec
2021-08-22 01:42:53 +0200 <fresheyeball> you can clearly see there are present in the cabal file for unit
2021-08-22 01:43:18 +0200xff0x(~xff0x@2001:1a81:5267:2d00:60:bdd1:fa4d:cbd0) (Ping timeout: 258 seconds)
2021-08-22 01:43:32 +0200 <sm> they are needed for some of the other components, perhaps ?
2021-08-22 01:43:38 +0200 <fresheyeball> yes
2021-08-22 01:43:45 +0200 <sm> executable 'client'
2021-08-22 01:43:45 +0200 <fresheyeball> all of them
2021-08-22 01:43:55 +0200 <fresheyeball> client is not failing though
2021-08-22 01:44:03 +0200 <fresheyeball> only the test suite is having this problem
2021-08-22 01:44:04 +0200geekosaur(~geekosaur@xmonad/geekosaur) (Ping timeout: 252 seconds)
2021-08-22 01:44:33 +0200geekosaur(~geekosaur@xmonad/geekosaur)
2021-08-22 01:44:40 +0200 <sm> hmm, yes
2021-08-22 01:46:06 +0200 <sm> check for weird whitespace/unicode chars ?
2021-08-22 01:46:10 +0200vysn(~vysn@user/vysn) (Ping timeout: 240 seconds)
2021-08-22 01:46:23 +0200 <sm> sure it's using this copy of the cabal file ?
2021-08-22 01:46:31 +0200 <fresheyeball> sm yes
2021-08-22 01:46:58 +0200 <sclv> this often happens if the src directories are shared between different stanzas
2021-08-22 01:47:13 +0200Guest4623(~Guest46@182.64.179.3) (Quit: Client closed)
2021-08-22 01:47:14 +0200 <sclv> like if your test stanza is using your /src just like your lib stanza is
2021-08-22 01:47:18 +0200 <sm> LoginSpec doesn't seem to be exposed by the library ?
2021-08-22 01:47:55 +0200 <sm> but listen to sclv, not me
2021-08-22 01:48:01 +0200 <sclv> yeah, this layout is wrong
2021-08-22 01:48:11 +0200 <sclv> no component should share the source dir with the lib component
2021-08-22 01:48:33 +0200 <fresheyeball> sm: sure but it's in lib
2021-08-22 01:48:35 +0200 <sclv> otherwise when it compiles Foo.Test and that imports Foo.Lib.Thing it _won't_ get it from the lib component, it'll pick it up from the source dir
2021-08-22 01:48:40 +0200 <sclv> and then you get that error!
2021-08-22 01:48:45 +0200 <fresheyeball> btw it compiles fine inside the nix-shell
2021-08-22 01:49:13 +0200 <sm> this is an old foot gun with cabal, isn't it ? I wonder how it could be prevented
2021-08-22 01:49:38 +0200 <sclv> yeah, its a classic problem. i think we reworked cabal init so it creates projects with test suites setup that don't have this issue
2021-08-22 01:49:40 +0200 <fresheyeball> I don't get it
2021-08-22 01:49:41 +0200 <sclv> to guide people away from it
2021-08-22 01:49:51 +0200 <sclv> ok, suppose you have LibModule and TestModule
2021-08-22 01:49:57 +0200 <sclv> and now TestModule imports LibModule
2021-08-22 01:49:57 +0200 <fresheyeball> ok
2021-08-22 01:50:05 +0200 <fresheyeball> yes
2021-08-22 01:50:07 +0200 <sclv> it could either pick it up from the _compiled library component_
2021-08-22 01:50:20 +0200 <fresheyeball> I don't have the library as a build-depends though
2021-08-22 01:50:22 +0200 <fresheyeball> to avoid that
2021-08-22 01:50:22 +0200 <sclv> _or_ it could notice that LibModule.hs is in your /src directory, which your tests also include
2021-08-22 01:50:40 +0200 <sclv> ok, but you _are_ importing its modules into your tests?
2021-08-22 01:51:04 +0200 <fresheyeball> yes
2021-08-22 01:51:11 +0200 <fresheyeball> but just by shared hs-source-dirs
2021-08-22 01:51:56 +0200 <fresheyeball> either way this error message is horrible
2021-08-22 01:52:08 +0200dajoer(~david@user/gvx)
2021-08-22 01:52:31 +0200 <sclv> ah
2021-08-22 01:53:20 +0200kissofthedeath(~fedorafan@user/fedorafan)
2021-08-22 01:53:42 +0200kissofthedeath(~fedorafan@user/fedorafan) (Textual IRC Client: www.textualapp.com)
2021-08-22 01:54:39 +0200 <sclv> right, ghc throws the error, and its doing it because somehow those modules aren't making their way to it. i don't have any better ideas. i'll note that you're only erroring out instead of getting a warning because you're explicitly calling -Werror, so you can fix that at least. *shrug*
2021-08-22 01:55:03 +0200enoq(~enoq@2a05:1141:1f5:5600:b9c9:721a:599:bfe7) (Quit: enoq)
2021-08-22 01:55:05 +0200 <fresheyeball> sclv: what is the point of other-modules?
2021-08-22 01:55:09 +0200 <sclv> running with verbosity will show you the erroring ghc call
2021-08-22 01:55:15 +0200 <fresheyeball> can I just ignore missing-home-modules
2021-08-22 01:55:17 +0200 <sclv> the point is exactly how you're using it.
2021-08-22 01:55:20 +0200 <fresheyeball> its a ton to maintain in the cabal file
2021-08-22 01:55:26 +0200 <fresheyeball> I wish it was automatic
2021-08-22 01:55:30 +0200xff0x(~xff0x@2001:1a81:5267:2d00:3019:a525:5831:f042)
2021-08-22 01:55:31 +0200 <sclv> assume you just had a library
2021-08-22 01:55:38 +0200raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 250 seconds)
2021-08-22 01:55:42 +0200 <sclv> if it didn't declare the modules, how would you know what was part of the package?
2021-08-22 01:55:46 +0200 <sclv> how would any manifest work?
2021-08-22 01:56:06 +0200 <fresheyeball> it would use the exposed modules
2021-08-22 01:56:16 +0200 <sclv> but how does it know what's exposed?
2021-08-22 01:56:24 +0200 <fresheyeball> you would still need to provide exposed-modules
2021-08-22 01:56:26 +0200 <sclv> the files need to be declared somewhere
2021-08-22 01:56:32 +0200 <fresheyeball> and it would include the tree of deps that implies
2021-08-22 01:56:44 +0200 <sclv> ok, so the issue is of course that cabal doesn't know the trace tree of the deps
2021-08-22 01:56:46 +0200 <fresheyeball> if the build requires a module that is not exposed, it just includes it
2021-08-22 01:56:47 +0200 <sclv> and nobody else does too
2021-08-22 01:56:56 +0200 <fresheyeball> well it sure seems to
2021-08-22 01:56:56 +0200 <sclv> so figuring out "what files are in this package" would require running ghc
2021-08-22 01:57:02 +0200 <fresheyeball> since it can warn about it
2021-08-22 01:57:08 +0200 <sclv> that's ghc's warning, not cabals
2021-08-22 01:57:11 +0200 <fresheyeball> right
2021-08-22 01:57:18 +0200 <fresheyeball> so... code needs to be written
2021-08-22 01:57:27 +0200 <sclv> anyway you asked what the point was, and that's the point
2021-08-22 01:57:36 +0200 <fresheyeball> but nothing to stop ghc's warning to become other-modules automatically behind the scenes
2021-08-22 01:57:37 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt)
2021-08-22 01:57:41 +0200 <fresheyeball> ok
2021-08-22 01:57:44 +0200 <fresheyeball> so fuck it
2021-08-22 01:57:45 +0200raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2021-08-22 01:57:46 +0200 <sclv> and also, even if cabal could know from ghc we'd still want a manifest so anyone else could know without running ghc
2021-08-22 01:57:49 +0200 <fresheyeball> I am goign to ignore this
2021-08-22 01:57:56 +0200 <sm> hpack can reduce maintenance effort. I don't know if it helps here at all
2021-08-22 01:57:59 +0200 <sclv> for a test suite you can ignore it
2021-08-22 01:57:59 +0200 <fresheyeball> I don't want to have to maintain these other-modules lists
2021-08-22 01:58:09 +0200 <sclv> for the main lib you can't ignore it
2021-08-22 01:58:10 +0200 <fresheyeball> why is that a special case?
2021-08-22 01:58:20 +0200 <sclv> because cabal sdist will not produce a proper package
2021-08-22 01:58:25 +0200 <fresheyeball> omg
2021-08-22 01:58:27 +0200 <sclv> since it won't gather up all the files
2021-08-22 01:58:34 +0200 <sclv> since it doesn't know what they are, unless you tell it
2021-08-22 01:58:36 +0200 <fresheyeball> we have got to fix this
2021-08-22 01:58:48 +0200 <fresheyeball> this is just annoying busy work for developers that doesn't need to be there
2021-08-22 01:58:49 +0200 <sclv> the alternative, which is far worse, is that cabal just grabs every stray file in /src
2021-08-22 01:58:56 +0200 <sclv> we have ides that manage this for you
2021-08-22 01:59:14 +0200 <fresheyeball> I don't find that satisfying
2021-08-22 01:59:16 +0200 <fresheyeball> also how?
2021-08-22 01:59:22 +0200 <sclv> well people wrote them
2021-08-22 01:59:25 +0200 <sclv> is how we got them
2021-08-22 01:59:39 +0200chris(~chris@81.96.113.213)
2021-08-22 01:59:42 +0200 <sm> less than a real fix, but could Cabal detect and warn about this more clearly ?
2021-08-22 01:59:43 +0200chrisGuest9363
2021-08-22 01:59:46 +0200 <sclv> anyway my recommendation is that sharing directories like you're doing is entirely not recommended
2021-08-22 02:00:00 +0200 <monochrom> "cabal sdist" warns.
2021-08-22 02:00:02 +0200 <fresheyeball> I know
2021-08-22 02:00:11 +0200 <fresheyeball> but it I don't share directories dev workflow sucks
2021-08-22 02:00:19 +0200 <fresheyeball> because I can't alter lib files and get an updte
2021-08-22 02:00:24 +0200 <fresheyeball> I have to restart ghcid
2021-08-22 02:00:31 +0200 <sm> there's a flag that does it
2021-08-22 02:00:49 +0200 <fresheyeball> oh!
2021-08-22 02:00:50 +0200 <fresheyeball> what is it
2021-08-22 02:00:51 +0200 <monochrom> I know both sides of the argument for and against "modules should be manually listed" "modules should be automatically detected".
2021-08-22 02:01:27 +0200 <sm> fresheyeball: I'm very sorry, I'm just dimly pattern-matching solutions I've heard about and don't remember
2021-08-22 02:01:40 +0200waleee(~waleee@2001:9b0:216:8200:d457:9189:7843:1dbd) (Ping timeout: 240 seconds)
2021-08-22 02:01:40 +0200 <fresheyeball> no worries
2021-08-22 02:01:42 +0200jgeerds(~jgeerds@55d4b311.access.ecotel.net) (Ping timeout: 245 seconds)
2021-08-22 02:01:56 +0200 <fresheyeball> I just can't see any argument in favor of manually listing
2021-08-22 02:02:06 +0200 <monochrom> At the end I am inclined towards the manual side. Besides, a simple "cabal sdist" already alerts you what you haven't listed.
2021-08-22 02:02:09 +0200 <sm> so what about the hpack idea
2021-08-22 02:02:13 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Ping timeout: 252 seconds)
2021-08-22 02:02:15 +0200 <fresheyeball> it just seems like busy work, and introduces the potential of adding a module that is not used
2021-08-22 02:02:27 +0200 <fresheyeball> I used to use hpack for this
2021-08-22 02:02:33 +0200 <fresheyeball> but people got mad at me :(
2021-08-22 02:02:36 +0200 <fresheyeball> so I go back to cabal
2021-08-22 02:02:48 +0200 <sclv> we do have a ticket for wildcards in cabal, but its currently blocked on the exact-print work. https://github.com/haskell/cabal/issues/5343 the good news is the exact-print work is underway for the next cabal release
2021-08-22 02:02:49 +0200 <sm> commit your cabal file, then there's no reason for anyone to get mad
2021-08-22 02:03:05 +0200 <monochrom> hpack doesn't seem to generate version bounds, last I heard from a user question. That will cause some other problems.
2021-08-22 02:03:39 +0200 <sm> I think that's not hpack's job, it just translates what you wrote in package.yaml
2021-08-22 02:04:01 +0200 <sm> there you can go wild with bounds, hpack has no opinion
2021-08-22 02:04:23 +0200 <monochrom> What is hpack's job? What is its use case? I mean if not for making something reasonably usable by a cabal-and-hackage user.
2021-08-22 02:04:48 +0200 <sclv> its job is just "you can write cabal files but use more braces in your syntax, if you like braces, dude"
2021-08-22 02:04:49 +0200 <monochrom> Without version bounds, a *.cabal file is immediately unusable in the context of hackage.
2021-08-22 02:04:53 +0200 <sm> it's pretty clear from the README IIRC ? I don't want to answer hastily and wrongly
2021-08-22 02:05:58 +0200 <sm> it lets you generate cabal files from a simpler and less redundant format, saving some work and for certain projects, removing a big source of errors (forgetting to mirror changes in all components, forgetting to declare new files, etc.)
2021-08-22 02:06:19 +0200 <sclv> common stanzas in cabal for the most part eliminated the "less redundant" bit
2021-08-22 02:06:37 +0200 <sclv> but in fairness to hpack those are much more recent than hpac
2021-08-22 02:06:46 +0200 <sm> yes, that's true nowadays, if you can require your builders to have a new-enough cabal-install
2021-08-22 02:07:26 +0200Guest82(~Guest82@p1256008-ipoe.ipoe.ocn.ne.jp)
2021-08-22 02:08:03 +0200 <fresheyeball> sclv: if I use -fno-warn-home-modules
2021-08-22 02:08:04 +0200 <sm> also, what's this about braces ? I have no braces in my package.yamls
2021-08-22 02:08:06 +0200 <fresheyeball> on the exes
2021-08-22 02:08:14 +0200 <fresheyeball> will cabal make too big of binaries?
2021-08-22 02:08:30 +0200 <monochrom> The *.cabal file format doesn't require braces either.
2021-08-22 02:09:09 +0200 <monochrom> Whoever talked about braces, I don't know what they're talking about, I think they don't know either. Unless the FUD hypothesis is true.
2021-08-22 02:09:28 +0200 <sm> ok, package.yaml and .cabal are dead even on the braces issue. :)
2021-08-22 02:09:55 +0200 <monochrom> I am not thrilled about YAML in general.
2021-08-22 02:10:21 +0200 <fresheyeball> yaml is... better that this batshit snowflake .cabal syntax
2021-08-22 02:10:34 +0200Guest82(~Guest82@p1256008-ipoe.ipoe.ocn.ne.jp) (Client Quit)
2021-08-22 02:10:45 +0200 <fresheyeball> hell I would take toml
2021-08-22 02:10:50 +0200 <fresheyeball> and I do not like yaml or toml
2021-08-22 02:11:20 +0200 <monochrom> YAML did not exist when .cabal needed some kind of syntax.
2021-08-22 02:11:37 +0200 <monochrom> At that time the other choice was XML.
2021-08-22 02:12:07 +0200 <fresheyeball> I don't fault the old gods for their choices
2021-08-22 02:12:13 +0200 <fresheyeball> but I would have like hpack to take over
2021-08-22 02:12:20 +0200 <fresheyeball> and get us out of snowflake land
2021-08-22 02:12:32 +0200 <sm> what would have been great is for cabal to merge hpack years ago, and accept either format
2021-08-22 02:12:46 +0200 <sm> ..in my mind..
2021-08-22 02:14:08 +0200lavaman(~lavaman@98.38.249.169) (Remote host closed the connection)
2021-08-22 02:17:55 +0200 <sm> and it's still technically quite possible..
2021-08-22 02:18:12 +0200 <sm> why is everyone looking at me
2021-08-22 02:20:11 +0200 <fresheyeball> sm: how do we make this happen?
2021-08-22 02:22:04 +0200mdunnio(~mdunn@205.178.28.97) (Ping timeout: 250 seconds)
2021-08-22 02:22:31 +0200 <monochrom> cabal devs are seriously under-staffed and overworked as is, even just for fixing known bugs and fulfilling the most trivial of feature requests.
2021-08-22 02:22:52 +0200 <sm> ask sclv or other devs (Mikolaj ?) if they'd be open to a nice PR ?
2021-08-22 02:23:12 +0200 <sm> more of them in #hackage, perhaps
2021-08-22 02:23:30 +0200 <monochrom> And hpack itself... After seeing one more example that whatever hpack outputs still requires human intervention, I am not optimistic about a proper automation.
2021-08-22 02:24:27 +0200 <monochrom> i.e., I am not optimistic about even technical plausibility, much less "who actually has time".
2021-08-22 02:26:20 +0200 <sm> monochrom, you haven't used it (I find it great, and never touch the generated files), and there does seem to be some great new energy in cabal dev, maybe there's a possibility
2021-08-22 02:28:10 +0200raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 240 seconds)
2021-08-22 02:30:38 +0200 <monochrom> https://ircbrowse.tomsmeding.com/day/lchaskell/2021/08/09?id=132634#trid132634
2021-08-22 02:31:22 +0200 <monochrom> The beginning of a conversation that concluded in "hpack doesn't gen version bounds, this is why your package is unbuildable under cabal and hackage"
2021-08-22 02:31:58 +0200 <monochrom> Last time c_wraith spoke very harshly, it's because of incidents like this.
2021-08-22 02:32:10 +0200Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net)
2021-08-22 02:32:10 +0200 <sm> I don't get it, it's not hpack's job to set bounds for you
2021-08-22 02:32:35 +0200 <monochrom> Then you have to agree with my "still requires human intervention".
2021-08-22 02:32:49 +0200 <sm> nope
2021-08-22 02:33:06 +0200 <monochrom> If it is not some programs job, then it is my hand's job.
2021-08-22 02:33:29 +0200 <monochrom> I can live with that conclusion, but either a program or a human needs to do it.
2021-08-22 02:33:40 +0200 <sm> hpack works as advertised: it lets you write your cabal file as a simpler package.yaml file. That's all
2021-08-22 02:33:46 +0200 <monochrom> Who else is there? Martians?
2021-08-22 02:35:40 +0200xff0x(~xff0x@2001:1a81:5267:2d00:3019:a525:5831:f042) (Ping timeout: 240 seconds)
2021-08-22 02:42:06 +0200markpythonicbtc(~textual@2601:647:5a00:35:ed7b:d29e:3bfe:71d0) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2021-08-22 02:42:30 +0200markpythonicbtc(~textual@2601:647:5a00:35:ed7b:d29e:3bfe:71d0)
2021-08-22 02:44:09 +0200aab(~aab@193.56.116.154) (Ping timeout: 268 seconds)
2021-08-22 02:44:52 +0200lavaman(~lavaman@98.38.249.169)
2021-08-22 02:46:20 +0200Erutuon(~Erutuon@user/erutuon) (Ping timeout: 250 seconds)
2021-08-22 02:47:10 +0200Xnuk(~xnuk@45.76.202.58) (Quit: ZNC - https://znc.in)
2021-08-22 02:47:27 +0200Xnuk(~xnuk@vultr.xnu.kr)
2021-08-22 02:49:31 +0200lavaman(~lavaman@98.38.249.169) (Ping timeout: 252 seconds)
2021-08-22 02:52:12 +0200Erutuon(~Erutuon@user/erutuon)
2021-08-22 02:55:12 +0200 <fresheyeball> so I have Servant
2021-08-22 02:55:21 +0200 <fresheyeball> a need to setup auth for my web application
2021-08-22 02:55:31 +0200 <fresheyeball> I also have postgres simple
2021-08-22 02:55:37 +0200 <fresheyeball> any recommendations? Advice?
2021-08-22 02:59:20 +0200shapr(~user@pool-100-36-247-68.washdc.fios.verizon.net) (Ping timeout: 250 seconds)
2021-08-22 03:07:25 +0200markpythonicbtc(~textual@2601:647:5a00:35:ed7b:d29e:3bfe:71d0) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2021-08-22 03:07:48 +0200markpythonicbtc(~textual@2601:647:5a00:35:ed7b:d29e:3bfe:71d0)
2021-08-22 03:17:27 +0200MQ-17J(~MQ-17J@d14-69-206-129.try.wideopenwest.com) (Read error: Connection reset by peer)
2021-08-22 03:18:00 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-08-22 03:21:05 +0200Gurkenglas(~Gurkengla@dslb-002-203-144-156.002.203.pools.vodafone-ip.de) (Ping timeout: 248 seconds)
2021-08-22 03:22:22 +0200MQ-17J(~MQ-17J@8.6.144.209)
2021-08-22 03:25:31 +0200 <hololeap> what kind of auth?
2021-08-22 03:25:36 +0200AndrewYu(~andrew@user/andrewyu)
2021-08-22 03:25:57 +0200 <hololeap> fresheyeball: ^
2021-08-22 03:26:06 +0200 <fresheyeball> just like cookie auth
2021-08-22 03:26:12 +0200 <fresheyeball> sessions management as well I suppose
2021-08-22 03:26:17 +0200 <fresheyeball> incase server reboots
2021-08-22 03:27:32 +0200 <hololeap> (I'm probably not qualified to respond to this question) but there is this: https://hackage.haskell.org/package/servant-auth
2021-08-22 03:28:32 +0200aab(~aab@193.56.116.59)
2021-08-22 03:28:48 +0200 <fresheyeball> I am looking at that now
2021-08-22 03:28:52 +0200 <fresheyeball> looks good so far
2021-08-22 03:31:41 +0200 <hololeap> check out https://docs.servant.dev/en/stable/cookbook/index.html
2021-08-22 03:31:49 +0200Axman6(~Axman6@user/axman6)
2021-08-22 03:31:50 +0200 <hololeap> https://docs.servant.dev/en/stable/cookbook/jwt-and-basic-auth/JWTAndBasicAuth.html
2021-08-22 03:32:52 +0200t0zy(~t0zy@49.207.193.1) (Ping timeout: 268 seconds)
2021-08-22 03:32:56 +0200 <hololeap> whenever I need to do this kind of thing, I just head over to Rails... you might be in "roll-your-own" territory... I don't know
2021-08-22 03:33:08 +0200aab(~aab@193.56.116.59) ()
2021-08-22 03:34:04 +0200sim590(~simon@modemcable090.207-203-24.mc.videotron.ca) (Ping timeout: 252 seconds)
2021-08-22 03:38:02 +0200t0zy(~t0zy@49.207.193.1)
2021-08-22 03:47:20 +0200sim590(~simon@modemcable090.207-203-24.mc.videotron.ca)
2021-08-22 03:50:32 +0200xff0x(~xff0x@2001:1a81:52ba:f800:f4cf:86a:773:6851)
2021-08-22 03:51:33 +0200keutoi(~keutoi@157.47.40.109)
2021-08-22 03:52:12 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 250 seconds)
2021-08-22 04:06:56 +0200t0zy(~t0zy@49.207.193.1) (Ping timeout: 250 seconds)
2021-08-22 04:08:01 +0200t0zy(~t0zy@2402:3a80:d22:d27f::3d9e:90dd)
2021-08-22 04:14:40 +0200t0zy(~t0zy@2402:3a80:d22:d27f::3d9e:90dd) (Ping timeout: 240 seconds)
2021-08-22 04:21:42 +0200xlei(znc@pool-68-129-84-118.nycmny.fios.verizon.net) (Quit: ZNC - https://znc.in)
2021-08-22 04:21:55 +0200FinnElija(~finn_elij@user/finn-elija/x-0085643) (Ping timeout: 252 seconds)
2021-08-22 04:24:03 +0200FinnElija(~finn_elij@user/finn-elija/x-0085643)
2021-08-22 04:25:57 +0200xlei(znc@pool-68-129-84-118.nycmny.fios.verizon.net)
2021-08-22 04:27:32 +0200Axma47030(~Axman6@user/axman6)
2021-08-22 04:30:03 +0200Axman6(~Axman6@user/axman6) (Ping timeout: 256 seconds)
2021-08-22 04:37:42 +0200leitz(~LeamHall@cpe-173-172-58-72.tx.res.rr.com) (Quit: nappy time)
2021-08-22 04:39:31 +0200td_(~td@muedsl-82-207-238-079.citykom.de) (Ping timeout: 252 seconds)
2021-08-22 04:39:56 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt)
2021-08-22 04:40:15 +0200Xe(~cadey@tailscale/xe) (Quit: WeeChat 3.1)
2021-08-22 04:40:30 +0200Xe(~cadey@tailscale/xe)
2021-08-22 04:41:24 +0200td_(~td@muedsl-82-207-238-124.citykom.de)
2021-08-22 04:44:10 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Ping timeout: 240 seconds)
2021-08-22 04:56:34 +0200geekosaur(~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b)))
2021-08-22 04:56:34 +0200allbery_b(~geekosaur@xmonad/geekosaur)
2021-08-22 04:56:37 +0200allbery_bgeekosaur
2021-08-22 05:00:13 +0200eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2021-08-22 05:04:21 +0200lavaman(~lavaman@98.38.249.169)
2021-08-22 05:04:49 +0200eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
2021-08-22 05:05:25 +0200alx741(~alx741@181.196.68.120) (Quit: alx741)
2021-08-22 05:08:54 +0200lavaman(~lavaman@98.38.249.169) (Ping timeout: 250 seconds)
2021-08-22 05:20:10 +0200spruit11(~quassel@2a02:a467:ccd6:1:6057:8486:da6d:d017) (Ping timeout: 240 seconds)
2021-08-22 05:24:04 +0200otto_s(~user@p5de2f4c7.dip0.t-ipconnect.de) (Ping timeout: 250 seconds)
2021-08-22 05:25:48 +0200otto_s(~user@p4ff27b55.dip0.t-ipconnect.de)
2021-08-22 05:27:15 +0200spruit11(~quassel@2a02:a467:ccd6:1:1d51:90f2:b4a7:ece8)
2021-08-22 05:28:24 +0200Erutuon(~Erutuon@user/erutuon) (Ping timeout: 250 seconds)
2021-08-22 05:28:32 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-08-22 05:28:32 +0200wroathe(~wroathe@user/wroathe)
2021-08-22 05:31:10 +0200stefan-_(~cri@42dots.de) (Ping timeout: 240 seconds)
2021-08-22 05:31:48 +0200nate1(~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
2021-08-22 05:35:12 +0200stefan-_(~cri@42dots.de)
2021-08-22 05:44:07 +0200Guest9363(~chris@81.96.113.213) (Remote host closed the connection)
2021-08-22 05:45:40 +0200machinedgod(~machinedg@24.105.81.50)
2021-08-22 05:46:37 +0200MQ-17J(~MQ-17J@8.6.144.209) (Ping timeout: 252 seconds)
2021-08-22 05:48:39 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-08-22 05:59:37 +0200chris(~chris@81.96.113.213)
2021-08-22 05:59:41 +0200chrisGuest1719
2021-08-22 06:06:04 +0200wei2912(~wei2912@112.199.250.21)
2021-08-22 06:08:58 +0200severen(~severen@202.36.179.72)
2021-08-22 06:22:55 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 252 seconds)
2021-08-22 06:27:53 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt)
2021-08-22 06:31:42 +0200fresheyeball(~fresheyeb@c-71-237-105-37.hsd1.co.comcast.net) (Quit: WeeChat 2.9)
2021-08-22 06:32:16 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Ping timeout: 252 seconds)
2021-08-22 06:34:24 +0200gentauro_(~gentauro@95.166.247.26)
2021-08-22 06:35:22 +0200gentauro_(~gentauro@95.166.247.26) (Remote host closed the connection)
2021-08-22 06:37:13 +0200nate1(~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 252 seconds)
2021-08-22 06:49:49 +0200nate1(~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
2021-08-22 06:53:36 +0200wei2912(~wei2912@112.199.250.21) (Read error: Connection reset by peer)
2021-08-22 06:55:14 +0200bitdex(~bitdex@gateway/tor-sasl/bitdex) (Ping timeout: 244 seconds)
2021-08-22 06:55:22 +0200severen(~severen@202.36.179.72) (Ping timeout: 252 seconds)
2021-08-22 06:55:28 +0200falafel(~falafel@68.232.54.239)
2021-08-22 06:57:57 +0200bitdex(~bitdex@gateway/tor-sasl/bitdex)
2021-08-22 06:58:16 +0200falafel(~falafel@68.232.54.239) (Remote host closed the connection)
2021-08-22 06:58:40 +0200falafel(~falafel@68.232.54.239)
2021-08-22 07:06:21 +0200mei(~mei@user/mei)
2021-08-22 07:12:45 +0200slowButPresent(~slowButPr@user/slowbutpresent) (Quit: leaving)
2021-08-22 07:13:36 +0200wei2912(~wei2912@112.199.250.21)
2021-08-22 07:23:58 +0200nate1(~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 252 seconds)
2021-08-22 07:31:02 +0200nate1(~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
2021-08-22 07:31:26 +0200mei(~mei@user/mei) (Quit: mei)
2021-08-22 07:32:03 +0200mei(~mei@user/mei)
2021-08-22 07:36:33 +0200wroathe(~wroathe@user/wroathe) (Ping timeout: 248 seconds)
2021-08-22 07:41:19 +0200mei(~mei@user/mei) (Quit: mei)
2021-08-22 07:41:59 +0200mei(~mei@user/mei)
2021-08-22 07:46:33 +0200ongy[m](~ongymatri@2001:470:69fc:105::5018)
2021-08-22 07:50:34 +0200tengu1(~tengu1@cpe-70-121-244-14.neb.res.rr.com) (Ping timeout: 246 seconds)
2021-08-22 07:52:52 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-08-22 07:52:52 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-08-22 07:52:52 +0200wroathe(~wroathe@user/wroathe)
2021-08-22 07:57:31 +0200nate1(~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 252 seconds)
2021-08-22 07:57:54 +0200wroathe(~wroathe@user/wroathe) (Ping timeout: 250 seconds)
2021-08-22 07:59:28 +0200alphabeta(~kilolympu@cpc92710-cmbg20-2-0-cust265.5-4.cable.virginm.net)
2021-08-22 07:59:29 +0200kilolympus(~kilolympu@cpc92710-cmbg20-2-0-cust265.5-4.cable.virginm.net) (Ping timeout: 248 seconds)
2021-08-22 08:05:18 +0200abrantesasf(~abrantesa@2804:14d:b086:4b3c:2e56:dcff:fedb:62f)
2021-08-22 08:12:39 +0200Vooch(~iovoo@096-038-011-034.biz.spectrum.com)
2021-08-22 08:15:23 +0200takuan(~takuan@178-116-218-225.access.telenet.be)
2021-08-22 08:16:34 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt)
2021-08-22 08:19:26 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-08-22 08:20:52 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Ping timeout: 250 seconds)
2021-08-22 08:44:39 +0200tzh(~tzh@c-24-21-73-154.hsd1.wa.comcast.net) (Quit: zzz)
2021-08-22 08:50:02 +0200abrantesasf(~abrantesa@2804:14d:b086:4b3c:2e56:dcff:fedb:62f) (Quit: Leaving)
2021-08-22 08:50:24 +0200kenran(~kenran@200116b82b8bf8008c77ec945bde89d6.dip.versatel-1u1.de)
2021-08-22 08:53:37 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 252 seconds)
2021-08-22 08:54:10 +0200Erutuon(~Erutuon@user/erutuon)
2021-08-22 08:59:45 +0200falafel(~falafel@68.232.54.239) (Ping timeout: 248 seconds)
2021-08-22 09:06:01 +0200lavaman(~lavaman@98.38.249.169)
2021-08-22 09:07:25 +0200fef(~thedawn@user/thedawn)
2021-08-22 09:08:29 +0200vysn(~vysn@user/vysn)
2021-08-22 09:09:41 +0200kayprish(~kayprish@cable-188-2-229-172.dynamic.sbb.rs)
2021-08-22 09:10:16 +0200lavaman(~lavaman@98.38.249.169) (Ping timeout: 250 seconds)
2021-08-22 09:13:16 +0200machinedgod(~machinedg@24.105.81.50) (Ping timeout: 268 seconds)
2021-08-22 09:14:56 +0200Tuplanolla(~Tuplanoll@91-159-69-50.elisa-laajakaista.fi)
2021-08-22 09:17:53 +0200goepsilongo(~goepsilon@2603-7000-ab00-62ed-1cf8-2891-43b9-94ea.res6.spectrum.com)
2021-08-22 09:20:10 +0200goepsilongo_(~goepsilon@2603-7000-ab00-62ed-c9e0-8f19-de85-1d2f.res6.spectrum.com) (Ping timeout: 240 seconds)
2021-08-22 09:29:20 +0200Erutuon(~Erutuon@user/erutuon) (Ping timeout: 250 seconds)
2021-08-22 09:31:50 +0200lyxia(~lyxia@poisson.chat) (Quit: WeeChat 3.1)
2021-08-22 09:36:34 +0200mc47(~mc47@xmonad/TheMC47)
2021-08-22 09:42:10 +0200Morrow_(~Morrow@bzq-110-168-31-106.red.bezeqint.net) (Ping timeout: 240 seconds)
2021-08-22 09:45:30 +0200kayprish(~kayprish@cable-188-2-229-172.dynamic.sbb.rs) (Read error: Connection reset by peer)
2021-08-22 09:46:43 +0200lyxia(~lyxia@poisson.chat)
2021-08-22 09:47:27 +0200_ht(~quassel@82-169-194-8.biz.kpn.net)
2021-08-22 09:59:01 +0200hololeap(~hololeap@user/hololeap) (Quit: Bye)
2021-08-22 09:59:20 +0200burnsidesLlama(~burnsides@client-8-91.eduroam.oxuni.org.uk)
2021-08-22 09:59:27 +0200burnsidesLlama(~burnsides@client-8-91.eduroam.oxuni.org.uk) (Remote host closed the connection)
2021-08-22 09:59:55 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk)
2021-08-22 10:00:06 +0200oldsk00l(~znc@ec2-52-58-63-152.eu-central-1.compute.amazonaws.com) (Remote host closed the connection)
2021-08-22 10:04:23 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt)
2021-08-22 10:05:13 +0200hendursa1(~weechat@user/hendursaga)
2021-08-22 10:06:15 +0200zaquest(~notzaques@5.128.210.178) (Remote host closed the connection)
2021-08-22 10:07:35 +0200zaquest(~notzaques@5.128.210.178)
2021-08-22 10:07:57 +0200hendursaga(~weechat@user/hendursaga) (Ping timeout: 244 seconds)
2021-08-22 10:08:40 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Ping timeout: 240 seconds)
2021-08-22 10:10:51 +0200acidjnk(~acidjnk@p200300d0c72b9549d9d86757fde39a6c.dip0.t-ipconnect.de)
2021-08-22 10:17:17 +0200severen(~severen@202.36.179.72)
2021-08-22 10:17:39 +0200geekosaur(~geekosaur@xmonad/geekosaur) (Killed (NickServ (GHOST command used by allbery_b)))
2021-08-22 10:17:39 +0200allbery_b(~geekosaur@xmonad/geekosaur)
2021-08-22 10:17:42 +0200allbery_bgeekosaur
2021-08-22 10:22:14 +0200Guest9(~Guest9@115.96.241.44)
2021-08-22 10:22:22 +0200 <Guest9> hi
2021-08-22 10:23:45 +0200 <Guest9> is this Haskell beginners forum ?
2021-08-22 10:25:31 +0200 <[exa]> beginners are welcome
2021-08-22 10:25:42 +0200 <[exa]> hello! :]
2021-08-22 10:27:29 +0200rmo(~rmo@user/msr)
2021-08-22 10:27:40 +0200keutoi(~keutoi@157.47.40.109) (Ping timeout: 252 seconds)
2021-08-22 10:29:24 +0200keutoi(~keutoi@223.238.95.231)
2021-08-22 10:34:51 +0200flairif(~user@2603-90d8-0b40-c000-9a65-0d16-0508-f6c0.res6.spectrum.com)
2021-08-22 10:35:50 +0200 <flairif> I've got a nooby question..
2021-08-22 10:36:06 +0200 <Hecate> flairif: don't ask to ask, simply ask :)
2021-08-22 10:37:33 +0200 <Guest9> hi
2021-08-22 10:38:02 +0200 <Guest9> I am trying to create a function which adds all digits to a single number
2021-08-22 10:38:42 +0200 <Hecate> Guest9: so, 'x + 1 + 2 + 3 + 4 + 5 + 6 + 7 + 8 + 9'?
2021-08-22 10:38:42 +0200 <Guest9> digitSum = sum . map (read . return) . show
2021-08-22 10:39:06 +0200 <Guest9> this is the function I wrote and it works..
2021-08-22 10:39:33 +0200 <Guest9> but now I want to make it such that it adds the result also to a single digit
2021-08-22 10:41:00 +0200 <Guest9> singleDigitSum digitsum
2021-08-22 10:41:00 +0200 <Guest9> | digitsum <= 9 = a
2021-08-22 10:41:01 +0200 <Guest9> | otherwise digitsum a
2021-08-22 10:41:10 +0200 <Guest9> so I wrote the above function
2021-08-22 10:41:25 +0200severen(~severen@202.36.179.72) (Ping timeout: 252 seconds)
2021-08-22 10:41:33 +0200 <Guest9> singleDigitSum digitsum
2021-08-22 10:41:34 +0200 <Guest9> | digitsum a <= 9 = a
2021-08-22 10:41:34 +0200 <Guest9> | otherwise digitsum a
2021-08-22 10:41:40 +0200 <Guest9> sorry typo
2021-08-22 10:41:44 +0200 <flairif> thanks :) I'm creating a little number guessing game.. I have `num :: IO (Int)` as the random number... I understand that it's not a "global variable" like in other languages... Everytime I do `n <- num` it's assigning a new random number to n, which is not quite what I want.
2021-08-22 10:42:27 +0200 <Hecate> flairif: the key here is "variable"
2021-08-22 10:42:33 +0200 <flairif> My question is difficult to ask, because its kinda contextual...
2021-08-22 10:42:50 +0200 <Hecate> it's a binding, which is accessible from everywhere (with scoping)
2021-08-22 10:42:58 +0200 <Hecate> but it's indeed not mutable
2021-08-22 10:43:33 +0200 <[exa]> Guest9: so your function should take a _list_ of numbers in strings (?) and add them together?
2021-08-22 10:43:40 +0200favonia(~favonia@user/favonia) (Ping timeout: 240 seconds)
2021-08-22 10:43:48 +0200 <[exa]> Guest9: or just sum 1 to 9 ?
2021-08-22 10:43:59 +0200 <[exa]> Guest9: or sum all digits of some number?
2021-08-22 10:44:14 +0200 <Guest9> @ no.. it just takes an number.. reads all digits and adds them up..
2021-08-22 10:44:32 +0200 <flairif> Right. I guess what I am trying to get at is, how would I "store" a single randomly generated Int that can be used be used throughout the entirity of the program?
2021-08-22 10:44:40 +0200 <Guest9> except that when the sum is more than 9 then it will add those also till it reaches a single digit..
2021-08-22 10:44:50 +0200 <Guest9> actually I am trying to learn recursion..: )
2021-08-22 10:45:03 +0200 <Hecate> flairif: you can pass it as argument :)
2021-08-22 10:45:05 +0200 <[exa]> Guest9: ah so. that explains the `return` there. You might have better luck with list comprehension, such as `sumDigits x = sum [read x | x <- show x]`
2021-08-22 10:45:30 +0200 <[exa]> Guest9: note: creating lists that you immediately consume is basically free in haskell, so no worries about an intermediate list
2021-08-22 10:45:52 +0200 <[exa]> btw I've got a mistake there, should be `read [x]` ofc.
2021-08-22 10:46:07 +0200 <[exa]> and even better name the `x` differently than the original `x`... :D
2021-08-22 10:46:59 +0200 <[exa]> :t \x -> sum [read [c] | c <- show x]
2021-08-22 10:47:00 +0200 <lambdabot> (Num a1, Show a2, Read a1) => a2 -> a1
2021-08-22 10:47:06 +0200 <flairif> Hecate: I suppose. It just feels uncomfortable, because what if my program was aribrarily large, with dozens of functions that all wanted access to that number, hypothetically?
2021-08-22 10:47:26 +0200 <[exa]> flairif: you might be looking for State or Reader monads
2021-08-22 10:47:33 +0200 <[exa]> these are pretty much contextural
2021-08-22 10:48:03 +0200 <Hecate> flairif: then you would take the time to explore such options by setting the boundaries of your requirements with these parameters ;)
2021-08-22 10:48:18 +0200 <flairif> hmmm
2021-08-22 10:48:21 +0200 <Hecate> and you would go towards MVar for example
2021-08-22 10:48:52 +0200 <Hecate> but for a guessing game it's extremely simple to have the number as an argument, especially if it's a bounded Int
2021-08-22 10:50:03 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-08-22 10:50:40 +0200 <Guest9> @[exa] : This would be lambda expressions ?.. I guess yet to reach there.. I am trying to write a toy program from C++ where in you take a list of dates and come out with a date number, month number and year number.. using mod operator.. a numerology program.. =D
2021-08-22 10:50:40 +0200 <lambdabot> Unknown command, try @list
2021-08-22 10:51:01 +0200 <Guest9> There are no exercises in LYAH..
2021-08-22 10:51:58 +0200 <[exa]> LYAH doesn't have many exercises, sadly, yes
2021-08-22 10:52:28 +0200 <[exa]> anyway yeah the \ is a lambda, you can equivalently have a named definition as `sumDigits x = sum [read [c] | c <- show x]`
2021-08-22 10:52:29 +0200 <flairif> Hecate, hmmm ok. I'll try it
2021-08-22 10:54:40 +0200kenran(~kenran@200116b82b8bf8008c77ec945bde89d6.dip.versatel-1u1.de) (Ping timeout: 240 seconds)
2021-08-22 10:55:00 +0200 <Guest9> yes.. but `sumDigits x = sum [read [c] | c <- show x]` gives a two digit answer when supplied with a string..
2021-08-22 10:55:34 +0200 <Guest9> Prelude> sumDigits 987458
2021-08-22 10:55:37 +0200kenran(~kenran@200116b82b8bf8007bc477e0c5eee3d0.dip.versatel-1u1.de)
2021-08-22 10:55:39 +0200 <Guest9> output is 41
2021-08-22 10:55:58 +0200 <[exa]> that's right isn't it?
2021-08-22 10:56:28 +0200 <[exa]> I might have misunderstood the original goal then if not :]
2021-08-22 10:56:55 +0200 <Hecate> flairif: https://replit.com/@Kleidukos/GreenyellowCyanProgrammer#src/Main.hs
2021-08-22 10:57:22 +0200 <Hecate> flairif: and type "stack run src/Main.hs" in the "Shell" tab
2021-08-22 10:57:22 +0200Sgeo(~Sgeo@user/sgeo) (Ping timeout: 252 seconds)
2021-08-22 10:59:13 +0200 <flairif> Ok cool
2021-08-22 11:01:18 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk) (Remote host closed the connection)
2021-08-22 11:01:22 +0200 <flairif> Hecate, I came up with a solution very similar to that one, so that's nice haha
2021-08-22 11:02:42 +0200eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2021-08-22 11:03:09 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt)
2021-08-22 11:06:37 +0200 <Guest9> is there a recursive way to solve this problem ?
2021-08-22 11:07:49 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Ping timeout: 252 seconds)
2021-08-22 11:08:22 +0200econo(uid147250@user/econo) (Quit: Connection closed for inactivity)
2021-08-22 11:14:04 +0200ubert(~Thunderbi@91.141.64.154.wireless.dyn.drei.com)
2021-08-22 11:14:44 +0200Guest1719(~chris@81.96.113.213) (Remote host closed the connection)
2021-08-22 11:15:41 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt)
2021-08-22 11:17:36 +0200 <[exa]> Guest9: what should be the result for 987458?
2021-08-22 11:17:40 +0200flairif(~user@2603-90d8-0b40-c000-9a65-0d16-0508-f6c0.res6.spectrum.com) (Ping timeout: 240 seconds)
2021-08-22 11:19:22 +0200ubert(~Thunderbi@91.141.64.154.wireless.dyn.drei.com) (Ping timeout: 252 seconds)
2021-08-22 11:19:24 +0200hnOsmium0001(uid453710@id-453710.stonehaven.irccloud.com) (Quit: Connection closed for inactivity)
2021-08-22 11:22:15 +0200jgeerds(~jgeerds@55d4b311.access.ecotel.net)
2021-08-22 11:22:49 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Remote host closed the connection)
2021-08-22 11:22:55 +0200Gurkenglas(~Gurkengla@dslb-002-203-144-156.002.203.pools.vodafone-ip.de)
2021-08-22 11:24:10 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 250 seconds)
2021-08-22 11:26:02 +0200phma(phma@2001:5b0:2144:518:c685:6b7:63c5:83c0) (Read error: Connection reset by peer)
2021-08-22 11:26:58 +0200phma(phma@2001:5b0:211f:c4a8:b4c0:8312:139:73b8)
2021-08-22 11:31:06 +0200azeem(~azeem@dynamic-adsl-94-34-33-6.clienti.tiscali.it) (Ping timeout: 250 seconds)
2021-08-22 11:31:08 +0200 <Guest9> 5
2021-08-22 11:31:35 +0200azeem(~azeem@176.200.245.90)
2021-08-22 11:32:02 +0200 <Guest9> 9+8+7+4+5+8 = 41.. 4+1 =5
2021-08-22 11:33:35 +0200azeem(~azeem@176.200.245.90) (Read error: Connection reset by peer)
2021-08-22 11:34:02 +0200azeem(~azeem@dynamic-adsl-94-34-33-6.clienti.tiscali.it)
2021-08-22 11:34:14 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk)
2021-08-22 11:34:37 +0200jtomas(~jtomas@233.red-83-34-2.dynamicip.rima-tde.net)
2021-08-22 11:34:46 +0200geekosaur(~geekosaur@xmonad/geekosaur) (Ping timeout: 252 seconds)
2021-08-22 11:36:32 +0200 <dminuoso> Guest9: Is this a homework assignment?
2021-08-22 11:36:47 +0200 <Guest9> nope
2021-08-22 11:37:02 +0200 <Guest9> I am taking Cpp problems and doing in haskell
2021-08-22 11:37:15 +0200 <Guest9> as I said earlier.. no examples in LYAH
2021-08-22 11:37:33 +0200geekosaur(~geekosaur@xmonad/geekosaur)
2021-08-22 11:38:28 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk) (Ping timeout: 250 seconds)
2021-08-22 11:39:34 +0200 <dminuoso> Guest9: start by writing a function `digits :: Integer -> [Integer]` perhaps?
2021-08-22 11:39:51 +0200reumeth(~reumeth@user/reumeth)
2021-08-22 11:40:02 +0200 <dminuoso> From there, you can proceed with writing some simple recursive function.
2021-08-22 11:40:36 +0200 <dminuoso> % sum digits 1234
2021-08-22 11:40:37 +0200 <yahb> dminuoso: ; <interactive>:4:5: error:; * Couldn't match type: [x0]; with: t0 -> t; Expected: x0 -> t0 -> t; Actual: x0 -> [x0]; * In the first argument of `sum', namely `digits'; In the expression: sum digits 1234; In an equation for `it': it = sum digits 1234; * Relevant bindings include it :: t (bound at <interactive>:4:1)
2021-08-22 11:40:39 +0200 <dminuoso> % sum (digits 1234)
2021-08-22 11:40:39 +0200 <yahb> dminuoso: 10
2021-08-22 11:41:02 +0200 <dminuoso> Is this enough to help you with the task?
2021-08-22 11:41:16 +0200 <dminuoso> Mind you, `digits` is something I wrote myself in a private chat.
2021-08-22 11:41:24 +0200 <dminuoso> So consider this one of the tasks for you to solve.
2021-08-22 11:41:50 +0200 <Guest9> hi.. I have already written function for summation
2021-08-22 11:44:27 +0200 <Guest9> digitSum = sum . map (read . return) . show
2021-08-22 11:44:44 +0200 <Guest9> this takes any number and adds the digits in it..
2021-08-22 11:44:52 +0200 <dminuoso> Mmm, this is not idiomatic
2021-08-22 11:44:56 +0200 <dminuoso> Try to avoid using `show` and `read`.
2021-08-22 11:44:58 +0200jgeerds(~jgeerds@55d4b311.access.ecotel.net) (Ping timeout: 250 seconds)
2021-08-22 11:45:24 +0200 <Guest9> I am looking for a way to apply it recursively... if the intermediate output is not a single digit no
2021-08-22 11:45:47 +0200 <dminuoso> Guest9: The way you'd encode this, is by doing conditional recursion.
2021-08-22 11:45:57 +0200 <dminuoso> i.e. thats how we encode loop conditionals
2021-08-22 11:46:01 +0200 <dminuoso> for example:
2021-08-22 11:46:48 +0200 <dminuoso> @src take
2021-08-22 11:46:48 +0200 <lambdabot> take n _ | n <= 0 = []
2021-08-22 11:46:48 +0200 <lambdabot> take _ [] = []
2021-08-22 11:46:48 +0200 <lambdabot> take n (x:xs) = x : take (n-1) xs
2021-08-22 11:47:18 +0200 <dminuoso> See how this, conditionally on n, either recurses or not? We stop recursing by simply not recursing. We also call this the base cae
2021-08-22 11:47:55 +0200 <dminuoso> And by modifying this argument in each recursion, we modify it - very much akin to how you might decrement a loop variable each turn.
2021-08-22 11:49:48 +0200 <dminuoso> Well, and conditionally on the list too, as if the list is empty, this also stops recursing.
2021-08-22 11:50:14 +0200 <dminuoso> Guest9: And regarding avoiding `read` and `show`, try using:
2021-08-22 11:50:16 +0200 <dminuoso> % :t divMod
2021-08-22 11:50:16 +0200 <yahb> dminuoso: Integral a => a -> a -> (a, a)
2021-08-22 11:51:10 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt)
2021-08-22 11:51:12 +0200 <Guest9> 2 querieas
2021-08-22 11:51:45 +0200 <Guest9> 1. what is idiomatic ? .. I am sorry.. I am self taught and got only learn you a Haskell as a resource..
2021-08-22 11:51:49 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Remote host closed the connection)
2021-08-22 11:52:14 +0200 <Guest9> The example you gave is for a list.. My struggle right now is how do I store the intermediate output?
2021-08-22 11:52:22 +0200 <dminuoso> Think of "idiomatic haskell" as "what haskell programmers would normally write"
2021-08-22 11:52:34 +0200 <dminuoso> Guest9: You store it in a function parameter.
2021-08-22 11:52:40 +0200 <dminuoso> Guest9: Look at the implementation of `take` cited above.
2021-08-22 11:52:50 +0200 <Guest9> because I need to apply the custom function to the intermediate output also if the output is less than 10
2021-08-22 11:53:01 +0200 <dminuoso> Note how in the recursive step we "drop" the head of the list, and pass down the tail instead?
2021-08-22 11:53:05 +0200 <dminuoso> i.e.
2021-08-22 11:53:09 +0200 <dminuoso> 11:46:48 lambdabot | take n (x:xs) = x : take (n-1) xs
2021-08-22 11:53:51 +0200 <dminuoso> If this definition is taken, we pattern match the second argument to a list whose head is `x`, and whose tail is `xs`. In the recursive application of take the first parameter is (n-1), and the second parameter is just the tail
2021-08-22 11:54:02 +0200 <dminuoso> So we "store/keep" intermediate values around in function arguments
2021-08-22 11:54:40 +0200 <dminuoso> equivalently we might write sum as:
2021-08-22 11:55:10 +0200 <dminuoso> % sum :: [Int] -> Int; sum [] = 0; sum (x:xs) = x + sum xs
2021-08-22 11:55:11 +0200 <yahb> dminuoso:
2021-08-22 11:55:14 +0200 <dminuoso> % sum [1,2,3]
2021-08-22 11:55:14 +0200 <yahb> dminuoso: 6
2021-08-22 11:55:42 +0200 <dminuoso> This will expand into
2021-08-22 11:55:49 +0200mnrmnaugh(~mnrmnaugh@68.162.206.56) (Quit: Leaving)
2021-08-22 11:56:28 +0200 <dminuoso> sum 1:2:3:[] ---> 1 + sum 2:3:[] ---> 1 + 2 + sum 3:[] ---> 1 + 2 + 3 + sum [] ---> 1 + 2 + 3 + 0
2021-08-22 11:56:39 +0200 <dminuoso> Guest9: Does this make any sense to you?
2021-08-22 11:57:25 +0200 <Guest9> this is partial application of function.. currying I think.. I am just on chap 6 ofLYAH
2021-08-22 11:57:35 +0200 <dminuoso> No, this is not partial application.
2021-08-22 11:57:48 +0200 <dminuoso> This is just plain function application
2021-08-22 11:58:11 +0200 <dminuoso> Try to focus on understanding how `sum` works, maybe.
2021-08-22 11:58:40 +0200 <dminuoso> How we use recursion to model loops, and function arguments to model loop variables.
2021-08-22 12:00:11 +0200 <Guest9> ok .. let me try going through the recursion chapter again and see..
2021-08-22 12:00:15 +0200 <Guest9> thanks
2021-08-22 12:03:13 +0200eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
2021-08-22 12:06:36 +0200zer0bitz_(~zer0bitz@dsl-hkibng31-58c384-213.dhcp.inet.fi)
2021-08-22 12:07:13 +0200zer0bitz(~zer0bitz@dsl-hkibng31-58c384-213.dhcp.inet.fi) (Ping timeout: 252 seconds)
2021-08-22 12:07:40 +0200eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2021-08-22 12:08:40 +0200xff0x(~xff0x@2001:1a81:52ba:f800:f4cf:86a:773:6851) (Ping timeout: 240 seconds)
2021-08-22 12:09:43 +0200xff0x(~xff0x@2001:1a81:52ba:f800:ba30:5326:3556:79a1)
2021-08-22 12:10:58 +0200kenran(~kenran@200116b82b8bf8007bc477e0c5eee3d0.dip.versatel-1u1.de) (Quit: WeeChat info:version)
2021-08-22 12:11:04 +0200__monty__(~toonn@user/toonn)
2021-08-22 12:18:41 +0200Guest9(~Guest9@115.96.241.44) (Quit: Ping timeout (120 seconds))
2021-08-22 12:25:31 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk)
2021-08-22 12:26:24 +0200zer0bitz_(~zer0bitz@dsl-hkibng31-58c384-213.dhcp.inet.fi) (Read error: Connection reset by peer)
2021-08-22 12:28:31 +0200Guest9(~Guest9@115.96.241.44)
2021-08-22 12:28:39 +0200Guest9(~Guest9@115.96.241.44) (Client Quit)
2021-08-22 12:30:57 +0200haskl(~haskl@user/haskl) (Read error: Connection reset by peer)
2021-08-22 12:31:55 +0200haskl(~haskl@98.37.78.63)
2021-08-22 12:33:34 +0200 <Gurkenglas> ...installing lens-regex doesnt install regex? hmm.
2021-08-22 12:34:48 +0200 <Gurkenglas> so i thought "every number in this string should be 2 higher". sounded like a lens oneliner. what's the proper workflow here? presumably not stack install lens, stack install lens-regex, stack install regex, stack ghci, import Control.Lens, import 3 more things, run oneliner
2021-08-22 12:35:14 +0200 <Gurkenglas> and making a project for that also seems like overkill
2021-08-22 12:35:38 +0200jtomas(~jtomas@233.red-83-34-2.dynamicip.rima-tde.net) (Remote host closed the connection)
2021-08-22 12:38:45 +0200mc47(~mc47@xmonad/TheMC47) (Remote host closed the connection)
2021-08-22 12:39:27 +0200 <Gurkenglas> or is the proper workflow in fact to have a project with all the scripting utilities within which i ghci whenever i have a oneliner to execute?
2021-08-22 12:40:19 +0200 <[exa]> Gurkenglas: maybe use cabal and runhaskell with -package :]
2021-08-22 12:40:44 +0200 <[exa]> stack is inevitably project-ish
2021-08-22 13:00:53 +0200alx741(~alx741@181.196.68.120)
2021-08-22 13:03:59 +0200tcard(~tcard@p2307053-ipngn17101hodogaya.kanagawa.ocn.ne.jp) (Quit: Leaving)
2021-08-22 13:04:20 +0200raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2021-08-22 13:07:42 +0200lavaman(~lavaman@98.38.249.169)
2021-08-22 13:08:50 +0200tcard(~tcard@p2307053-ipngn17101hodogaya.kanagawa.ocn.ne.jp)
2021-08-22 13:10:11 +0200hannessteffenhag(~hannesste@ip4d14ffc8.dynamic.kabel-deutschland.de)
2021-08-22 13:11:15 +0200gehmehgeh(~user@user/gehmehgeh)
2021-08-22 13:12:32 +0200lavaman(~lavaman@98.38.249.169) (Ping timeout: 268 seconds)
2021-08-22 13:14:21 +0200mastarija(~mastarija@78-3-210-70.adsl.net.t-com.hr)
2021-08-22 13:15:30 +0200kuribas(~user@ptr-25vy0iac19m0oa3eqv7.18120a2.ip6.access.telenet.be)
2021-08-22 13:16:05 +0200 <mastarija> When documenting a type, how does one differentiate between a type constructor and value constructor with the same name? e.g. I have `MyName a = MyName a | OtherName a`
2021-08-22 13:16:29 +0200 <mastarija> In Haddock I can use single quotes to link to a type or value constructor, but in this case, how do I differentiate?
2021-08-22 13:18:11 +0200zer0bitz(~zer0bitz@dsl-hkibng31-58c384-213.dhcp.inet.fi)
2021-08-22 13:18:13 +0200 <mastarija> I have a feeling it was something like MyName:MyName? Can't remember and the documentation is not very clear on this.
2021-08-22 13:20:30 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-08-22 13:35:43 +0200 <[exa]> I'd try MyName.MyName but no idea really
2021-08-22 13:36:02 +0200 <[exa]> perhaps check the markup generated at the target site
2021-08-22 13:37:58 +0200dsrt^(~dsrt@209.65.131.194) (Ping timeout: 252 seconds)
2021-08-22 13:39:03 +0200hannessteffenhag(~hannesste@ip4d14ffc8.dynamic.kabel-deutschland.de) (Ping timeout: 268 seconds)
2021-08-22 13:39:09 +0200 <[exa]> the hrefs seem to have v: and t: prefixes
2021-08-22 13:39:57 +0200dsrt^(~dsrt@209.65.131.194)
2021-08-22 13:46:35 +0200 <Arsen> is there a base64encode :: [Char] -> [Char] anywhere?
2021-08-22 13:47:02 +0200vysn(~vysn@user/vysn) (Ping timeout: 258 seconds)
2021-08-22 13:47:05 +0200 <Arsen> I already found libraries implementing that for Text and ByteString
2021-08-22 13:49:24 +0200 <hpc> in pseudo-haskell, base64encode :: binary data -> text data, so i don't think it would really make sense
2021-08-22 13:50:02 +0200 <hpc> the existing ones don't really make sense either though, i guess Text -> Text assumes a specific encoding on the input and ByteString -> ByteString assumes ascii-encoded output?
2021-08-22 13:51:23 +0200 <Arsen> that'd make sense to me
2021-08-22 13:51:27 +0200keutoi(~keutoi@223.238.95.231) (Quit: leaving)
2021-08-22 13:51:57 +0200 <Arsen> and, AFAIK, Data.Text specifies the encoding as UTF16
2021-08-22 13:52:03 +0200alphabeta(~kilolympu@cpc92710-cmbg20-2-0-cust265.5-4.cable.virginm.net) (Quit: Quitting IRC :()
2021-08-22 13:52:50 +0200 <hpc> then maybe for String it can specify UTF8 to make a nightmare for future programmers :D
2021-08-22 13:53:16 +0200 <hpc> anyhoo, i would just explicitly encode the string
2021-08-22 13:54:00 +0200 <Arsen> heh, I'm trying to replace a show with a base64 string, and I just realized show might be all I need here, one moment
2021-08-22 13:54:28 +0200cheater(~Username@user/cheater) (Ping timeout: 252 seconds)
2021-08-22 13:54:36 +0200Hecatehad to blink twice because seeing a Haskell programme coverage tool speak on IRC was probably the last straw that broke my sanity
2021-08-22 13:54:41 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 248 seconds)
2021-08-22 13:54:49 +0200 <Hecate> hpc: should I expect hls to chat here as well? :p
2021-08-22 13:56:09 +0200 <Arsen> b64wrap :: Text -> [Char]
2021-08-22 13:56:09 +0200 <Arsen> b64wrap = ("atob("++) . (++")") . show . encodeBase64
2021-08-22 13:56:09 +0200 <Arsen> it's disgusting, I love it :D
2021-08-22 13:56:27 +0200 <Arsen> (encodeBase64 is from Data.Text.Encoding.Base64)
2021-08-22 13:57:03 +0200 <hpc> Hecate: ski is here, if you count mathematical concepts :D
2021-08-22 13:58:37 +0200goepsilongo(~goepsilon@2603-7000-ab00-62ed-1cf8-2891-43b9-94ea.res6.spectrum.com) (Quit: Textual IRC Client: www.textualapp.com)
2021-08-22 13:59:45 +0200 <Hecate> hpc: nah I'm used to mathematical concepts speaking to me in my sleep
2021-08-22 14:00:05 +0200 <Hecate> I've let that part of my sanity go its own way for some time now :p
2021-08-22 14:01:42 +0200dsrt^(~dsrt@209.65.131.194) (Remote host closed the connection)
2021-08-22 14:02:02 +0200dsrt^(~dsrt@209.65.131.194)
2021-08-22 14:02:28 +0200dsrt^(~dsrt@209.65.131.194) (Remote host closed the connection)
2021-08-22 14:02:43 +0200pavonia(~user@user/siracusa) (Quit: Bye!)
2021-08-22 14:04:45 +0200eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
2021-08-22 14:04:58 +0200cheater(~Username@user/cheater)
2021-08-22 14:09:16 +0200eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 268 seconds)
2021-08-22 14:10:11 +0200hannessteffenhag(~hannesste@ip4d14ffc8.dynamic.kabel-deutschland.de)
2021-08-22 14:14:49 +0200hannessteffenhag(~hannesste@ip4d14ffc8.dynamic.kabel-deutschland.de) (Ping timeout: 252 seconds)
2021-08-22 14:24:22 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk) (Remote host closed the connection)
2021-08-22 14:27:28 +0200mastarija(~mastarija@78-3-210-70.adsl.net.t-com.hr) (Ping timeout: 252 seconds)
2021-08-22 14:31:01 +0200markpythonicbtc(~textual@2601:647:5a00:35:ed7b:d29e:3bfe:71d0) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2021-08-22 14:52:57 +0200loonycyborg(~loonycybo@wesnoth/developer/loonycyborg) (Quit: ZNC - http://znc.sourceforge.net)
2021-08-22 14:55:08 +0200loonycyborg(~loonycybo@wesnoth/developer/loonycyborg)
2021-08-22 14:56:42 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk)
2021-08-22 14:58:59 +0200nrl^(~nrl@209.65.131.194)
2021-08-22 14:59:51 +0200s-h-i-n-o-b-i(~quassel@104.244.75.124)
2021-08-22 15:00:55 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk) (Remote host closed the connection)
2021-08-22 15:01:01 +0200markpythonicbtc(~textual@2600:380:4559:3d84:9546:7b48:3a47:abd9)
2021-08-22 15:01:03 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk)
2021-08-22 15:01:05 +0200keutoi(~keutoi@106.208.52.196)
2021-08-22 15:07:39 +0200waleee(~waleee@2001:9b0:216:8200:d457:9189:7843:1dbd)
2021-08-22 15:08:12 +0200wei2912(~wei2912@112.199.250.21) (Quit: Lost terminal)
2021-08-22 15:08:19 +0200mastarija(~mastarija@78-3-210-70.adsl.net.t-com.hr)
2021-08-22 15:13:00 +0200loonycyborg(~loonycybo@wesnoth/developer/loonycyborg) (Quit: ZNC - http://znc.sourceforge.net)
2021-08-22 15:13:35 +0200loonycyborg(~loonycybo@wesnoth/developer/loonycyborg)
2021-08-22 15:16:24 +0200favonia(~favonia@user/favonia)
2021-08-22 15:17:45 +0200Lycurgus(~juan@cpe-45-46-140-49.buffalo.res.rr.com)
2021-08-22 15:23:07 +0200fef(~thedawn@user/thedawn) (Ping timeout: 244 seconds)
2021-08-22 15:23:30 +0200markpythonicbtc(~textual@2600:380:4559:3d84:9546:7b48:3a47:abd9) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2021-08-22 15:27:23 +0200pretty_dumm_guy(trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655)
2021-08-22 15:29:19 +0200pbrisbin(~patrick@174-081-116-011.res.spectrum.com)
2021-08-22 15:30:10 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-08-22 15:34:17 +0200markpythonicbtc(~textual@50.228.44.6)
2021-08-22 15:35:19 +0200fef(~thedawn@user/thedawn)
2021-08-22 15:40:41 +0200img(~img@user/img) (Quit: ZNC 1.8.2 - https://znc.in)
2021-08-22 15:41:11 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk) (Remote host closed the connection)
2021-08-22 15:45:32 +0200img(~img@user/img)
2021-08-22 15:46:12 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk)
2021-08-22 15:49:42 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk) (Remote host closed the connection)
2021-08-22 15:51:36 +0200lbseale(~lbseale@user/ep1ctetus)
2021-08-22 15:52:07 +0200 <mastarija> [exa], you were right it is MyName.MyName thx
2021-08-22 15:53:04 +0200Lycurgus(~juan@cpe-45-46-140-49.buffalo.res.rr.com) (Quit: Exeunt)
2021-08-22 15:53:16 +0200keutoi(~keutoi@106.208.52.196) (Ping timeout: 250 seconds)
2021-08-22 15:53:32 +0200keutoi(~keutoi@106.208.52.196)
2021-08-22 16:01:23 +0200 <[exa]> mastarija: plain luck guess tho. :D
2021-08-22 16:01:29 +0200 <mastarija> :D
2021-08-22 16:03:36 +0200slowButPresent(~slowButPr@user/slowbutpresent)
2021-08-22 16:06:45 +0200eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
2021-08-22 16:10:16 +0200jess(~jess@libera/staff/jess) (Quit: brb real quick)
2021-08-22 16:10:46 +0200jess(~jess@libera/staff/jess)
2021-08-22 16:11:15 +0200fendor(~fendor@178.115.66.241.wireless.dyn.drei.com)
2021-08-22 16:11:25 +0200eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 252 seconds)
2021-08-22 16:26:59 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk)
2021-08-22 16:27:57 +0200amahl(~amahl@dsl-jklbng12-54fbca-64.dhcp.inet.fi)
2021-08-22 16:31:24 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk) (Ping timeout: 250 seconds)
2021-08-22 16:33:58 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 252 seconds)
2021-08-22 16:33:58 +0200pbrisbin(~patrick@174-081-116-011.res.spectrum.com) (Ping timeout: 252 seconds)
2021-08-22 16:41:42 +0200dajoer(~david@user/gvx) (Quit: leaving)
2021-08-22 16:42:38 +0200Guest|24(~Guest|24@185.238.122.126)
2021-08-22 16:43:00 +0200Guest|24(~Guest|24@185.238.122.126) (Client Quit)
2021-08-22 16:43:54 +0200jess(~jess@libera/staff/jess) ()
2021-08-22 16:47:32 +0200machinedgod(~machinedg@24.105.81.50)
2021-08-22 16:49:48 +0200 <kuribas> The Monoid for Map looks wrong. It should have been (Ord k, Monoid v) => Monoid (Map k v)
2021-08-22 16:50:16 +0200qrpnxz(~qrpnxz@user/qrpnxz) (Ping timeout: 258 seconds)
2021-08-22 16:57:00 +0200keutoi(~keutoi@106.208.52.196) (Ping timeout: 268 seconds)
2021-08-22 16:58:08 +0200lbseale(~lbseale@user/ep1ctetus) (Read error: Connection reset by peer)
2021-08-22 16:59:39 +0200jtomas(~jtomas@233.red-83-34-2.dynamicip.rima-tde.net)
2021-08-22 17:02:45 +0200mc47(~mc47@xmonad/TheMC47)
2021-08-22 17:02:54 +0200machinedgod(~machinedg@24.105.81.50) (Read error: Connection reset by peer)
2021-08-22 17:03:47 +0200keutoi(~keutoi@157.47.25.147)
2021-08-22 17:04:13 +0200qrpnxz(~qrpnxz@user/qrpnxz)
2021-08-22 17:06:04 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk)
2021-08-22 17:06:49 +0200oxide(~lambda@user/oxide)
2021-08-22 17:09:01 +0200lavaman(~lavaman@98.38.249.169)
2021-08-22 17:10:24 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk) (Ping timeout: 250 seconds)
2021-08-22 17:13:34 +0200lavaman(~lavaman@98.38.249.169) (Ping timeout: 252 seconds)
2021-08-22 17:14:52 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-08-22 17:14:52 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-08-22 17:14:52 +0200wroathe(~wroathe@user/wroathe)
2021-08-22 17:14:57 +0200adamflott(~adamflott@c-73-60-249-202.hsd1.ma.comcast.net)
2021-08-22 17:17:59 +0200mastarija(~mastarija@78-3-210-70.adsl.net.t-com.hr) (Quit: Leaving)
2021-08-22 17:18:49 +0200turlando(~turlando@93-42-250-112.ip89.fastwebnet.it)
2021-08-22 17:18:49 +0200turlando(~turlando@93-42-250-112.ip89.fastwebnet.it) (Changing host)
2021-08-22 17:18:49 +0200turlando(~turlando@user/turlando)
2021-08-22 17:25:39 +0200xff0x(~xff0x@2001:1a81:52ba:f800:ba30:5326:3556:79a1) (Quit: xff0x)
2021-08-22 17:26:11 +0200tremontremon_
2021-08-22 17:27:42 +0200 <dsal> kuribas: that would've been nice, though less applicable. I've written that bug more than once, though.
2021-08-22 17:28:35 +0200 <kuribas> dsal: isn't it differently applicable though?
2021-08-22 17:29:31 +0200 <kuribas> these instances don't overlap.
2021-08-22 17:31:36 +0200zebrag(~chris@user/zebrag)
2021-08-22 17:32:06 +0200 <kuribas> for Monoids I think about "combining", not "throwing away", though of course they both follow the Monoid laws.
2021-08-22 17:35:10 +0200 <dsal> If both existed, they'd overlap, wouldn't they?
2021-08-22 17:35:34 +0200 <kuribas> with different behaviour
2021-08-22 17:36:06 +0200 <dsal> But yeah, I had the same intuition. I've also got code with maps nested like, five deep with piles of `unionWith (<>)`
2021-08-22 17:38:17 +0200 <nshepperd> (Ord k, Semigroup v) => Monoid (Map k v) even
2021-08-22 17:38:33 +0200 <kuribas> ah indeed
2021-08-22 17:39:42 +0200 <nshepperd> it would nicely subsume the existing instance if you (fmap First)
2021-08-22 17:40:07 +0200 <nshepperd> or maybe Last. see, i can't even remember which way it's biased
2021-08-22 17:40:19 +0200 <dsal> Yeah. There's a bit of ship-has-sailed, though. `union` exists today and is correct behavior for some apps. I suppose it wouldn't break anything silently, though.
2021-08-22 17:40:31 +0200keutoi(~keutoi@157.47.25.147) (Ping timeout: 252 seconds)
2021-08-22 17:40:44 +0200 <kuribas> maybe being explicit is better in this case.
2021-08-22 17:40:48 +0200 <dsal> Right, that's half the problem. I've written *that* bug several times, too.
2021-08-22 17:41:04 +0200Igfoo(~ian@matrix.chaos.earth.li) (Quit: BIAB)
2021-08-22 17:41:15 +0200 <dsal> "The expression (union t1 t2) takes the left-biased union of t1 and t2. It prefers t1 when duplicate keys are encountered, i.e. (union == unionWith const)."
2021-08-22 17:41:42 +0200 <dsal> `(<>) = union`
2021-08-22 17:42:33 +0200keutoi(~keutoi@157.47.0.177)
2021-08-22 17:42:36 +0200hnOsmium0001(uid453710@id-453710.stonehaven.irccloud.com)
2021-08-22 17:42:39 +0200 <dsal> It'd be nice to be able to confidently combine maps without read the docs each time.
2021-08-22 17:45:32 +0200 <dsal> https://github.com/haskell/containers/issues/539
2021-08-22 17:49:58 +0200nate1(~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net)
2021-08-22 17:52:38 +0200benin036932(~benin@183.82.178.142)
2021-08-22 17:54:38 +0200Igloo(~ian@matrix.chaos.earth.li)
2021-08-22 17:55:04 +0200averell(~averell@user/averell)
2021-08-22 17:55:09 +0200Igloo(~ian@matrix.chaos.earth.li) (Client Quit)
2021-08-22 17:55:18 +0200Igloo(~ian@matrix.chaos.earth.li)
2021-08-22 17:59:58 +0200alicebudda(~alicebudd@cold.passenger.volia.net)
2021-08-22 18:01:55 +0200Lycurgus(~juan@cpe-45-46-140-49.buffalo.res.rr.com)
2021-08-22 18:01:59 +0200 <adamflott> I have a strange error I'm not sure where to start debugging. I have a fairly simple stack based app that runs fine on NixOS, but fails with "app: user-error" on Ubuntu and OSX. They all use stack, ghc-8.10.4, and polysemy
2021-08-22 18:02:50 +0200acidjnk(~acidjnk@p200300d0c72b9549d9d86757fde39a6c.dip0.t-ipconnect.de) (Ping timeout: 250 seconds)
2021-08-22 18:03:07 +0200 <adamflott> I know it at least enters main as my argument parser is run, but after that I have no context/idea where it could be failing
2021-08-22 18:03:07 +0200 <Lycurgus> does anyone use NixOS in production?
2021-08-22 18:03:21 +0200 <Lycurgus> i used it about a decade ago
2021-08-22 18:03:29 +0200 <Lycurgus> not in prod ofc
2021-08-22 18:03:41 +0200 <maerwald> I rip it out of production whenever I can :p
2021-08-22 18:04:31 +0200 <dminuoso> Lycurgus: Yes.
2021-08-22 18:04:32 +0200shapr(~user@pool-100-36-247-68.washdc.fios.verizon.net)
2021-08-22 18:05:02 +0200 <dminuoso> Lycurgus: We're starting to switch our complex infrastructure pieces, and depending on how this goes perhaps largely switch everything over.
2021-08-22 18:05:10 +0200 <maerwald> oh dear
2021-08-22 18:05:30 +0200 <Lycurgus> dminuoso, interesting to see how that turns out
2021-08-22 18:05:36 +0200 <dminuoso> Right now this entails our zoo of mail related servers, and in the near future our customer authentication infrastructure
2021-08-22 18:05:42 +0200 <maerwald> Lycurgus: with a low bus factor :p
2021-08-22 18:05:48 +0200 <Lycurgus> in fairness I haven't looked at nix/nixos in a few years
2021-08-22 18:06:10 +0200 <maerwald> it hasn't changed... still all constantly moving underdocumented stuff with bad bus factor
2021-08-22 18:06:34 +0200 <maerwald> now there's a new haskell pkg infrastructure
2021-08-22 18:06:46 +0200 <dminuoso> maerwald: We're reducing this. Im aiming for 3 senior nix engineers for the rest of the team to ask in depth questions. :)
2021-08-22 18:06:53 +0200 <Lycurgus> sfaik the originating utrecht dept is the only place it's used outside enthusiasts
2021-08-22 18:06:54 +0200 <dminuoso> Which for our size is good enough
2021-08-22 18:07:08 +0200 <maerwald> yeah, I'd rather not hire nix engineers to begin with :p
2021-08-22 18:07:09 +0200 <Lycurgus> utrecht or wherever
2021-08-22 18:07:09 +0200 <dminuoso> And yes, the bus factor is definitely a valid concern, but one that is addressable through organizational means
2021-08-22 18:07:21 +0200 <dminuoso> maerwald: We're going to do the training with existing engineers.
2021-08-22 18:07:36 +0200 <Lycurgus> lol, will 3 be enuf?
2021-08-22 18:07:37 +0200 <maerwald> I usually make clear in interviews that I'm not willing to learn nix :p
2021-08-22 18:07:45 +0200 <dminuoso> Lycurgus: We're a relatively small shop, so yes.
2021-08-22 18:08:00 +0200 <dminuoso> We arent using nix for development, so this is more about devops of servers.
2021-08-22 18:08:13 +0200 <dminuoso> maerwald: That's completely fair.
2021-08-22 18:08:33 +0200 <Lycurgus> it's pretty easy to learn, or was
2021-08-22 18:08:41 +0200 <dminuoso> I think the important part of nix is to be open and honest about the issues it has.
2021-08-22 18:08:44 +0200 <maerwald> If someone else maintains it... sure. But I already had a case of nix engineer leaving the startup and then everyone got cold feet.
2021-08-22 18:09:00 +0200machinedgod(~machinedg@24.105.81.50)
2021-08-22 18:09:09 +0200 <dminuoso> I think to some extend, the critcism of nix is just more open and honest, the sheer amount of headaches Ive had with things like ansible.. it's all a trade off.
2021-08-22 18:09:24 +0200 <dminuoso> Except ansible fanboys have a low tendency to agree that there's deep issues with their approach
2021-08-22 18:09:31 +0200 <dminuoso> Lack of reflection
2021-08-22 18:09:47 +0200 <maerwald> ansible is just bash
2021-08-22 18:09:52 +0200 <dminuoso> heh
2021-08-22 18:09:53 +0200 <Lycurgus> you could make a much better case for it when it started 15 ya or so
2021-08-22 18:10:01 +0200 <dminuoso> lexically written in yaml
2021-08-22 18:10:05 +0200 <Lycurgus> since then LSB distro have vastly improved
2021-08-22 18:10:28 +0200 <dminuoso> I think the only reasonable alternative for our problem domain would have been k8s
2021-08-22 18:10:34 +0200 <Lycurgus> fight the next war, not the last one
2021-08-22 18:10:54 +0200 <Lycurgus> *distros
2021-08-22 18:11:09 +0200 <maerwald> all distros suck
2021-08-22 18:11:41 +0200 <Lycurgus> well you want NixOS then
2021-08-22 18:11:49 +0200 <Hecate> or no computers
2021-08-22 18:11:57 +0200 <Hecate> which would be optimal :p
2021-08-22 18:12:10 +0200 <dminuoso> 18:11:09 maerwald | all distros suck
2021-08-22 18:12:15 +0200 <dminuoso> Just like all programming languages suck
2021-08-22 18:12:25 +0200 <maerwald> dminuoso: yeah, I also say that in interviews: programming sucks
2021-08-22 18:13:27 +0200 <dminuoso> Right now, its just that nixos is in my comfort zone, and it gives me the right mix of proper declarative description with atomic updates, and yet results in a mostly plain linux system that non-nixos users can interact with.
2021-08-22 18:13:48 +0200Guest|58(~Guest|58@77.213.94.23)
2021-08-22 18:13:51 +0200 <dminuoso> So our old admins can still log in and look around for problems like they're used to. With k8s that approach doesnt work anymore
2021-08-22 18:14:10 +0200Erutuon(~Erutuon@user/erutuon)
2021-08-22 18:14:33 +0200 <maerwald> calling nixos *declarative* is a far stretch, that may merely rely on technical definitions rather than reality
2021-08-22 18:15:04 +0200 <maerwald> once you got your messy stuff written out, it does roughly the same thing (except in different environments/kernels/...)
2021-08-22 18:15:55 +0200stef204(~stef204@user/stef204)
2021-08-22 18:16:11 +0200 <dminuoso> I dont know about that, with nixos its much easier to say "this is an accurate description of our systems". If I remove `services.postfix.enable = true;`, then I have very good reason to trust that the systemd unit will no longer appear.
2021-08-22 18:16:50 +0200 <dminuoso> Of course this is still based on contracts. If people violate it through various means (say a user is running a postfix from a shell in a tmux session), that cant be helped.
2021-08-22 18:17:22 +0200nate1(~nate@108-233-125-227.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 252 seconds)
2021-08-22 18:17:26 +0200 <maerwald> can't something later in your expression re-enable the postfix service?
2021-08-22 18:17:43 +0200Guest|58(~Guest|58@77.213.94.23) (Client Quit)
2021-08-22 18:17:56 +0200 <dminuoso> Sure. And if I really wanted to assert its off, I can just set `services.postfix.enable = lib.mkForce false`
2021-08-22 18:17:58 +0200 <maerwald> my point being: if it's declarative, there'd be only *one* possible place
2021-08-22 18:18:08 +0200 <dminuoso> well
2021-08-22 18:18:11 +0200 <dminuoso> there is one possible place
2021-08-22 18:18:14 +0200 <dminuoso> its that exact option.
2021-08-22 18:19:15 +0200 <dminuoso> And nixos doesnt have easy escape hatches here - but since the server description resides on a git repository, you cant trivially violate it
2021-08-22 18:19:18 +0200wroathe(~wroathe@user/wroathe) (Ping timeout: 250 seconds)
2021-08-22 18:19:48 +0200 <maerwald> sure, puppet, propellor, etc etc
2021-08-22 18:19:48 +0200 <dminuoso> i.e. you cant log into the server and break that promise without the next deployment undoing your change completely
2021-08-22 18:19:52 +0200 <maerwald> nothing new
2021-08-22 18:19:55 +0200 <dminuoso> sure
2021-08-22 18:20:05 +0200 <dminuoso> puppet achieves similar things, propellor Im not familiar with
2021-08-22 18:20:30 +0200 <dminuoso> But with puppet it's rather a piece of software that tries to control some existing plain linux
2021-08-22 18:20:54 +0200 <maerwald> that's good, because it gives me more options to choose from different ecosystems
2021-08-22 18:20:56 +0200 <dminuoso> With nixos, /etc/systemd/system is a symlink to a store path, which is on a readonly mount
2021-08-22 18:21:03 +0200 <dminuoso> You cant trivially screw around with that while logged in to the server
2021-08-22 18:21:12 +0200 <dminuoso> maerwald: absolutely!
2021-08-22 18:21:19 +0200 <dminuoso> if that's your requirement, then nixos is definitely not for you
2021-08-22 18:21:34 +0200 <maerwald> since I don't consider NixOS security focussed at all, I wouldn't really use it for deployment in the first place
2021-08-22 18:21:36 +0200 <dminuoso> for us, we want the opposite: we want to assert that the git repository is the true and complete description of the server.
2021-08-22 18:22:40 +0200 <dminuoso> And yeah, nixos doesnt get us there all the way - at the end you cant if you want to have any local state. Say, a server has local logs, and the system declaration is obviously not covering that
2021-08-22 18:22:57 +0200 <dminuoso> Or you might have a database, or maybe the fail2ban database
2021-08-22 18:23:33 +0200stef204(~stef204@user/stef204) (Quit: WeeChat 3.2)
2021-08-22 18:24:02 +0200 <dminuoso> maerwald: yeah, the security perspective isnt ideal - but honestly, with most distributions it relies on active maintainers that just donate their free time to rapidly push updates.
2021-08-22 18:25:31 +0200stef204(~stef204@user/stef204)
2021-08-22 18:25:44 +0200 <maerwald> yeah, caring about security in devops isn't a nice job
2021-08-22 18:26:28 +0200stef204(~stef204@user/stef204) (Client Quit)
2021-08-22 18:26:38 +0200 <dminuoso> Honestly, if you care about security, you have to subscribe to CVE updates yourself, and then take the flag yourself.
2021-08-22 18:26:46 +0200 <maerwald> that's why I'm also not convinced of stackage as a concept and much rather have rolling freeze files
2021-08-22 18:27:07 +0200 <maerwald> I used to bump our freeze file every 2 weeks
2021-08-22 18:27:09 +0200 <dminuoso> maerwald: at least nixos has that for you.
2021-08-22 18:27:34 +0200 <maerwald> nixpkgs uses stackage
2021-08-22 18:27:39 +0200 <dminuoso> for haskell, yeah
2021-08-22 18:27:59 +0200 <dminuoso> I was thinking about regular packages and libraries
2021-08-22 18:28:19 +0200 <maerwald> yeah, that was a docker container and the binary was built with a max 2 old freeze file
2021-08-22 18:28:20 +0200 <dminuoso> For haskell, Im thinking if we go down that way, we'll end up using haskell.nix
2021-08-22 18:28:25 +0200 <maerwald> *weeks
2021-08-22 18:28:44 +0200 <dminuoso> That way we'd have plain old cabal hackage semantics again, with respect to updates
2021-08-22 18:28:53 +0200 <dminuoso> As long as we regularly bump nixpkgs, which I guess we should want anyway
2021-08-22 18:31:07 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-08-22 18:31:09 +0200 <dsal> Lycurgus: I'm using nixos on all my "production" linux machines. It's the easiest thing to build and replace at the moment, with no leftover junk I have to compete with.
2021-08-22 18:31:19 +0200 <maerwald> I much prefer to build static binaries and put them in minimal containers that are heavily syscall restricted, are read-only filesystem etc
2021-08-22 18:32:14 +0200 <Lycurgus> dsal, i note ur scare quotes
2021-08-22 18:32:20 +0200 <dminuoso> maerwald: One last thing that I really love about nixos:
2021-08-22 18:32:45 +0200 <dsal> Lycurgus: Yeah, I just mean for my personal production systems, not my work systems. Work is k8s stuff right now.
2021-08-22 18:32:49 +0200 <dminuoso> It's how Im generally not afraid of system updates. If something breaks, I know I can completely rollback and not have stuff leaked from the update.
2021-08-22 18:33:15 +0200 <dminuoso> The only other solution that has this type of "rollback" is if you're fleeting containers
2021-08-22 18:33:20 +0200 <maerwald> dminuoso: cardanos daedalus (frontend, wallet backend and node) are started via nix expressions btw. I've thought how that'd look like with docker locally, but I believe that would suck. So that might be an interesting use case for nix indeed.
2021-08-22 18:33:23 +0200 <Lycurgus> the toughest things for humans are simple things it seems once they get on a jag with this or that concept
2021-08-22 18:33:30 +0200 <maerwald> Because starting docker stuff on a users machine is not good practice
2021-08-22 18:34:01 +0200 <dminuoso> maerwald: My experience with docker has been pretty poor. The way it screws with the local firewall to implement its networking is absolutely scaring to me.
2021-08-22 18:34:06 +0200 <dminuoso> And it's very error prone
2021-08-22 18:34:10 +0200 <maerwald> yes, its broken
2021-08-22 18:34:36 +0200jakalx(~jakalx@base.jakalx.net) (Error from remote client)
2021-08-22 18:34:47 +0200 <maerwald> it's like windows CI... restart it a couple times until it succeeds
2021-08-22 18:35:11 +0200 <maerwald> but the point is: containers are cattle. If they misbehave, shoot them and respawn.
2021-08-22 18:35:25 +0200 <maerwald> don't pet them
2021-08-22 18:35:32 +0200 <dminuoso> We're currently running on centos, and on about 1/3 of the machines we run docker containers on, we've had to spend days to debug and make horrible hotfixes in iptables
2021-08-22 18:35:56 +0200 <dminuoso> Maybe nobody else runs centos + docker? I dont know, but Im surprised that apparently nobody else has these extreme problems
2021-08-22 18:36:13 +0200 <dminuoso> Because everything Ive seen suggests that it's properly broken
2021-08-22 18:38:57 +0200pretty_dumm_guy(trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655) (Quit: WeeChat 3.2)
2021-08-22 18:39:35 +0200 <sm> Gurkenglas: when a project is too much, stack scripts can work well
2021-08-22 18:47:49 +0200tzh(~tzh@c-24-21-73-154.hsd1.or.comcast.net)
2021-08-22 18:49:58 +0200Lorra(~Lorra@2001:a61:3ae0:8401:6154:47aa:9ecc:175c)
2021-08-22 18:52:12 +0200Lorra(~Lorra@2001:a61:3ae0:8401:6154:47aa:9ecc:175c) (Client Quit)
2021-08-22 18:53:27 +0200gehmehgeh(~user@user/gehmehgeh) (Quit: Leaving)
2021-08-22 18:56:41 +0200mnrmnaugh(~mnrmnaugh@68.162.206.56)
2021-08-22 18:56:46 +0200mnrmnaugh(~mnrmnaugh@68.162.206.56) (Remote host closed the connection)
2021-08-22 18:58:46 +0200alicebudda(~alicebudd@cold.passenger.volia.net) (Quit: Client closed)
2021-08-22 19:03:10 +0200favonia(~favonia@user/favonia) (Ping timeout: 240 seconds)
2021-08-22 19:03:26 +0200Vq(~vq@90-227-195-41-no77.tbcn.telia.com) (Ping timeout: 268 seconds)
2021-08-22 19:04:07 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 252 seconds)
2021-08-22 19:05:47 +0200xff0x(~xff0x@2001:1a81:52ba:f800:27e0:55e3:7826:b52d)
2021-08-22 19:08:43 +0200jakalx(~jakalx@base.jakalx.net)
2021-08-22 19:11:24 +0200markpythonicbtc(~textual@50.228.44.6) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2021-08-22 19:13:10 +0200haskl(~haskl@98.37.78.63) (Changing host)
2021-08-22 19:13:10 +0200haskl(~haskl@user/haskl)
2021-08-22 19:14:41 +0200Vq(~vq@90-227-195-41-no77.tbcn.telia.com)
2021-08-22 19:15:56 +0200favonia(~favonia@user/favonia)
2021-08-22 19:17:22 +0200xff0x(~xff0x@2001:1a81:52ba:f800:27e0:55e3:7826:b52d) (Ping timeout: 250 seconds)
2021-08-22 19:18:06 +0200xff0x(~xff0x@2001:1a81:52ba:f800:b837:8a9e:e00a:9d36)
2021-08-22 19:19:31 +0200ggvgc(~ggVGc@a.lowtech.earth) (Quit: WeeChat 3.1)
2021-08-22 19:19:50 +0200econo(uid147250@user/econo)
2021-08-22 19:27:35 +0200keutoi(~keutoi@157.47.0.177) (Quit: leaving)
2021-08-22 19:27:56 +0200eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net)
2021-08-22 19:33:27 +0200ggVGc(~ggVGc@a.lowtech.earth)
2021-08-22 19:37:44 +0200oxide(~lambda@user/oxide) (Ping timeout: 250 seconds)
2021-08-22 19:41:14 +0200doyougnu(~user@c-73-25-202-122.hsd1.or.comcast.net)
2021-08-22 19:41:41 +0200 <sm> hey all. How do you find out which cabal-install version is required for a given cabal-version (file format) ?
2021-08-22 19:41:55 +0200 <sm> I want to know which one supports cabal-version 2.2
2021-08-22 19:41:56 +0200fendor_(~fendor@91.141.64.241.wireless.dyn.drei.com)
2021-08-22 19:42:14 +0200Lycurgus(~juan@cpe-45-46-140-49.buffalo.res.rr.com) (Quit: Exeunt)
2021-08-22 19:44:33 +0200fendor(~fendor@178.115.66.241.wireless.dyn.drei.com) (Ping timeout: 248 seconds)
2021-08-22 19:45:03 +0200 <sclv> iirc that far back anything cabal-install 2.2 and above would work (i.e. we had them coupled at that point)
2021-08-22 19:45:21 +0200 <int-e> sm: looks like cabal-install x.y depends on Cabal x.y since 1.16
2021-08-22 19:47:40 +0200nrl^(~nrl@209.65.131.194) (Remote host closed the connection)
2021-08-22 19:48:33 +0200 <sm> thanks
2021-08-22 19:51:11 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2021-08-22 19:51:11 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Changing host)
2021-08-22 19:51:11 +0200wroathe(~wroathe@user/wroathe)
2021-08-22 19:57:13 +0200bontaq(~user@ool-18e47f8d.dyn.optonline.net)
2021-08-22 19:59:03 +0200vysn(~vysn@user/vysn)
2021-08-22 19:59:18 +0200jumper149(~jumper149@80.240.31.34)
2021-08-22 20:02:34 +0200pbrisbin(~patrick@174-081-116-011.res.spectrum.com)
2021-08-22 20:05:14 +0200fef(~thedawn@user/thedawn) (Remote host closed the connection)
2021-08-22 20:06:03 +0200hololeap(~hololeap@user/hololeap)
2021-08-22 20:06:45 +0200gustik(~gustik@2a01:c844:2410:9020:63ab:4bb6:83d2:e11b)
2021-08-22 20:08:31 +0200pavonia(~user@user/siracusa)
2021-08-22 20:10:54 +0200kuribas(~user@ptr-25vy0iac19m0oa3eqv7.18120a2.ip6.access.telenet.be) (Remote host closed the connection)
2021-08-22 20:13:21 +0200Guest5329(~chris@81.96.113.213)
2021-08-22 20:14:34 +0200azeem(~azeem@dynamic-adsl-94-34-33-6.clienti.tiscali.it) (Ping timeout: 250 seconds)
2021-08-22 20:15:17 +0200lavaman(~lavaman@98.38.249.169)
2021-08-22 20:15:41 +0200azeem(~azeem@176.200.223.33)
2021-08-22 20:19:59 +0200oxide(~lambda@user/oxide)
2021-08-22 20:24:40 +0200azeem(~azeem@176.200.223.33) (Ping timeout: 240 seconds)
2021-08-22 20:25:17 +0200azeem(~azeem@176.200.223.33)
2021-08-22 20:29:44 +0200azeem(~azeem@176.200.223.33) (Ping timeout: 250 seconds)
2021-08-22 20:30:58 +0200fresheyeball(~fresheyeb@c-71-237-105-37.hsd1.co.comcast.net)
2021-08-22 20:31:28 +0200 <fresheyeball> I am trying to impliment an instance of Show for an existenial type
2021-08-22 20:31:33 +0200 <fresheyeball> I feel lost
2021-08-22 20:32:23 +0200 <c_wraith> You probably can't.
2021-08-22 20:32:41 +0200 <fresheyeball> I got Eq and Ord already
2021-08-22 20:32:44 +0200 <fresheyeball> why not Show?
2021-08-22 20:32:48 +0200azeem(~azeem@176.200.223.33)
2021-08-22 20:33:13 +0200 <c_wraith> what's the type?
2021-08-22 20:33:33 +0200 <fresheyeball> data Page = PEcho | PLogin
2021-08-22 20:33:58 +0200 <c_wraith> that's not existential
2021-08-22 20:34:10 +0200 <fresheyeball> data PageView = forall (p :: Page). (Eq (PageModel p), Typeable p, DemotePage p) => PageView (Proxy p) (PageModel p)
2021-08-22 20:35:07 +0200 <fresheyeball> I figured it out
2021-08-22 20:35:16 +0200 <fresheyeball> I didn't know I could just make show, and not showsPrec
2021-08-22 20:35:21 +0200 <fresheyeball> showsPrec is hard
2021-08-22 20:35:26 +0200 <fresheyeball> I thought I had to make showsPrec
2021-08-22 20:35:37 +0200 <c_wraith> showsPrec isn't any harder than show...
2021-08-22 20:35:38 +0200Pickchea(~private@user/pickchea)
2021-08-22 20:35:52 +0200 <fresheyeball> It is to me
2021-08-22 20:35:55 +0200 <sm> tis
2021-08-22 20:35:58 +0200 <fresheyeball> I don't understand it
2021-08-22 20:36:06 +0200 <fresheyeball> ShowS? Int for precidence?
2021-08-22 20:36:13 +0200 <c_wraith> I mean... ok, you need to write more code. But it's identical complexity at the type level.
2021-08-22 20:36:25 +0200 <fresheyeball> sure ok
2021-08-22 20:36:30 +0200 <fresheyeball> that makes sense
2021-08-22 20:36:37 +0200 <fresheyeball> ok, now I need to do Generic
2021-08-22 20:36:39 +0200 <fresheyeball> FEAR
2021-08-22 20:36:48 +0200 <sm> I'll tell that one to new users from now on
2021-08-22 20:37:12 +0200 <c_wraith> I've written showsPrec by hand. It really isn't hard. It breaks down into a few common patterns
2021-08-22 20:37:20 +0200 <sm> to my wife, in fact
2021-08-22 20:37:33 +0200 <c_wraith> the docs are nice enough to illustrate all those patterns for you, in fact.
2021-08-22 20:38:43 +0200 <c_wraith> and Prelude even exports a bunch of weird functions that are useless most of the time, but really convenient for writing showsPrec instances
2021-08-22 20:39:32 +0200 <c_wraith> :t showParen -- like this
2021-08-22 20:39:33 +0200 <lambdabot> Bool -> ShowS -> ShowS
2021-08-22 20:39:42 +0200raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net) (Ping timeout: 250 seconds)
2021-08-22 20:39:45 +0200hexfive(~eric@50.35.83.177)
2021-08-22 20:39:50 +0200sm. o O "what do you mean you don't understand ? it's identical complexity at the type level !" "Oh, of course! How silly of me, thanks for making everything clear"
2021-08-22 20:40:32 +0200 <c_wraith> hey, when the complaint is "I can't figure out how to do X with an existential, but I can figure out Y", pointing out that the existential is irrelevant for the difference matters.
2021-08-22 20:40:58 +0200raehik(~raehik@cpc95906-rdng25-2-0-cust156.15-3.cable.virginm.net)
2021-08-22 20:41:02 +0200 <fresheyeball> c_wraith: fair enough, it was a bad question
2021-08-22 20:41:18 +0200 <fresheyeball> any examples of hand written Generic instances?
2021-08-22 20:41:37 +0200 <c_wraith> I don't know if anyone has ever hand-written a Generic instance.
2021-08-22 20:41:56 +0200 <fresheyeball> is there a way to get a Generic instances for my data type?
2021-08-22 20:42:16 +0200 <c_wraith> ... ok, that's certainly an exaggeration. I'm sure it was done by hand for comparison during the development of the DeriveGeneric extension.
2021-08-22 20:42:22 +0200 <sm> c_wraith: no criticism implied, I'm just joking around (and backing up fresheyeball's perception, in human terms showsPrec is way harder than show)
2021-08-22 20:42:43 +0200 <fresheyeball> right, the existential part was really not part of the question though
2021-08-22 20:42:50 +0200 <fresheyeball> it was more why I can't derive it
2021-08-22 20:43:39 +0200hexfive(~eric@50.35.83.177) (Client Quit)
2021-08-22 20:43:45 +0200 <fresheyeball> And why I can't derive Generic either
2021-08-22 20:45:26 +0200 <c_wraith> my general experience is that when something is hard to get to work in Haskell, it's also hard to use.
2021-08-22 20:45:50 +0200 <fresheyeball> c_wraith: maybe so, but I really want the safety and ergonimics this will provide to the code
2021-08-22 20:45:54 +0200 <c_wraith> the type system issues don't go away
2021-08-22 20:46:10 +0200 <c_wraith> I question the ergonomics.
2021-08-22 20:46:25 +0200 <c_wraith> I expect it will be as hard to use everywhere as it is to implement
2021-08-22 20:46:27 +0200 <fresheyeball> If I can get his, I have dependantly typed routes, which will let me write code in terms of the actual model without a ton of hand mapping between run time ADTs
2021-08-22 20:46:47 +0200xff0x(~xff0x@2001:1a81:52ba:f800:b837:8a9e:e00a:9d36) (Ping timeout: 258 seconds)
2021-08-22 20:47:26 +0200dschrempf(~dominik@2a01-036d-0118-46d4-2358-1c2a-8fb3-e278.pool6.digikabel.hu)
2021-08-22 20:47:42 +0200xff0x(~xff0x@2001:1a81:52ba:f800:f347:6f1f:6209:b9ad)
2021-08-22 20:47:56 +0200pbrisbin(~patrick@174-081-116-011.res.spectrum.com) (Ping timeout: 250 seconds)
2021-08-22 20:48:07 +0200 <glguy> fresheyeball, There's some research what it means to extend GHC.Generics to handle existential quantification, but the stuff you need isn't in base
2021-08-22 20:48:26 +0200 <fresheyeball> glguy: that's fine
2021-08-22 20:48:30 +0200 <fresheyeball> I just need to figure this out
2021-08-22 20:48:34 +0200 <glguy> and everything that works with generics would need to be updated to use the new stuff
2021-08-22 20:48:42 +0200 <fresheyeball> all the types that are existentialized in are Generic
2021-08-22 20:48:48 +0200 <fresheyeball> and the only other thing in this type is a Proxy
2021-08-22 20:48:52 +0200 <fresheyeball> so it should be possible
2021-08-22 20:49:07 +0200 <glguy> it's not something Generics currently supports
2021-08-22 20:49:23 +0200 <fresheyeball> glguy: are you saying it's currently impossible while logically possible?
2021-08-22 20:49:45 +0200 <glguy> someone could perhaps make a thing that wasn't GHC.Generics but was similar and then it might work
2021-08-22 20:49:49 +0200 <glguy> but it doesn't work in GHC.Generics
2021-08-22 20:50:00 +0200 <fresheyeball> so... yes?
2021-08-22 20:50:10 +0200 <glguy> so no you can't make a Generic instance
2021-08-22 20:50:14 +0200segfaultfizzbuzz(~segfaultf@157-131-253-1.fiber.dynamic.sonic.net)
2021-08-22 20:50:16 +0200 <glguy> but you could invent a whole new generics system
2021-08-22 20:50:19 +0200 <fresheyeball> ok
2021-08-22 20:50:35 +0200 <fresheyeball> so that makes sense because type Rep would need the existenail variable
2021-08-22 20:51:15 +0200 <fresheyeball> well lame
2021-08-22 20:51:30 +0200 <fresheyeball> hmm, I can get around this
2021-08-22 20:51:39 +0200 <fresheyeball> because I think I am only using Generic for Aeson
2021-08-22 20:51:43 +0200timCF(~timCF@m91-129-108-244.cust.tele2.ee)
2021-08-22 20:52:07 +0200 <glguy> You could perhaps use Generics on your underlying PageModel type and then use a not-generics thing to wrap that up for PageView
2021-08-22 20:52:30 +0200 <fresheyeball> glguy: I don't understand that
2021-08-22 20:52:43 +0200segfaultfizzbuzz(~segfaultf@157-131-253-1.fiber.dynamic.sonic.net) (Leaving)
2021-08-22 20:52:44 +0200 <fresheyeball> you mean get ToJSON from the underly Generic?
2021-08-22 20:52:58 +0200 <fresheyeball> and then use that instance in my hand written instance?
2021-08-22 20:53:06 +0200 <glguy> There's no reason to store a Proxy in the datatype, anyway
2021-08-22 20:53:29 +0200 <glguy> the whole datatype really is just the PageModel
2021-08-22 20:53:32 +0200abrantesasf(~abrantesa@2804:14d:b086:4b3c:2e56:dcff:fedb:62f)
2021-08-22 20:53:33 +0200 <fresheyeball> I don't see how to get even Eq without it
2021-08-22 20:54:01 +0200 <glguy> Storing the proxy in the datatype, that first field with type (Proxy p), doesn't help implement Eq
2021-08-22 20:54:04 +0200 <fresheyeball> http://ix.io/3wGy
2021-08-22 20:54:09 +0200 <fresheyeball> if you want to see what I have in full
2021-08-22 20:54:23 +0200 <fresheyeball> I am using it with typeable to get Eq
2021-08-22 20:55:25 +0200 <timCF> Hello! I'm looking for a some soft of "standard" function `Int -> Rational -> Text` which takes amount of symbols to render aftrer dot as first argument. Ideally I want this function to work without convertions to Float/Double and corresponding rounding errors. I came up with this, but not sure it's optimal solution
2021-08-22 20:55:30 +0200 <timCF> https://github.com/tkachuk-labs/rentier/blob/8089b849d431b8eaa6aa793894c624d473bd4b04/src/Rentier/…
2021-08-22 20:55:47 +0200 <fresheyeball> timCF: convert to Fixed first
2021-08-22 20:55:48 +0200 <glguy> fresheyeball, You can always just make a new "Proxy" value when you need it; storing it on the constructor doesn't do anything extra
2021-08-22 20:55:57 +0200 <fresheyeball> then just use Show
2021-08-22 20:56:46 +0200 <fresheyeball> glguy: I don't see how to do it
2021-08-22 20:56:59 +0200 <fresheyeball> how do I bring p into scope without to Proxy?
2021-08-22 20:57:11 +0200 <timCF> fresheyeball: thanks!
2021-08-22 20:57:47 +0200 <glguy> fresheyeball, one moment, your file was missing all the language extensions
2021-08-22 20:57:59 +0200 <fresheyeball> glguy: yeah it's in the cabal file
2021-08-22 20:58:09 +0200 <glguy> yeah, this is why that's not as good as putting them in the file
2021-08-22 20:58:23 +0200 <fresheyeball> glguy: I get really sick of adding them
2021-08-22 20:58:44 +0200 <glguy> fortunately making new files isn't the most common part of making things
2021-08-22 20:59:14 +0200 <fresheyeball> glguy: I understand the critique, but I am doing it this way and I am not changing it
2021-08-22 20:59:29 +0200 <glguy> that fine, it just means your file doesn't load. I'll stop
2021-08-22 21:00:57 +0200 <fresheyeball> glguy: I got it
2021-08-22 21:01:08 +0200 <fresheyeball> I can do (x :: PageModel p) and avoid the Proxy
2021-08-22 21:01:21 +0200 <shachaf> -fglasgow-exts for life
2021-08-22 21:01:26 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-08-22 21:01:43 +0200 <shachaf> I heard they were adding something like glasgow-exts back to GHC?
2021-08-22 21:02:24 +0200 <fresheyeball> Oop nope
2021-08-22 21:02:28 +0200 <fresheyeball> I do need the Proxy
2021-08-22 21:02:33 +0200 <fresheyeball> otherwise I can't get instances into scope
2021-08-22 21:05:44 +0200 <glguy> no, pattern matching on the PageView constructor brings instances into scope, not the Proxy
2021-08-22 21:06:34 +0200 <janus> shachaf: is it GHC2021 that is like glasgow-exts?
2021-08-22 21:06:50 +0200 <glguy> If you ever need a proxy you can recover it like: toProxy :: f p -> Proxy p; toProxy _ = Proxy
2021-08-22 21:06:54 +0200 <shachaf> Oh, that sounds right.
2021-08-22 21:10:00 +0200 <janus> GHC2021+GADTs+OverloadedStrings+DerivingStrategies 4 lyfe :P
2021-08-22 21:11:14 +0200Guest5329(~chris@81.96.113.213) (Remote host closed the connection)
2021-08-22 21:11:42 +0200azeem(~azeem@176.200.223.33) (Ping timeout: 258 seconds)
2021-08-22 21:11:46 +0200dschrempf(~dominik@2a01-036d-0118-46d4-2358-1c2a-8fb3-e278.pool6.digikabel.hu) (Ping timeout: 250 seconds)
2021-08-22 21:11:57 +0200 <janus> hmm what if they had done multiple levels og GHC2021? :P hahaha you could have GHC2021SevenVotes, GHC2021SixVotes :P then, if like me, you think ghc2021 is a bit too conserative, you'd have the option
2021-08-22 21:11:58 +0200 <shachaf> Glaswegian Algebraic Data Types isn't part of GHC2021?
2021-08-22 21:12:23 +0200 <janus> shachaf: they are not ;) the one i mentioned are at 7 votes, they'd need 8 votes to be included
2021-08-22 21:13:17 +0200 <janus> in effect, i guess it would be like a two-staged voting system
2021-08-22 21:13:23 +0200azeem(~azeem@176.200.223.33)
2021-08-22 21:13:34 +0200 <janus> then, you could probe haskell and see which level of ghc2021 people would commonly choose
2021-08-22 21:13:44 +0200 <janus> i think GHC2021SevenVotes would be more popular than GHC2021EightVotes
2021-08-22 21:14:06 +0200 <janus> s/haskell/hackage/ (sorry)
2021-08-22 21:14:23 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk)
2021-08-22 21:15:28 +0200hendursa1(~weechat@user/hendursaga) (Quit: hendursa1)
2021-08-22 21:15:39 +0200Sgeo(~Sgeo@user/sgeo)
2021-08-22 21:15:55 +0200hendursaga(~weechat@user/hendursaga)
2021-08-22 21:17:58 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk) (Remote host closed the connection)
2021-08-22 21:18:42 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk)
2021-08-22 21:19:58 +0200azeem(~azeem@176.200.223.33) (Ping timeout: 252 seconds)
2021-08-22 21:21:52 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk) (Remote host closed the connection)
2021-08-22 21:22:30 +0200 <fresheyeball> ok so ToJSON was easy
2021-08-22 21:22:34 +0200 <fresheyeball> but FromJSON is hard
2021-08-22 21:23:19 +0200neo(~neo3@cpe-292712.ip.primehome.com)
2021-08-22 21:24:34 +0200 <c_wraith> I'd expect FromJSON to actually be impossible
2021-08-22 21:24:48 +0200 <fresheyeball> c_wraith: I did this before with singletons
2021-08-22 21:24:56 +0200 <fresheyeball> but I don't want to pull in singletons just for this
2021-08-22 21:25:06 +0200 <fresheyeball> basically I demote Page and encode that into the json
2021-08-22 21:25:18 +0200 <fresheyeball> then I decode Page, and need to convert it to a Proxy of itself
2021-08-22 21:25:37 +0200pretty_dumm_guy(trottel@gateway/vpn/protonvpn/prettydummguy/x-88029655)
2021-08-22 21:26:07 +0200 <janus> hmmm i wonder if it even makes sense to have a discussion around GHC2021SevenVotes or if is it just plain politically infeasible
2021-08-22 21:26:09 +0200 <c_wraith> your options are all various forms of "a table". The only question is whether you manage that table yourself or try to throw it into instances of some class to make the compiler do it
2021-08-22 21:28:07 +0200mei(~mei@user/mei) (Quit: mei)
2021-08-22 21:31:10 +0200oxide(~lambda@user/oxide) (Ping timeout: 240 seconds)
2021-08-22 21:34:26 +0200 <fresheyeball> c_wraith: I got it!
2021-08-22 21:35:02 +0200 <fresheyeball> http://ix.io/3wGF
2021-08-22 21:35:29 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 248 seconds)
2021-08-22 21:41:29 +0200chris(~chris@81.96.113.213)
2021-08-22 21:41:32 +0200chrisGuest934
2021-08-22 21:42:59 +0200Lord_of_Life_(~Lord@user/lord-of-life/x-2819915)
2021-08-22 21:43:24 +0200Lord_of_Life(~Lord@user/lord-of-life/x-2819915) (Ping timeout: 250 seconds)
2021-08-22 21:44:16 +0200Lord_of_Life_Lord_of_Life
2021-08-22 21:45:40 +0200Guest934(~chris@81.96.113.213) (Ping timeout: 240 seconds)
2021-08-22 21:47:44 +0200alx741(~alx741@181.196.68.120) (Ping timeout: 250 seconds)
2021-08-22 21:48:36 +0200_xor(~xor@74.215.232.67) (Read error: Connection reset by peer)
2021-08-22 21:49:12 +0200_xor(~xor@74.215.232.67)
2021-08-22 21:51:01 +0200azeem(~azeem@176.200.243.28)
2021-08-22 21:53:59 +0200_xor(~xor@74.215.232.67) (Read error: Connection reset by peer)
2021-08-22 21:54:24 +0200_xor(~xor@74.215.232.67)
2021-08-22 21:57:44 +0200_ht(~quassel@82-169-194-8.biz.kpn.net) (Remote host closed the connection)
2021-08-22 21:58:16 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk)
2021-08-22 22:00:09 +0200zaquest(~notzaques@5.128.210.178) (Quit: Leaving)
2021-08-22 22:00:47 +0200alx741(~alx741@181.196.68.94)
2021-08-22 22:01:13 +0200zaquest(~notzaques@5.128.210.178)
2021-08-22 22:02:41 +0200burnsidesLlama(~burnsides@dhcp168-023.wadham.ox.ac.uk) (Ping timeout: 248 seconds)
2021-08-22 22:05:04 +0200juhp(~juhp@128.106.188.220) (Ping timeout: 250 seconds)
2021-08-22 22:07:48 +0200azeem(~azeem@176.200.243.28) (Ping timeout: 268 seconds)
2021-08-22 22:08:04 +0200juhp(~juhp@128.106.188.220)
2021-08-22 22:09:05 +0200eggplantade(~Eggplanta@108-201-191-115.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 248 seconds)
2021-08-22 22:09:40 +0200[Kalisto](~nico@user/kalisto/x-8968079) (Ping timeout: 268 seconds)
2021-08-22 22:11:21 +0200eggplantade(~Eggplanta@2600:1700:bef1:5e10:fc6b:7277:c769:1dab)
2021-08-22 22:12:58 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt)
2021-08-22 22:13:27 +0200fendor_(~fendor@91.141.64.241.wireless.dyn.drei.com) (Remote host closed the connection)
2021-08-22 22:16:59 +0200azeem(~azeem@176.200.243.28)
2021-08-22 22:23:46 +0200azeem(~azeem@176.200.243.28) (Ping timeout: 252 seconds)
2021-08-22 22:25:52 +0200benin036932(~benin@183.82.178.142) (Ping timeout: 250 seconds)
2021-08-22 22:28:11 +0200azeem(~azeem@176.200.243.28)
2021-08-22 22:31:14 +0200Xnuk(~xnuk@vultr.xnu.kr) (Quit: ZNC - https://znc.in)
2021-08-22 22:35:35 +0200Xnuk(~xnuk@45.76.202.58)
2021-08-22 22:35:36 +0200Xnuk(~xnuk@45.76.202.58) (Remote host closed the connection)
2021-08-22 22:36:25 +0200azeem(~azeem@176.200.243.28) (Ping timeout: 252 seconds)
2021-08-22 22:37:58 +0200azeem(~azeem@176.200.243.28)
2021-08-22 22:40:19 +0200junkicide(~user@2a01cb0001f4f500f106e9e16d7acd2d.ipv6.abo.wanadoo.fr)
2021-08-22 22:40:52 +0200 <junkicide> what is wrong with the following version of the "all" function?
2021-08-22 22:40:55 +0200 <junkicide> all' :: (a -> Bool) -> [a]-> Bool
2021-08-22 22:40:55 +0200 <junkicide> all' f l = foldl (\x y -> f $ x) True l
2021-08-22 22:41:19 +0200 <junkicide> error: …
2021-08-22 22:41:19 +0200 <junkicide> • Couldn't match expected type ‘a’ with actual type ‘Bool’
2021-08-22 22:41:19 +0200 <junkicide> ‘a’ is a rigid type variable bound by
2021-08-22 22:41:19 +0200 <junkicide> the type signature for:
2021-08-22 22:41:22 +0200 <junkicide> all' :: forall a. (a -> Bool) -> [a] -> Bool
2021-08-22 22:41:25 +0200 <junkicide> at /home/akulkarni/haskell/hutton/chp7.hs:5:1-33
2021-08-22 22:41:28 +0200 <junkicide> • In the expression: f $ x
2021-08-22 22:41:32 +0200 <junkicide> In the first argument of ‘foldl’, namely ‘(\ x y -> f $ x)’
2021-08-22 22:41:35 +0200 <junkicide> In the expression: foldl (\ x y -> f $ x) True l
2021-08-22 22:41:36 +0200 <c_wraith> well, I'd argue that you never use y in the lambda is a big problem
2021-08-22 22:41:39 +0200 <dsal> Too much paste
2021-08-22 22:41:51 +0200 <junkicide> dsal: sorry about that
2021-08-22 22:42:18 +0200 <dsal> But yes, I don't understand what you're trying to do with that lambda
2021-08-22 22:42:57 +0200azeem(~azeem@176.200.243.28) (Ping timeout: 268 seconds)
2021-08-22 22:43:46 +0200 <dsal> One thing you might consider is naming those parameters better.
2021-08-22 22:45:00 +0200acidjnk(~acidjnk@p200300d0c72b9558d9d86757fde39a6c.dip0.t-ipconnect.de)
2021-08-22 22:45:06 +0200azeem(~azeem@176.200.243.28)
2021-08-22 22:45:08 +0200 <junkicide> ah I see the problem now
2021-08-22 22:45:37 +0200 <junkicide> thanks
2021-08-22 22:46:25 +0200Erutuon(~Erutuon@user/erutuon) (Ping timeout: 248 seconds)
2021-08-22 22:48:41 +0200reumeth(~reumeth@user/reumeth) (Ping timeout: 258 seconds)
2021-08-22 22:49:26 +0200eggplantade(~Eggplanta@2600:1700:bef1:5e10:fc6b:7277:c769:1dab) (Remote host closed the connection)
2021-08-22 22:50:10 +0200eggplantade(~Eggplanta@2600:1700:bef1:5e10:fc6b:7277:c769:1dab)
2021-08-22 22:50:23 +0200Xnuk(~xnuk@45.76.202.58)
2021-08-22 22:53:55 +0200jpds(~jpds@gateway/tor-sasl/jpds) (Remote host closed the connection)
2021-08-22 22:54:19 +0200jpds(~jpds@gateway/tor-sasl/jpds)
2021-08-22 22:54:40 +0200eggplantade(~Eggplanta@2600:1700:bef1:5e10:fc6b:7277:c769:1dab) (Ping timeout: 240 seconds)
2021-08-22 22:55:46 +0200azeem(~azeem@176.200.243.28) (Ping timeout: 250 seconds)
2021-08-22 22:56:34 +0200hseg(~gesh@IGLD-84-228-238-79.inter.net.il)
2021-08-22 22:57:05 +0200azeem(~azeem@176.200.243.28)
2021-08-22 22:57:05 +0200mestre(~mestre@191.177.175.57) (Quit: Lost terminal)
2021-08-22 22:57:59 +0200__monty__(~toonn@user/toonn) (Quit: leaving)
2021-08-22 22:58:45 +0200 <hseg> Hi. am getting spooky type errors at a distance. consider the following (ill-formed) program: http://ix.io/3wGQ. ofc, GHC should complain about applying a type to a fully-saturated type. Instead, GHC complains it can't reduce any type family in my program
2021-08-22 22:59:40 +0200 <dminuoso> hseg: What's the exact error message?
2021-08-22 23:00:42 +0200 <hseg> so am getting the expected "Cannot apply expression of type ‘Bool’ to a visible type argument ‘Ord’" message
2021-08-22 23:01:28 +0200 <hseg> but it's buried under a bunch of "Could not match type Sorted NonEmpty with SortedNE" messages, which go away if I delete that offending bit of codee
2021-08-22 23:01:41 +0200 <hseg> which, note, has exactly nothing to do with my Sorted type family
2021-08-22 23:02:45 +0200 <dminuoso> This error message looks to be expected.
2021-08-22 23:02:46 +0200 <hseg> Am similarly getting errors that "Couldn't match type: Item (Map String Int) with: (String, b0) The type 'b0' is ambiguous"
2021-08-22 23:02:48 +0200 <dminuoso> Why do you think it shouldnt be there?
2021-08-22 23:03:00 +0200 <hseg> the error message itself is not the problem
2021-08-22 23:03:16 +0200 <hseg> it's that it causes _other, unrelated_ parts of the code to error
2021-08-22 23:04:44 +0200 <dminuoso> hseg: Is this `h` top level binding in your original code?
2021-08-22 23:04:44 +0200eggplantade(~Eggplanta@2600:1700:bef1:5e10:fc6b:7277:c769:1dab)
2021-08-22 23:04:48 +0200 <hseg> yes
2021-08-22 23:05:10 +0200 <dminuoso> I see. So if you replaced the definifion of `h` with undefined, these tyfam errors go away?
2021-08-22 23:05:16 +0200 <hseg> yup
2021-08-22 23:05:28 +0200 <dminuoso> Sounds ripe for a bug report then
2021-08-22 23:05:32 +0200 <hseg> same if I remove the @Ord type application
2021-08-22 23:05:55 +0200 <maerwald> blergh... who likes word shifting? :D
2021-08-22 23:05:59 +0200 <hseg> I only get a "could not deduce c (First a) from context c a" error, as expected
2021-08-22 23:06:22 +0200 <dminuoso> hseg: Possibly related, but...
2021-08-22 23:06:25 +0200mc47(~mc47@xmonad/TheMC47) (Remote host closed the connection)
2021-08-22 23:06:32 +0200 <dminuoso> hseg: What if you provide a well typed definition for it?
2021-08-22 23:06:34 +0200 <maerwald> https://hackage.haskell.org/package/bytestring-0.11.1.0/docs/src/Data.ByteString.html#breakSubstring -- trying to figure out how to make this work with Word16
2021-08-22 23:06:44 +0200 <dminuoso> GHC sometimes bails out earlier or later, depending on the type error.
2021-08-22 23:07:59 +0200 <maerwald> or you could argue this function isn't defined for Word16 bytestream
2021-08-22 23:08:05 +0200 <maerwald> I'm not sure
2021-08-22 23:08:06 +0200 <hseg> yeah, am having trouble getting the right permutation to trip ghc up
2021-08-22 23:09:02 +0200 <dminuoso> hseg: I think Ive observed GHC sometimes provide a different set of "visible" type errors before. Are the tyfam errors you saw legit?
2021-08-22 23:09:11 +0200 <hseg> nope
2021-08-22 23:09:16 +0200lavaman(~lavaman@98.38.249.169) (Remote host closed the connection)
2021-08-22 23:09:22 +0200 <hseg> as I mentioned, if I delete h, ghc compiles clean
2021-08-22 23:09:25 +0200 <dminuoso> So if you provide a well-typed definition for `h`, the entire module compiles?
2021-08-22 23:09:27 +0200 <dminuoso> Uh
2021-08-22 23:09:30 +0200 <dminuoso> Okay, then go file a bug report.
2021-08-22 23:09:32 +0200lavaman(~lavaman@98.38.249.169)
2021-08-22 23:09:37 +0200 <dminuoso> Do you have any type checker plugins?
2021-08-22 23:09:38 +0200lavaman(~lavaman@98.38.249.169) (Remote host closed the connection)
2021-08-22 23:09:54 +0200 <hseg> no plugins, but quite a few extensions
2021-08-22 23:10:12 +0200 <hseg> trying to reeduce to mwe
2021-08-22 23:11:14 +0200 <dminuoso> Which GHC version is this with?
2021-08-22 23:11:29 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Remote host closed the connection)
2021-08-22 23:11:49 +0200 <hseg> 9.0.1
2021-08-22 23:11:55 +0200fresheyeball(~fresheyeb@c-71-237-105-37.hsd1.co.comcast.net) (Quit: WeeChat 2.9)
2021-08-22 23:12:23 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt)
2021-08-22 23:12:40 +0200wroathe(~wroathe@user/wroathe) (Ping timeout: 250 seconds)
2021-08-22 23:14:36 +0200markpythonicbtc(~textual@2601:647:5a00:35:d936:f2de:ef6:f0f4)
2021-08-22 23:15:49 +0200jakalx(~jakalx@base.jakalx.net) (Error from remote client)
2021-08-22 23:16:19 +0200 <dminuoso> hseg: can you provide the full error message with the tyfams you are getting?
2021-08-22 23:16:34 +0200 <hseg> a moment, trying to get a mwe
2021-08-22 23:18:27 +0200venue(~venue@user/venue)
2021-08-22 23:18:41 +0200roboguy_(~roboguy_@2605:a601:afe7:9f00:2d0e:8bc:c41d:5a84)
2021-08-22 23:19:23 +0200[itchyjunk](~itchyjunk@user/itchyjunk/x-7353470)
2021-08-22 23:19:29 +0200 <hseg> ok, reproduced, minimizing
2021-08-22 23:22:26 +0200 <hseg> hrm. somehow ANN pragmas are involved?
2021-08-22 23:24:42 +0200takuan(~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
2021-08-22 23:25:15 +0200o1lo01ol1o(~o1lo01ol1@5.181.115.89.rev.vodafone.pt) (Remote host closed the connection)
2021-08-22 23:27:08 +0200wroathe(~wroathe@user/wroathe)
2021-08-22 23:27:23 +0200wroathe(~wroathe@user/wroathe) (Client Quit)
2021-08-22 23:27:33 +0200wroathe(~wroathe@96-88-30-181-static.hfc.comcastbusiness.net)
2021-08-22 23:27:33 +0200wroathe(~wroathe@96-88-30-181-static.hfc.comcastbusiness.net) (Changing host)
2021-08-22 23:27:33 +0200wroathe(~wroathe@user/wroathe)
2021-08-22 23:27:46 +0200reumeth(~reumeth@user/reumeth)
2021-08-22 23:28:05 +0200 <geekosaur> ANN prgamas mostly behave like expressions at whatever level they're at
2021-08-22 23:29:40 +0200 <hseg> ok, mwe: http://ix.io/3wH1
2021-08-22 23:30:10 +0200 <hseg> deleting adapt compiles clean
2021-08-22 23:30:28 +0200 <hseg> deleting myid only shows adapt's errors
2021-08-22 23:30:58 +0200jumper149(~jumper149@80.240.31.34) (Quit: WeeChat 3.2)
2021-08-22 23:31:33 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2021-08-22 23:35:51 +0200Racl(~Racl@80.174.59.205.dyn.user.ono.com)
2021-08-22 23:35:59 +0200junkicide(~user@2a01cb0001f4f500f106e9e16d7acd2d.ipv6.abo.wanadoo.fr) (Remote host closed the connection)
2021-08-22 23:36:21 +0200chris(~chris@81.96.113.213)
2021-08-22 23:36:24 +0200chrisGuest554
2021-08-22 23:39:33 +0200Racl(~Racl@80.174.59.205.dyn.user.ono.com) (Quit: Leaving...)
2021-08-22 23:40:18 +0200lavaman(~lavaman@98.38.249.169)
2021-08-22 23:44:44 +0200lavaman(~lavaman@98.38.249.169) (Ping timeout: 250 seconds)
2021-08-22 23:45:09 +0200 <hseg> reported: https://gitlab.haskell.org/ghc/ghc/-/issues/20265
2021-08-22 23:50:46 +0200roboguy_(~roboguy_@2605:a601:afe7:9f00:2d0e:8bc:c41d:5a84) (Remote host closed the connection)
2021-08-22 23:51:28 +0200roboguy_(~roboguy_@2605:a601:afe7:9f00:2d0e:8bc:c41d:5a84)
2021-08-22 23:52:01 +0200jakalx(~jakalx@base.jakalx.net)
2021-08-22 23:54:16 +0200reumeth(~reumeth@user/reumeth) (Ping timeout: 250 seconds)
2021-08-22 23:56:26 +0200roboguy_(~roboguy_@2605:a601:afe7:9f00:2d0e:8bc:c41d:5a84) (Ping timeout: 250 seconds)
2021-08-22 23:58:51 +0200doyougnu(~user@c-73-25-202-122.hsd1.or.comcast.net) (Remote host closed the connection)
2021-08-22 23:58:52 +0200azeem(~azeem@176.200.243.28) (Read error: Connection reset by peer)
2021-08-22 23:59:07 +0200azeem(~azeem@dynamic-adsl-94-34-33-6.clienti.tiscali.it)