2020/09/26

2020-09-26 00:00:38 +0200Rudd0(~Rudd0@185.189.115.98)
2020-09-26 00:01:01 +0200GyroW(~GyroW@unaffiliated/gyrow) (Remote host closed the connection)
2020-09-26 00:01:24 +0200GyroW(~GyroW@ptr-48ujrfb8c7gfd2lu92q.18120a2.ip6.access.telenet.be)
2020-09-26 00:01:25 +0200GyroW(~GyroW@ptr-48ujrfb8c7gfd2lu92q.18120a2.ip6.access.telenet.be) (Changing host)
2020-09-26 00:01:25 +0200GyroW(~GyroW@unaffiliated/gyrow)
2020-09-26 00:01:49 +0200 <dsal> I used to use tcsh a lot way back in the day and people mocked me for various scripting things you couldn't do in tcsh. I'm like... I write my scripts in bourne shell, but I don't hang out there.
2020-09-26 00:02:20 +0200 <dsal> A friend had me try nushell which is... an idea. But it's a bit ununixy and a big uphill battle.
2020-09-26 00:04:43 +0200shafox(~shafox@106.51.234.111) (Remote host closed the connection)
2020-09-26 00:04:44 +0200ryansmccoy(~ryansmcco@193.37.254.27) (Ping timeout: 272 seconds)
2020-09-26 00:05:45 +0200ryansmccoy(~ryansmcco@156.96.151.132)
2020-09-26 00:06:00 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 272 seconds)
2020-09-26 00:07:33 +0200mu__(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 00:08:02 +0200mu(~mu@unaffiliated/mu)
2020-09-26 00:10:58 +0200GyroW(~GyroW@unaffiliated/gyrow) (Remote host closed the connection)
2020-09-26 00:11:22 +0200GyroW(~GyroW@ptr-48ujrfb8c7gfd2lu92q.18120a2.ip6.access.telenet.be)
2020-09-26 00:11:22 +0200GyroW(~GyroW@ptr-48ujrfb8c7gfd2lu92q.18120a2.ip6.access.telenet.be) (Changing host)
2020-09-26 00:11:22 +0200GyroW(~GyroW@unaffiliated/gyrow)
2020-09-26 00:11:53 +0200chaosmasttter(~chaosmast@p200300c4a7105f013091658b0e650c79.dip0.t-ipconnect.de) (Quit: WeeChat 2.9)
2020-09-26 00:13:10 +0200 <ski> @where thwap
2020-09-26 00:13:10 +0200 <lambdabot> "Bob the Angry Flower's Quick Guide to" : "the apostrophe" in 2010-02 at <http://eloquentscience.com/wp-content/uploads/2010/02/bobsqu.gif>,"its and it's" in 2010-03 at <http://eloquentscience.com/
2020-09-26 00:13:11 +0200 <lambdabot> wp-content/uploads/2010/03/angry-flower-guide-to-its.gif> )
2020-09-26 00:13:21 +0200 <ski> ddellacosta,Cale ^
2020-09-26 00:13:27 +0200 <dolio> Wow, nushell has like 3 corporate buzzwords phrases in the first two sentences describing it.
2020-09-26 00:15:15 +0200Erato(585fd1fd@ti0203q160-5312.bb.online.no) (Remote host closed the connection)
2020-09-26 00:15:35 +0200mu(~mu@unaffiliated/mu) (Quit: mu)
2020-09-26 00:16:11 +0200luke(~luke@bitnomial/staff/luke) (Quit: sleep)
2020-09-26 00:16:16 +0200 <ski> monochrom : don't forget Fᵢ-shell <http://fishell.sf.net> :)
2020-09-26 00:16:54 +0200 <ski> (partially inspired by logic programming)
2020-09-26 00:21:40 +0200jonatanb(~jonatanb@83.24.231.247.ipv4.supernova.orange.pl) (Quit: Leaving...)
2020-09-26 00:21:42 +0200falafel_(~falafel@2605:e000:1527:d491:f090:20fe:cddf:2a1a) (Ping timeout: 260 seconds)
2020-09-26 00:23:45 +0200evanjs(~evanjs@075-129-188-019.res.spectrum.com) (Ping timeout: 240 seconds)
2020-09-26 00:24:51 +0200machinedgod(~machinedg@24.105.81.50)
2020-09-26 00:25:40 +0200eruditass(uid248673@gateway/web/irccloud.com/x-eolintwxiwbmuxmq) (Quit: Connection closed for inactivity)
2020-09-26 00:26:44 +0200alanz_alanz
2020-09-26 00:28:45 +0200fendor(~fendor@91.141.3.153.wireless.dyn.drei.com) (Remote host closed the connection)
2020-09-26 00:28:58 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 260 seconds)
2020-09-26 00:29:12 +0200tomku(~tomku@unaffiliated/tomku) (Ping timeout: 256 seconds)
2020-09-26 00:29:16 +0200evanjs(~evanjs@075-129-188-019.res.spectrum.com)
2020-09-26 00:30:07 +0200 <ddellacosta> ski: :-D
2020-09-26 00:34:01 +0200ahri(~ahri@178.209.40.84) (Quit: Ping timeout (120 seconds))
2020-09-26 00:34:04 +0200mu(~mu@unaffiliated/mu)
2020-09-26 00:34:15 +0200mu(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 00:34:45 +0200mu(~mu@unaffiliated/mu)
2020-09-26 00:34:48 +0200ahri(~ahri@178.209.40.84)
2020-09-26 00:35:46 +0200tomku(~tomku@unaffiliated/tomku)
2020-09-26 00:37:02 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 00:37:45 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:39e7:ae73:eac9:cd04)
2020-09-26 00:39:24 +0200irc_user(uid423822@gateway/web/irccloud.com/x-kojvjfqrylgayrvg) (Quit: Connection closed for inactivity)
2020-09-26 00:39:45 +0200__monty__(~toonn@unaffiliated/toonn) (Quit: leaving)
2020-09-26 00:42:18 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-09-26 00:44:16 +0200mu(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 00:44:45 +0200mu(~mu@unaffiliated/mu)
2020-09-26 00:46:39 +0200DataComputist(~lumeng@static-50-43-26-251.bvtn.or.frontiernet.net) (Quit: Leaving...)
2020-09-26 00:49:34 +0200oisdk(~oisdk@2001:bb6:3329:d100:fd58:7633:8b1d:97)
2020-09-26 00:49:58 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt) (Remote host closed the connection)
2020-09-26 00:50:37 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt)
2020-09-26 00:51:34 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:39e7:ae73:eac9:cd04) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 00:54:15 +0200mu(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 00:54:46 +0200mu(~mu@unaffiliated/mu)
2020-09-26 00:55:13 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt) (Ping timeout: 260 seconds)
2020-09-26 00:59:23 +0200DataComputist(~lumeng@static-50-43-26-251.bvtn.or.frontiernet.net)
2020-09-26 01:00:36 +0200alexm_(~alexm_@161.8.233.138)
2020-09-26 01:01:21 +0200archaephyrryx(~archaephy@straasha.imrryr.org) ()
2020-09-26 01:02:09 +0200elliott_(~elliott_@pool-100-36-54-163.washdc.fios.verizon.net) (Ping timeout: 265 seconds)
2020-09-26 01:02:15 +0200 <maerwald> can you tell ormolu the indent size?
2020-09-26 01:02:48 +0200 <monochrom> No, tell formolu instead.
2020-09-26 01:03:07 +0200Guest86631z0
2020-09-26 01:03:23 +0200mu(~mu@unaffiliated/mu) (Quit: mu)
2020-09-26 01:03:44 +0200 <maerwald> https://github.com/tweag/ormolu/issues/637
2020-09-26 01:03:46 +0200 <maerwald> lol
2020-09-26 01:04:33 +0200wroathe(~wroathe@c-73-24-27-54.hsd1.mn.comcast.net) (Ping timeout: 256 seconds)
2020-09-26 01:05:08 +0200rprije(~rprije@27.143.220.203.dial.dynamic.acc01-myal-dub.comindico.com.au)
2020-09-26 01:05:32 +0200alexm_(~alexm_@161.8.233.138) (Ping timeout: 272 seconds)
2020-09-26 01:05:37 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:9c30:b346:e09c:915)
2020-09-26 01:05:55 +0200 <maerwald> consistency across projects that are alien to one another is big nonsense imo
2020-09-26 01:07:37 +0200 <dsal> ormolu is really awful. I know some people like the elm-inspired style, but it's actively bad.
2020-09-26 01:08:47 +0200shatriff(~vitaliish@176.52.219.10) (Remote host closed the connection)
2020-09-26 01:09:36 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 01:10:31 +0200wroathe(~wroathe@c-73-24-27-54.hsd1.mn.comcast.net)
2020-09-26 01:10:34 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2020-09-26 01:10:40 +0200thewormkill(~thewormki@unaffiliated/twk-)
2020-09-26 01:10:45 +0200iinuwa1(iinuwamatr@gateway/shell/matrix.org/x-thwbsslmbetrqwug)
2020-09-26 01:10:59 +0200Randy_(randy@freebsd/user/randy)
2020-09-26 01:11:14 +0200jneira(501e65ce@gateway/web/cgi-irc/kiwiirc.com/ip.80.30.101.206)
2020-09-26 01:11:22 +0200 <maerwald> uh... the way it breaks down long function signatures is odd
2020-09-26 01:11:25 +0200michaelpj1(michaelpjm@gateway/shell/matrix.org/x-zdqnoycusovyxytr)
2020-09-26 01:11:27 +0200 <maerwald> -> is at the end of the line
2020-09-26 01:11:30 +0200DANtheBEASTman(dysfigured@2600:3c00::f03c:92ff:feb4:be75)
2020-09-26 01:11:31 +0200atk(~Arch-TK@ircpuzzles/staff/Arch-TK) (Quit: Well this is unexpected.)
2020-09-26 01:11:43 +0200atk(~Arch-TK@ircpuzzles/staff/Arch-TK)
2020-09-26 01:12:00 +0200 <maerwald> the end of a line is naturally what your eyes skip with a 50% chance
2020-09-26 01:12:08 +0200DavSanchez[m]1(davsanchez@gateway/shell/matrix.org/x-intvmspuzeodooky)
2020-09-26 01:12:43 +0200 <justsomeguy> dsal: If you like shells, I found this awesome page of weird unix shells ... https://github.com/oilshell/oil/wiki/ExternalResources
2020-09-26 01:12:55 +0200 <ski> maerwald : yea ..
2020-09-26 01:12:56 +0200 <dsal> Some people have weird style preferences and very strong views that everyone should use them. (I say "weird" in the sense that it's just different from all the code I read when I was learning stuff, and a major disruption from stylish-haskell as I've been using it).
2020-09-26 01:13:17 +0200iinuwa(iinuwamatr@gateway/shell/matrix.org/x-cpxacqnfoehfxudr) (Ping timeout: 246 seconds)
2020-09-26 01:13:17 +0200twk-(~thewormki@unaffiliated/twk-) (Ping timeout: 246 seconds)
2020-09-26 01:13:17 +0200dysfigured(dysfigured@2600:3c00::f03c:92ff:feb4:be75) (Ping timeout: 246 seconds)
2020-09-26 01:13:17 +0200Randy(randy@freebsd/user/randy) (Read error: Connection reset by peer)
2020-09-26 01:13:17 +0200michaelpj(michaelpjm@gateway/shell/matrix.org/x-vziiihintzllemir) (Ping timeout: 246 seconds)
2020-09-26 01:13:18 +0200SlackIntegration(slackbotma@gateway/shell/matrix.org/x-knwcnagkikvaicmj) (Ping timeout: 246 seconds)
2020-09-26 01:13:18 +0200DavSanchez[m](davsanchez@gateway/shell/matrix.org/x-rxubxddrjnvzmpdu) (Ping timeout: 246 seconds)
2020-09-26 01:13:18 +0200DANtheBEASTmandysfigured
2020-09-26 01:13:18 +0200 <dsal> justsomeguy: I just kind of live in shells. I eventually gave up on trying to build a perfect environment.
2020-09-26 01:13:18 +0200Randy_Randy
2020-09-26 01:14:42 +0200 <dsal> I eventually started using bash so I wouldn't be That Weird Guy, and then recently OS X told me I need to move out of bash because it's not shiny enough.
2020-09-26 01:14:56 +0200 <yushyin> monochrom: afaik the fork is fourmolu (minor typo)
2020-09-26 01:15:20 +0200 <dsal> Wait, is it really just ormolu with s/2/4/g ?
2020-09-26 01:15:23 +0200 <justsomeguy> dsal: I've pretty much standardized on bash, too, but I do enjoy experimenting with other things.
2020-09-26 01:15:33 +0200 <ski> dsal : back to tcsh, or what ?
2020-09-26 01:15:35 +0200 <dsal> justsomeguy: nushell was neat, but I did break it pretty quickly. heh. joys of nix, though.
2020-09-26 01:15:44 +0200 <dsal> ski: OS X is moving folks to zsh
2020-09-26 01:15:49 +0200 <ski> mhm
2020-09-26 01:15:53 +0200 <dsal> But yeah, that's a good point. OS X was tcsh when I started using it.
2020-09-26 01:16:07 +0200ski's still using TCsh ..
2020-09-26 01:16:56 +0200oatsoa
2020-09-26 01:23:41 +0200reppertj(~textual@pool-96-246-209-59.nycmny.fios.verizon.net) (Quit: Textual IRC Client: www.textualapp.com)
2020-09-26 01:25:32 +0200thc202(~thc202@unaffiliated/thc202) (Ping timeout: 260 seconds)
2020-09-26 01:28:27 +0200cr3(~cr3@192-222-143-195.qc.cable.ebox.net) (Quit: leaving)
2020-09-26 01:28:28 +0200ryansmccoy(~ryansmcco@156.96.151.132) (Ping timeout: 260 seconds)
2020-09-26 01:29:25 +0200ryansmccoy(~ryansmcco@193.37.254.27)
2020-09-26 01:29:45 +0200isovector1(~isovector@172.103.216.166) (Ping timeout: 240 seconds)
2020-09-26 01:35:17 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 01:36:29 +0200Tuplanolla(~Tuplanoll@91-159-68-239.elisa-laajakaista.fi) (Quit: Leaving.)
2020-09-26 01:38:30 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 01:39:34 +0200josh_(~josh@c-67-164-104-206.hsd1.ca.comcast.net) (Remote host closed the connection)
2020-09-26 01:40:51 +0200ryansmccoy(~ryansmcco@193.37.254.27) (Ping timeout: 258 seconds)
2020-09-26 01:41:10 +0200ryansmccoy(~ryansmcco@193.37.254.27)
2020-09-26 01:41:53 +0200Gurkenglas(~Gurkengla@unaffiliated/gurkenglas) (Ping timeout: 260 seconds)
2020-09-26 01:43:00 +0200polyrain(~polyrain@2001:8003:e501:6901:d8b0:8850:f51:bc36)
2020-09-26 01:43:19 +0200josh_(~josh@c-67-164-104-206.hsd1.ca.comcast.net)
2020-09-26 01:43:23 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 240 seconds)
2020-09-26 01:43:25 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 264 seconds)
2020-09-26 01:43:39 +0200josh_(~josh@c-67-164-104-206.hsd1.ca.comcast.net) (Remote host closed the connection)
2020-09-26 01:49:46 +0200Henson(~kvirc@24-246-25-37.cable.teksavvy.com)
2020-09-26 01:56:15 +0200wroathe_(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-09-26 01:58:34 +0200kirill(~user@135-23-120-233.cpe.pppoe.ca)
2020-09-26 01:58:37 +0200wroathe(~wroathe@c-73-24-27-54.hsd1.mn.comcast.net) (Ping timeout: 272 seconds)
2020-09-26 01:59:30 +0200 <kirill> hi all, I was looking at some docs and saw this definition "class Monad m => Blah k v m | m -> k, m -> v where [...]". what does the "| m -> k, m -> v" mean in this context?
2020-09-26 02:00:01 +0200aj1(~aj@185.204.1.185) ()
2020-09-26 02:00:45 +0200wroathe_(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Ping timeout: 240 seconds)
2020-09-26 02:01:54 +0200Dablyon(~godel@173.171.157.121)
2020-09-26 02:02:32 +0200 <Turmfalke> It's called functional dependencies. m -> k states that k can be uniquely determined from m
2020-09-26 02:03:16 +0200 <kirill> "functional dependencies" -- thanks! I'll read up on these
2020-09-26 02:04:37 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net) (Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net)
2020-09-26 02:04:56 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net)
2020-09-26 02:06:22 +0200bloodstalker(~bloodstal@46.166.187.178)
2020-09-26 02:06:25 +0200kirill(~user@135-23-120-233.cpe.pppoe.ca) ("ERC (IRC client for Emacs 27.1)")
2020-09-26 02:06:34 +0200 <monochrom> maerwald: There is one school of thought of coding style that wants: line n "1st long thing +", line n+1 "2nd long thing". I think ormulo putting "->" just before line break is following that.
2020-09-26 02:07:52 +0200 <monochrom> And there is an opposite school of thought that wants: line n " 1st long thing", line n+1 "+ 2nd long thing". For example the Python official coding style promotes this. I like it too.
2020-09-26 02:08:14 +0200Dablyon(~godel@173.171.157.121) (Ping timeout: 272 seconds)
2020-09-26 02:08:38 +0200 <monochrom> Err actually the Python coding style promotes line n "1st long thing" without leading spaces for aligning with the 2nd long thing, heh.
2020-09-26 02:09:36 +0200 <monochrom> It says it's inspired by math formula formatting style. But of course, math formatting style adds leading space to align, and then the Python guide decides to give a reason to change that.
2020-09-26 02:11:05 +0200 <monochrom> I think one reason is when "+ 2nd long thing" is added or removed, no change to line n, reducing "code commit that changes spacing".
2020-09-26 02:11:08 +0200glguy(x@freenode/staff/haskell.developer.glguy) (Read error: Connection reset by peer)
2020-09-26 02:11:13 +0200 <monochrom> s/reducing/avoiding/
2020-09-26 02:12:14 +0200 <monochrom> Plain-text-file programming is really aging and showing its cracks.
2020-09-26 02:13:08 +0200olligobber(olligobber@gateway/vpn/privateinternetaccess/olligobber)
2020-09-26 02:13:37 +0200glguy(~glguy@freenode/staff/haskell.developer.glguy)
2020-09-26 02:14:52 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:9c30:b346:e09c:915) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 02:17:49 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 02:18:52 +0200glguy(~glguy@freenode/staff/haskell.developer.glguy) (Read error: Connection reset by peer)
2020-09-26 02:18:54 +0200Dablyon(~godel@173.171.157.121)
2020-09-26 02:19:27 +0200glguy(~glguy@freenode/staff/haskell.developer.glguy)
2020-09-26 02:20:17 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net) (Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net)
2020-09-26 02:20:21 +0200isovector1(~isovector@172.103.216.166.cable.tpia.cipherkey.com)
2020-09-26 02:21:13 +0200Rudd0(~Rudd0@185.189.115.98) (Ping timeout: 264 seconds)
2020-09-26 02:21:15 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1)
2020-09-26 02:21:57 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net)
2020-09-26 02:22:45 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 240 seconds)
2020-09-26 02:23:29 +0200Dablyon(~godel@173.171.157.121) (Ping timeout: 246 seconds)
2020-09-26 02:26:30 +0200sand_dull(~theuser@62.182.99.37)
2020-09-26 02:31:10 +0200CrazyPython(~crazypyth@71-135-5-88.lightspeed.rlghnc.sbcglobal.net)
2020-09-26 02:31:32 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 02:33:09 +0200meditans(uid129819@gateway/web/irccloud.com/x-rnbjhlecdsqalsub) (Quit: Connection closed for inactivity)
2020-09-26 02:33:23 +0200 <dolio> Arguments about changing extra lines seems a lot like one of those 'programmers optimizing what doesn't actually matter' things.
2020-09-26 02:36:13 +0200 <monochrom> I know right?
2020-09-26 02:36:50 +0200 <yushyin> but the diffs must be as small as possible!!1
2020-09-26 02:37:21 +0200 <monochrom> As I think through this again, I am now more inclined to adding the extra space before "1st long thing" because that gap is visual cue to alert you "expect a connecting infix operator to happen next line"
2020-09-26 02:37:56 +0200 <monochrom> But deep down in my heart, I like Leslie Lamport's way the best.
2020-09-26 02:38:05 +0200Henson(~kvirc@24-246-25-37.cable.teksavvy.com) (Ping timeout: 240 seconds)
2020-09-26 02:38:51 +0200 <dolio> I'm not sure any math references are legitimate, either.
2020-09-26 02:39:01 +0200 <monochrom> Let me describe it by first referring to common math formatting. You have 3 long things added together, so you go " 1st long thing", "+ 2nd long thing", "+ 3rd long thing", right?
2020-09-26 02:39:18 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1)
2020-09-26 02:39:25 +0200spew(uid195861@gateway/web/irccloud.com/x-cksfmsrynriuwhsd) (Quit: Connection closed for inactivity)
2020-09-26 02:39:34 +0200 <monochrom> Lamport was like "why not make the + play the double role of being the bullet in your list of bullet points!"
2020-09-26 02:39:58 +0200 <monochrom> So his style goes "+ 1st long thing", "+ 2nd long thing", "+ 3rd long thing".
2020-09-26 02:40:36 +0200 <monochrom> This is the best of both worlds of visually cuing you to a connecting infix operator and avoiding spacing changes when you add or remove an operand.
2020-09-26 02:41:10 +0200isovector1(~isovector@172.103.216.166.cable.tpia.cipherkey.com) (Ping timeout: 272 seconds)
2020-09-26 02:41:41 +0200 <monochrom> Hrm let me check again about the math reference.
2020-09-26 02:41:47 +0200oisdk(~oisdk@2001:bb6:3329:d100:fd58:7633:8b1d:97) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 02:42:17 +0200 <dolio> Well, I just don't believe 99.99% of programmers when they talk about math. :)
2020-09-26 02:42:19 +0200 <monochrom> It is possible that I misremembered, that more correctly the Python guide is referring to specifically one textbook.
2020-09-26 02:42:30 +0200oisdk(~oisdk@2001:bb6:3329:d100:fd58:7633:8b1d:97)
2020-09-26 02:43:46 +0200 <dolio> Also math notation is all over the place, and isn't always very good.
2020-09-26 02:44:50 +0200 <monochrom> The Python style guide is at https://www.python.org/dev/peps/pep-0008/#should-a-line-break-before-or-after-a-binary-operator , it refers to Donald Knuth
2020-09-26 02:45:36 +0200 <monochrom> But it does claim "mathematicians and their publishers" before citing Donald Knuth, heh.
2020-09-26 02:46:12 +0200 <dolio> Haskell should ditch lambda expressions and switch to calculus notation for variable binding.
2020-09-26 02:46:27 +0200 <dolio> fmap (x + 1 dx) [1,2,3]
2020-09-26 02:46:49 +0200 <monochrom> haha
2020-09-26 02:47:06 +0200 <monochrom> f x = x + 2*y dy
2020-09-26 02:48:04 +0200kritzefitz(~kritzefit@212.86.56.80) (Remote host closed the connection)
2020-09-26 02:48:22 +0200 <monochrom> I like Lamport's the best. It has the most symmetry.
2020-09-26 02:49:35 +0200 <monochrom> But don't worry, I don't have a strong conviction in this. I'm OK with the other two styles.
2020-09-26 02:49:57 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 02:50:24 +0200gabiruh(~gabiruh@vps19177.publiccloud.com.br) (Quit: ZNC 1.7.5 - https://znc.in)
2020-09-26 02:50:49 +0200gabiruh(~gabiruh@vps19177.publiccloud.com.br)
2020-09-26 02:51:31 +0200 <monochrom> You know that the calculus dx notation takes on a life of its own, right? Actually two or even more lives.
2020-09-26 02:51:51 +0200 <monochrom> One is infinitestimal non-standard analysis.
2020-09-26 02:51:53 +0200 <dolio> Yes.
2020-09-26 02:52:13 +0200 <dolio> You can actually make sense of all the 'wrong' stuff that physicists do using something like synthetic differential geometry, I think.
2020-09-26 02:52:16 +0200 <monochrom> Another is those 1-forms, 2-forms, etc., wedge products, tensor thingies in differential geometry.
2020-09-26 02:52:31 +0200 <EvanR> "all" the wrong stuff?
2020-09-26 02:52:32 +0200 <monochrom> Yeah that.
2020-09-26 02:52:36 +0200 <dolio> Actually, probably weirder stuff that physicists even come up with, I've heard.
2020-09-26 02:52:42 +0200 <dolio> Than, even.
2020-09-26 02:53:15 +0200 <monochrom> Well, I am sympathetic because Dirac's delta function is useful, even though it's a headache to give semantics to.
2020-09-26 02:53:17 +0200 <dolio> EvanR: The stuff that mathematicians tell you is wrong, but actually works, at least.
2020-09-26 02:53:55 +0200 <dolio> Because the mathematicians lie about studying the basis for what the physicists are doing.
2020-09-26 02:55:03 +0200nineonine(~nineonine@216.81.48.202) (Remote host closed the connection)
2020-09-26 02:55:12 +0200 <monochrom> I'm sympathetic to that too, because I believe that the mathematicians don't intend to lie, they just get sidetracked.
2020-09-26 02:55:36 +0200nineonine(~nineonine@216.81.48.202)
2020-09-26 02:55:36 +0200 <EvanR> i've come to see calculus notations as being part of a type system
2020-09-26 02:56:01 +0200 <EvanR> 5 and 5 dx aren't two different values, they not even the same type
2020-09-26 02:56:13 +0200 <monochrom> They started out really wanting to explain what the physicists are doing. Then there is a side discovery that led them down a tangent to a new hobby.
2020-09-26 02:56:26 +0200 <dolio> Yeah.
2020-09-26 02:57:11 +0200inkbottle(~inkbottle@aaubervilliers-654-1-115-202.w86-198.abo.wanadoo.fr) (Quit: Konversation terminated!)
2020-09-26 02:57:27 +0200inkbottle(~inkbottle@aaubervilliers-654-1-115-202.w86-198.abo.wanadoo.fr)
2020-09-26 02:57:51 +0200vk3wtf(~doc@27-32-252-91.tpgi.com.au) (Quit: WeeChat 2.7.1)
2020-09-26 02:58:47 +0200xff0x(~fox@2001:1a81:52cd:2700:e58f:2a70:d271:af84) (Ping timeout: 240 seconds)
2020-09-26 02:59:00 +0200 <dolio> That doesn't make them correct to say that the physicists need to follow the rules of their tangent hobby, though.
2020-09-26 02:59:37 +0200 <EvanR> prescriptive vs descriptive math ?
2020-09-26 02:59:45 +0200nineonine(~nineonine@216.81.48.202) (Ping timeout: 240 seconds)
2020-09-26 02:59:49 +0200xff0x(~fox@port-92-195-124-251.dynamic.as20676.net)
2020-09-26 03:00:26 +0200 <monochrom> tangential vs secantial :)
2020-09-26 03:00:29 +0200 <glguy> What're criticizing exactly?
2020-09-26 03:00:46 +0200 <glguy> We*
2020-09-26 03:01:03 +0200 <monochrom> We are not criticizing. OK, I am not.
2020-09-26 03:01:17 +0200 <glguy> Well that doesn't help me
2020-09-26 03:01:43 +0200 <monochrom> If you like, maybe it all started with criticizing coding styles?
2020-09-26 03:02:02 +0200 <dolio> I don't have a good specific example. But if you watch physics lectures, eventually you'll see a professor do something that doesn't make sense from a classical analysis perspective, and someone in some comments will say, "as a mathematician, what you did there was invalid."
2020-09-26 03:02:14 +0200 <monochrom> Like, if you have "1st long thing + 2nd long thing" to be split into two lines, where do you split and format the two lines?
2020-09-26 03:02:39 +0200 <dolio> Like, cancelling numerators/denominators in derivative stuff or something is a simple example.
2020-09-26 03:02:58 +0200 <EvanR> i kind of hope this characterization of "mathematicians" is only a stereotype
2020-09-26 03:03:02 +0200 <dolio> But there are mathematical systems where stuff like that is complately justified.
2020-09-26 03:03:45 +0200ahri(~ahri@178.209.40.84) (Quit: Ping timeout (120 seconds))
2020-09-26 03:03:58 +0200 <monochrom> We have similarly anal, narrow-minded programmers as well.
2020-09-26 03:04:14 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-09-26 03:04:27 +0200ahri(~ahri@178.209.40.84)
2020-09-26 03:04:40 +0200 <monochrom> You write a C program that's tuned to your compiler and OS and hardware, and you know why it is correct in your context.
2020-09-26 03:04:55 +0200olligobber(olligobber@gateway/vpn/privateinternetaccess/olligobber) (Remote host closed the connection)
2020-09-26 03:05:08 +0200 <dolio> This probably isn't a description of a lot of good mathematicians, but there are a alot of not good ones commenting on things.
2020-09-26 03:05:11 +0200 <monochrom> Someone is going to come and say "this line is UB" ignoring how you only intend your code for only one context.
2020-09-26 03:06:33 +0200 <dolio> Same phenomenon on interesting engineering principle videos I see that rack up comments about using PSI instead of metric, or pronouncing aluminum wrong.
2020-09-26 03:06:41 +0200 <EvanR> someone on the business end of dunning kruger
2020-09-26 03:07:12 +0200 <dolio> Can't focus on the interesting content instead of the veneer of units and stuff.
2020-09-26 03:07:21 +0200vk3wtf(~doc@27-32-252-91.tpgi.com.au)
2020-09-26 03:07:52 +0200xerox_(~xerox@unaffiliated/xerox) (Ping timeout: 256 seconds)
2020-09-26 03:08:27 +0200 <dolio> I didn't watch your video because you pronounced solder differently than I do.
2020-09-26 03:09:13 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Ping timeout: 264 seconds)
2020-09-26 03:10:34 +0200whataday(~xxx@2400:8902::f03c:92ff:fe60:98d8) (Remote host closed the connection)
2020-09-26 03:11:32 +0200 <EvanR> well, there being an isomorphism between physics in meters and physics in feet, or j^2 = -1 not i^2 seems different from stepping completely outside normal math rules
2020-09-26 03:11:41 +0200whataday(~xxx@2400:8902::f03c:92ff:fe60:98d8)
2020-09-26 03:11:45 +0200ryansmccoy(~ryansmcco@193.37.254.27) (Ping timeout: 240 seconds)
2020-09-26 03:12:07 +0200 <EvanR> esp without warning
2020-09-26 03:12:07 +0200ryansmccoy(~ryansmcco@68.235.48.108)
2020-09-26 03:12:07 +0200 <dolio> I saw a video a few days back where the professor mentioned that the speed of light is pretty close to 1 foot/ns.
2020-09-26 03:13:56 +0200 <glguy> That's convenient for me as I use gigafeet a lot
2020-09-26 03:15:36 +0200 <dolio> Why are the normal math rules the ones that don't correctly describe what works in physics and stuff, then?
2020-09-26 03:16:41 +0200machinedgod(~machinedg@24.105.81.50) (Ping timeout: 258 seconds)
2020-09-26 03:17:02 +0200 <EvanR> maybe math courses have a hard time distinguishing between, all our practices are consistent across subjects because they form part of a holy pyramid, or are like that for technical convenience
2020-09-26 03:18:00 +0200 <dolio> Yeah, I mean, there's definitely the 'Platonist' "everything is applied (classical) math" angle pushed heavily.
2020-09-26 03:18:13 +0200carlomagno1(~cararell@inet-hqmc02-o.oracle.com) (Ping timeout: 264 seconds)
2020-09-26 03:18:54 +0200 <ezzieyguywuf> if I'm doing `pure . Left "some error"` to put a Left into a State, isn't there a way to use fmap or something to do this more succinctly?
2020-09-26 03:19:24 +0200parsnip(sid147265@gateway/web/irccloud.com/x-vjnuxmoamisxbwgm) ()
2020-09-26 03:20:19 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64) (Ping timeout: 272 seconds)
2020-09-26 03:20:25 +0200 <dolio> I'm not sure how you could get much shorter than that.
2020-09-26 03:23:16 +0200 <monochrom> Wait a second, do you mean "pure (Left "some error")"? Or equivalently "(pure . Left) "some error""?
2020-09-26 03:23:32 +0200 <dolio> That was my assumption.
2020-09-26 03:23:39 +0200st8less(~st8less@2603:a060:11fe:0:b0dd:9d1b:8825:d363) (Quit: WeeChat 2.7.1)
2020-09-26 03:23:44 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-09-26 03:23:53 +0200 <monochrom> But yeah it's as short as you can get.
2020-09-26 03:24:00 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-09-26 03:25:00 +0200 <dolio> fmap is as long as pure, so I'm not sure how you could anticipate making something shorter with it. Left isn't a very long word, either.
2020-09-26 03:25:03 +0200shatriff(~vitaliish@176.52.219.10)
2020-09-26 03:25:54 +0200glguy(~glguy@freenode/staff/haskell.developer.glguy) (Quit: Quit)
2020-09-26 03:25:56 +0200 <dolio> In some larger context maybe you could shorten things.
2020-09-26 03:26:03 +0200glguy(x@freenode/staff/haskell.developer.glguy)
2020-09-26 03:26:57 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2020-09-26 03:28:47 +0200nineonine(~nineonine@216-19-190-182.dyn.novuscom.net)
2020-09-26 03:29:36 +0200nineonine(~nineonine@216-19-190-182.dyn.novuscom.net) (Remote host closed the connection)
2020-09-26 03:29:48 +0200nineonine(~nineonine@216-19-190-182.dyn.novuscom.net)
2020-09-26 03:29:49 +0200jneira(501e65ce@gateway/web/cgi-irc/kiwiirc.com/ip.80.30.101.206) (Ping timeout: 272 seconds)
2020-09-26 03:30:25 +0200 <ezzieyguywuf> dolio: monochrom: yes.
2020-09-26 03:30:52 +0200 <ezzieyguywuf> I thought that fmap could replace both pure and Left, but maybe I'm getting things confused.
2020-09-26 03:31:03 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 03:33:29 +0200 <monochrom> fmap can replace it but you have to also replace a larger context.
2020-09-26 03:33:58 +0200 <monochrom> `cmd >>= pure . Left` is replaceable by `fmap Left cmd`
2020-09-26 03:34:15 +0200 <ski> monochrom : oh, so i should refer to Lamport, when using indentation to avoid multiple-line-spanning parentheses ?
2020-09-26 03:34:46 +0200ahri(~ahri@178.209.40.84) (Quit: Ping timeout (120 seconds))
2020-09-26 03:34:47 +0200 <monochrom> If you go `fmap Left (pure "some error")`, that's legal, but also dorky. :)
2020-09-26 03:34:55 +0200 <ezzieyguywuf> monochrom: that's what I was thinking of
2020-09-26 03:35:05 +0200ahri(~ahri@178.209.40.84)
2020-09-26 03:35:13 +0200 <ezzieyguywuf> monochrom: i.e. cmd >> pure . Left
2020-09-26 03:35:25 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 240 seconds)
2020-09-26 03:35:51 +0200 <monochrom> ski: I think I don't know what Lamport does to indentation vs multiple-line-spanning parentheses.
2020-09-26 03:36:16 +0200 <dolio> ezzieyguywuf: Well, if you mean >>=, that is `fmap Left`.
2020-09-26 03:36:34 +0200 <ski> mhm, ok
2020-09-26 03:36:39 +0200 <dolio> If you mean `cmd >> pure (Left x)` that is `Left x <$ cmd`.
2020-09-26 03:36:58 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 03:41:28 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 260 seconds)
2020-09-26 03:42:37 +0200Carl2(726cdbbe@114.108.219.190)
2020-09-26 03:42:53 +0200miguel_clean(~Miguel@89-72-187-203.dynamic.chello.pl) (Read error: Connection reset by peer)
2020-09-26 03:42:59 +0200HarveyPwca(~HarveyPwc@c-98-220-98-201.hsd1.il.comcast.net)
2020-09-26 03:43:42 +0200 <ezzieyguywuf> nah, I meant >>=
2020-09-26 03:43:45 +0200Dablyon(~godel@173.171.157.121)
2020-09-26 03:43:45 +0200Carl2(726cdbbe@114.108.219.190) (Remote host closed the connection)
2020-09-26 03:46:02 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 03:47:42 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2020-09-26 03:48:04 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 03:48:07 +0200acidjnk_new(~acidjnk@p200300d0c7237802f9328c36b4a510ff.dip0.t-ipconnect.de) (Ping timeout: 240 seconds)
2020-09-26 03:49:53 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 03:50:28 +0200eco(ac696eac@172.105.110.172)
2020-09-26 03:52:42 +0200eco(ac696eac@172.105.110.172) (Remote host closed the connection)
2020-09-26 03:53:32 +0200GnumYabba(ac696eac@172.105.110.172)
2020-09-26 03:53:59 +0200xff0x_(~fox@2001:1a81:5304:1100:8dc8:588d:2a33:4ee3)
2020-09-26 03:54:02 +0200carlomagno(~cararell@inet-hqmc01-o.oracle.com)
2020-09-26 03:54:44 +0200kotrcka(~peter@ip-94-112-194-11.net.upcbroadband.cz)
2020-09-26 03:55:47 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64)
2020-09-26 03:56:01 +0200oaoats
2020-09-26 03:56:31 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 03:56:56 +0200xff0x(~fox@port-92-195-124-251.dynamic.as20676.net) (Ping timeout: 246 seconds)
2020-09-26 03:58:22 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-09-26 03:59:47 +0200mnrmnaughmnrgle(~mnrmnaugh@unaffiliated/mnrmnaugh) (Ping timeout: 240 seconds)
2020-09-26 04:00:05 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64) (Ping timeout: 246 seconds)
2020-09-26 04:02:14 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 272 seconds)
2020-09-26 04:02:48 +0200lucasb(uid333435@gateway/web/irccloud.com/x-lrjjlkqiwvxbxlhd) (Quit: Connection closed for inactivity)
2020-09-26 04:03:20 +0200RC-3004(~RC-3004@84.39.117.57)
2020-09-26 04:03:24 +0200DataComputist(~lumeng@static-50-43-26-251.bvtn.or.frontiernet.net) (Ping timeout: 260 seconds)
2020-09-26 04:04:45 +0200polyrain(~polyrain@2001:8003:e501:6901:d8b0:8850:f51:bc36) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 04:06:03 +0200danso(~dan@107-190-41-58.cpe.teksavvy.com)
2020-09-26 04:06:55 +0200DataComputist(~lumeng@static-50-43-26-251.bvtn.or.frontiernet.net)
2020-09-26 04:10:18 +0200xerox_(~xerox@unaffiliated/xerox)
2020-09-26 04:11:55 +0200mnrmnaughmnrgle(~mnrmnaugh@unaffiliated/mnrmnaugh)
2020-09-26 04:12:40 +0200Dablyon(~godel@173.171.157.121) (Quit: leaving)
2020-09-26 04:17:38 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt)
2020-09-26 04:18:38 +0200GnumYabba(ac696eac@172.105.110.172) (Remote host closed the connection)
2020-09-26 04:22:10 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt) (Ping timeout: 256 seconds)
2020-09-26 04:23:08 +0200sand_dull(~theuser@62.182.99.37) (Ping timeout: 272 seconds)
2020-09-26 04:24:34 +0200sand_dull(~theuser@62.182.99.37)
2020-09-26 04:27:03 +0200vk3wtf(~doc@27-32-252-91.tpgi.com.au) (Quit: WeeChat 2.7.1)
2020-09-26 04:27:28 +0200CrazyPyt_(~crazypyth@71-135-5-88.lightspeed.rlghnc.sbcglobal.net)
2020-09-26 04:27:33 +0200CrazyPython(~crazypyth@71-135-5-88.lightspeed.rlghnc.sbcglobal.net) (Ping timeout: 260 seconds)
2020-09-26 04:28:24 +0200lagothrixGuest2214
2020-09-26 04:28:24 +0200Guest2214(~lagothrix@unaffiliated/lagothrix) (Killed (rothfuss.freenode.net (Nickname regained by services)))
2020-09-26 04:28:32 +0200lagothrix(~lagothrix@unaffiliated/lagothrix)
2020-09-26 04:28:59 +0200vk3wtf(~doc@27-32-252-91.tpgi.com.au)
2020-09-26 04:33:22 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 04:34:26 +0200ahri(~ahri@178.209.40.84) (Quit: Ping timeout (120 seconds))
2020-09-26 04:34:55 +0200ahri(~ahri@178.209.40.84)
2020-09-26 04:34:57 +0200drbean(~drbean@TC210-63-209-151.static.apol.com.tw)
2020-09-26 04:35:24 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64)
2020-09-26 04:35:36 +0200hololeap(~hololeap@unaffiliated/hololeap)
2020-09-26 04:36:45 +0200raehik(~raehik@cpc96984-rdng25-2-0-cust109.15-3.cable.virginm.net) (Ping timeout: 265 seconds)
2020-09-26 04:37:47 +0200CrazyPyt_(~crazypyth@71-135-5-88.lightspeed.rlghnc.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 04:40:07 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64) (Ping timeout: 272 seconds)
2020-09-26 04:48:18 +0200mounty(~mounty@mail.nextgenerationvoice.com.au) (Ping timeout: 258 seconds)
2020-09-26 04:49:37 +0200Amras(~Amras@unaffiliated/amras0000) (Ping timeout: 272 seconds)
2020-09-26 04:51:27 +0200mounty(~mounty@n49-198-160-249.mrk1.qld.optusnet.com.au)
2020-09-26 04:55:02 +0200theDon(~td@94.134.91.145) (Ping timeout: 256 seconds)
2020-09-26 04:56:42 +0200theDon(~td@muedsl-82-207-238-034.citykom.de)
2020-09-26 04:58:20 +0200Lord_of_Life_(~Lord@unaffiliated/lord-of-life/x-0885362)
2020-09-26 05:00:01 +0200RC-3004(~RC-3004@84.39.117.57) ()
2020-09-26 05:00:11 +0200Lord_of_Life(~Lord@unaffiliated/lord-of-life/x-0885362) (Ping timeout: 258 seconds)
2020-09-26 05:00:12 +0200Lord_of_Life_Lord_of_Life
2020-09-26 05:00:43 +0200alexm_(~alexm_@161.8.233.138)
2020-09-26 05:02:17 +0200justanotheruser(~justanoth@unaffiliated/justanotheruser) (Ping timeout: 272 seconds)
2020-09-26 05:04:18 +0200ahri(~ahri@178.209.40.84) (Quit: Ping timeout (120 seconds))
2020-09-26 05:04:50 +0200alexm_(~alexm_@161.8.233.138) (Ping timeout: 246 seconds)
2020-09-26 05:04:52 +0200ahri(~ahri@178.209.40.84)
2020-09-26 05:07:45 +0200falafel_(~falafel@2605:e000:1527:d491:f090:20fe:cddf:2a1a)
2020-09-26 05:07:59 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 246 seconds)
2020-09-26 05:08:26 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 05:10:50 +0200notzmv(~user@unaffiliated/zmv)
2020-09-26 05:11:42 +0200bloodstalker(~bloodstal@46.166.187.178) (Remote host closed the connection)
2020-09-26 05:17:20 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1)
2020-09-26 05:17:24 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64)
2020-09-26 05:17:26 +0200justanotheruser(~justanoth@unaffiliated/justanotheruser)
2020-09-26 05:19:23 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 05:19:30 +0200mounty(~mounty@n49-198-160-249.mrk1.qld.optusnet.com.au) (Ping timeout: 272 seconds)
2020-09-26 05:19:57 +0200mounty(~mounty@mail.nextgenerationvoice.com.au)
2020-09-26 05:20:18 +0200DataComputist(~lumeng@static-50-43-26-251.bvtn.or.frontiernet.net) (Remote host closed the connection)
2020-09-26 05:21:38 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64) (Ping timeout: 246 seconds)
2020-09-26 05:21:53 +0200SAnnaBot(~SAnnaBot@185.204.1.185)
2020-09-26 05:24:08 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 260 seconds)
2020-09-26 05:24:38 +0200adamwespiser(~adam_wesp@209.6.42.110)
2020-09-26 05:29:07 +0200ericsagnes(~ericsagne@2405:6580:0:5100:c98f:bbb5:ca9:3c24) (Ping timeout: 260 seconds)
2020-09-26 05:30:55 +0200toorevitimirp(~tooreviti@117.182.182.201)
2020-09-26 05:31:28 +0200pankajgodbole(~user@122.179.155.150)
2020-09-26 05:36:20 +0200ddellacosta(~dd@86.106.121.168) (Ping timeout: 256 seconds)
2020-09-26 05:36:52 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 05:41:01 +0200ericsagnes(~ericsagne@2405:6580:0:5100:3c:e5e5:4614:3169)
2020-09-26 05:42:20 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 260 seconds)
2020-09-26 05:42:49 +0200xff0x_(~fox@2001:1a81:5304:1100:8dc8:588d:2a33:4ee3) (Ping timeout: 272 seconds)
2020-09-26 05:43:10 +0200xff0x_(~fox@2001:1a81:5304:1100:a54a:18d7:1a45:1603)
2020-09-26 05:43:33 +0200oisdk(~oisdk@2001:bb6:3329:d100:fd58:7633:8b1d:97) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 05:52:47 +0200danso(~dan@107-190-41-58.cpe.teksavvy.com) (Quit: WeeChat 2.9)
2020-09-26 05:58:28 +0200hackagehspec-wai-json 0.11.0 - Testing JSON APIs with hspec-wai https://hackage.haskell.org/package/hspec-wai-json-0.11.0 (SimonHengel)
2020-09-26 06:00:25 +0200Rudd0(~Rudd0@185.189.115.108)
2020-09-26 06:06:15 +0200polyphem(~p0lyph3m@2a02:810d:640:776c:76d7:55f6:f85b:c889) (Ping timeout: 272 seconds)
2020-09-26 06:06:20 +0200day_(~Unknown@unaffiliated/day)
2020-09-26 06:07:46 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 06:09:38 +0200day(~Unknown@unaffiliated/day) (Ping timeout: 260 seconds)
2020-09-26 06:09:38 +0200day_day
2020-09-26 06:10:10 +0200TooDifficult(~TooDiffic@139.59.59.230)
2020-09-26 06:14:24 +0200Sheilong(uid293653@gateway/web/irccloud.com/x-jwcpkbwpnookjrjz) ()
2020-09-26 06:14:27 +0200hackagehspec-wai 0.11.0 - Experimental Hspec support for testing WAI applications https://hackage.haskell.org/package/hspec-wai-0.11.0 (SimonHengel)
2020-09-26 06:17:48 +0200sand_dull(~theuser@62.182.99.37) (Ping timeout: 260 seconds)
2020-09-26 06:18:43 +0200cole-h(~cole-h@c-73-48-197-220.hsd1.ca.comcast.net)
2020-09-26 06:19:28 +0200sand_dull(~theuser@185.217.69.182)
2020-09-26 06:19:40 +0200perdent(~blah@101.175.167.92) (Ping timeout: 272 seconds)
2020-09-26 06:20:18 +0200perdent(~blah@101.175.129.224)
2020-09-26 06:21:35 +0200fraktor(~walt@129.93.191.18)
2020-09-26 06:22:14 +0200pankajgodbole(~user@122.179.155.150) ("ERC (IRC client for Emacs 26.3)")
2020-09-26 06:22:24 +0200fxg(~fxg@unaffiliated/fxg)
2020-09-26 06:23:04 +0200 <fraktor> Is there an equivalent in `base` to the Map datatype? I need it for a project that will run in an environment I don't control.
2020-09-26 06:23:33 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 06:24:51 +0200 <dsal> Equivalent in what way? List is there.
2020-09-26 06:25:14 +0200 <dsal> But if you want something that behaves like Data.Map.Strict, then you'll want Data.Map.Strict. It shouldn't be very hard to argue that as a dependency. :)
2020-09-26 06:25:39 +0200 <fraktor> True. I am running into an issue where I would like to "update" a map from coordinates to values, and doing that with associative lists is a little tricky.
2020-09-26 06:25:46 +0200eager_lambda(~gdrvnl@cpe-76-94-36-134.socal.res.rr.com)
2020-09-26 06:27:05 +0200 <dsal> That's basically map.
2020-09-26 06:27:42 +0200 <fraktor> Admission time: this is for homework that will run on a remote system.
2020-09-26 06:27:59 +0200 <dsal> You could make it average more efficient with a custom update function that wouldn't be that hard.
2020-09-26 06:29:50 +0200 <fraktor> Yeah, I just wrote one actually. I'm going to assume I can't use Map and then worry about it later.
2020-09-26 06:31:12 +0200justanotheruser(~justanoth@unaffiliated/justanotheruser) (Ping timeout: 260 seconds)
2020-09-26 06:31:39 +0200_vaibhavingale_(~Adium@203.188.228.27)
2020-09-26 06:35:57 +0200wei2912(~wei2912@unaffiliated/wei2912)
2020-09-26 06:41:12 +0200eager_lambda(~gdrvnl@cpe-76-94-36-134.socal.res.rr.com) (Quit: Leaving)
2020-09-26 06:41:26 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 246 seconds)
2020-09-26 06:41:39 +0200eager_lambda(~gdrvnl@cpe-76-94-36-134.socal.res.rr.com)
2020-09-26 06:42:42 +0200W3BV1P3R_(~W3BV1P3R@c-73-5-91-226.hsd1.tn.comcast.net)
2020-09-26 06:42:59 +0200ericsagnes(~ericsagne@2405:6580:0:5100:3c:e5e5:4614:3169) (Ping timeout: 272 seconds)
2020-09-26 06:45:53 +0200 <dolio> It doesn't make a lot of sense to not be allowed to use Data.Map, because it's part of the core libraries. It was just split out of base long ago so that it could be updated independently.
2020-09-26 06:45:57 +0200Rudd0(~Rudd0@185.189.115.108) (Remote host closed the connection)
2020-09-26 06:46:26 +0200totallynotnate(~nate@125.161.70.37)
2020-09-26 06:48:14 +0200W3BV1P3R_(~W3BV1P3R@c-73-5-91-226.hsd1.tn.comcast.net) (Quit: Igloo IRC: https://iglooirc.com)
2020-09-26 06:48:40 +0200shafox(~shafox@106.51.234.111)
2020-09-26 06:50:05 +0200Rudd0(~Rudd0@185.189.115.103)
2020-09-26 06:50:32 +0200 <fraktor> dolio: Wait, is it part of the regular GHC distribution?
2020-09-26 06:50:43 +0200 <fraktor> It's not that I'm not allowed to use it, but rather that I cannot install packages at all.
2020-09-26 06:51:10 +0200 <dolio> It normally ships with GHC, yeah.
2020-09-26 06:51:37 +0200Faker(bad2e02e@186.210.224.46)
2020-09-26 06:52:24 +0200 <dolio> Although it's entirely possible that someone could choose not to install all the things GHC ships with in e.g. a Linux package manager.
2020-09-26 06:52:46 +0200 <dolio> It wouldn't be very nice of your professor, th ough.
2020-09-26 06:53:44 +0200 <Faker> How to turn a lowercase string to uppercase ?
2020-09-26 06:54:37 +0200 <fraktor> dolio: I think that it's running on Debian? With GHC installed from a package manager.
2020-09-26 06:55:04 +0200ericsagnes(~ericsagne@2405:6580:0:5100:4882:fcf:4dee:3726)
2020-09-26 06:55:16 +0200 <c_wraith> wow. debian's package manager breaks ghc in lots of fun ways!
2020-09-26 06:55:28 +0200 <c_wraith> hope you never need to profile anything!
2020-09-26 06:55:58 +0200 <dolio> Well, hopefully they at least install the core libraries.
2020-09-26 07:00:00 +0200 <c_wraith> yep, looks like it does.
2020-09-26 07:00:02 +0200Saukk(~Saukk@2001:998:dc:4a67:1c59:9bb5:b94c:4)
2020-09-26 07:00:43 +0200alexm_(~alexm_@161.8.233.138)
2020-09-26 07:04:57 +0200mmohammadi9812(~mmohammad@2.178.197.45)
2020-09-26 07:04:59 +0200alexm_(~alexm_@161.8.233.138) (Ping timeout: 240 seconds)
2020-09-26 07:07:21 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net) (Quit: leaving)
2020-09-26 07:07:33 +0200 <fraktor> Even though it's a homework problem, is it okay if I post my code here to get some help with readability? I find it hard to understand but don't really know how to improve that.
2020-09-26 07:08:24 +0200totallynotnate(~nate@125.161.70.37) (Quit: WeeChat 2.9)
2020-09-26 07:08:27 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 07:10:11 +0200 <dsal> Faker: map all the chars to a function that upper cases each char
2020-09-26 07:10:42 +0200urodna(~urodna@unaffiliated/urodna) (Quit: urodna)
2020-09-26 07:11:18 +0200 <dsal> fraktor: "worry about it later" is a great skill
2020-09-26 07:11:36 +0200 <c_wraith> @where paste
2020-09-26 07:11:37 +0200 <lambdabot> Help us help you: please paste full code, input and/or output at eg https://paste.tomsmeding.com
2020-09-26 07:12:27 +0200 <perdent> Anyone here good with ECC/ECDLP crypto?
2020-09-26 07:12:29 +0200 <c_wraith> fraktor: if you want style advice, put the code there and then give us the link and ask for the kind of advice you'd like
2020-09-26 07:13:04 +0200 <fraktor> https://paste.tomsmeding.com/7AifjNEN
2020-09-26 07:13:11 +0200 <fraktor> Mostly it's style advice.
2020-09-26 07:13:18 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 256 seconds)
2020-09-26 07:13:37 +0200 <c_wraith> on a first glance, the overall appearance is fine.
2020-09-26 07:13:49 +0200 <c_wraith> that's roughly what Haskell code should look like
2020-09-26 07:13:50 +0200 <dsal> You named (Int, Int), use the name :)
2020-09-26 07:14:29 +0200 <fraktor> Whoops
2020-09-26 07:15:04 +0200 <c_wraith> oh. I'd rework encodeBoard. that second lambda is too much.
2020-09-26 07:15:06 +0200 <dsal> `EQ == compare y1 y2` is `y1 == y2`
2020-09-26 07:15:08 +0200josh_(~josh@c-67-164-104-206.hsd1.ca.comcast.net)
2020-09-26 07:15:42 +0200 <dsal> groupOn would be nice
2020-09-26 07:15:45 +0200 <fraktor> dsal: Hmm. Interesting
2020-09-26 07:15:45 +0200 <c_wraith> (and the first lambda happens to be identical to a function you probably already know)
2020-09-26 07:15:52 +0200 <dsal> @src groupOn
2020-09-26 07:15:53 +0200 <lambdabot> Source not found.
2020-09-26 07:16:05 +0200alexm_(~alexm_@161.8.233.138)
2020-09-26 07:16:09 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 07:16:39 +0200 <dsal> :t groupOn
2020-09-26 07:16:41 +0200 <lambdabot> error:
2020-09-26 07:16:41 +0200 <lambdabot> • Variable not in scope: groupOn
2020-09-26 07:16:41 +0200 <lambdabot> • Perhaps you meant one of these:
2020-09-26 07:16:44 +0200 <dsal> boo
2020-09-26 07:17:07 +0200berberman(~berberman@2408:8207:2565:18d0::a44) (Ping timeout: 240 seconds)
2020-09-26 07:17:16 +0200 <dsal> :t groupBy
2020-09-26 07:17:18 +0200 <lambdabot> (a -> a -> Bool) -> [a] -> [[a]]
2020-09-26 07:17:27 +0200SAnnaBot(~SAnnaBot@185.204.1.185) (Remote host closed the connection)
2020-09-26 07:17:56 +0200berberman(~berberman@2408:8207:256c:1c00:584e:a9ff:fe9b:d3fe)
2020-09-26 07:18:25 +0200 <fraktor> :t comparing
2020-09-26 07:18:25 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64)
2020-09-26 07:18:26 +0200 <lambdabot> Ord a => (b -> a) -> b -> b -> Ordering
2020-09-26 07:18:37 +0200 <fraktor> Kind of? But not really.
2020-09-26 07:18:54 +0200 <dsal> groupOn kind of rhymes with that
2020-09-26 07:19:39 +0200 <dsal> It's easy to write with groupBy and it makes that really readable.
2020-09-26 07:20:09 +0200 <fraktor> :t groupWith
2020-09-26 07:20:10 +0200 <lambdabot> error:
2020-09-26 07:20:10 +0200 <lambdabot> • Variable not in scope: groupWith
2020-09-26 07:20:10 +0200 <lambdabot> • Perhaps you meant one of these:
2020-09-26 07:21:04 +0200 <fraktor> Interesting. Hackage shows that existing.
2020-09-26 07:21:05 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 240 seconds)
2020-09-26 07:21:39 +0200sambo(6bb5131e@107.181.19.30)
2020-09-26 07:21:41 +0200sambo(6bb5131e@107.181.19.30) (Remote host closed the connection)
2020-09-26 07:22:14 +0200 <fraktor> Ah, it's in GHC.Exts. I think that's acceptable.
2020-09-26 07:22:22 +0200takuan(~takuan@178-116-218-225.access.telenet.be)
2020-09-26 07:23:37 +0200 <fraktor> c_wraith: Is this better? https://paste.tomsmeding.com/dfCZuFjh
2020-09-26 07:24:01 +0200 <c_wraith> that is a *lot* better, yes. :)
2020-09-26 07:24:09 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64) (Ping timeout: 272 seconds)
2020-09-26 07:25:07 +0200 <fraktor> applyMove also makes me sad
2020-09-26 07:27:09 +0200 <c_wraith> that's one of those cases where a do block might actually read better.
2020-09-26 07:27:25 +0200 <c_wraith> fromMaybe board $ do ...
2020-09-26 07:28:45 +0200jdgr(601c428b@gateway/web/cgi-irc/kiwiirc.com/ip.96.28.66.139) (Ping timeout: 240 seconds)
2020-09-26 07:28:47 +0200 <fraktor> Hmm. Let's see
2020-09-26 07:29:45 +0200 <dsal> liftM looks weird to me. Is that fmap?
2020-09-26 07:29:50 +0200 <c_wraith> yes
2020-09-26 07:32:11 +0200 <fraktor> Yeah I should use fmap.
2020-09-26 07:32:20 +0200 <dsal> I'd probably write `emptyIndex board = fst <$> Map.lookupMin . Map.filter (== 0) board`
2020-09-26 07:32:37 +0200 <c_wraith> yeah, I ran through it... applyMove gets a lot cleaner if you make most of it a do block
2020-09-26 07:32:43 +0200 <dsal> Though my brain compiler is rejecting that.
2020-09-26 07:32:58 +0200 <fraktor> That is so much better
2020-09-26 07:32:59 +0200 <c_wraith> since you get to drop a lot of stuff going on to maintain Maybe values
2020-09-26 07:33:03 +0200AmberJ_(~AmberJ_@195.140.213.38)
2020-09-26 07:33:17 +0200 <fraktor> https://paste.tomsmeding.com/MO0geafX
2020-09-26 07:33:56 +0200 <c_wraith> Yep. I think that's an improvement
2020-09-26 07:34:08 +0200 <fraktor> I'm happy with that function now. It's relatively easy to understand
2020-09-26 07:36:21 +0200 <dsal> I don't like return, but it's not incorrect. :)
2020-09-26 07:36:40 +0200 <Faker> dsal: How ?
2020-09-26 07:36:51 +0200 <dsal> Faker: what do you have?
2020-09-26 07:37:33 +0200 <fraktor> I'm guessing `Just`?
2020-09-26 07:37:39 +0200 <c_wraith> nah, pure
2020-09-26 07:37:46 +0200 <dsal> I'm a `pure`ist
2020-09-26 07:37:48 +0200 <c_wraith> but I don't think the difference matters
2020-09-26 07:37:52 +0200 <dsal> It doesn't.
2020-09-26 07:38:12 +0200Guest26(a181464f@gateway/web/cgi-irc/kiwiirc.com/ip.161.129.70.79)
2020-09-26 07:38:23 +0200 <fraktor> By the way, I just wrote `groupOn` so I wouldn't have to import a GHC extension
2020-09-26 07:38:46 +0200 <fraktor> `groupOn f = groupBy (\a b -> f a == f b)`
2020-09-26 07:39:01 +0200 <Faker> receives a word and returns the original word in tuple and uppercase
2020-09-26 07:39:21 +0200 <fraktor> Faker: What do you mean the "original word in tuple"?
2020-09-26 07:39:29 +0200 <Guest26> hello, I have a question about using Haskell to exchange data with a web page
2020-09-26 07:39:30 +0200 <Faker> the same word
2020-09-26 07:39:40 +0200 <fraktor> Oh I see. So it would be (original, uppercase)?
2020-09-26 07:39:52 +0200 <dsal> fraktor: yeah, it's not an important detail, but little things make big differences.
2020-09-26 07:39:57 +0200 <Faker> Exactly!
2020-09-26 07:40:26 +0200 <Guest26> there are several options for using Haskell for the web page also, but my question is about the interface
2020-09-26 07:40:26 +0200 <fraktor> http://hackage.haskell.org/package/base-4.14.0.0/docs/Data-Char.html This might have what you need, Faker
2020-09-26 07:40:35 +0200 <Faker> i dont know how to use uppercase yet
2020-09-26 07:40:53 +0200 <Faker> fraktor i will see
2020-09-26 07:41:10 +0200 <Guest26> most online tutorials suggest something like SQL - but there are also here several options that just use Haskell
2020-09-26 07:41:25 +0200 <dsal> Faker: You gave a really imprecise description of your goal. What code do you have? What signature?
2020-09-26 07:41:35 +0200 <dsal> Returning your input isn't usually very useful. Anyone who calls a function with input already has the input.
2020-09-26 07:41:56 +0200 <Faker> The input will be a string
2020-09-26 07:42:11 +0200 <dsal> Guest26: haskell and SQL aren't the same genus. It's not clear what you're trying to do.
2020-09-26 07:42:15 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1)
2020-09-26 07:42:41 +0200 <fraktor> Faker: I'm also confused why you would want to return a tuple when the caller can just do `(str, myFunc str)`
2020-09-26 07:43:12 +0200 <Guest26> for a test case, i would like to visualise some data sent through a database. in the browser i would like to use some libraries or js to make the visualisation nicer
2020-09-26 07:43:35 +0200 <dsal> Guest26: Sounds like a plan. I do that sometimes.
2020-09-26 07:43:47 +0200 <Guest26> dsal: i thought SQL could be a good way to send data between languages
2020-09-26 07:44:05 +0200 <dsal> SQL isn't a transport or interchange of any sort.
2020-09-26 07:44:14 +0200 <dsal> It's just some kind of structured query language.
2020-09-26 07:44:21 +0200 <Guest26> but since the language im sending it from is Haskell, i thought maybe a haskell replacement for SQL would work
2020-09-26 07:44:42 +0200 <fraktor> Guest26: what do you mean "a Haskell replacement for SQL"? They do fundamentally different things
2020-09-26 07:44:50 +0200 <Guest26> dsal: just because both languages normally would be able to interface with an SQL server
2020-09-26 07:44:53 +0200 <fraktor> What is the flow of data/queries that you're envisioning?
2020-09-26 07:45:50 +0200 <Guest26> something like, a server writing the number of users online, and the webpage displaying this as a graph that can be updated by refreshing the page
2020-09-26 07:46:06 +0200mirrorbird(~psutcliff@m83-187-185-252.cust.tele2.se)
2020-09-26 07:46:24 +0200 <fraktor> I see. So you're thinking of using a Haskell backend to mediate between a SQL server that has that information, and a web frontend?
2020-09-26 07:46:46 +0200 <Guest26> im not sure. it seems like haskell could even replace the web frontend aswell
2020-09-26 07:46:53 +0200 <fraktor> What? how?
2020-09-26 07:47:11 +0200 <Guest26> and then, it might not need SQL at all, because its not "communication between languages"
2020-09-26 07:47:20 +0200 <Guest26> which i thought i would need to send it to HTML
2020-09-26 07:47:22 +0200 <fraktor> That's... that's not what SQL does.
2020-09-26 07:47:23 +0200 <dsal> Whatever you mean by "send SQL" is almost certainly wrong.
2020-09-26 07:47:48 +0200sand_dull(~theuser@185.217.69.182) (Ping timeout: 256 seconds)
2020-09-26 07:47:50 +0200 <fraktor> SQL is a way of communicating with a database specifically. It's not a serialization format like JSON or XML. It describes queries, not data.
2020-09-26 07:48:01 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 07:48:23 +0200 <Faker> Fraktor how to use toUpper :: Char -> Char ?
2020-09-26 07:48:24 +0200jedws(~jedws@121.209.139.222)
2020-09-26 07:48:30 +0200 <dsal> > toUpper 'x'
2020-09-26 07:48:33 +0200 <lambdabot> 'X'
2020-09-26 07:48:57 +0200 <dsal> It takes a Char. It returns a Char.
2020-09-26 07:49:13 +0200 <Faker> Variable not in scope: toUpper :: Char -> t
2020-09-26 07:49:20 +0200 <Faker> Give me this error
2020-09-26 07:49:28 +0200 <Guest26> fraktor: yes, i mean there would be an SQL database, and both the HTML page, and the haskell program that needs to send data, could use the SQL database as a gobetween
2020-09-26 07:49:28 +0200 <fraktor> What code are you running on it?
2020-09-26 07:49:51 +0200Wuzzy(~Wuzzy@p5b0df9fe.dip0.t-ipconnect.de) (Remote host closed the connection)
2020-09-26 07:49:53 +0200 <fraktor> Guest26: Oh! You mean that the Haskell application is writing to the database, and the HTML page is reading from it?
2020-09-26 07:49:58 +0200 <Guest26> yes!
2020-09-26 07:50:02 +0200 <dsal> Faker: Sounds like you didn't import it. Are you trying to learn Haskell by trial and error?
2020-09-26 07:50:07 +0200 <fraktor> Okay. I think I understand now.
2020-09-26 07:50:34 +0200sand_dull(~theuser@185.217.69.182)
2020-09-26 07:50:37 +0200 <fraktor> Are you talking specifically about monitoring users though? More generally, is the data that you're using all metric-based?
2020-09-26 07:50:44 +0200 <Guest26> this seems like it might not be needed however, since if the haskell is also doing the webpage, then there might be an easier way to send the data
2020-09-26 07:51:14 +0200 <fraktor> Guest26: If the Haskell program is hosting the web page and acting as the backend, then you can send information through a serialization format. JSON is really easy to use in this use case.
2020-09-26 07:51:25 +0200 <Faker> dsal the import will be import Data.Char ?
2020-09-26 07:51:26 +0200 <Guest26> fraktor: i think most generally i would be sending json serializable data - but for the sake of example could just be a vector of doubles
2020-09-26 07:51:47 +0200 <Guest26> or, just a double, as thats easy to make a time dependent graph of
2020-09-26 07:52:29 +0200 <fraktor> Guest26: If you haven't, I would look into Prometheus. It's a tool specifically used for general metrics collection and querying, and is super widely used. It might not be to your use case, but I'd at least consider not reinventing the wheel.
2020-09-26 07:52:33 +0200 <Guest26> im not sure what you meant metric-based, does that answer the question?
2020-09-26 07:53:08 +0200 <Guest26> suppose i want to send a random number and visualise that in a time dependant graph
2020-09-26 07:53:31 +0200 <Guest26> im not sure if it being a user count is confusing things
2020-09-26 07:53:33 +0200 <fraktor> I should have said "time-series metrics." So for example, the total number of requests served, the number of active connections, percentiles for response times for your server, and so on.
2020-09-26 07:53:43 +0200 <dsal> I use influxdb from Haskell quite a bit. My coworkers like prometheus, but I don't respond to their peer pressure.
2020-09-26 07:53:43 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2020-09-26 07:53:45 +0200berberman(~berberman@2408:8207:256c:1c00:584e:a9ff:fe9b:d3fe) (Quit: ZNC 1.7.5 - https://znc.in)
2020-09-26 07:54:07 +0200 <Guest26> hmm, yes, certainly it is not supposed to be doing this, metrics thing
2020-09-26 07:54:08 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt)
2020-09-26 07:54:19 +0200 <fraktor> Prometheus is not really great as a time-series database generally, but if you're doing metrics, then it's absolutely the tool (or a very good tool anyway) for the job.
2020-09-26 07:54:38 +0200 <Guest26> im not
2020-09-26 07:54:51 +0200 <Guest26> it was just a simple example of a time varying value
2020-09-26 07:55:01 +0200Tops2(~Tobias@dyndsl-095-033-024-124.ewe-ip-backbone.de) (Quit: Leaving.)
2020-09-26 07:55:04 +0200 <fraktor> Okay. In that case, a time-series database with a Haskell backend is a good choice. I haven't used influxdb but I've heard good things.
2020-09-26 07:55:09 +0200 <Guest26> but a random number based on time of day is a better example
2020-09-26 07:55:13 +0200 <fraktor> If you don't mind me asking, what is the data that you're sending?
2020-09-26 07:55:25 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 07:55:32 +0200AmberJ_(~AmberJ_@195.140.213.38) (Remote host closed the connection)
2020-09-26 07:56:03 +0200 <Guest26> like i say, generally any json serializable, or perhaps binary serializable data. so generally any type that supports a generic instance.
2020-09-26 07:56:29 +0200 <fraktor> Is it all time-series data?
2020-09-26 07:56:35 +0200 <EvanR> a single random number based on the current time of day can be pretty bad
2020-09-26 07:56:43 +0200 <dsal> Even 4?
2020-09-26 07:56:53 +0200 <EvanR> 4 is one of the worst
2020-09-26 07:56:53 +0200 <Guest26> but if it has to go to an SQL database so it can be read by the HTML page, then maybe this limits the type
2020-09-26 07:57:09 +0200 <fraktor> I don't mean to pry but, what is the problem you're trying to solve?
2020-09-26 07:57:23 +0200sand_dull(~theuser@185.217.69.182) (Ping timeout: 246 seconds)
2020-09-26 07:57:30 +0200 <Guest26> fraktor: its not time series data persay, refreshing the webpage should just visualise the current database
2020-09-26 07:57:47 +0200 <Guest26> it would be time series data if the database update were just simple addition of a new value
2020-09-26 07:57:48 +0200 <dsal> What is "the current database" ?
2020-09-26 07:58:05 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt) (Ping timeout: 240 seconds)
2020-09-26 07:58:17 +0200 <Guest26> thats quite arbitrary - but for the sake of argument its a list of (time of day,double)
2020-09-26 07:58:41 +0200 <fraktor> You can absolutely use Haskell as a backend for some kind of frontend, and that would solve that problem, but what on earth are you doing with it?
2020-09-26 07:58:43 +0200 <Guest26> at least then i can imagine a simple HTML based visualisation thats just an xy graph
2020-09-26 07:58:49 +0200 <fraktor> Like, what is the software you're writing trying to solve?
2020-09-26 07:58:55 +0200 <dsal> Is a database even helpful? If your goal is to put all the data in a web page, then what does the database do here?
2020-09-26 07:59:19 +0200 <fraktor> dsal: I think that they were saying they didn't want to use the database if possible
2020-09-26 07:59:19 +0200 <Guest26> the database was for when i was thinking to visualise the data using R
2020-09-26 07:59:38 +0200 <Guest26> the R tutorial here used an SQL server; https://www.r-bloggers.com/2018/07/real-time-data-visualization-using-r-and-data-extracting-from-s…
2020-09-26 07:59:43 +0200 <dsal> I've never used R with a database.
2020-09-26 07:59:50 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 246 seconds)
2020-09-26 08:00:01 +0200 <Guest26> but if i dont use R, but a haskell powered webpage instead, maybe i dont need SQL
2020-09-26 08:00:30 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 08:00:39 +0200 <fraktor> What is this data? I'm really trying to understand what kind of data would have the properties you're describing.
2020-09-26 08:00:41 +0200 <Guest26> the most important feature is to be able to somehow have the webpage read some data written to disk by the other haskell program producing the data
2020-09-26 08:00:44 +0200 <dsal> You're just using words in places where they don't fit and that's a bit confusing.
2020-09-26 08:01:07 +0200 <dsal> Web servers are pretty good at reading data from disk and serving it to web browsers.
2020-09-26 08:01:21 +0200 <Guest26> % utc
2020-09-26 08:01:21 +0200 <yahb> Guest26: ; <interactive>:111:1: error: Variable not in scope: utc
2020-09-26 08:01:46 +0200 <Guest26> % getCurrentTime
2020-09-26 08:01:47 +0200 <yahb> Guest26: ; <interactive>:112:1: error:; * Variable not in scope: getCurrentTime; * Perhaps you meant `getCurrentCCS#' (imported from GHC.Prim)
2020-09-26 08:01:58 +0200 <Guest26> hmm, thats from Data.Time
2020-09-26 08:02:29 +0200 <Guest26> [(UTCTime,Double)]
2020-09-26 08:02:52 +0200Saukk(~Saukk@2001:998:dc:4a67:1c59:9bb5:b94c:4) (Remote host closed the connection)
2020-09-26 08:02:57 +0200 <fraktor> I understand that's the format of the data.
2020-09-26 08:03:02 +0200 <dsal> % getCurrentTime
2020-09-26 08:03:03 +0200 <yahb> dsal: 2020-09-26 06:03:02.989582121 UTC
2020-09-26 08:03:06 +0200 <fraktor> But like, what are you trying to accomplish with this software?
2020-09-26 08:03:07 +0200berberman(~berberman@2408:8207:256c:4a80:584e:a9ff:fe9b:d3fe)
2020-09-26 08:03:21 +0200 <Guest26> maybe i could write each data entry to its own file, but that seems bad. thats where i thought an SQL database that could be simultaniously updated by one process, and read by another process, would be good
2020-09-26 08:03:22 +0200 <fraktor> I'm asking because a solution might already exist for what you're doing.
2020-09-26 08:03:40 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 08:03:53 +0200ahri(~ahri@178.209.40.84) (Quit: Ping timeout (120 seconds))
2020-09-26 08:03:58 +0200 <Guest26> certainly not, the data is being calculated by another program, its impossible this would already exist
2020-09-26 08:04:05 +0200 <dsal> Do you have a problem you're trying to solve? It just sounds like you have a few parts y ou want to be part of a solution, but you don't have a problem that will use all those parts.
2020-09-26 08:04:14 +0200 <Guest26> you could think of it as a mass spring system for example
2020-09-26 08:04:23 +0200 <fraktor> Oh, so you're running simulations?
2020-09-26 08:04:26 +0200ahri(~ahri@178.209.40.84)
2020-09-26 08:04:39 +0200 <Guest26> its just calculated data, that is output infrequently
2020-09-26 08:04:59 +0200adamwespiser(~adam_wesp@209.6.42.110) (Ping timeout: 240 seconds)
2020-09-26 08:05:00 +0200 <Guest26> and i want to have the time on the x axis of the plot in the html page
2020-09-26 08:05:13 +0200 <fraktor> I see. So you do want a time-series database, but Prometheus is kinda the wrong tool.
2020-09-26 08:05:22 +0200 <Guest26> so that the most up to data version is displayed on refreshing the page
2020-09-26 08:05:59 +0200 <dsal> If you serve a file from a web server, it will serve the latest version of that file when requested.
2020-09-26 08:06:09 +0200 <fraktor> May I suggest Grafana? It's an open-source visualization tool that can use whatever as a backend, I think including static files
2020-09-26 08:06:10 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt)
2020-09-26 08:06:12 +0200 <Guest26> the components i need are something equivalent to an SQL database for storing the data to, and something like a HTML page, that can do the visualization
2020-09-26 08:06:27 +0200 <dsal> Yeah, I'm using grafana with influxdb. It's pretty great.
2020-09-26 08:06:39 +0200justanotheruser(~justanoth@unaffiliated/justanotheruser)
2020-09-26 08:06:42 +0200 <dsal> I liked not having to write that part. heh
2020-09-26 08:07:03 +0200 <fraktor> In case you can't tell I've done DevOps stuff before, so Prometheus and Grafana are my go-to tools for system monitoring lol
2020-09-26 08:07:09 +0200 <dsal> I've got a bunch of bits of haskell that read and write influxdb and a bunch of that stuff ends up in grafana.
2020-09-26 08:07:32 +0200 <dsal> I've managed to never use prometheus. At this point, I'll just keep not using it .heh
2020-09-26 08:07:39 +0200 <Guest26> this? http://hackage.haskell.org/package/grafana-0.2 https://en.wikipedia.org/wiki/Grafana
2020-09-26 08:07:42 +0200 <Guest26> looks good
2020-09-26 08:07:53 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 246 seconds)
2020-09-26 08:08:25 +0200 <dsal> It's very unlikely you want a grafana haskell lib.
2020-09-26 08:08:29 +0200 <fraktor> I'd recommend using an intermediary DB now that I understand a little better, since that means you can run arbitrary queries on it.
2020-09-26 08:08:37 +0200 <Guest26> and this https://hackage.haskell.org/package/influxdb https://en.wikipedia.org/wiki/InfluxDB
2020-09-26 08:08:57 +0200 <fraktor> The Grafana haskell library is for when you want to write a custom interface with grafana, and using an intermediary database is simpler and more powerful.
2020-09-26 08:09:01 +0200 <Guest26> ah, yeah, i thought SQL seemed better than trying to write to the disk
2020-09-26 08:09:09 +0200 <Guest26> so is that where influxdb is advised?
2020-09-26 08:09:09 +0200 <fraktor> Yep. InfluxDB and Grafana are a good pair from what I've heard
2020-09-26 08:09:23 +0200 <Guest26> dsal: any chance of a demo?
2020-09-26 08:09:45 +0200mu_(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 08:09:47 +0200 <dsal> "sql" and "write to the disk" aren't different things.
2020-09-26 08:09:51 +0200 <dsal> I use sql to write to the disk.
2020-09-26 08:09:58 +0200 <dsal> Let me see if I can find a good one.
2020-09-26 08:09:59 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 08:10:24 +0200 <Guest26> https://hackage.haskell.org/package/prometheus https://prometheus.io/
2020-09-26 08:10:30 +0200 <Guest26> im not sure about that...
2020-09-26 08:10:39 +0200 <Guest26> i dont think metrics is the right idea here
2020-09-26 08:10:51 +0200 <fraktor> Yeah, Prometheus is the wrong tool here
2020-09-26 08:10:53 +0200 <dsal> You've made it really hard to have any idea what you're doing.
2020-09-26 08:11:08 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt) (Ping timeout: 272 seconds)
2020-09-26 08:11:26 +0200 <Guest26> sorry
2020-09-26 08:11:35 +0200 <dsal> Most of my stuff is readings I pick up via mqtt and write to influxdb (using github.com/dustin/influxer )
2020-09-26 08:11:40 +0200ggole(~ggole@2001:8003:8119:7200:7423:d49d:a274:5670)
2020-09-26 08:11:48 +0200 <dsal> If my network wakes up, I'll try to pull up a dashboard.
2020-09-26 08:13:09 +0200 <dsal> Here's a small dashboard of my car from a recent drive: https://snapshot.raintank.io/dashboard/snapshot/biEthNTKdEOHlOrgIpnrcUFjQljRrQTF
2020-09-26 08:13:38 +0200 <fraktor> Yo I gotta ask, why
2020-09-26 08:13:45 +0200 <Guest26> im not quite sure what im looking at here
2020-09-26 08:14:03 +0200 <Guest26> either the github or the graphana dashboard
2020-09-26 08:14:08 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 08:14:18 +0200 <fraktor> This is a dashboard for the various metrics that were collected from dsal's car
2020-09-26 08:14:18 +0200 <dsal> This is one of my haskell MQTT servers: https://snapshot.raintank.io/dashboard/snapshot/nvP6u1KXnbrd0fY9RFz2qCYvBe4YHUsy
2020-09-26 08:14:52 +0200 <Guest26> it seems like this is very powerful visualisation. it could be perfect - the bit im not sure about now is the databasing
2020-09-26 08:14:53 +0200 <dsal> fraktor: people mock my Car monad, but the Car monad serves me well.
2020-09-26 08:15:11 +0200 <Guest26> what does its join instance do!?
2020-09-26 08:15:13 +0200 <dsal> This is backed by nifluxdb. My programs just dump stuff into influxdb.
2020-09-26 08:15:25 +0200 <dsal> Crashes cars!
2020-09-26 08:15:27 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64)
2020-09-26 08:16:00 +0200 <Guest26> makes a train?
2020-09-26 08:16:03 +0200 <alexm_> @pl score c = Score . fromMaybe 0 $ lookup c score
2020-09-26 08:16:04 +0200 <lambdabot> score = fix (((Score . fromMaybe 0) .) . flip lookup)
2020-09-26 08:16:08 +0200 <fraktor> The way that Grafana works is that you create graphs that are associated with queries, and then the results of those queries are used in the visualization. So you can have the same underlying data and change the query to visualize the same data in a different way without modfying your program.
2020-09-26 08:16:12 +0200 <dsal> It mainly just holds the state and pushes stuff through. e.g. https://dustin.github.io/tesla/Tesla-Car-Command-Alerts.html
2020-09-26 08:16:45 +0200 <dsal> heh, if pl gives you fix, you should win a prize.
2020-09-26 08:16:57 +0200 <Guest26> hmm, it seems like i would have to learn graphana before i could get this up and running
2020-09-26 08:17:10 +0200 <dsal> What would you prefer to learn?
2020-09-26 08:17:12 +0200 <fraktor> It's very easy to get started with, especially compared to writing your own visualization
2020-09-26 08:17:17 +0200 <fraktor> @pl
2020-09-26 08:17:18 +0200 <lambdabot> (line 1, column 1):
2020-09-26 08:17:18 +0200 <lambdabot> unexpected end of input
2020-09-26 08:17:18 +0200 <lambdabot> expecting white space, "()", natural, identifier, lambda abstraction or expression
2020-09-26 08:17:24 +0200 <fraktor> What is @pl?
2020-09-26 08:17:35 +0200 <Guest26> i was hoping there might be a path of less resistance - i just needed a very simple plot - and if it can be haskell that would be better
2020-09-26 08:17:44 +0200 <Guest26> i kind of wanted haskell html
2020-09-26 08:17:50 +0200 <dsal> fraktor: pl is a pointfree converter.
2020-09-26 08:17:58 +0200 <dsal> @pl f x = a x
2020-09-26 08:17:59 +0200 <lambdabot> f = a
2020-09-26 08:18:01 +0200 <fraktor> Guest26: Well, you'd need to write that yourself then, afaik.
2020-09-26 08:18:11 +0200 <Guest26> thats what i was asking about
2020-09-26 08:18:25 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 08:18:29 +0200 <Guest26> but yes, a very much more simple version of this is kind of what i was after
2020-09-26 08:18:33 +0200 <Guest26> but written in haskell
2020-09-26 08:19:06 +0200 <dsal> At some point, you have to make things a browser understands.
2020-09-26 08:19:55 +0200mu_(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 08:20:00 +0200mu__(~mu@unaffiliated/mu)
2020-09-26 08:20:20 +0200Omentiger(~Omentiger@cpe-24-25-246-129.hawaii.res.rr.com)
2020-09-26 08:20:37 +0200 <fraktor> Also, I think that setting up a grafana dashboard would still be easier than writing a haskell program, even if a library for client-side visualization already existed?
2020-09-26 08:20:42 +0200 <Guest26> perhaps it could be as simple as just displaying a jpg, but then i would need to use something like an external ploting program to produce this from input data
2020-09-26 08:20:54 +0200Faker(bad2e02e@186.210.224.46) (Ping timeout: 245 seconds)
2020-09-26 08:21:08 +0200 <Guest26> oh, and then it wouldnt refresh properly
2020-09-26 08:21:25 +0200 <Guest26> fraktor: im not sure that it would
2020-09-26 08:21:30 +0200 <fraktor> Grafana is probably the most robust solution
2020-09-26 08:21:31 +0200 <dsal> jpg is the worst format for displaying data
2020-09-26 08:21:36 +0200 <fraktor> At least use PNG
2020-09-26 08:21:42 +0200 <Guest26> sorry...
2020-09-26 08:21:52 +0200 <fraktor> No, it's okay! We're just thinking about what would annoy us as users
2020-09-26 08:21:56 +0200 <dsal> heh
2020-09-26 08:22:04 +0200 <Guest26> oh! it wasnt for an actual webpage
2020-09-26 08:22:06 +0200 <dsal> dumb peeves
2020-09-26 08:22:15 +0200 <Guest26> i mean, not for comercial use
2020-09-26 08:22:24 +0200 <fraktor> Even as an internal user I would be annoyed
2020-09-26 08:22:32 +0200 <Guest26> i just wanted to be able to quickly refresh the graph of some data i was generating
2020-09-26 08:22:48 +0200 <dsal> this problem has been solved so many ways, it's weird to even talk about it.
2020-09-26 08:22:52 +0200 <Guest26> there is something nice about the low latency of the html solution
2020-09-26 08:23:00 +0200justan0theruser(~justanoth@unaffiliated/justanotheruser)
2020-09-26 08:23:04 +0200 <fraktor> Also dsal, I don't know what to ask about first: the fact that you have a dashboard of metrics for your Tesla, or the fact that it's called "Muad'Dib." Do you have a spice-powered car?
2020-09-26 08:23:08 +0200 <dsal> what's low latency about htlm?
2020-09-26 08:23:22 +0200 <fraktor> Guest26: I mean, Grafana automatically refreshes stuff, and you don't have to refresh the whole page
2020-09-26 08:23:22 +0200 <dsal> fraktor: haha. I was reading Dune when I got it.
2020-09-26 08:23:46 +0200 <dsal> fraktor: I like collecting data, though.
2020-09-26 08:23:55 +0200 <Guest26> hmm, i think i should probably insist on the approach that doesnt use the third party tool
2020-09-26 08:24:09 +0200 <fraktor> You do you
2020-09-26 08:24:14 +0200 <Guest26> im specifically trying to write a webpage with a very simple graph
2020-09-26 08:24:18 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 08:24:20 +0200 <Guest26> and my main concern is the database
2020-09-26 08:24:40 +0200 <Guest26> im not sure if inflixdb is best - maybe thats just good for graphana
2020-09-26 08:24:49 +0200 <fraktor> Do you want to keep old data around for a while? Or can it be discarded?
2020-09-26 08:25:02 +0200justanotheruser(~justanoth@unaffiliated/justanotheruser) (Ping timeout: 246 seconds)
2020-09-26 08:25:25 +0200 <dsal> I wrote a tool called 'influxer' that writes stuff from mqtt to influxdb, and a tool called outfluxer that runs influxdb queries and spits out mqtt topics.
2020-09-26 08:25:46 +0200 <dsal> Lets me make easy dashboards on my phone that tell me current things like how much energy I've generated today so far.
2020-09-26 08:26:05 +0200TooDifficult(~TooDiffic@139.59.59.230) (Ping timeout: 240 seconds)
2020-09-26 08:26:07 +0200 <Guest26> the database should persist in memory - but i can write these to special .dat files, and then just have another program mirroring these on to the database, that shouldnt be too hard, the main point is having it as something that can be easily queried by the HTML page
2020-09-26 08:26:15 +0200 <Guest26> i dont want to be writing fancy HTML
2020-09-26 08:26:37 +0200isovector1(~isovector@172.103.216.166)
2020-09-26 08:26:46 +0200 <fraktor> You're going to have to write something to do the plot?
2020-09-26 08:26:53 +0200 <Guest26> yes
2020-09-26 08:27:11 +0200 <Guest26> but i was hoping there would be html or js solutions
2020-09-26 08:27:28 +0200 <Guest26> not sure how difficult it would be to use them with a haskell webpage though
2020-09-26 08:27:39 +0200 <dsal> fraktor: For a good time, you can see my influxer confs. Gets a few fun things I can plot in grafana, but the tool also stores the whole captured state periodically: https://gist.github.com/dustin/3015d0dee2b5cee3ce8b2d1895aee144
2020-09-26 08:27:52 +0200oxide(~lambda@unaffiliated/mclaren)
2020-09-26 08:28:16 +0200 <dsal> I realized looking at this that one of my mqtt servers isn't storing its stats. :(
2020-09-26 08:28:25 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 08:29:04 +0200 <fraktor> Guest26: There are Javascript libraries that do graphs and so on
2020-09-26 08:29:10 +0200isovector1(~isovector@172.103.216.166) (Client Quit)
2020-09-26 08:29:11 +0200 <Guest26> this is what i used to get a html thing working; https://ocharles.org.uk/posts/2013-12-19-websockets.html
2020-09-26 08:29:16 +0200 <fraktor> But if you want a pre-built solution in HTML/JS that can do visualizations... Grafana
2020-09-26 08:29:31 +0200 <Guest26> but thats not a haskell program
2020-09-26 08:29:31 +0200mu__(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 08:29:34 +0200 <dsal> Now you're getting into websockets?
2020-09-26 08:29:52 +0200 <Guest26> that was just a simple web example
2020-09-26 08:29:55 +0200 <fraktor> ...Why does it have to be a Haskell program? So that you don't need the database?
2020-09-26 08:30:03 +0200 <Guest26> i guess i could use yesod instead
2020-09-26 08:30:07 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 08:30:11 +0200 <dsal> My mqtt client and server both support websockets. That's about all I know about WS. heh
2020-09-26 08:31:24 +0200 <Guest26> it doesnt have to be a haskell program - it just has to be simple enough code for me to understand, and haskell is a huge advantage in that
2020-09-26 08:31:52 +0200 <Guest26> the html used in o'charles blog post is very very simple, simple enough to understand even
2020-09-26 08:32:03 +0200 <Guest26> graphana however...
2020-09-26 08:32:18 +0200 <fraktor> I've never read HTML I couldn't understand. It's just markup
2020-09-26 08:32:39 +0200 <Guest26> well, anything except haskell is difficult for me to read
2020-09-26 08:33:03 +0200 <fraktor> Can you use WebSockets in HTML without Javascript?
2020-09-26 08:33:08 +0200 <fraktor> I haven't heard of that before
2020-09-26 08:33:15 +0200 <dsal> You can't use websockets in html at all.
2020-09-26 08:33:47 +0200sfvm(~sfvm@37.228.215.148) (Remote host closed the connection)
2020-09-26 08:33:47 +0200 <dsal> There's a javascript mechanism.
2020-09-26 08:33:57 +0200 <Guest26> whatever is the least sufficient way to convert it to haskell development, like a thin wrapper in HTML or something, thats fine, as long as it does not require any actual proficiency in the second language to maintain - thats why i cant do android
2020-09-26 08:34:15 +0200 <dsal> My GoPro interface was written in elm and I figured writing a websockets client would be easy there. It was silly hard.
2020-09-26 08:34:38 +0200 <fraktor> I mean, ports?
2020-09-26 08:34:40 +0200 <dsal> Having the haskell code write to WS via MonadLogger was tiny and boring.
2020-09-26 08:35:00 +0200 <Guest26> here is the code from that blog post example above if you want to see the HTML https://github.com/ocharles/blog/blob/master/code/2013-12-19-client.html
2020-09-26 08:35:05 +0200 <dsal> Guest26: You have no path that doesn't require learning.
2020-09-26 08:35:32 +0200 <Guest26> least sufficient HTML is preferred to graphana
2020-09-26 08:35:43 +0200bitmapper(uid464869@gateway/web/irccloud.com/x-kucaomxlfuldfryc) (Quit: Connection closed for inactivity)
2020-09-26 08:36:14 +0200 <Guest26> its more transferable. if i learn how to do graphs with html and js and haskell, im sure thats a better approach
2020-09-26 08:36:16 +0200 <dsal> Do you even have a theoretical way to display a timeseries chart in HTML?
2020-09-26 08:36:26 +0200 <Guest26> arguably industry might prefer i use graphana.
2020-09-26 08:36:48 +0200 <fraktor> dsal: Why was the Elm client silly hard?
2020-09-26 08:37:03 +0200 <Guest26> dsal: no, but thats the perfect question
2020-09-26 08:37:23 +0200 <Guest26> i wonder if there is anything written using scotty that does that
2020-09-26 08:37:54 +0200 <dsal> fraktor: there's just no way to do websockets. Required lots of weird stuff in a third party library and javascript bridgy stuff to get working at all.
2020-09-26 08:38:23 +0200mnrmnaugh(~mnrmnaugh@unaffiliated/mnrmnaugh) (Ping timeout: 260 seconds)
2020-09-26 08:39:34 +0200 <fraktor> Oh yeah. You need ports and message conversion and stuff
2020-09-26 08:39:34 +0200mu_(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 08:39:35 +0200mnrmnaugh(~mnrmnaugh@unaffiliated/mnrmnaugh)
2020-09-26 08:39:39 +0200 <Guest26> i suppose i could just send all the data through the websocket and not bother with the db
2020-09-26 08:39:59 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 08:40:00 +0200 <fraktor> It's better now though https://github.com/elm-lang/websocket
2020-09-26 08:40:04 +0200 <Guest26> but thats not really "language independent"
2020-09-26 08:40:28 +0200 <Guest26> if i wrote it to SQL, then that R visualisation approach would work too...
2020-09-26 08:41:10 +0200 <Guest26> i guess with that design consideration im back considering SQL proper vs haskelly alternatives
2020-09-26 08:41:28 +0200 <Guest26> im not sure if they are as easy to query from some arbitrary endpoint language
2020-09-26 08:42:04 +0200 <Guest26> i can find this though; https://github.com/dleutnant/influxdbr
2020-09-26 08:42:10 +0200 <dsal> fraktor: hmm... That might be better.
2020-09-26 08:42:28 +0200 <Guest26> "R interface to InfluxDB"
2020-09-26 08:42:41 +0200 <Guest26> and then i guess i would want this in html aswell
2020-09-26 08:43:23 +0200 <dsal> I had to use some PortFunnel thing and a bunch of other junk.
2020-09-26 08:44:03 +0200 <fraktor> https://github.com/elm-community/js-integration-examples/tree/master/websockets
2020-09-26 08:44:11 +0200 <fraktor> This is apparently the preferred solution nowadays
2020-09-26 08:44:17 +0200 <Guest26> i might want to add a button or something, i dont know if i could do that with graphana
2020-09-26 08:44:28 +0200hackagecommandert 0.1.0.0 - A monad for commanders https://hackage.haskell.org/package/commandert-0.1.0.0 (sgschlesinger)
2020-09-26 08:44:31 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 08:44:36 +0200 <Guest26> and i might not want to be working in r if i want to start making it more complicated
2020-09-26 08:44:57 +0200 <Guest26> so i think a haskell html thing is really what i want, for the reason of customisability
2020-09-26 08:45:26 +0200 <Guest26> i might want to restart the simulation from different random initialisation for example
2020-09-26 08:45:35 +0200 <dsal> You want a thing you don't know anything at all about because it does all the things you can imagine. heh
2020-09-26 08:45:56 +0200 <dsal> fraktor: I guess I should update this gross stuff.
2020-09-26 08:45:57 +0200 <Guest26> well, thats why i want to have it written mostly in haskell
2020-09-26 08:46:31 +0200 <Guest26> so far it seems like databasing is only good for interfacing with R or graphana or such
2020-09-26 08:46:59 +0200 <Guest26> and that what i should really be asking is more to do with writing a simple graph in yesod or something
2020-09-26 08:47:07 +0200 <dsal> I gave a kid a 3D printer a few days ago. He was asking me whether he could make each of a long list of things. He just saw a tool come in that can make physical things, so he thinks of every physical thing and asks if it can make that thing.
2020-09-26 08:47:46 +0200 <Guest26> im justifying, with a good reason, why graphana isnt right for what i want to do
2020-09-26 08:48:18 +0200 <fraktor> You don't have to justify it to us
2020-09-26 08:48:22 +0200 <Guest26> while motivating why the approach i would prefer, is better
2020-09-26 08:48:31 +0200 <Guest26> ok, well i just thought id explain
2020-09-26 08:48:34 +0200 <dsal> Your reason is "I don't know anything about how web UIs work, but I can write something better than what everyone else uses once I learn it all."
2020-09-26 08:48:43 +0200 <Guest26> dsal: im happy for the kid that got the 3d printer
2020-09-26 08:48:45 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 08:49:05 +0200mu_(~mu@unaffiliated/mu) (Quit: mu_)
2020-09-26 08:49:08 +0200 <EvanR> didn't you just explain 99.9% of where web UIs came from
2020-09-26 08:49:20 +0200 <EvanR> seems to work
2020-09-26 08:49:21 +0200 <Guest26> i dont need it to be "better" i just need it to support a graph, and a button
2020-09-26 08:49:39 +0200 <dsal> Heh, that's fair, EvanR
2020-09-26 08:49:41 +0200 <Guest26> and anything else i need to think of to mean graphana isnt going to do it!
2020-09-26 08:49:57 +0200hackagecommander-cli 0.8.0.0 - A command line argument/option parser library https://hackage.haskell.org/package/commander-cli-0.8.0.0 (sgschlesinger)
2020-09-26 08:50:02 +0200 <dsal> Guest26: but you don't have a working theory of what "a graph and a button" in haskell might look like.
2020-09-26 08:50:15 +0200 <dsal> Because you can't just throw haskell at a web browser and get that result.
2020-09-26 08:50:35 +0200 <dsal> You have to feed the browser a language it understands, or use an intermediary that someone has built for you.
2020-09-26 08:50:40 +0200 <Guest26> this is the question - and the graphana is a distraction from that ultimate goal
2020-09-26 08:50:47 +0200 <EvanR> a graph and a button is really easy with some javascript
2020-09-26 08:50:55 +0200 <dsal> e.g., ghcjs will *run* in a browser, but it won't magically make a functional UI.
2020-09-26 08:51:34 +0200 <Guest26> well then it seems like "no haskell for the web interface" is advocated
2020-09-26 08:51:56 +0200 <EvanR> if the goal is to use haskell that's another story
2020-09-26 08:52:15 +0200 <Guest26> it would be better if as much of it as possible was in the language i can actually write in
2020-09-26 08:52:35 +0200fxg(~fxg@unaffiliated/fxg) (Ping timeout: 240 seconds)
2020-09-26 08:52:57 +0200hackagecommander-cli 0.9.0.0 - A command line argument/option parser library https://hackage.haskell.org/package/commander-cli-0.9.0.0 (sgschlesinger)
2020-09-26 08:53:03 +0200 <Guest26> then the html could be as simple as just refreshing an image, and the haskell file then just has to write the graph to a .png
2020-09-26 08:53:28 +0200 <Guest26> and the button with simple websockets is basically all then covered by that o'charles blogpost
2020-09-26 08:53:34 +0200 <fraktor> dsal: Regarding PortFunnel, it looks like you wanted to take different kinds of websocket messages and turn them into different elm messages. Which I think you can do with a case statement in subscriptions?
2020-09-26 08:53:38 +0200 <dsal> Why websockets?
2020-09-26 08:53:48 +0200josh_(~josh@c-67-164-104-206.hsd1.ca.comcast.net) (Remote host closed the connection)
2020-09-26 08:53:55 +0200 <Guest26> to send the data from the button to the running haskell program
2020-09-26 08:54:12 +0200 <dsal> fraktor: I spent a while trying to figure it out when I wrote that. A better answer would be great. This one also seems a little unreliable.
2020-09-26 08:54:22 +0200josh_(~josh@c-67-164-104-206.hsd1.ca.comcast.net)
2020-09-26 08:54:47 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 08:54:55 +0200 <Guest26> but then the problem is still, producing a png from the haskell data
2020-09-26 08:55:10 +0200 <Guest26> and then im back trying to send it through R
2020-09-26 08:55:17 +0200 <dsal> Guest26: why does the button have data? It's unclear what webockets does other than make the problem a lot harder.
2020-09-26 08:55:35 +0200edwardk(sid47016@haskell/developer/edwardk)
2020-09-26 08:55:42 +0200 <dsal> I'm using websockets to stream MonadLogger messages to my web app as stuff happens.
2020-09-26 08:56:00 +0200ChrisMarquardt(~ChrisMarq@84.39.117.57)
2020-09-26 08:56:41 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 08:56:43 +0200vicfred(~vicfred@unaffiliated/vicfred) (Remote host closed the connection)
2020-09-26 08:56:56 +0200 <Guest26> this is all because i couldnt get sdl-diagrams to work...
2020-09-26 08:56:58 +0200 <fraktor> dsal: Is this project open-source? I can maybe take a look
2020-09-26 08:57:06 +0200vicfred(~vicfred@unaffiliated/vicfred)
2020-09-26 08:58:02 +0200 <Guest26> dsal: the data it could send could be interpreted by the haskell program, so it could be eg a command such as "restart simulation" or "convert boundaries to reflective/periodic"
2020-09-26 08:58:30 +0200 <dsal> fraktor: Alright, but I don't use standard elm layout because I wrote all this code before anyone told me about it and I thought it was ugly. heh github.com/dustin/gopro -- static is the, uh, static content. ui is the elm source.
2020-09-26 08:58:43 +0200josh_(~josh@c-67-164-104-206.hsd1.ca.comcast.net) (Ping timeout: 265 seconds)
2020-09-26 08:58:59 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 08:59:01 +0200 <dsal> socketHandler handlers sockets.
2020-09-26 08:59:52 +0200 <Guest26> this is some serious code
2020-09-26 08:59:58 +0200hackagetasty-wai 0.1.1.1 - Test 'wai' endpoints via Test.Tasty https://hackage.haskell.org/package/tasty-wai-0.1.1.1 (GeorgeWilson)
2020-09-26 08:59:58 +0200 <fraktor> Oh wait, you didn't use the Elm architecture?
2020-09-26 09:00:40 +0200fxg(~fxg@unaffiliated/fxg)
2020-09-26 09:00:50 +0200jdgr(601c428b@gateway/web/cgi-irc/kiwiirc.com/ip.96.28.66.139)
2020-09-26 09:00:55 +0200 <Guest26> dsal: i dont see where it does the visualisation
2020-09-26 09:00:59 +0200MarcelineVQplays a violin for the readme.md
2020-09-26 09:01:24 +0200 <fraktor> Guest26: It's not for the same kind of thing; I'm just curious about what dsal wrote lol.
2020-09-26 09:01:26 +0200mnrmnaugh(~mnrmnaugh@unaffiliated/mnrmnaugh) (Ping timeout: 246 seconds)
2020-09-26 09:01:28 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 256 seconds)
2020-09-26 09:01:35 +0200 <Guest26> ok
2020-09-26 09:01:46 +0200 <dsal> MarcelineVQ: heh. nobody ever uses my programs no matter how well I document them.
2020-09-26 09:01:47 +0200 <Guest26> ah, it was about websockets
2020-09-26 09:02:26 +0200 <dsal> This is really good software lots of people should use, though.
2020-09-26 09:02:29 +0200 <Guest26> dsal: what is it for this gopro interface?
2020-09-26 09:02:34 +0200 <fraktor> I want to go back to 1980 and try to explain this: `addToast toast = Toasty.addToast toastConfig ToastyMsg toast`
2020-09-26 09:02:44 +0200MarcelineVQplays Agnus Dei for the code commentary :>
2020-09-26 09:03:18 +0200 <dsal> Guest26: it's a bunch of tools for managing data in gopro's cloud.
2020-09-26 09:03:31 +0200 <jdgr> Okay, was going over Haskell with my girlfriend. She's "bored" so I put studying Haskell on pause and introduced her to Scratch.
2020-09-26 09:03:38 +0200 <Guest26> extractGPMDStream filename stream = readCmd "ffmpeg" ["-y", "-i", filename, "-loglevel", "-8", "-codec", "copy", "-map", "0:" <> show stream, "-f", "rawvideo", "-"] id
2020-09-26 09:03:41 +0200 <Guest26> horrible
2020-09-26 09:04:11 +0200 <jdgr> Probably a better introduction to programming because it's visual and you can immediately do interesting things.
2020-09-26 09:04:23 +0200Omentiger(~Omentiger@cpe-24-25-246-129.hawaii.res.rr.com) (Quit: Leaving)
2020-09-26 09:04:27 +0200 <Guest26> sounds like you need a dog
2020-09-26 09:04:56 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 09:05:08 +0200 <Guest26> https://ocharles.org.uk/img/2013-12-19-websockets.png
2020-09-26 09:05:29 +0200 <jdgr> We need a visual IDE for Haskell that makes the language easy and fun for beginners like Scratch is
2020-09-26 09:05:30 +0200 <dsal> Guest26: yet I've pushed a TB of video through it. I'll take a patch, but I didn't find an mpeg library that could solve the problem that line did.
2020-09-26 09:05:58 +0200 <dsal> It was enough that I had to write a parser for GoPro's metadata stream because all of their tools were unusable even as FFI.
2020-09-26 09:06:35 +0200 <Guest26> oh right, its got all those funny arguments because its a command line tool
2020-09-26 09:06:38 +0200fxg(~fxg@unaffiliated/fxg) (Ping timeout: 256 seconds)
2020-09-26 09:06:44 +0200 <fraktor> I still need to actually write a real project in Elm. Maybe I'll update my Rust/Vue project to do that
2020-09-26 09:06:57 +0200 <Guest26> hmm, maybe thats the best way to do this plotting too... just compile something to exe
2020-09-26 09:07:12 +0200 <dsal> This was my "I should try out elm" project. It works. The WS was the worst pain (which was surprising).
2020-09-26 09:07:15 +0200 <Guest26> i can easily read the .png in by refreshing the page
2020-09-26 09:07:35 +0200 <fraktor> Then again, I'm not really good at Haskell either. I still don't understand how to use Monad Transformers
2020-09-26 09:07:45 +0200 <Guest26> each time the simulation produces new data i can get the thing that watches the data dir to overwrite the plot image
2020-09-26 09:07:57 +0200 <fraktor> That's probably the easiest way
2020-09-26 09:08:04 +0200 <fraktor> I would not recommend websockets if you don't want to dive deep
2020-09-26 09:08:04 +0200 <Guest26> ok! that sounds like a plan. so how do i plot the timeseries data?
2020-09-26 09:08:09 +0200 <dsal> I just write code to solve my problems.
2020-09-26 09:08:21 +0200 <fraktor> Guest26: I don't really know. You'd need to find a Haskell library for that.
2020-09-26 09:08:27 +0200 <jdgr> That's the whole point of programming
2020-09-26 09:08:30 +0200 <Guest26> ok brb
2020-09-26 09:08:32 +0200 <jdgr> Making your life easier
2020-09-26 09:08:37 +0200 <fraktor> Not true! Sometimes it's for fun
2020-09-26 09:08:45 +0200 <jdgr> That too
2020-09-26 09:08:56 +0200 <Guest26> i soon find; https://hackage.haskell.org/package/plots
2020-09-26 09:09:18 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 260 seconds)
2020-09-26 09:09:19 +0200 <fraktor> Great!
2020-09-26 09:09:25 +0200 <dsal> This GoPro thing is... unofficial (had to reverse engineer the API and violate all the terms of service), but the service isn't usable without it.
2020-09-26 09:09:40 +0200 <dsal> Like, I would be surprised if anyone uses their stuff at all.
2020-09-26 09:09:43 +0200 <fraktor> I've definitely used APIs in a creative way before.
2020-09-26 09:10:29 +0200 <dsal> They don't have a published API. Their web UI is *impressively* bad, and doesn't even do a lot of the things you'd want done.
2020-09-26 09:11:01 +0200 <Guest26> ah but this doesnt seem to write to a .png
2020-09-26 09:11:06 +0200 <dsal> But most importantly, when they decide they don't want to store my TB of data for $5/mo anymore, I have a commandline that will ship it all off to S3 just about instantly.
2020-09-26 09:13:01 +0200xsperry(~as@unaffiliated/xsperry)
2020-09-26 09:13:33 +0200 <dsal> http://dustin.sallings.org/2020/04/29/gopro-plus.html <-- I wrote about it there. I guess I could document things since I think I've got it as stable as I want now, just in case someone somewhere has a gopro.
2020-09-26 09:14:02 +0200 <Guest26> horay! human words
2020-09-26 09:14:04 +0200 <dsal> I've worked around a crapload of bugs on their side as well. I've got this cool thing where I can do bulk updates of metadata on their end using SQL queries.
2020-09-26 09:15:02 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 09:15:36 +0200 <dsal> e.g., there's some way I can upload stuff where they just can't figure out what camera it came from, but like, I can read it directly out of the EXIF or GPMD streams, so I write a SQL query that returns the metadata that I know for all of the rows where they don't know and it translates that into mutation API calls on their end. Fun stuff.
2020-09-26 09:15:53 +0200toorevitimirp(~tooreviti@117.182.182.201) (Remote host closed the connection)
2020-09-26 09:16:31 +0200 <Guest26> i guess its more of a home use tool than a lib for hackage?
2020-09-26 09:17:00 +0200 <dsal> If you just want to use the APIs, they're here: http://hackage.haskell.org/package/gopro-plus
2020-09-26 09:17:06 +0200 <dsal> and gpmf and stuff.
2020-09-26 09:17:11 +0200 <dsal> (linked in that article)
2020-09-26 09:17:18 +0200 <Guest26> oh right, thats far less impressive
2020-09-26 09:17:38 +0200 <dsal> Heh, that stuff was hard to reverse engineer and write.
2020-09-26 09:17:43 +0200 <Guest26> oh - you wrote those aswell
2020-09-26 09:17:47 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 258 seconds)
2020-09-26 09:17:56 +0200 <Guest26> completely impressive
2020-09-26 09:18:06 +0200 <Guest26> i cant even do a line plot
2020-09-26 09:18:12 +0200 <Guest26> :-?
2020-09-26 09:18:12 +0200 <dsal> Like, this is the *simple* case of uploading media: https://github.com/dustin/gopro-plus/wiki/Upload
2020-09-26 09:18:32 +0200jdgr(601c428b@gateway/web/cgi-irc/kiwiirc.com/ip.96.28.66.139) (Ping timeout: 256 seconds)
2020-09-26 09:18:53 +0200 <Guest26> now i want a go-pro, just to use this library....
2020-09-26 09:19:14 +0200 <dsal> But you can do server-side concatenation of multiple files (e.g., when the camera splits, or you just took multiple videos and want them to be a single one) by defining a single multi-part video across a set of files, each of which is split into 6MB chunks and uploaded.
2020-09-26 09:19:17 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 246 seconds)
2020-09-26 09:19:17 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64) (Ping timeout: 246 seconds)
2020-09-26 09:19:48 +0200 <dsal> The upload is completely resumable as well (since my connectivity goes out). I was uploading earlier, and then stopped for some reason (^C) and then just told it to keep uploading whatever it was doing before.
2020-09-26 09:19:48 +0200 <Guest26> but i think before too long it would become philip k dicks second variety
2020-09-26 09:20:07 +0200 <Guest26> do we have an interface to project gutenburg?
2020-09-26 09:20:19 +0200 <dsal> What would that do?
2020-09-26 09:20:35 +0200dmiles(dmiles@c-73-67-179-188.hsd1.wa.comcast.net) (Ping timeout: 240 seconds)
2020-09-26 09:22:24 +0200 <Guest26> idk, something like search and download? or maybe an interface to have it for use as a text corpus eg. for machine learning
2020-09-26 09:22:31 +0200 <Guest26> it has entries like this;
2020-09-26 09:22:32 +0200 <Guest26> https://www.gutenberg.org/files/32032/32032-h/32032-h.htm
2020-09-26 09:25:10 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 09:25:35 +0200Guest26(a181464f@gateway/web/cgi-irc/kiwiirc.com/ip.161.129.70.79) (Quit: Connection closed)
2020-09-26 09:25:50 +0200DirefulSalt(DirefulSal@gateway/vpn/privateinternetaccess/direfulsalt)
2020-09-26 09:26:19 +0200v_m_v(~vm_v@2a02:aa12:3200:6480:f507:71a:9334:3099)
2020-09-26 09:27:24 +0200 <dsal> I don't know what APIs are available, or how structured that might be. Making APIs for stuff like that isn't typically that hard if you have some idea what you're trying to accomplish.
2020-09-26 09:28:26 +0200 <dsal> Oh man, I just got the notification about sprinkler schedule for the day. I guess I should kill that software since I've removed all the hardware. :(
2020-09-26 09:29:23 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 09:30:54 +0200 <fraktor> Does anyone have good resources on Monad Transformers? I really don't understand them that well
2020-09-26 09:32:19 +0200 <dsal> There's really not that much. Mostly, you just have IO and then you wrap a ReaderT around it so you can have an implicit variable passed around. Sometimes you throw in a MonadLogger or whatever and you `lift` to the next transformer up the stack.
2020-09-26 09:32:35 +0200 <c_wraith> :t lift
2020-09-26 09:32:37 +0200 <lambdabot> (MonadTrans t, Monad m) => m a -> t m a
2020-09-26 09:32:43 +0200 <c_wraith> that's really all you need to know :)
2020-09-26 09:32:51 +0200 <dsal> The only thing that's kind of hard is starting all the runXT things and then lift.
2020-09-26 09:32:59 +0200 <dsal> And usually you probably just need liftIO :)
2020-09-26 09:33:24 +0200 <c_wraith> honestly, I internalized monad transformers before monads. They don't involve nearly as complex of topics.
2020-09-26 09:33:28 +0200 <fraktor> ReaderT seems super useful but it's hard to understand
2020-09-26 09:34:21 +0200 <dsal> It's hard to understand because it sounds dumb. In practice, it just means you have a variable that's implicit.
2020-09-26 09:34:46 +0200shad0w_(~shad0w_@160.202.37.29)
2020-09-26 09:35:09 +0200v_m_v(~vm_v@2a02:aa12:3200:6480:f507:71a:9334:3099) (Remote host closed the connection)
2020-09-26 09:35:16 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 09:35:23 +0200 <dsal> fraktor: This is a "I went too hard after a bunch of time" example, but: https://github.com/dustin/gopro/blob/master/src/GoPro/Commands.hs#L46-L61
2020-09-26 09:37:02 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 09:37:31 +0200 <dsal> Anything in GoPro knows its API credentials, DB location, argv, etc... So the aforementioned `fixup` command just has to do this: https://github.com/dustin/gopro/blob/master/src/GoPro/Commands/Fixup.hs#L19
2020-09-26 09:38:40 +0200 <dsal> Yeah, I should really have found something easier... this also pulls the whole environment to rewrap it in a database environment. Related: monads don't always compose well.
2020-09-26 09:39:25 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 09:39:59 +0200mnrmnaugh(~mnrmnaugh@unaffiliated/mnrmnaugh)
2020-09-26 09:42:25 +0200 <dsal> fraktor: Just try throwing a ReaderT at something where you're passing a bunch of junk around and see if you can make things easier.
2020-09-26 09:42:44 +0200dsalneeds to stop trying to be awake
2020-09-26 09:43:30 +0200Dolly(585fd1fd@ti0203q160-5312.bb.online.no)
2020-09-26 09:44:29 +0200Dolly(585fd1fd@ti0203q160-5312.bb.online.no) (Remote host closed the connection)
2020-09-26 09:44:42 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 09:45:20 +0200 <fraktor> dsal: honestly same. I've had too much wine and too little sleep to learn rn
2020-09-26 09:45:28 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 09:45:56 +0200 <MarcelineVQ> while drinking wine is exactly the time to be a wizard
2020-09-26 09:46:53 +0200Tuplanolla(~Tuplanoll@91-159-68-239.elisa-laajakaista.fi)
2020-09-26 09:47:46 +0200cole-h(~cole-h@c-73-48-197-220.hsd1.ca.comcast.net) (Quit: Goodbye)
2020-09-26 09:49:59 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 258 seconds)
2020-09-26 09:50:44 +0200galagora(c5ed143c@197.237.20.60)
2020-09-26 09:52:35 +0200galagora(c5ed143c@197.237.20.60) (Remote host closed the connection)
2020-09-26 09:55:29 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 09:59:57 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 258 seconds)
2020-09-26 10:02:20 +0200John20(~John@82.46.59.122)
2020-09-26 10:04:47 +0200berberman(~berberman@2408:8207:256c:4a80:584e:a9ff:fe9b:d3fe) (Ping timeout: 246 seconds)
2020-09-26 10:05:06 +0200berberman(~berberman@2408:8207:256c:d310:584e:a9ff:fe9b:d3fe)
2020-09-26 10:05:36 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 10:07:01 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 10:08:58 +0200mirrorbird(~psutcliff@m83-187-185-252.cust.tele2.se) (Ping timeout: 256 seconds)
2020-09-26 10:09:18 +0200zaquest(~notzaques@5.128.210.178) (Quit: Leaving)
2020-09-26 10:09:45 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 10:10:23 +0200zaquest(~notzaques@5.128.210.178)
2020-09-26 10:11:42 +0200mnrmnaugh(~mnrmnaugh@unaffiliated/mnrmnaugh) (Ping timeout: 265 seconds)
2020-09-26 10:12:19 +0200isBEKaml(~isBEKaml@unaffiliated/isbekaml)
2020-09-26 10:12:39 +0200mmohammadi98128(~mmohammad@5.116.3.183)
2020-09-26 10:12:59 +0200mmohammadi98128(~mmohammad@5.116.3.183) (Client Quit)
2020-09-26 10:13:03 +0200mmohammadi9812(~mmohammad@2.178.197.45) (Read error: Connection reset by peer)
2020-09-26 10:13:37 +0200mmohammadi9812(~mmohammad@5.116.3.183)
2020-09-26 10:13:47 +0200cyphase(~cyphase@unaffiliated/cyphase) (Ping timeout: 240 seconds)
2020-09-26 10:14:05 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 240 seconds)
2020-09-26 10:14:39 +0200tomsmeding(~tomsmedin@tomsmeding.com) (Quit: ZNC 1.7.5 - https://znc.in)
2020-09-26 10:15:38 +0200inkbottle(~inkbottle@aaubervilliers-654-1-115-202.w86-198.abo.wanadoo.fr) (Quit: Konversation terminated!)
2020-09-26 10:15:46 +0200Orbstheorem(~roosember@hellendaal.orbstheorem.ch) (Ping timeout: 244 seconds)
2020-09-26 10:15:52 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 10:15:57 +0200inkbottle(~inkbottle@aaubervilliers-654-1-115-202.w86-198.abo.wanadoo.fr)
2020-09-26 10:16:01 +0200tomsmeding(~tomsmedin@tomsmeding.com)
2020-09-26 10:18:26 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 246 seconds)
2020-09-26 10:18:51 +0200mnrmnaugh(~mnrmnaugh@unaffiliated/mnrmnaugh)
2020-09-26 10:19:50 +0200mnrmnaugh(~mnrmnaugh@unaffiliated/mnrmnaugh) (Max SendQ exceeded)
2020-09-26 10:20:11 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 246 seconds)
2020-09-26 10:20:40 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 10:22:33 +0200mirrorbird(~psutcliff@2a00:801:42d:ae17:bde1:9f2f:16be:1acb)
2020-09-26 10:22:44 +0200Orbstheorem(~roosember@hellendaal.orbstheorem.ch)
2020-09-26 10:22:52 +0200mmohammadi9812(~mmohammad@5.116.3.183) (Read error: Connection reset by peer)
2020-09-26 10:24:09 +0200kuribas(~user@ptr-25vy0i7b1r54f1gv0vq.18120a2.ip6.access.telenet.be)
2020-09-26 10:25:30 +0200mmohammadi9812(~mmohammad@5.116.3.183)
2020-09-26 10:25:40 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt)
2020-09-26 10:25:52 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 10:29:13 +0200isBEKaml(~isBEKaml@unaffiliated/isbekaml) (Ping timeout: 260 seconds)
2020-09-26 10:30:40 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 256 seconds)
2020-09-26 10:31:05 +0200dhil(~dhil@11.29.39.217.dyn.plus.net)
2020-09-26 10:31:40 +0200chaosmasttter(~chaosmast@p200300c4a7105f0120adba39e14d4586.dip0.t-ipconnect.de)
2020-09-26 10:32:39 +0200isBEKaml(~isBEKaml@unaffiliated/isbekaml)
2020-09-26 10:34:17 +0200berberman(~berberman@2408:8207:256c:d310:584e:a9ff:fe9b:d3fe) (Quit: ZNC 1.7.5 - https://znc.in)
2020-09-26 10:34:29 +0200berberman(~berberman@123.118.109.217)
2020-09-26 10:35:49 +0200cyphase(~cyphase@unaffiliated/cyphase)
2020-09-26 10:36:17 +0200murphy_(~murphy_@2604:2000:1281:8a9e:f9e2:b2b0:776f:fb0d) (Ping timeout: 246 seconds)
2020-09-26 10:37:28 +0200murphy_(~murphy_@2604:2000:1281:8a9e:d1f4:d14c:3b99:af32)
2020-09-26 10:38:35 +0200Orbstheorem(~roosember@hellendaal.orbstheorem.ch) (Ping timeout: 272 seconds)
2020-09-26 10:38:43 +0200isBEKaml(~isBEKaml@unaffiliated/isbekaml) ()
2020-09-26 10:42:30 +0200cyphase(~cyphase@unaffiliated/cyphase) (Ping timeout: 272 seconds)
2020-09-26 10:42:31 +0200ChrisMarquardt(~ChrisMarq@84.39.117.57) (Remote host closed the connection)
2020-09-26 10:42:58 +0200berberman(~berberman@123.118.109.217) (Quit: ZNC 1.7.5 - https://znc.in)
2020-09-26 10:43:16 +0200berberman(~berberman@123.118.109.217)
2020-09-26 10:43:32 +0200ericsagnes(~ericsagne@2405:6580:0:5100:4882:fcf:4dee:3726) (Ping timeout: 260 seconds)
2020-09-26 10:44:12 +0200hnOsmium0001(uid453710@gateway/web/irccloud.com/x-ibhrcxsjgffyrrzh) (Quit: Connection closed for inactivity)
2020-09-26 10:44:47 +0200mirrorbird(~psutcliff@2a00:801:42d:ae17:bde1:9f2f:16be:1acb) (Quit: Leaving)
2020-09-26 10:45:04 +0200mirrorbird(~psutcliff@2a00:801:42d:ae17:bde1:9f2f:16be:1acb)
2020-09-26 10:46:13 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 10:46:38 +0200mananamenos(~mananamen@84.122.202.215.dyn.user.ono.com)
2020-09-26 10:46:48 +0200tzh(~tzh@2601:448:c500:5300::82b3) (Quit: zzz)
2020-09-26 10:47:33 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 10:48:05 +0200berberman(~berberman@123.118.109.217) (Client Quit)
2020-09-26 10:48:30 +0200berberman(~berberman@2408:8207:256c:d310::a44)
2020-09-26 10:49:29 +0200Orbstheorem(~roosember@hellendaal.orbstheorem.ch)
2020-09-26 10:50:16 +0200fendor(~fendor@178.115.129.156.wireless.dyn.drei.com)
2020-09-26 10:50:25 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 10:52:12 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 256 seconds)
2020-09-26 10:52:28 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 246 seconds)
2020-09-26 10:53:26 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 10:55:44 +0200ericsagnes(~ericsagne@2405:6580:0:5100:4950:94c:b421:e6e)
2020-09-26 10:56:18 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 11:00:43 +0200kaychaks_riot(kaychaksma@gateway/shell/matrix.org/x-tflbmrkeqvvmbbze) ("Kicked by @appservice-irc:matrix.org : Idle for 30+ days")
2020-09-26 11:00:47 +0200robin[m]1(robinyurii@gateway/shell/matrix.org/x-vhpdnjyaahhjoyky) (Quit: Idle for 30+ days)
2020-09-26 11:00:54 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 258 seconds)
2020-09-26 11:03:13 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 264 seconds)
2020-09-26 11:03:38 +0200Saten-san(~Saten-san@ip-213-49-124-100.dsl.scarlet.be)
2020-09-26 11:03:45 +0200drbean(~drbean@TC210-63-209-151.static.apol.com.tw) (Ping timeout: 240 seconds)
2020-09-26 11:03:57 +0200hackagebugsnag-hs 0.2.0.1 - A Bugsnag client for Haskell. https://hackage.haskell.org/package/bugsnag-hs-0.2.0.1 (JasperWoudenberg)
2020-09-26 11:04:47 +0200Orbstheorem(~roosember@hellendaal.orbstheorem.ch) (Ping timeout: 260 seconds)
2020-09-26 11:06:25 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 11:07:21 +0200cyphase(~cyphase@unaffiliated/cyphase)
2020-09-26 11:08:56 +0200macrover(~macrover@ip70-189-231-35.lv.lv.cox.net)
2020-09-26 11:10:30 +0200coffeeturtle(~coffeetur@cpc103420-donc13-2-0-cust24.17-1.cable.virginm.net)
2020-09-26 11:10:38 +0200outer_passage(outerpassa@2600:3c01::f03c:92ff:fed1:4643)
2020-09-26 11:10:38 +0200jamestmartin(james@jtmar.me) (Ping timeout: 244 seconds)
2020-09-26 11:10:42 +0200arkeet`(~arkeet@moriya.ca)
2020-09-26 11:10:43 +0200jtmar(james@jtmar.me)
2020-09-26 11:10:45 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 11:10:48 +0200mirrorbird(~psutcliff@2a00:801:42d:ae17:bde1:9f2f:16be:1acb) (Quit: Leaving)
2020-09-26 11:10:53 +0200Klumben(Nsaiswatch@gateway/shell/panicbnc/x-yzdmtfgsysducyrw) (Ping timeout: 272 seconds)
2020-09-26 11:11:12 +0200outerpassage(outerpassa@2600:3c01::f03c:92ff:fed1:4643) (Ping timeout: 260 seconds)
2020-09-26 11:11:47 +0200arkeet(arkeet@unaffiliated/arkeet) (Ping timeout: 260 seconds)
2020-09-26 11:12:22 +0200mpereira(~mpereira@2a02:810d:f40:d96:5151:9344:10a3:da64)
2020-09-26 11:14:26 +0200carlomagno(~cararell@inet-hqmc01-o.oracle.com) (Remote host closed the connection)
2020-09-26 11:16:23 +0200shad0w_(~shad0w_@160.202.37.29) (Remote host closed the connection)
2020-09-26 11:16:53 +0200shad0w_(~shad0w_@160.202.37.29)
2020-09-26 11:17:17 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 11:18:43 +0200coffeeturtle(~coffeetur@cpc103420-donc13-2-0-cust24.17-1.cable.virginm.net) (Quit: leaving)
2020-09-26 11:22:12 +0200zariuq(~zar@fw1.ciirc.cvut.cz)
2020-09-26 11:25:55 +0200Gurkenglas(~Gurkengla@unaffiliated/gurkenglas)
2020-09-26 11:26:05 +0200John20(~John@82.46.59.122) (Ping timeout: 240 seconds)
2020-09-26 11:26:28 +0200mmohammadi98121(~mmohammad@188.210.120.71)
2020-09-26 11:26:41 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 11:27:00 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 11:27:44 +0200mmohammadi9812(~mmohammad@5.116.3.183) (Ping timeout: 246 seconds)
2020-09-26 11:27:45 +0200mmohammadi98121mmohammadi9812
2020-09-26 11:28:12 +0200shad0w_(~shad0w_@160.202.37.29) (Remote host closed the connection)
2020-09-26 11:28:37 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 260 seconds)
2020-09-26 11:31:05 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 11:31:16 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 272 seconds)
2020-09-26 11:31:25 +0200dhil(~dhil@11.29.39.217.dyn.plus.net) (Ping timeout: 260 seconds)
2020-09-26 11:34:39 +0200TooDifficult_(~TooDiffic@139.59.59.230)
2020-09-26 11:36:35 +0200mmohammadi98124(~mmohammad@188.210.102.88)
2020-09-26 11:36:57 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 11:38:18 +0200ph88(~ph88@ip5f5af71a.dynamic.kabel-deutschland.de)
2020-09-26 11:38:37 +0200berberman(~berberman@2408:8207:256c:d310::a44) (Quit: ZNC 1.7.5 - https://znc.in)
2020-09-26 11:39:21 +0200berberman(~berberman@2408:8207:256c:d310::a44)
2020-09-26 11:39:34 +0200mmohammadi9812(~mmohammad@188.210.120.71) (Ping timeout: 256 seconds)
2020-09-26 11:39:35 +0200mmohammadi98124mmohammadi9812
2020-09-26 11:39:58 +0200carlomagno(~cararell@inet-hqmc02-o.oracle.com)
2020-09-26 11:41:41 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 260 seconds)
2020-09-26 11:42:03 +0200berberman(~berberman@2408:8207:256c:d310::a44) (Client Quit)
2020-09-26 11:42:41 +0200berberman(~berberman@2408:8207:256c:d310::a44)
2020-09-26 11:42:50 +0200Orbstheorem(~roosember@hellendaal.orbstheorem.ch)
2020-09-26 11:44:07 +0200jedws(~jedws@121.209.139.222) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 11:44:30 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 265 seconds)
2020-09-26 11:47:22 +0200knupfer(~Thunderbi@87.123.206.233)
2020-09-26 11:47:50 +0200zaquest(~notzaques@5.128.210.178) (Read error: Connection reset by peer)
2020-09-26 11:48:35 +0200zaquest(~notzaques@5.128.210.178)
2020-09-26 11:50:16 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 11:50:28 +0200berberman(~berberman@2408:8207:256c:d310::a44) (Quit: ZNC 1.7.5 - https://znc.in)
2020-09-26 11:51:09 +0200berberman(~berberman@123.118.109.217)
2020-09-26 11:51:10 +0200Dolly(585fd1fd@ti0203q160-5312.bb.online.no)
2020-09-26 11:51:56 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6)
2020-09-26 11:52:33 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6) (Client Quit)
2020-09-26 11:55:26 +0200HedgeMage1(~HedgeMage@84.39.117.57)
2020-09-26 11:56:52 +0200 <dwts> hello all, I've just started playing with Haskell and following a Course. (Learning Haskell Programming from Lynda.com if that matters). I'm adding hspec in my test-suite section of my project.cabal file but when I'm running `stack test` I get an error for importing Hspec and the hspec entry in my project.cabal file is no longer there. Any ideas where I should be looking at to resolve this issue?
2020-09-26 11:57:04 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 11:57:20 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 11:59:05 +0200 <dwts> basically the error states: "Could not find module 'Test.Hspec'
2020-09-26 12:01:25 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 264 seconds)
2020-09-26 12:01:54 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 265 seconds)
2020-09-26 12:02:01 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 12:02:02 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 246 seconds)
2020-09-26 12:02:12 +0200AlterEgo-(~ladew@124-198-158-163.dynamic.caiway.nl)
2020-09-26 12:07:16 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 12:07:36 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 12:09:36 +0200berberman(~berberman@123.118.109.217) (Quit: ZNC 1.7.5 - https://znc.in)
2020-09-26 12:10:11 +0200TooDifficult_(~TooDiffic@139.59.59.230) (Ping timeout: 240 seconds)
2020-09-26 12:12:10 +0200mirrorbird(~psutcliff@2a00:801:42d:ae17:bde1:9f2f:16be:1acb)
2020-09-26 12:12:26 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 272 seconds)
2020-09-26 12:12:27 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-09-26 12:15:23 +0200mirrorbirdpsutcliffe
2020-09-26 12:17:10 +0200wei2912(~wei2912@unaffiliated/wei2912) (Quit: Lost terminal)
2020-09-26 12:17:22 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 12:18:25 +0200 <tomjaguarpaw> Perhaps post your cabal file at https://paste.tomsmeding.com/
2020-09-26 12:19:34 +0200kotrcka(~peter@ip-94-112-194-11.net.upcbroadband.cz) (Quit: Konversation terminated!)
2020-09-26 12:19:47 +0200mmohammadi9812(~mmohammad@188.210.102.88) (Ping timeout: 240 seconds)
2020-09-26 12:21:38 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 246 seconds)
2020-09-26 12:21:57 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6)
2020-09-26 12:22:33 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6) (Client Quit)
2020-09-26 12:23:11 +0200v_m_v(~vm_v@31-10-157-87.cgn.dynamic.upc.ch)
2020-09-26 12:26:59 +0200rembo10(~rembo10@wally.codeshy.com) (Quit: ZNC 1.8.1 - https://znc.in)
2020-09-26 12:27:31 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 12:30:07 +0200acidjnk_new(~acidjnk@p200300d0c723789624d205acd1b15fd8.dip0.t-ipconnect.de)
2020-09-26 12:30:09 +0200random(~random@185.219.70.106)
2020-09-26 12:30:18 +0200rembo10(~rembo10@wally.codeshy.com)
2020-09-26 12:30:23 +0200xff0x_(~fox@2001:1a81:5304:1100:a54a:18d7:1a45:1603) (Ping timeout: 246 seconds)
2020-09-26 12:30:27 +0200 <random> hey guys
2020-09-26 12:30:33 +0200 <random> does anyone know if you can derive Generic via some field
2020-09-26 12:31:02 +0200 <random> I have a data type `data Something a = Something { blabla :: a, blablabla :: SomethingElse }`
2020-09-26 12:31:07 +0200falafel_(~falafel@2605:e000:1527:d491:f090:20fe:cddf:2a1a) (Ping timeout: 260 seconds)
2020-09-26 12:31:15 +0200 <random> I want to use generic-lens on `Something a` as if I was using it on a
2020-09-26 12:31:17 +0200 <random> is that possible?
2020-09-26 12:31:19 +0200__monty__(~toonn@unaffiliated/toonn)
2020-09-26 12:32:20 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 256 seconds)
2020-09-26 12:33:13 +0200Sgeo(~Sgeo@ool-18b982ad.dyn.optonline.net) (Read error: Connection reset by peer)
2020-09-26 12:33:57 +0200ryansmccoy(~ryansmcco@68.235.48.108) (Ping timeout: 260 seconds)
2020-09-26 12:34:24 +0200ryansmccoy(~ryansmcco@193.37.254.27)
2020-09-26 12:35:26 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 12:37:39 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 12:38:46 +0200howdoi(uid224@gateway/web/irccloud.com/x-aqxmdshelfofznzr) (Quit: Connection closed for inactivity)
2020-09-26 12:40:28 +0200DirefulSalt(DirefulSal@gateway/vpn/privateinternetaccess/direfulsalt) (Remote host closed the connection)
2020-09-26 12:40:50 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-09-26 12:40:54 +0200DirefulSalt(DirefulSal@gateway/vpn/privateinternetaccess/direfulsalt)
2020-09-26 12:41:46 +0200Klumben(Nsaiswatch@gateway/shell/panicbnc/x-qoebdhwirjmxvlle)
2020-09-26 12:42:21 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 260 seconds)
2020-09-26 12:43:03 +0200 <dwts> tomjaguarpaw: Hi, this is how the .cabal file looks like before running `stack test`: https://paste.tomsmeding.com/cnrUyvSC and this is how it looks after running stack test: https://paste.tomsmeding.com/hT7eCgTj
2020-09-26 12:47:46 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 12:48:39 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6)
2020-09-26 12:49:52 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6) (Client Quit)
2020-09-26 12:51:09 +0200xff0x_(~fox@2001:1a81:5304:1100:a54a:18d7:1a45:1603)
2020-09-26 12:52:20 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 272 seconds)
2020-09-26 12:54:00 +0200 <tomjaguarpaw> This file has been generated from package.yaml by hpack version 0.34.2.
2020-09-26 12:54:01 +0200knupfer(~Thunderbi@87.123.206.233) (Ping timeout: 260 seconds)
2020-09-26 12:54:11 +0200 <dwts> yes
2020-09-26 12:54:18 +0200 <tomjaguarpaw> Did you put the hspec dependency in stack.yaml?
2020-09-26 12:54:28 +0200 <dwts> oh...
2020-09-26 12:54:37 +0200Dolly(585fd1fd@ti0203q160-5312.bb.online.no) (Remote host closed the connection)
2020-09-26 12:54:42 +0200Turmfalke(~user@unaffiliated/siracusa) (Quit: Bye!)
2020-09-26 12:57:34 +0200fdem(~quassel@217.131.87.102)
2020-09-26 12:57:54 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 12:58:02 +0200rprije(~rprije@27.143.220.203.dial.dynamic.acc01-myal-dub.comindico.com.au) (Ping timeout: 272 seconds)
2020-09-26 13:01:22 +0200 <dwts> hmmm, nope something doesn't look right
2020-09-26 13:01:28 +0200hackagekubernetes-client-core 0.3.0.0 - Auto-generated kubernetes-client-core API Client https://hackage.haskell.org/package/kubernetes-client-core-0.3.0.0 (axeman)
2020-09-26 13:01:35 +0200 <dwts> I repeated the whole process and I still end up wit hthe same files
2020-09-26 13:02:21 +0200 <dwts> is it normal for project.cabal to be "^refreshed" to its initial state after running `stack test` ?
2020-09-26 13:02:28 +0200hackagekubernetes-client 0.3.0.0 - Client library for Kubernetes https://hackage.haskell.org/package/kubernetes-client-0.3.0.0 (axeman)
2020-09-26 13:02:37 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 264 seconds)
2020-09-26 13:05:38 +0200aarvar(~foewfoiew@50.35.43.33) (Ping timeout: 272 seconds)
2020-09-26 13:08:06 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 13:09:26 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 13:10:14 +0200Tuplanolla(~Tuplanoll@91-159-68-239.elisa-laajakaista.fi) (Quit: Leaving.)
2020-09-26 13:11:08 +0200lucid_0x80(~lucid_0x8@188.253.224.148)
2020-09-26 13:12:25 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 13:12:31 +0200coffeeturtle(~coffeetur@cpc103420-donc13-2-0-cust24.17-1.cable.virginm.net)
2020-09-26 13:21:41 +0200Henson(~kvirc@24-246-25-37.cable.teksavvy.com)
2020-09-26 13:21:45 +0200coffeeturtle(~coffeetur@cpc103420-donc13-2-0-cust24.17-1.cable.virginm.net) (Quit: leaving)
2020-09-26 13:22:32 +0200dyeplexer(~lol@unaffiliated/terpin)
2020-09-26 13:23:49 +0200v_m_v(~vm_v@31-10-157-87.cgn.dynamic.upc.ch) (Remote host closed the connection)
2020-09-26 13:26:32 +0200Gurkenglas(~Gurkengla@unaffiliated/gurkenglas) (Ping timeout: 272 seconds)
2020-09-26 13:28:16 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 13:29:22 +0200RusAlex(~Chel@unaffiliated/rusalex) (Quit: WeeChat 2.7.1)
2020-09-26 13:30:15 +0200zebrag(~inkbottle@aaubervilliers-654-1-106-91.w86-212.abo.wanadoo.fr)
2020-09-26 13:30:49 +0200inkbottle(~inkbottle@aaubervilliers-654-1-115-202.w86-198.abo.wanadoo.fr) (Ping timeout: 264 seconds)
2020-09-26 13:31:46 +0200hekkaidekapus_(~tchouri@gateway/tor-sasl/hekkaidekapus)
2020-09-26 13:32:35 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 13:34:03 +0200hekkaidekapus(~tchouri@gateway/tor-sasl/hekkaidekapus) (Ping timeout: 240 seconds)
2020-09-26 13:36:56 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Remote host closed the connection)
2020-09-26 13:38:25 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 13:38:28 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 13:41:41 +0200 <tomjaguarpaw> I expect so. I'm not a stack user but I imagine that you are not supposed to write project.cabal directly. Instead you are supposed to edit stack.yaml and stack generates project.cabal for you.
2020-09-26 13:42:45 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 13:42:50 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 246 seconds)
2020-09-26 13:43:23 +0200lemmih(~lemmih@58.182.131.25) (Remote host closed the connection)
2020-09-26 13:43:40 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-09-26 13:44:03 +0200lemmih(~lemmih@2406:3003:2072:44:5428:a9c5:7934:3415)
2020-09-26 13:45:24 +0200RusAlex(~Chel@unaffiliated/rusalex)
2020-09-26 13:47:04 +0200alx741(~alx741@181.196.68.114) (Ping timeout: 256 seconds)
2020-09-26 13:48:33 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 13:50:11 +0200xff0x_(~fox@2001:1a81:5304:1100:a54a:18d7:1a45:1603) (Ping timeout: 246 seconds)
2020-09-26 13:50:28 +0200hackagearch-hs 0.1.0.0 - A program generating PKGBUILD for hackage packages. https://hackage.haskell.org/package/arch-hs-0.1.0.0 (berberman)
2020-09-26 13:51:20 +0200xff0x_(~fox@2001:1a81:5304:1100:600f:1d33:a4fd:a80e)
2020-09-26 13:51:30 +0200drbean(~drbean@TC210-63-209-57.static.apol.com.tw)
2020-09-26 13:52:59 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 246 seconds)
2020-09-26 13:57:26 +0200HedgeMage1(~HedgeMage@84.39.117.57) (Remote host closed the connection)
2020-09-26 13:58:26 +0200John20(~John@82.46.59.122)
2020-09-26 13:58:48 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 13:59:59 +0200ericsagnes(~ericsagne@2405:6580:0:5100:4950:94c:b421:e6e) (Ping timeout: 246 seconds)
2020-09-26 14:00:09 +0200alx741(~alx741@186.178.110.72)
2020-09-26 14:00:22 +0200chaosmasttter(~chaosmast@p200300c4a7105f0120adba39e14d4586.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-09-26 14:02:29 +0200Unhammer(~Unhammer@gateway/tor-sasl/unhammer) (Remote host closed the connection)
2020-09-26 14:03:08 +0200Unhammer(~Unhammer@gateway/tor-sasl/unhammer)
2020-09-26 14:03:13 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 246 seconds)
2020-09-26 14:03:13 +0200John20(~John@82.46.59.122) (Ping timeout: 246 seconds)
2020-09-26 14:03:29 +0200justan0theruser(~justanoth@unaffiliated/justanotheruser) (Ping timeout: 246 seconds)
2020-09-26 14:03:42 +0200John20(~John@82.46.59.122)
2020-09-26 14:07:14 +0200solonarv(~solonarv@anancy-653-1-63-100.w109-217.abo.wanadoo.fr)
2020-09-26 14:08:09 +0200bitmagie(~Thunderbi@200116b8069cc400d57e23bacd856e4d.dip.versatel-1u1.de)
2020-09-26 14:08:14 +0200utopic_int0x80(~lucid_0x8@188.253.232.227)
2020-09-26 14:08:49 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 14:09:10 +0200TooDifficult(~TooDiffic@139.59.59.230)
2020-09-26 14:10:25 +0200lucid_0x80(~lucid_0x8@188.253.224.148) (Ping timeout: 240 seconds)
2020-09-26 14:11:57 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 14:13:13 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 260 seconds)
2020-09-26 14:13:26 +0200ericsagnes(~ericsagne@2405:6580:0:5100:800:278:bf0b:4a49)
2020-09-26 14:13:39 +0200 <maerwald> dwts: that happens when you use package.yaml
2020-09-26 14:13:44 +0200 <maerwald> otherwise not
2020-09-26 14:14:27 +0200hackagebytestring 0.10.9.0 - Fast, compact, strict and lazy byte strings with a list interface https://hackage.haskell.org/package/bytestring-0.10.9.0 (Bodigrim)
2020-09-26 14:14:38 +0200machinedgod(~machinedg@24.105.81.50)
2020-09-26 14:17:14 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 265 seconds)
2020-09-26 14:17:20 +0200Saukk(~Saukk@2001:998:dc:4a67:1c59:9bb5:b94c:4)
2020-09-26 14:19:05 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 14:21:31 +0200polyphem(~p0lyph3m@2a02:810d:640:776c:76d7:55f6:f85b:c889)
2020-09-26 14:21:34 +0200Dooode(df132b1b@223.19.43.27)
2020-09-26 14:21:52 +0200Dooode(df132b1b@223.19.43.27) (Remote host closed the connection)
2020-09-26 14:23:25 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 14:25:06 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 14:26:22 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Remote host closed the connection)
2020-09-26 14:27:09 +0200Saukk(~Saukk@2001:998:dc:4a67:1c59:9bb5:b94c:4) (Remote host closed the connection)
2020-09-26 14:27:13 +0200Uma(~uma@umazalakain.info) (Ping timeout: 260 seconds)
2020-09-26 14:27:47 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 14:29:01 +0200xerox_(~xerox@unaffiliated/xerox) (Ping timeout: 264 seconds)
2020-09-26 14:29:09 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 14:29:24 +0200jneira(501e65ce@gateway/web/cgi-irc/kiwiirc.com/ip.80.30.101.206)
2020-09-26 14:30:18 +0200chaosmasttter(~chaosmast@p200300c4a7105f0120adba39e14d4586.dip0.t-ipconnect.de)
2020-09-26 14:30:30 +0200dyeplexer(~lol@unaffiliated/terpin) (Read error: Connection reset by peer)
2020-09-26 14:31:45 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 240 seconds)
2020-09-26 14:32:11 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 246 seconds)
2020-09-26 14:33:32 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net) (Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net)
2020-09-26 14:33:39 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 258 seconds)
2020-09-26 14:36:30 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net)
2020-09-26 14:37:01 +0200supercoven_(~Supercove@dsl-hkibng32-54fb54-166.dhcp.inet.fi)
2020-09-26 14:37:02 +0200supercoven_(~Supercove@dsl-hkibng32-54fb54-166.dhcp.inet.fi) (Max SendQ exceeded)
2020-09-26 14:37:16 +0200supercoven_(~Supercove@dsl-hkibng32-54fb54-166.dhcp.inet.fi)
2020-09-26 14:37:16 +0200supercoven_(~Supercove@dsl-hkibng32-54fb54-166.dhcp.inet.fi) (Max SendQ exceeded)
2020-09-26 14:37:32 +0200supercoven_(~Supercove@dsl-hkibng32-54fb54-166.dhcp.inet.fi)
2020-09-26 14:37:33 +0200supercoven_(~Supercove@dsl-hkibng32-54fb54-166.dhcp.inet.fi) (Max SendQ exceeded)
2020-09-26 14:37:33 +0200supercoven(~Supercove@dsl-hkibng32-54fb54-166.dhcp.inet.fi) (K-Lined)
2020-09-26 14:38:53 +0200TooDifficult(~TooDiffic@139.59.59.230) (Ping timeout: 260 seconds)
2020-09-26 14:39:14 +0200TooDifficult(~TooDiffic@139.59.59.230)
2020-09-26 14:39:19 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 14:41:31 +0200mmohammadi9812(~mmohammad@188.210.102.88)
2020-09-26 14:43:44 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 256 seconds)
2020-09-26 14:43:55 +0200raehik(~raehik@cpc96984-rdng25-2-0-cust109.15-3.cable.virginm.net)
2020-09-26 14:44:40 +0200_vaibhavingale_1(~Adium@203.188.228.27)
2020-09-26 14:45:41 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 14:45:55 +0200_vaibhavingale_(~Adium@203.188.228.27) (Ping timeout: 258 seconds)
2020-09-26 14:49:30 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 14:51:48 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 14:53:57 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 260 seconds)
2020-09-26 14:56:25 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1)
2020-09-26 14:57:35 +0200maxfragg1(~maxfragg@185.244.214.216)
2020-09-26 14:58:01 +0200mananamenos(~mananamen@84.122.202.215.dyn.user.ono.com) (Read error: Connection reset by peer)
2020-09-26 14:58:28 +0200_vaibhavingale_(~Adium@203.188.228.27)
2020-09-26 14:58:29 +0200_vaibhavingale_1(~Adium@203.188.228.27) (Read error: Connection reset by peer)
2020-09-26 14:58:32 +0200Rudd0(~Rudd0@185.189.115.103) (Ping timeout: 256 seconds)
2020-09-26 14:59:39 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 14:59:41 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6)
2020-09-26 15:00:41 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6) (Client Quit)
2020-09-26 15:00:54 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 272 seconds)
2020-09-26 15:01:23 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net) (Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net)
2020-09-26 15:02:35 +0200 <tomjaguarpaw> maerwald: Thanks again for ghcup. I have been using it frequently!
2020-09-26 15:02:49 +0200 <maerwald> o/
2020-09-26 15:03:06 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 15:03:31 +0200ubert(~Thunderbi@178.115.131.152.wireless.dyn.drei.com)
2020-09-26 15:04:13 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 260 seconds)
2020-09-26 15:06:03 +0200shafox(~shafox@106.51.234.111) (Remote host closed the connection)
2020-09-26 15:06:20 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net)
2020-09-26 15:06:57 +0200hackagehablog 0.7.1 - A blog system https://hackage.haskell.org/package/hablog-0.7.1 (gilmi)
2020-09-26 15:07:16 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 246 seconds)
2020-09-26 15:09:28 +0200shafox(~shafox@106.51.234.111)
2020-09-26 15:09:42 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 15:11:29 +0200mmohammadi9812(~mmohammad@188.210.102.88) (Read error: Connection reset by peer)
2020-09-26 15:11:34 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6)
2020-09-26 15:12:32 +0200mmohammadi9812(~mmohammad@80.210.51.115)
2020-09-26 15:12:43 +0200John20(~John@82.46.59.122) (Ping timeout: 260 seconds)
2020-09-26 15:14:17 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 15:14:28 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 260 seconds)
2020-09-26 15:15:36 +0200josh_(~josh@c-67-164-104-206.hsd1.ca.comcast.net)
2020-09-26 15:17:52 +0200shad0w_(~shad0w_@160.202.37.29)
2020-09-26 15:18:36 +0200ddellacosta(~dd@86.106.121.168)
2020-09-26 15:19:47 +0200josh_(~josh@c-67-164-104-206.hsd1.ca.comcast.net) (Ping timeout: 246 seconds)
2020-09-26 15:19:48 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 15:20:16 +0200v_m_v(~vm_v@31-10-157-87.cgn.dynamic.upc.ch)
2020-09-26 15:24:58 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 272 seconds)
2020-09-26 15:25:36 +0200xerox_(~xerox@unaffiliated/xerox)
2020-09-26 15:26:14 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 272 seconds)
2020-09-26 15:26:17 +0200sand_dull(~theuser@185.217.69.182)
2020-09-26 15:26:18 +0200pasha1(~pasha@103.252.171.167)
2020-09-26 15:27:17 +0200pasha1(~pasha@103.252.171.167) (Client Quit)
2020-09-26 15:27:59 +0200mmohammadi98120(~mmohammad@5.238.165.34)
2020-09-26 15:28:16 +0200mmohammadi9812(~mmohammad@80.210.51.115) (Ping timeout: 246 seconds)
2020-09-26 15:28:17 +0200mmohammadi98120mmohammadi9812
2020-09-26 15:28:23 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 15:28:50 +0200Tops2(~Tobias@dyndsl-095-033-089-216.ewe-ip-backbone.de)
2020-09-26 15:30:05 +0200John20(~John@82.46.59.122)
2020-09-26 15:30:55 +0200CrazyPython(~crazypyth@71-135-5-88.lightspeed.rlghnc.sbcglobal.net)
2020-09-26 15:32:23 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 246 seconds)
2020-09-26 15:32:32 +0200ubert(~Thunderbi@178.115.131.152.wireless.dyn.drei.com) (Ping timeout: 256 seconds)
2020-09-26 15:33:05 +0200fdem(~quassel@217.131.87.102) (Ping timeout: 246 seconds)
2020-09-26 15:36:13 +0200kritzefitz(~kritzefit@212.86.56.80)
2020-09-26 15:36:14 +0200kritzefitz(~kritzefit@212.86.56.80) (Client Quit)
2020-09-26 15:37:11 +0200coeus(~coeus@p200300d02724ef00d20f0ecf5ac74df4.dip0.t-ipconnect.de) (*.net *.split)
2020-09-26 15:37:11 +0200debugloop(~danieln@unaffiliated/debugloop) (*.net *.split)
2020-09-26 15:37:11 +0200magog(~wee@unaffiliated/magog) (*.net *.split)
2020-09-26 15:37:11 +0200maralorn(maralornma@gateway/shell/matrix.org/x-ezvabzjgnlwkefwo) (*.net *.split)
2020-09-26 15:37:12 +0200Majoo(~Majiir@2601:18c:ca00:a400:211:32ff:fe42:6eda) (*.net *.split)
2020-09-26 15:37:12 +0200Alleria_(~AllahuAkb@2604:2000:1484:26:e98f:8381:852e:ca0) (*.net *.split)
2020-09-26 15:37:12 +0200vnz(~vnz@unaffiliated/vnz) (*.net *.split)
2020-09-26 15:37:12 +0200jkaye[m](jkayematri@gateway/shell/matrix.org/x-bugyajrlynkkcpgn) (*.net *.split)
2020-09-26 15:37:12 +0200themsay[m](themsaymat@gateway/shell/matrix.org/x-wxsxhqlajtqicyiz) (*.net *.split)
2020-09-26 15:37:12 +0200alexfmpe(alexfmpema@gateway/shell/matrix.org/x-imhylowfnwnyorun) (*.net *.split)
2020-09-26 15:37:12 +0200sureyeaah(shauryab98@gateway/shell/matrix.org/x-djatmabmxnhvvvhf) (*.net *.split)
2020-09-26 15:37:12 +0200rednaZ[m](r3dnazmatr@gateway/shell/matrix.org/x-acshcfgqgpxmjkwb) (*.net *.split)
2020-09-26 15:37:12 +0200chreekat[m](chreekatma@gateway/shell/matrix.org/x-exxcchwgrqwwfgam) (*.net *.split)
2020-09-26 15:37:12 +0200Jon(jon@dow.land) (*.net *.split)
2020-09-26 15:37:12 +0200Taneb(~Taneb@2001:41c8:51:10d:aaaa:0:aaaa:0) (*.net *.split)
2020-09-26 15:37:12 +0200byorgey(~byorgey@155.138.238.211) (*.net *.split)
2020-09-26 15:37:12 +0200nopf(~frosch@static.179.17.76.144.clients.your-server.de) (*.net *.split)
2020-09-26 15:37:12 +0200M2tias(m2@seri.fi) (*.net *.split)
2020-09-26 15:37:21 +0200vnz(~vnz@51.15.143.225)
2020-09-26 15:37:21 +0200byorgey(~byorgey@155.138.238.211)
2020-09-26 15:37:21 +0200vnz(~vnz@51.15.143.225) (Changing host)
2020-09-26 15:37:21 +0200vnz(~vnz@unaffiliated/vnz)
2020-09-26 15:37:24 +0200Jon(jon@dow.land)
2020-09-26 15:37:25 +0200MVQq(~anja@198.254.202.72)
2020-09-26 15:37:36 +0200Majiir(~Majiir@2601:18c:ca00:a400:211:32ff:fe42:6eda)
2020-09-26 15:37:40 +0200debugloop(~danieln@unaffiliated/debugloop)
2020-09-26 15:37:44 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6)
2020-09-26 15:38:11 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 15:39:28 +0200jneira(501e65ce@gateway/web/cgi-irc/kiwiirc.com/ip.80.30.101.206) (Quit: Ping timeout (120 seconds))
2020-09-26 15:40:05 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 15:40:25 +0200deu(de@uio.re) (Ping timeout: 264 seconds)
2020-09-26 15:40:29 +0200maralorn(maralornma@gateway/shell/matrix.org/x-jcjdlorwwncednaz)
2020-09-26 15:40:43 +0200MarcelineVQ(~anja@198.254.202.72) (Ping timeout: 260 seconds)
2020-09-26 15:41:18 +0200 <tomjaguarpaw> Is there some option I can set to convince cabal to minimize rebuilds?
2020-09-26 15:41:20 +0200sureyeaah(shauryab98@gateway/shell/matrix.org/x-ixgowzetgwdpalkm)
2020-09-26 15:41:24 +0200chreekat[m](chreekatma@gateway/shell/matrix.org/x-linhirjvdrhofayv)
2020-09-26 15:41:33 +0200rednaZ[m](r3dnazmatr@gateway/shell/matrix.org/x-pxthlvwirdzkfldr)
2020-09-26 15:41:44 +0200alexfmpe(alexfmpema@gateway/shell/matrix.org/x-qdsezkyvjisttceh)
2020-09-26 15:42:30 +0200xzax_[m](xzaxmatrix@gateway/shell/matrix.org/x-vlvhwzrgsdarqxvk)
2020-09-26 15:42:42 +0200themsay[m](themsaymat@gateway/shell/matrix.org/session)
2020-09-26 15:42:42 +0200jkaye[m](jkayematri@gateway/shell/matrix.org/session)
2020-09-26 15:42:42 +0200Alleria_(~AllahuAkb@2604:2000:1484:26:c494:5a0b:fe0f:9b26)
2020-09-26 15:42:42 +0200coeus(~coeus@p200300d02724ef00d20f0ecf5ac74df4.dip0.t-ipconnect.de)
2020-09-26 15:42:42 +0200magog(~wee@unaffiliated/magog)
2020-09-26 15:42:42 +0200Taneb(~Taneb@2001:41c8:51:10d:aaaa:0:aaaa:0)
2020-09-26 15:42:42 +0200nopf(~frosch@static.179.17.76.144.clients.your-server.de)
2020-09-26 15:42:42 +0200M2tias(m2@seri.fi)
2020-09-26 15:42:43 +0200jkaye[m](jkayematri@gateway/shell/matrix.org/session) (Changing host)
2020-09-26 15:42:43 +0200jkaye[m](jkayematri@gateway/shell/matrix.org/x-rpmuernsphlxsxxq)
2020-09-26 15:42:43 +0200themsay[m](themsaymat@gateway/shell/matrix.org/session) (Changing host)
2020-09-26 15:42:43 +0200themsay[m](themsaymat@gateway/shell/matrix.org/x-mjbquguhfulgkgro)
2020-09-26 15:43:26 +0200xzax_[m](xzaxmatrix@gateway/shell/matrix.org/x-vlvhwzrgsdarqxvk) ("User left")
2020-09-26 15:44:36 +0200ddellacosta(~dd@86.106.121.168) (Ping timeout: 272 seconds)
2020-09-26 15:44:55 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 15:45:14 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 272 seconds)
2020-09-26 15:45:17 +0200drbean(~drbean@TC210-63-209-57.static.apol.com.tw) (Ping timeout: 260 seconds)
2020-09-26 15:47:17 +0200 <whataday> what's the different meaning between Reader and Cont?
2020-09-26 15:47:28 +0200deu(de@uio.re)
2020-09-26 15:47:55 +0200 <whataday> or effects?
2020-09-26 15:48:39 +0200berberman(~berberman@2408:8207:256c:d310::a44)
2020-09-26 15:48:41 +0200 <whataday> both related to callbacks?
2020-09-26 15:49:06 +0200 <tomjaguarpaw> What do you mean? Reader and Cont are completely different.
2020-09-26 15:49:11 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 246 seconds)
2020-09-26 15:49:40 +0200machinedgod(~machinedg@24.105.81.50) (Ping timeout: 272 seconds)
2020-09-26 15:49:55 +0200 <whataday> I mean in function form, not the type structure form
2020-09-26 15:49:56 +0200 <Cale> whataday: Reader just gives you access to a single immutable value. Reader r a is essentially the same thing as r -> a
2020-09-26 15:50:36 +0200 <Cale> whataday: Cont on the other hand abstracts over the continuation of the computation, and lets you do stuff like callCC
2020-09-26 15:51:01 +0200 <Cale> Cont r a is effectively (a -> r) -> r
2020-09-26 15:51:41 +0200 <whataday> basically Reader give a access to a single value, and Cont can access an unary function?
2020-09-26 15:52:16 +0200 <whataday> they're both related to function callback, right?
2020-09-26 15:53:11 +0200 <whataday> Reader is simple, like we do function compose
2020-09-26 15:53:49 +0200 <whataday> what's the abstract meaning of Cont?
2020-09-26 15:54:23 +0200 <tomjaguarpaw> Hmm, not really
2020-09-26 15:54:28 +0200 <tomjaguarpaw> Reader r a is a -> r
2020-09-26 15:54:41 +0200 <tomjaguarpaw> *Reader r a is r -> a
2020-09-26 15:54:43 +0200 <whataday> monad is a->
2020-09-26 15:54:51 +0200 <tomjaguarpaw> Cont r a is (a -> r) -> r
2020-09-26 15:54:57 +0200 <whataday> cont monad is (a->r)->
2020-09-26 15:55:13 +0200 <tomjaguarpaw> No, cont monad is (_ -> r) -> r
2020-09-26 15:55:20 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 15:55:22 +0200 <tomjaguarpaw> Reader monad is r -> _
2020-09-26 15:55:34 +0200berberman(~berberman@2408:8207:256c:d310::a44) (Quit: ZNC 1.7.5 - https://znc.in)
2020-09-26 15:55:35 +0200 <tomjaguarpaw> The parameter _ is in a completely different place in each case. They are nothing like each other.
2020-09-26 15:56:00 +0200 <whataday> but monad has kind *->*?
2020-09-26 15:56:05 +0200berberman(~berberman@123.118.109.217)
2020-09-26 15:56:12 +0200 <whataday> r->_ kind is?
2020-09-26 15:56:42 +0200 <whataday> and _ is a magic stuff just in ghci?
2020-09-26 15:56:54 +0200CrazyPython(~crazypyth@71-135-5-88.lightspeed.rlghnc.sbcglobal.net) (Remote host closed the connection)
2020-09-26 15:57:23 +0200 <tomjaguarpaw> "_" is just the syntax I'm using to indicate the type parameter
2020-09-26 15:57:53 +0200 <tomjaguarpaw> Reader r a is r -> a so it is "an a that has access to an r"
2020-09-26 15:57:57 +0200 <whataday> I'm confused
2020-09-26 15:57:58 +0200 <tomjaguarpaw> r
2020-09-26 15:58:10 +0200 <tomjaguarpaw> Cont r a is (a -> r) -> r so it is not "an a" in any sense
2020-09-26 15:58:24 +0200jneira(501e65ce@gateway/web/cgi-irc/kiwiirc.com/ip.80.30.101.206)
2020-09-26 15:58:27 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1)
2020-09-26 15:59:57 +0200 <whataday> what's the meaning when concat Cont?
2020-09-26 16:00:08 +0200 <whataday> I mean use >>= to bind Cont
2020-09-26 16:00:23 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 16:00:36 +0200 <whataday> f . g = \x -> f (g x)
2020-09-26 16:00:47 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 16:01:15 +0200 <whataday> function composing I understand
2020-09-26 16:01:26 +0200 <whataday> what's about Cont?
2020-09-26 16:02:32 +0200 <Cale> Well, let's look at the type first of all
2020-09-26 16:02:43 +0200 <Cale> Cont r a -> (a -> Cont r b) -> Cont r b
2020-09-26 16:03:19 +0200 <Cale> So that's like ((a -> r) -> r) -> (a -> ((b -> r) -> r)) -> ((b -> r) -> r)
2020-09-26 16:03:57 +0200 <Cale> It's a bit of a puzzle figuring out how to put these pieces together, but there's not all that many ways to do it
2020-09-26 16:04:04 +0200 <whataday> construct a new Cont, and the value is from the second parameter
2020-09-26 16:04:27 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 16:05:22 +0200 <Cale> It's sort of a funny thing, Cont r a is like a thing which can answer r-valued questions that are presumably about a value of type a. However there might not actually be a value of type a for which the answers it gives are the right ones.
2020-09-26 16:05:23 +0200 <whataday> use function a-> Cont r b to construct a new Cont with a from Cont r a?
2020-09-26 16:05:43 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 246 seconds)
2020-09-26 16:06:12 +0200 <Cale> But yeah, the general way of things is that x >>= f is going to "run x" (whatever that means) and then apply f to its result to figure out what to run after that
2020-09-26 16:07:13 +0200 <Cale> In the case of Cont specifically, it can be a bit tricky to think through what's going on, though we can have a machine do it for us if we like:
2020-09-26 16:07:20 +0200 <Cale> @djinn ((a -> r) -> r) -> (a -> ((b -> r) -> r)) -> ((b -> r) -> r)
2020-09-26 16:07:20 +0200 <lambdabot> f a b c = a (\ d -> b d c)
2020-09-26 16:09:10 +0200 <Cale> Actually, let me rephrase this a bit so that it makes more sense...
2020-09-26 16:09:18 +0200utopic_int0x80(~lucid_0x8@188.253.232.227) (Ping timeout: 256 seconds)
2020-09-26 16:09:41 +0200 <whataday> we give an unary function to Cont r a to extract a, then pass a to a-> Cont r b to construct Cont r b?
2020-09-26 16:09:56 +0200 <Cale> Yeah, d :: a here
2020-09-26 16:10:39 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 16:10:42 +0200 <Cale> So it's like we're making a thing which can answer questions (which djinn called c) about a value of type b
2020-09-26 16:11:47 +0200 <Cale> and we do it by asking the Cont r a the question "if we applied this function of type (a -> Cont r b) to your value of type a, and then asked the resulting Cont r b our question, what would its answer be?"
2020-09-26 16:12:22 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 246 seconds)
2020-09-26 16:14:08 +0200 <whataday> wait a sec, we extract Cont r a by passing (a->r), and a is passing to a-> Cont r b too
2020-09-26 16:14:17 +0200 <Cale> newtype QuestionBox r a = Box { askTheBox :: (a -> r) -> r }
2020-09-26 16:14:58 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 256 seconds)
2020-09-26 16:15:11 +0200 <Cale> x >>= f = Box (\question -> askTheBox x (\a -> askTheBox (f a) question))
2020-09-26 16:15:28 +0200machinedgod(~machinedg@bras-base-sconpq1802w-grc-02-69-159-109-171.dsl.bell.ca)
2020-09-26 16:15:31 +0200 <whataday> QuestionBlx r a = Box (a-> r) -> r
2020-09-26 16:16:01 +0200 <whataday> askTheBox QuestionBox r a :: (a->r)->r
2020-09-26 16:16:34 +0200 <Cale> askTheBox's full type here would be askTheBox :: QuestionBox r a -> (a -> r) -> r
2020-09-26 16:16:41 +0200 <whataday> askTheBox and Box are isomorphic
2020-09-26 16:17:05 +0200 <Cale> No, but they're isomorphisms in opposite directions between QuestionBox r a and (a -> r) -> r
2020-09-26 16:17:31 +0200 <whataday> oh right
2020-09-26 16:17:37 +0200 <Cale> Box :: ((a -> r) -> r) -> QuestionBox r a
2020-09-26 16:17:49 +0200 <Cale> askTheBox :: QuestionBox r a -> ((a -> r) -> r)
2020-09-26 16:18:09 +0200 <whataday> Box (a->r) ->r :: QuestionBox r a
2020-09-26 16:18:26 +0200random(~random@185.219.70.106) (Ping timeout: 256 seconds)
2020-09-26 16:18:37 +0200 <Cale> Or it would be more correct to say that when f :: (a -> r) -> r, then Box f :: QuestionBox r a
2020-09-26 16:18:47 +0200 <whataday> I don't understand why haskell always wrap them?
2020-09-26 16:18:54 +0200 <Cale> wrap what?
2020-09-26 16:19:03 +0200 <whataday> the type the value
2020-09-26 16:19:08 +0200 <Cale> hm?
2020-09-26 16:19:24 +0200 <whataday> Box (a->r)->r
2020-09-26 16:19:44 +0200 <Cale> That's mixing up things at the term and type level
2020-09-26 16:19:55 +0200 <Cale> Box is a term, it lives on the left side of the ::
2020-09-26 16:19:56 +0200 <whataday> why not just use function to express
2020-09-26 16:20:01 +0200 <Cale> (a -> r) -> r is a type
2020-09-26 16:20:07 +0200 <Cale> it lives on the right side of the ::
2020-09-26 16:20:45 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 16:21:09 +0200 <Cale> As for why we don't just work with functions here
2020-09-26 16:21:17 +0200 <Cale> Well, it's a few different reasons
2020-09-26 16:21:35 +0200 <Cale> One is that we're trying to produce an abstraction, functions are just our implementation mechanism
2020-09-26 16:21:48 +0200 <whataday> for Reader, a->r is a type, why we use Reader r a to express it?
2020-09-26 16:21:53 +0200 <Cale> Eventually, we'll have enough pieces that perhaps we won't need to use Box explicitly so much
2020-09-26 16:22:02 +0200 <Cale> Similarly with Reader
2020-09-26 16:22:24 +0200 <Cale> Secondly, we can't have more than one instance of Monad for functions
2020-09-26 16:22:36 +0200 <Cale> and the Reader-like instance is already there
2020-09-26 16:23:09 +0200 <Cale> (and the Cont-like one wouldn't really work, since we can't isolate the appropriate type parameter in a points-free way)
2020-09-26 16:23:15 +0200totallynotnate(~nate@125.161.70.37)
2020-09-26 16:23:59 +0200 <Cale> In order to have a monad, we need a type level function M such that our computations have types that look like M a
2020-09-26 16:24:17 +0200 <whataday> not all languages support higher-kinded polymorphism, here we use Reader r a to express is not available in other languages
2020-09-26 16:24:18 +0200 <Cale> So Cont r does that for us here
2020-09-26 16:24:27 +0200TooDifficult(~TooDiffic@139.59.59.230) (Quit: TooDifficult)
2020-09-26 16:24:38 +0200 <Cale> Or Reader r
2020-09-26 16:24:50 +0200 <Cale> instance Monad (Reader r) where ...
2020-09-26 16:24:59 +0200 <Cale> It turns out we *can* write:
2020-09-26 16:25:06 +0200 <Cale> instance Monad ((->) r) where ...
2020-09-26 16:25:10 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 256 seconds)
2020-09-26 16:25:16 +0200 <Cale> partially-applying the function arrow
2020-09-26 16:25:48 +0200 <whataday> r-> is the monad for Reader
2020-09-26 16:25:51 +0200 <Cale> But (1) that's a little sneaky and might even be considered a little too surprising
2020-09-26 16:25:56 +0200 <Cale> and (2) it doesn't work for Cont
2020-09-26 16:26:15 +0200 <whataday> (a->r)-> ?
2020-09-26 16:26:24 +0200 <whataday> can't be monad for cont?
2020-09-26 16:26:31 +0200 <Cale> Yeah, we need an M for which M a = (a -> r) -> r
2020-09-26 16:26:43 +0200 <Cale> and we can't get that by partial application of anything which already exists
2020-09-26 16:27:58 +0200 <whataday> some people are familiar with continuation or cps in other languages, but in haskell, cont monad is hard to understand by type signature
2020-09-26 16:28:15 +0200 <whataday> other I mean dynamic languages
2020-09-26 16:28:19 +0200GyroW(~GyroW@unaffiliated/gyrow) (Quit: Someone ate my pie)
2020-09-26 16:28:36 +0200GyroW(~GyroW@d54C03E98.access.telenet.be)
2020-09-26 16:28:36 +0200GyroW(~GyroW@d54C03E98.access.telenet.be) (Changing host)
2020-09-26 16:28:36 +0200GyroW(~GyroW@unaffiliated/gyrow)
2020-09-26 16:29:08 +0200 <Cale> It's not really any worse than understanding continuations in other dynamic languages, I think. It's just that what you need to understand has been made explicit by the types
2020-09-26 16:29:58 +0200 <Cale> Continuations are a little bit twisty and confusing in either case, but without types, you *really* have to know what you're doing
2020-09-26 16:30:32 +0200mananamenos(~mananamen@84.122.202.215.dyn.user.ono.com)
2020-09-26 16:30:57 +0200 <whataday> just like closure in dynamic languages, easy to understand and use, but in haskell I don't understand how to
2020-09-26 16:31:17 +0200 <Cale> Closures are just an implementation mechanism for functions
2020-09-26 16:31:37 +0200 <whataday> in dynamic languages we can change variables in an environment, but haskell can't change
2020-09-26 16:31:43 +0200 <Cale> In Haskell, we usually just say "function" and not "closure" unless we're really talking about the low-level implementation
2020-09-26 16:31:45 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 16:32:04 +0200turion(~turion@ip5f5af77e.dynamic.kabel-deutschland.de)
2020-09-26 16:32:28 +0200 <Cale> You can define things which capture mutable variables from their scope of definition in Haskell if you like
2020-09-26 16:32:31 +0200 <solonarv> you absolutely can have mutable references in Haskell, and you can have functions that close over them
2020-09-26 16:32:39 +0200 <solonarv> heh, ninja'd
2020-09-26 16:32:55 +0200 <Cale> Make a new IORef and return a function which produces an action that writes to it, and separately an action which reads from it
2020-09-26 16:33:23 +0200 <whataday> but IORef is not suggested
2020-09-26 16:33:28 +0200 <Cale> ?
2020-09-26 16:33:33 +0200totallynotnate(~nate@125.161.70.37) (Quit: WeeChat 2.9)
2020-09-26 16:33:43 +0200 <Cale> IORefs definitely have their place
2020-09-26 16:33:49 +0200mmohammadi9812(~mmohammad@5.238.165.34) (Ping timeout: 264 seconds)
2020-09-26 16:34:16 +0200totallynotnate(~nate@125.161.70.37)
2020-09-26 16:34:24 +0200 <Cale> They might not be the first thing you learn about, since if you're an imperative programmer, the first thing to learn is how not to be wasteful with mutable variables :)
2020-09-26 16:34:29 +0200 <whataday> I thought people always said IO is evil
2020-09-26 16:34:33 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 16:34:47 +0200 <Cale> It's evil in some ways, but it's also the entire point of running a program
2020-09-26 16:35:38 +0200 <whataday> so let's save the princess a from evil IO a
2020-09-26 16:36:15 +0200 <whataday> just kidding
2020-09-26 16:36:16 +0200totallynotnate(~nate@125.161.70.37) (Client Quit)
2020-09-26 16:36:21 +0200 <dwts> maerwald: hey, thanks. I used `stack new [project_name] to generate my project. This also creates a pagkage.yml. It is possible that when the course was recorded that wasn't the case or that pacakge.yml didn't cause issues
2020-09-26 16:36:25 +0200 <Cale> If you're not, e.g. doing communication between threads, or any actual I/O, then using IORef might be ill-advised.
2020-09-26 16:36:59 +0200mmohammadi9812(~mmohammad@5.238.165.34)
2020-09-26 16:37:32 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 16:38:06 +0200 <whataday> when we need to use the twisted Cont?
2020-09-26 16:38:20 +0200 <whataday> for which scene?
2020-09-26 16:38:25 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Remote host closed the connection)
2020-09-26 16:38:26 +0200 <dwts> maerwald: after removing package.yml I got better results
2020-09-26 16:39:03 +0200John20(~John@82.46.59.122) (Ping timeout: 260 seconds)
2020-09-26 16:39:36 +0200 <Cale> whataday: Mostly we don't, but there are some cases where you run into a lot of functions which allocate/deallocate resources, and take a function which says what to do with the resource while it's available
2020-09-26 16:40:05 +0200 <Cale> Mostly these functions have names like withSomething
2020-09-26 16:40:09 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 16:40:12 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-09-26 16:40:16 +0200mmohammadi98128(~mmohammad@5.238.165.34)
2020-09-26 16:40:31 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 16:40:46 +0200 <whataday> but that's the coroutine scene
2020-09-26 16:40:53 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 16:40:53 +0200 <Cale> Cont and ContT can straighten out the situation where you're nesting a lot of such functions to allocate (and later deallocate) many resources
2020-09-26 16:41:06 +0200 <Cale> and let you write code that looks like it just obtains things directly
2020-09-26 16:41:12 +0200mmohammadi9812(~mmohammad@5.238.165.34) (Read error: Connection reset by peer)
2020-09-26 16:41:12 +0200mmohammadi98128mmohammadi9812
2020-09-26 16:41:25 +0200 <Cale> So instead of:
2020-09-26 16:41:41 +0200 <Cale> withResource1 (\r1 -> withResource2 (\r2 -> ...))
2020-09-26 16:41:46 +0200 <Cale> You're writing something like
2020-09-26 16:42:01 +0200 <Cale> do r1 <- getResource1; r2 <- getResource2; ...
2020-09-26 16:42:49 +0200 <Cale> (typically, getResource1 = ContT withResource1)
2020-09-26 16:44:19 +0200 <Cale> Sometimes, even if you're not going to build up the whole abstraction of using Cont or ContT, it can be helpful to have something like sequence for Cont to obtain a whole list of resources at once
2020-09-26 16:44:26 +0200 <Cale> :t runCont . sequence . map cont
2020-09-26 16:44:27 +0200 <lambdabot> [(a -> r) -> r] -> ([a] -> r) -> r
2020-09-26 16:44:34 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 246 seconds)
2020-09-26 16:45:02 +0200GyroW_(~GyroW@ptr-48ujrfb8c7gfd2lu92q.18120a2.ip6.access.telenet.be)
2020-09-26 16:45:03 +0200GyroW_(~GyroW@ptr-48ujrfb8c7gfd2lu92q.18120a2.ip6.access.telenet.be) (Changing host)
2020-09-26 16:45:03 +0200GyroW_(~GyroW@unaffiliated/gyrow)
2020-09-26 16:45:04 +0200 <Cale> This thing takes a list of resource-acquiring functions, and then produces a function which acquires a list of the resources all at once
2020-09-26 16:45:04 +0200GyroW(~GyroW@unaffiliated/gyrow) (Ping timeout: 256 seconds)
2020-09-26 16:45:27 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 240 seconds)
2020-09-26 16:45:31 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 258 seconds)
2020-09-26 16:45:44 +0200 <whataday> a concret example?
2020-09-26 16:45:57 +0200 <whataday> that above?
2020-09-26 16:46:25 +0200sand_dull(~theuser@185.217.69.182) (Ping timeout: 240 seconds)
2020-09-26 16:47:00 +0200 <Cale> https://downloads.haskell.org/~ghc/latest/docs/html/libraries/base-4.14.0.0/Foreign-Marshal-Array.… -- suppose you're doing FFI to some C library, and you need to allocate a bunch of arrays of various lengths, and then make sure they get deallocated afterwards
2020-09-26 16:47:22 +0200 <Cale> allocaArray :: Storable a => Int -> (Ptr a -> IO b) -> IO b
2020-09-26 16:48:02 +0200 <Cale> is a helpful thing to allocate an array of some length, giving the function a pointer to it, and then deallocating the array automatically once the action that the function produces has run
2020-09-26 16:48:20 +0200 <Cale> (or if that action throws an exception...)
2020-09-26 16:48:40 +0200sand_dull(~theuser@185.217.69.182)
2020-09-26 16:48:41 +0200 <maerwald> sm[m]: how can I ignore stderr in shelltestrunner for a certain test?
2020-09-26 16:48:45 +0200 <Cale> So, maybe we want to allocate a handful of arrays, perhaps of lengths 5, 7, and 10
2020-09-26 16:48:56 +0200josh_(~josh@c-67-164-104-206.hsd1.ca.comcast.net)
2020-09-26 16:49:23 +0200 <Cale> We could use that function above on the list map allocaArray [5,7,10]
2020-09-26 16:49:31 +0200Gurkenglas(~Gurkengla@unaffiliated/gurkenglas)
2020-09-26 16:49:38 +0200 <Cale> :t allocaArray -- wonder if we have this around...
2020-09-26 16:49:40 +0200 <lambdabot> error: Variable not in scope: allocaArray
2020-09-26 16:49:53 +0200 <Cale> :t Foreign.Marshal.Array.allocaArray -- qualified?
2020-09-26 16:49:54 +0200 <lambdabot> Foreign.Storable.Storable a => Int -> (GHC.Ptr.Ptr a -> IO b) -> IO b
2020-09-26 16:49:57 +0200 <Cale> cool
2020-09-26 16:50:05 +0200 <Cale> :t map Foreign.Marshal.Array.allocaArray [5,7,10]
2020-09-26 16:50:06 +0200 <whataday> ...
2020-09-26 16:50:07 +0200 <lambdabot> Foreign.Storable.Storable a => [(GHC.Ptr.Ptr a -> IO b) -> IO b]
2020-09-26 16:50:22 +0200 <Cale> :t runCont . sequence . map cont $ map Foreign.Marshal.Array.allocaArray [5,7,10]
2020-09-26 16:50:24 +0200 <lambdabot> Foreign.Storable.Storable a => ([GHC.Ptr.Ptr a] -> IO b) -> IO b
2020-09-26 16:50:38 +0200 <Cale> Now it's a thing which gives our function a list of pointers :)
2020-09-26 16:50:52 +0200 <Cale> (to our arrays of size 5, 7, and 10)
2020-09-26 16:51:02 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 16:51:06 +0200 <Cale> and it'll deallocate all the arrays after we're done using them
2020-09-26 16:51:14 +0200 <Cale> (once the action completes)
2020-09-26 16:52:06 +0200 <Cale> I'm not sure I'd take the trouble of using Cont in exactly this situation, but when you end up nesting a large number of withFoo-style functions it can end up untangling code.
2020-09-26 16:52:24 +0200jb55(~jb55@gateway/tor-sasl/jb55) (Remote host closed the connection)
2020-09-26 16:52:49 +0200 <Cale> Mostly, we just don't use Cont though. It's a good example monad, but it's not all that practical. Usually something with less power will do the trick.
2020-09-26 16:53:03 +0200 <whataday> yes
2020-09-26 16:53:05 +0200 <Cale> Cont gives you callCC which is like first-class GOTO
2020-09-26 16:53:30 +0200 <Cale> and... usually that's just a recipe for creating headaches
2020-09-26 16:53:34 +0200 <whataday> nesting is easy to understand
2020-09-26 16:54:33 +0200jb55(~jb55@gateway/tor-sasl/jb55)
2020-09-26 16:54:40 +0200 <Cale> Yeah, though, sometimes it's awkward to write the thing which straightforwardly nests, when you don't know ahead of time which things you'll want to allocate, or there are an indefinite number of them
2020-09-26 16:54:56 +0200 <glguy> Allocation nesting doesn't need the full Cont, at least
2020-09-26 16:55:11 +0200 <Cale> That as well
2020-09-26 16:55:27 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 16:56:06 +0200 <whataday> I'm glad we can do something with easy way
2020-09-26 16:56:19 +0200 <Cale> The way I like to think about callCC is that it gives you exactly the thing that return does in C/Python/whatever
2020-09-26 16:56:22 +0200 <glguy> https://github.com/glguy/irc-core/blob/v2/src/Client/CApi.hs#L265
2020-09-26 16:56:41 +0200 <Cale> Except that it gives it to you *as a function which you can pass around and call from wherever*
2020-09-26 16:56:46 +0200 <glguy> That module needs a ton of nested with- operations
2020-09-26 16:56:56 +0200 <whataday> call/cc is easy to use and understand in scheme
2020-09-26 16:57:18 +0200 <whataday> if we don't to think how it's implemented
2020-09-26 16:57:44 +0200 <Cale> For some value of "easy to understand" which allows for arbitrarily-hard-to-understand interactions
2020-09-26 16:58:02 +0200 <glguy> Easy to know you don't understand it?
2020-09-26 16:59:35 +0200Lord_of_Life_(~Lord@unaffiliated/lord-of-life/x-0885362)
2020-09-26 17:00:01 +0200maxfragg1(~maxfragg@185.244.214.216) ()
2020-09-26 17:00:22 +0200alexkubicail(~alexkubic@37.142.205.101)
2020-09-26 17:01:13 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 17:01:14 +0200Lord_of_Life(~Lord@unaffiliated/lord-of-life/x-0885362) (Ping timeout: 272 seconds)
2020-09-26 17:02:29 +0200Lord_of_Life_Lord_of_Life
2020-09-26 17:02:49 +0200coot(~coot@37.30.52.6.nat.umts.dynamic.t-mobile.pl) (Quit: coot)
2020-09-26 17:03:36 +0200GyroW_(~GyroW@unaffiliated/gyrow) (Quit: Someone ate my pie)
2020-09-26 17:03:56 +0200GyroW(~GyroW@d54c03e98.access.telenet.be)
2020-09-26 17:03:56 +0200GyroW(~GyroW@d54c03e98.access.telenet.be) (Changing host)
2020-09-26 17:03:56 +0200GyroW(~GyroW@unaffiliated/gyrow)
2020-09-26 17:04:42 +0200chaosmasttter(~chaosmast@p200300c4a7105f0120adba39e14d4586.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-09-26 17:05:02 +0200oisdk(~oisdk@2001:bb6:3329:d100:3937:264b:c180:39d6) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 17:05:12 +0200dhil(~dhil@11.29.39.217.dyn.plus.net)
2020-09-26 17:05:27 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 17:06:37 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 246 seconds)
2020-09-26 17:06:42 +0200 <sm[m]> maerwald: >2 // I think (match anything)
2020-09-26 17:07:21 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net) (Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net)
2020-09-26 17:07:32 +0200 <sm[m]> also might need >=1 or >=//
2020-09-26 17:07:57 +0200alexkubicail(~alexkubic@37.142.205.101) (Quit: Leaving)
2020-09-26 17:08:08 +0200 <maerwald> I'm using format 2
2020-09-26 17:08:14 +0200alexkubicail(~alexkubic@37.142.205.101)
2020-09-26 17:08:28 +0200 <maerwald> >>>2 //
2020-09-26 17:08:30 +0200 <maerwald> yes?
2020-09-26 17:08:46 +0200chaosmasttter(~chaosmast@p200300c4a7105f0120adba39e14d4586.dip0.t-ipconnect.de)
2020-09-26 17:09:10 +0200 <sm[m]> Yes
2020-09-26 17:10:32 +0200kotrcka(~peter@ip-94-112-194-11.net.upcbroadband.cz)
2020-09-26 17:10:54 +0200Sgeo(~Sgeo@ool-18b982ad.dyn.optonline.net)
2020-09-26 17:11:20 +0200 <kuribas> tdammers: hi
2020-09-26 17:11:23 +0200 <kuribas> tdammers: did you do work on supercompilation?
2020-09-26 17:12:31 +0200nbloomf(~nbloomf@2600:1700:83e0:1f40:cc55:612b:5adc:f6f1) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 17:13:14 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net)
2020-09-26 17:15:38 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 17:15:56 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 17:16:01 +0200bloodstalker(~bloodstal@46.166.187.178)
2020-09-26 17:17:29 +0200knupfer(~Thunderbi@87.123.206.233)
2020-09-26 17:17:34 +0200urodna(~urodna@unaffiliated/urodna)
2020-09-26 17:18:31 +0200bitmapper(uid464869@gateway/web/irccloud.com/x-ljepinlfusvtsirz)
2020-09-26 17:18:32 +0200knupfer(~Thunderbi@87.123.206.233) (Client Quit)
2020-09-26 17:18:43 +0200knupfer(~Thunderbi@200116b82c2b4e000cf1902bacfcade4.dip.versatel-1u1.de)
2020-09-26 17:19:47 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 240 seconds)
2020-09-26 17:23:30 +0200v_m_v(~vm_v@31-10-157-87.cgn.dynamic.upc.ch) (Remote host closed the connection)
2020-09-26 17:23:44 +0200v_m_v(~vm_v@2a02:aa12:3200:6480:f507:71a:9334:3099)
2020-09-26 17:27:47 +0200v_m_v(~vm_v@2a02:aa12:3200:6480:f507:71a:9334:3099) (Ping timeout: 240 seconds)
2020-09-26 17:31:29 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 17:34:21 +0200cocreature(K5Bm45ovDM@gateway/shell/uberspace.de/x-nbwtipuyknbchowa) ("WeeChat 2.6")
2020-09-26 17:34:40 +0200cocreature_(~cocreatur@eirene.uberspace.de)
2020-09-26 17:34:57 +0200NieDzejkob(~quassel@188.123.215.55) (Ping timeout: 260 seconds)
2020-09-26 17:35:45 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 17:35:49 +0200NieDzejkob(~quassel@188.123.215.55)
2020-09-26 17:35:53 +0200cocreature_cocreature
2020-09-26 17:36:07 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 240 seconds)
2020-09-26 17:36:24 +0200dcoutts(~duncan@unaffiliated/dcoutts) (Remote host closed the connection)
2020-09-26 17:36:44 +0200 <ski> @hackage managed -- whataday, perhaps this could be interesting to see, re `ContT'
2020-09-26 17:36:44 +0200 <lambdabot> https://hackage.haskell.org/package/managed -- whataday, perhaps this could be interesting to see, re `ContT'
2020-09-26 17:37:12 +0200elliott_(~elliott@pool-100-36-54-163.washdc.fios.verizon.net)
2020-09-26 17:39:21 +0200rcdilorenzo(~rcdiloren@cpe-76-182-87-188.nc.res.rr.com)
2020-09-26 17:39:47 +0200TooDifficult(~TooDiffic@139.59.59.230)
2020-09-26 17:40:34 +0200 <whataday> kan-extensions...
2020-09-26 17:40:55 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 246 seconds)
2020-09-26 17:41:32 +0200tzh(~tzh@2601:448:c500:5300::82b3)
2020-09-26 17:41:42 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 17:42:56 +0200ericsagnes(~ericsagne@2405:6580:0:5100:800:278:bf0b:4a49) (Ping timeout: 246 seconds)
2020-09-26 17:43:13 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 260 seconds)
2020-09-26 17:44:51 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2020-09-26 17:45:13 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 17:52:30 +0200tomku(~tomku@unaffiliated/tomku) (Ping timeout: 256 seconds)
2020-09-26 17:52:30 +0200dhananjay(~root@ares.dbalan.in) (Read error: Connection reset by peer)
2020-09-26 17:54:54 +0200ericsagnes(~ericsagne@2405:6580:0:5100:45be:1ab8:9d1a:eec6)
2020-09-26 17:55:04 +0200rektide1(~rektide@84.39.117.57)
2020-09-26 17:57:09 +0200TooDifficult_(~TooDiffic@106.206.110.145)
2020-09-26 17:58:02 +0200toorevitimirp(~tooreviti@117.182.182.201)
2020-09-26 17:58:25 +0200TooDifficult(~TooDiffic@139.59.59.230) (Ping timeout: 264 seconds)
2020-09-26 17:58:26 +0200TooDifficult_TooDifficult
2020-09-26 18:00:31 +0200jiribenes(jbmatrixji@gateway/shell/matrix.org/x-hdzhixicavigjvqu) (Quit: Idle for 30+ days)
2020-09-26 18:00:41 +0200Rudd0(~Rudd0@185.189.115.103)
2020-09-26 18:01:37 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 18:02:32 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 18:02:48 +0200tomku(~tomku@unaffiliated/tomku)
2020-09-26 18:04:31 +0200retropikzel_(~Retropikz@dyvyf3fs8gw7zbnhkmk4y-4.rev.dnainternet.fi)
2020-09-26 18:05:20 +0200toorevitimirp(~tooreviti@117.182.182.201) (Remote host closed the connection)
2020-09-26 18:05:46 +0200toorevitimirp(~tooreviti@117.182.182.201)
2020-09-26 18:05:47 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 240 seconds)
2020-09-26 18:07:12 +0200keteskyl(~kelsey@2600:6c64:7b7f:fa42:2cda:1ff8:55be:a617)
2020-09-26 18:07:25 +0200jluttine(~jluttine@87-95-204-180.bb.dnainternet.fi) (Ping timeout: 240 seconds)
2020-09-26 18:07:42 +0200acidjnk_new(~acidjnk@p200300d0c723789624d205acd1b15fd8.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-09-26 18:08:31 +0200jluttine(~jluttine@87-95-204-180.bb.dnainternet.fi)
2020-09-26 18:09:02 +0200retropikzel_(~Retropikz@dyvyf3fs8gw7zbnhkmk4y-4.rev.dnainternet.fi) (Client Quit)
2020-09-26 18:11:31 +0200ahmr88(~ahmr88@cpc85006-haye22-2-0-cust131.17-4.cable.virginm.net)
2020-09-26 18:11:56 +0200alexkubicail(~alexkubic@37.142.205.101) ("Leaving")
2020-09-26 18:14:17 +0200_deepfire(~user@80.92.100.69)
2020-09-26 18:15:12 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 18:15:34 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 18:16:16 +0200fxg(~fxg@unaffiliated/fxg)
2020-09-26 18:18:47 +0200MVQq(~anja@198.254.202.72) (Quit: q)
2020-09-26 18:19:23 +0200MarcelineVQ(~anja@198.254.202.72)
2020-09-26 18:23:07 +0200ddellacosta(~dd@86.106.121.168)
2020-09-26 18:23:20 +0200coot(~coot@37.30.52.6.nat.umts.dynamic.t-mobile.pl)
2020-09-26 18:23:22 +0200fresheyeball(~isaac@c-71-237-105-37.hsd1.co.comcast.net)
2020-09-26 18:23:39 +0200ahmr88(~ahmr88@cpc85006-haye22-2-0-cust131.17-4.cable.virginm.net) (Remote host closed the connection)
2020-09-26 18:24:25 +0200elliott_(~elliott@pool-100-36-54-163.washdc.fios.verizon.net) (Ping timeout: 240 seconds)
2020-09-26 18:24:44 +0200machinedgod(~machinedg@bras-base-sconpq1802w-grc-02-69-159-109-171.dsl.bell.ca) (Ping timeout: 256 seconds)
2020-09-26 18:25:37 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 18:26:09 +0200Sheilong(uid293653@gateway/web/irccloud.com/x-oxndjxbsupaxjafx)
2020-09-26 18:27:21 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 18:30:32 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 272 seconds)
2020-09-26 18:31:06 +0200mu_(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 18:31:12 +0200mu__(~mu@unaffiliated/mu)
2020-09-26 18:32:12 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-09-26 18:32:13 +0200fluturel(~fluturel@82.137.14.51)
2020-09-26 18:32:56 +0200 <fluturel> i have a small question regarding a small piece of code i wrote
2020-09-26 18:33:06 +0200geekosaur(42d52102@66.213.33.2)
2020-09-26 18:33:19 +0200 <fluturel> I am trying to write a zip function
2020-09-26 18:33:38 +0200 <fluturel> but for some reason it doesn't seem to want to work with infinite lists
2020-09-26 18:33:56 +0200 <ski> did you use an accumulator ?
2020-09-26 18:34:07 +0200sand_dull(~theuser@185.217.69.182) (Ping timeout: 240 seconds)
2020-09-26 18:34:23 +0200 <fluturel> This is my version with list comprehension: zip' xs ys = [(xs !! i, ys !! i) | i <- [0..(min (length xs) (length ys))-1]]
2020-09-26 18:34:39 +0200 <fluturel> ski: how do you mean?
2020-09-26 18:34:51 +0200mu__(~mu@unaffiliated/mu) (Client Quit)
2020-09-26 18:35:06 +0200 <fluturel> my suspicion is it doesn't work becuase of the min function
2020-09-26 18:35:12 +0200 <ski> ok. yea `length' won't terminate on infinite lists
2020-09-26 18:35:26 +0200 <ski> > [0 .. length [0 ..] - 1]
2020-09-26 18:35:30 +0200dhil(~dhil@11.29.39.217.dyn.plus.net) (Ping timeout: 256 seconds)
2020-09-26 18:35:33 +0200 <lambdabot> mueval-core: Time limit exceeded
2020-09-26 18:35:37 +0200mmohammadi9812(~mmohammad@5.238.165.34) (Ping timeout: 264 seconds)
2020-09-26 18:35:42 +0200mnrmnaughmnrgle(~mnrmnaugh@unaffiliated/mnrmnaugh) (Ping timeout: 260 seconds)
2020-09-26 18:35:52 +0200 <fluturel> yeah, that makes sense and i figured that much
2020-09-26 18:36:03 +0200 <fluturel> is there any way to check if a list is infinite?
2020-09-26 18:36:04 +0200 <ski> so the problem is that you're using `length'
2020-09-26 18:36:06 +0200 <ski> no
2020-09-26 18:36:29 +0200 <ski> you can only observe finitely many elements of a list, in finite time
2020-09-26 18:37:01 +0200 <ski> so, if you've seen a thousand elements, then you know the list has at least that many elements. might have no more, or one or ten more. or might be infinite
2020-09-26 18:37:54 +0200mmohammadi9812(~mmohammad@188.210.108.97)
2020-09-26 18:37:56 +0200 <ski> to gracefully handle infinite lists, make sure that your computation is "incremental", or productive, will produce some part(s) of the output, before having seen the end of the input list(s)
2020-09-26 18:38:44 +0200 <ski> `length' is not incremental. it won't produce an answer, until it sees the end of the list. and since an infinite list has no end, it will never produce an answer, for such
2020-09-26 18:39:26 +0200 <fluturel> so i iterate through the elements, form the tuples, and check if the next i is valid for both lists. If it isn't for one of them, that's all i need to know
2020-09-26 18:40:12 +0200 <ski> yea, i suppose you could do that
2020-09-26 18:40:37 +0200 <fluturel> what aabout the accumulator you mentioned?
2020-09-26 18:40:44 +0200 <ski> another approach is to not bother with indices at all, just to pattern-match on the lists
2020-09-26 18:41:22 +0200toorevitimirp(~tooreviti@117.182.182.201) (Read error: Connection reset by peer)
2020-09-26 18:41:25 +0200 <fluturel> i haven't learned pattern-matching yet, so i don't know the syntax or anything
2020-09-26 18:41:55 +0200 <ski> well .. sometimes people write "loops" like this, using an accumulator. but that doesn't really work, for infinite lists. so, i was thinking that maybe you were using an accumulator, and that that was why your function didn't work on infinite lists
2020-09-26 18:42:08 +0200 <ski> ok
2020-09-26 18:42:33 +0200 <ski> if you can check whether an index is a valid index in a list, i think you should be able to do it that way, as well
2020-09-26 18:42:48 +0200Izeau(~Izeau@2001:41d0:8:c493::)
2020-09-26 18:43:12 +0200 <ski> (and you would have to check that, without calling `length' on the list)
2020-09-26 18:43:23 +0200 <ski> hm
2020-09-26 18:43:39 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 18:44:25 +0200 <ski> i think i see one way you could do it .. using a library function, from the `Prelude'
2020-09-26 18:44:59 +0200 <ski> (alternatively, you could try diving into pattern-matching, at this point)
2020-09-26 18:45:00 +0200 <fluturel> ok, shoot
2020-09-26 18:45:22 +0200 <ski> consider the `!!' operator
2020-09-26 18:45:25 +0200 <ski> @type (!!)
2020-09-26 18:45:27 +0200 <lambdabot> [a] -> Int -> a
2020-09-26 18:45:49 +0200 <ski> the problem here is that this assumes that the given index is already valid
2020-09-26 18:46:00 +0200 <ski> > [2,3,5,7] !! 23
2020-09-26 18:46:01 +0200mnrmnaughmnrgle(~mnrmnaugh@unaffiliated/mnrmnaugh)
2020-09-26 18:46:04 +0200 <lambdabot> *Exception: Prelude.!!: index too large
2020-09-26 18:46:15 +0200 <fluturel> yeah, exactly
2020-09-26 18:46:29 +0200 <ski> so, you'd like to be able to detect whether an index is valid (without calling `length')
2020-09-26 18:46:39 +0200 <ski> do you know the `Maybe' data type ?
2020-09-26 18:47:19 +0200 <fluturel> heard about it. It's something like: maybe it's an int, maybe its Nothing
2020-09-26 18:47:25 +0200 <ski> yes
2020-09-26 18:47:36 +0200 <ski> it's something which you could possibly use here
2020-09-26 18:47:57 +0200 <ski> if you could define an operator, say `!!?', with a type signature
2020-09-26 18:48:05 +0200 <ski> (!!?) :: [a] -> Int -> Maybe a
2020-09-26 18:48:44 +0200 <ski> so that it looks up the value at the given index, if the index is valid, and otherwise tells the caller that there was no value to give back
2020-09-26 18:48:55 +0200 <ski> that could be one way
2020-09-26 18:49:14 +0200 <fluturel> but that would mean i need to catch the exception if it doesn't find anything there, right?
2020-09-26 18:49:20 +0200 <ski> then, after calling that, it'd tell you whether it succeeded in looking up, or not
2020-09-26 18:49:23 +0200 <ski> well
2020-09-26 18:49:39 +0200 <ski> `!!' gives an exception, in case the index is not valid
2020-09-26 18:49:45 +0200Izeau(~Izeau@2001:41d0:8:c493::) ()
2020-09-26 18:49:47 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 240 seconds)
2020-09-26 18:50:02 +0200 <fluturel> yeah
2020-09-26 18:50:09 +0200 <ski> however, the point here was that `!!?' would not give an exception then. but rather return an "error code", so to speak
2020-09-26 18:50:18 +0200fxg(~fxg@unaffiliated/fxg) (Ping timeout: 260 seconds)
2020-09-26 18:50:33 +0200 <ski> so, you wouldn't need any exception catching, just to check the result whether there's an `a' element there or not
2020-09-26 18:50:45 +0200 <fluturel> yeah, no, i understand that. I am querstioning what to do while implementing !!?
2020-09-26 18:51:07 +0200 <ski> anyway, you'd still need to define `!!?', somehow (possibly using a `Prelude' function, as i hinted at)
2020-09-26 18:51:27 +0200 <ski> and then, you'd need to figure out how to inspect the result of calling `!!?', in your `zip' version
2020-09-26 18:52:06 +0200 <ski> the alternative here, would be to directly call that `Prelude' function from `zip', skipping `!!?' altogether (so, skipping having to deal with `Maybe')
2020-09-26 18:52:21 +0200 <ski> but then you'd be dealing with more details, at the same time, perhaps
2020-09-26 18:52:42 +0200 <fluturel> this seems like way above my paygrade for now, but i will give it a shot, although i barely learned the basics in haskell by now
2020-09-26 18:52:45 +0200raehik(~raehik@cpc96984-rdng25-2-0-cust109.15-3.cable.virginm.net) (Ping timeout: 240 seconds)
2020-09-26 18:52:52 +0200 <fluturel> I will see what i can ddo
2020-09-26 18:53:17 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 256 seconds)
2020-09-26 18:53:25 +0200stef204(~stef204@unaffiliated/stef-204/x-384198)
2020-09-26 18:53:30 +0200elliott_(~elliott@pool-100-36-54-163.washdc.fios.verizon.net)
2020-09-26 18:53:49 +0200 <ski> to work with `Maybe' values, you could use `Nothing',`Just',`isJust',`fromJust'
2020-09-26 18:54:43 +0200 <ski> fluturel : would you like a hint for how you could check if an index is valid ?
2020-09-26 18:55:01 +0200retropikzel_(~Retropikz@dyvyf3fs8gw7zbnhkmk4y-4.rev.dnainternet.fi)
2020-09-26 18:55:09 +0200 <fluturel> when declarinf functions i saw you can write something like func :: Int -> Int -> Int. Which is the return type? The last one?
2020-09-26 18:55:20 +0200 <ski> yes, the last one
2020-09-26 18:55:27 +0200raehik(~raehik@cpc96984-rdng25-2-0-cust109.15-3.cable.virginm.net)
2020-09-26 18:55:49 +0200 <fluturel> I think I will do my research on that one, i need to get familiar with the docs. If I can't, i will come back here
2020-09-26 18:55:56 +0200 <fluturel> ok, thank you
2020-09-26 18:56:00 +0200skinods
2020-09-26 18:56:07 +0200knupfer(~Thunderbi@200116b82c2b4e000cf1902bacfcade4.dip.versatel-1u1.de) (Ping timeout: 260 seconds)
2020-09-26 18:56:19 +0200 <fluturel> how do you do that?
2020-09-26 18:56:25 +0200 <ski> hm, do what ?
2020-09-26 18:56:25 +0200 <fluturel> The nods thing
2020-09-26 18:56:31 +0200 <ski> /me nods
2020-09-26 18:56:48 +0200fluturellooks frightened at the documentation
2020-09-26 18:56:54 +0200 <fluturel> Awesome
2020-09-26 18:57:06 +0200 <ski> np
2020-09-26 18:58:46 +0200isovector1(~isovector@172.103.216.166)
2020-09-26 19:00:42 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 19:00:49 +0200 <ski> fluturel : hm, perhaps i should also mention that normally it's not a good idea to use `!!' on lists, unless they're fairly short. the point is that random-access in (singly) linked lists is not instant, it has to traverse the list from the start to the place in question
2020-09-26 19:01:17 +0200 <ski> so, generally, one'd work with lists in other ways .. or switching to another data-structure, if one wants more efficient random-access
2020-09-26 19:01:37 +0200 <ski> but since you're just learning the basics, it's okay to use `!!', for now
2020-09-26 19:01:40 +0200oisdk(~oisdk@2001:bb6:3329:d100:4c4c:f42f:20c9:6844)
2020-09-26 19:02:12 +0200TooDifficult(~TooDiffic@106.206.110.145) (Ping timeout: 272 seconds)
2020-09-26 19:02:43 +0200 <c_wraith> I can think of approximately one idiom where !! stays relevant, and even it is sketchy
2020-09-26 19:02:47 +0200 <fluturel> yeah, i heard that haskell uses linked lists and figured that !! is bad for obvious reasons, but as of now, i have no other clue how to do this little exercise i challenged myself with
2020-09-26 19:03:05 +0200 <c_wraith> but when you're starting out, as ski says. don't worry about it.
2020-09-26 19:04:15 +0200jedws(~jedws@121.209.139.222)
2020-09-26 19:04:15 +0200mu_(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 19:04:33 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 19:05:39 +0200 <ski> (hm, for `Maybe' values, `fromMaybe' could possibly also be nice to use. depending on how you structure your code)
2020-09-26 19:06:12 +0200v_m_v(~vm_v@2a02:aa12:3200:6480:f507:71a:9334:3099)
2020-09-26 19:06:20 +0200mmohammadi9812(~mmohammad@188.210.108.97) (Ping timeout: 256 seconds)
2020-09-26 19:06:24 +0200Saten-san(~Saten-san@ip-213-49-124-100.dsl.scarlet.be) (Quit: WeeChat 2.8)
2020-09-26 19:08:22 +0200 <c_wraith> ski: did you see the person asking for style advice last night who ended up refactoring a big Maybe value into being generated by a do block? I suggested it, and was happy it ended up working out so cleanly.
2020-09-26 19:09:10 +0200jedws(~jedws@121.209.139.222) (Ping timeout: 272 seconds)
2020-09-26 19:10:44 +0200keteskyl(~kelsey@2600:6c64:7b7f:fa42:2cda:1ff8:55be:a617) (Quit: WeeChat 2.8)
2020-09-26 19:10:49 +0200svipal(5baf3116@91-175-49-22.subs.proxad.net)
2020-09-26 19:11:23 +0200 <Boarders> does anyone know how with hakyll what delimiters I use for inline latex?
2020-09-26 19:11:25 +0200 <svipal> yo
2020-09-26 19:11:37 +0200 <Boarders> for display mode I use $$ [equations] $$
2020-09-26 19:12:02 +0200cole-h(~cole-h@c-73-48-197-220.hsd1.ca.comcast.net)
2020-09-26 19:13:02 +0200Jeanne-Kamikaze(~Jeanne-Ka@static-198-54-131-92.cust.tzulo.com)
2020-09-26 19:13:02 +0200stef204(~stef204@unaffiliated/stef-204/x-384198) (Quit: WeeChat 2.9)
2020-09-26 19:13:25 +0200 <ski> c_wraith : hm, i didn't see it. any paste link which might still be valid ?
2020-09-26 19:14:09 +0200 <c_wraith> it's just out of my scrollback on this computer. I'd have to go to the other one and check my browser history :)
2020-09-26 19:14:10 +0200mu_(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 19:14:10 +0200 <ski> (or approx. how many hours ago was it ?)
2020-09-26 19:14:12 +0200dhil(~dhil@11.29.39.217.dyn.plus.net)
2020-09-26 19:14:29 +0200 <c_wraith> so it was a bit over 10 hours ago
2020-09-26 19:14:33 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 19:15:54 +0200 <svipal> for some reason rtmidi ignores me changing the flags
2020-09-26 19:16:01 +0200 <svipal> in my stack.yaml
2020-09-26 19:16:07 +0200 <svipal> is it because it has external c bits
2020-09-26 19:17:17 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 19:17:33 +0200kelsey(~kelsey@2600:6c64:7b7f:fa42:2cda:1ff8:55be:a617)
2020-09-26 19:17:37 +0200 <ski> c_wraith : hm, seems to be <https://paste.tomsmeding.com/7AifjNEN>,<https://paste.tomsmeding.com/dfCZuFjh>,<https://paste.tomsmeding.com/MO0geafX> ?
2020-09-26 19:17:57 +0200kelseyGuest19180
2020-09-26 19:18:09 +0200 <c_wraith> yeah, those. The function in the third one is the rewrite
2020-09-26 19:18:13 +0200turion(~turion@ip5f5af77e.dynamic.kabel-deutschland.de) (Quit: Leaving.)
2020-09-26 19:18:41 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Remote host closed the connection)
2020-09-26 19:19:18 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 19:19:56 +0200Guest19180(~kelsey@2600:6c64:7b7f:fa42:2cda:1ff8:55be:a617) (Client Quit)
2020-09-26 19:20:20 +0200kelsey1(~kelsey@2600:6c64:7b7f:fa42:2cda:1ff8:55be:a617)
2020-09-26 19:21:48 +0200kelsey1keteskyl
2020-09-26 19:22:06 +0200 <ski> c_wraith : ah, yes. that does look quite nice :)
2020-09-26 19:22:22 +0200 <c_wraith> It's not often you get to do that, but I really enjoy when it works out.
2020-09-26 19:22:36 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-09-26 19:23:01 +0200 <ski> and the OP hopefully understood the use of `do' for `Maybe' here, and was pleased
2020-09-26 19:23:15 +0200keteskyl(~kelsey@2600:6c64:7b7f:fa42:2cda:1ff8:55be:a617) (Client Quit)
2020-09-26 19:23:30 +0200 <c_wraith> I mean, I suggested using a do block, but they did the rewrite themselves. Seemed plenty comfortable doing so.
2020-09-26 19:23:34 +0200kelsey1(~kelsey@2600:6c64:7b7f:fa42:2cda:1ff8:55be:a617)
2020-09-26 19:24:08 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 260 seconds)
2020-09-26 19:24:09 +0200mu_(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 19:24:33 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 19:24:47 +0200kelsey1(~kelsey@2600:6c64:7b7f:fa42:2cda:1ff8:55be:a617) (Client Quit)
2020-09-26 19:25:27 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 19:25:39 +0200skinods and smiles
2020-09-26 19:26:09 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 19:31:28 +0200 <ski> hm, i wonder what type of board game this is, whether there can be more than one empty position
2020-09-26 19:31:41 +0200 <ski> .. perhaps it's the "fifteen game"
2020-09-26 19:31:47 +0200chaosmasttter(~chaosmast@p200300c4a7105f0120adba39e14d4586.dip0.t-ipconnect.de) (Ping timeout: 240 seconds)
2020-09-26 19:32:10 +0200Igloo(~igloo@81.2.99.210)
2020-09-26 19:32:23 +0200 <ski> (`applyOffset' could possibly also have use of having the result in a `Maybe')
2020-09-26 19:33:22 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 256 seconds)
2020-09-26 19:34:28 +0200mu_(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 19:34:34 +0200mu__(~mu@unaffiliated/mu)
2020-09-26 19:35:10 +0200hiptobecubic(~john@unaffiliated/hiptobecubic) (Remote host closed the connection)
2020-09-26 19:36:49 +0200ystael(~ystael@209.6.50.55)
2020-09-26 19:37:37 +0200jb55(~jb55@gateway/tor-sasl/jb55) (Remote host closed the connection)
2020-09-26 19:39:14 +0200Turmfalke(~user@unaffiliated/siracusa)
2020-09-26 19:43:57 +0200hackageFrames-streamly 0.1.0.0 - A streamly layer for Frames I/O https://hackage.haskell.org/package/Frames-streamly-0.1.0.0 (adamCS)
2020-09-26 19:44:04 +0200mu__(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 19:44:34 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 19:48:26 +0200z0(~z0@bl15-165-108.dsl.telepac.pt) (Quit: Lost terminal)
2020-09-26 19:49:06 +0200oisdk(~oisdk@2001:bb6:3329:d100:4c4c:f42f:20c9:6844) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 19:49:14 +0200mmohammadi9812(~mmohammad@188.210.108.97)
2020-09-26 19:53:52 +0200 <nineonine> hey everyone
2020-09-26 19:54:04 +0200 <nineonine> I have a function for calculating binomial coefficient
2020-09-26 19:54:04 +0200mu_(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 19:54:15 +0200 <nineonine> binomCoef :: Double -> Double -> Double
2020-09-26 19:54:15 +0200 <nineonine> binomCoef n k
2020-09-26 19:54:15 +0200 <nineonine> | n < 2 = 0
2020-09-26 19:54:17 +0200 <nineonine> | otherwise = fact n / ((fact (n-k)) * (fact k))
2020-09-26 19:54:19 +0200 <nineonine> where fact m = product [1..m]
2020-09-26 19:54:31 +0200 <nineonine> so when I play with it in ghci it works fine
2020-09-26 19:54:39 +0200Achylles(~Achylles@200-161-190-140.dsl.telesp.net.br)
2020-09-26 19:54:41 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 19:54:52 +0200 <nineonine> so binomCoef 21 2 => 210.0
2020-09-26 19:55:11 +0200 <nineonine> but when it is used deep in my program it returns different result
2020-09-26 19:55:29 +0200 <nineonine> it returns -17.46593177669282 for exact same arguments
2020-09-26 19:55:32 +0200 <nineonine> I am puzzled
2020-09-26 19:55:46 +0200vicfred(~vicfred@unaffiliated/vicfred) (Quit: Leaving)
2020-09-26 19:55:46 +0200 <nineonine> so the question is
2020-09-26 19:55:49 +0200 <nineonine> why?
2020-09-26 19:56:58 +0200 <nineonine> note, that the first guard in the function is specific to the problem which I am trying to solve so please ignore it
2020-09-26 19:57:26 +0200 <nineonine> the actual calculation is in second GRHS
2020-09-26 19:57:44 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 19:57:51 +0200poljar(~poljar@93-139-70-179.adsl.net.t-com.hr) (Remote host closed the connection)
2020-09-26 19:58:10 +0200 <nineonine> it works fine up to 20
2020-09-26 19:58:18 +0200 <nineonine> after that it starts returning nonsense results
2020-09-26 19:58:47 +0200poljar(~poljar@93-139-70-179.adsl.net.t-com.hr)
2020-09-26 20:00:02 +0200rektide1(~rektide@84.39.117.57) ()
2020-09-26 20:00:24 +0200 <monochrom> Could you post the complete code that produced -17.46... ?
2020-09-26 20:00:27 +0200 <monochrom> @where paste
2020-09-26 20:00:27 +0200 <lambdabot> Help us help you: please paste full code, input and/or output at eg https://paste.tomsmeding.com
2020-09-26 20:00:57 +0200 <nineonine> here you go!
2020-09-26 20:00:57 +0200 <nineonine> https://paste.tomsmeding.com/SDUUcLFg
2020-09-26 20:01:00 +0200 <nineonine> thx!
2020-09-26 20:01:29 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net) (Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net)
2020-09-26 20:01:30 +0200laxask(~lax@unaffiliated/laxask)
2020-09-26 20:01:38 +0200laxasksudden
2020-09-26 20:01:43 +0200 <tomsmeding> nineonine: the inner binomCoef takes Int's
2020-09-26 20:01:49 +0200 <tomsmeding> that product [1..m] is going to overflow
2020-09-26 20:01:54 +0200 <nineonine> aha
2020-09-26 20:01:58 +0200mu_(~mu@unaffiliated/mu) (Quit: mu_)
2020-09-26 20:02:11 +0200 <nineonine> how do I fix it
2020-09-26 20:02:14 +0200 <monochrom> > product [1..21] :: Int
2020-09-26 20:02:16 +0200 <lambdabot> -4249290049419214848
2020-09-26 20:02:20 +0200 <tomsmeding> possible solutions: Integer instead of Int; Double instead of Int; use a different algorithm that isn't as susceptible to overflow :)
2020-09-26 20:02:21 +0200 <monochrom> Ah, like that.
2020-09-26 20:02:26 +0200 <fluturel> ski: are you still here?
2020-09-26 20:02:38 +0200 <ski> no
2020-09-26 20:02:46 +0200 <ski> i'm over there
2020-09-26 20:02:46 +0200ap5(~ap5@85.184.161.18) (Ping timeout: 256 seconds)
2020-09-26 20:02:47 +0200 <monochrom> Yeah using factorial for binom is the worst idea.
2020-09-26 20:02:53 +0200 <fluturel> i think i got it with pattern matching
2020-09-26 20:02:56 +0200 <monochrom> In multiple ways, not just this one.
2020-09-26 20:03:00 +0200 <ski> fluturel : okay ?
2020-09-26 20:03:01 +0200 <nineonine> what would be a better solution here?
2020-09-26 20:03:20 +0200 <tomsmeding> nineonine: e.g. https://math.stackexchange.com/a/927064/68044
2020-09-26 20:03:22 +0200 <fluturel> ski : you know, the zip' function
2020-09-26 20:03:46 +0200 <tomsmeding> wait no
2020-09-26 20:03:55 +0200 <ski> fluturel : yes, i didn't forget :)
2020-09-26 20:04:24 +0200 <ski> (i meant "okay ?", as in "well, let's hear about it ?")
2020-09-26 20:04:33 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 20:04:36 +0200 <monochrom> > product [1..21] :: Double
2020-09-26 20:04:38 +0200 <fluturel> zip' :: [a] -> [b] -> [(a,b)]
2020-09-26 20:04:38 +0200 <lambdabot> 5.109094217170944e19
2020-09-26 20:04:39 +0200 <fluturel> zip' (x:xs) (y:ys) = [(x,y)] ++ (zip' xs ys)
2020-09-26 20:04:39 +0200 <fluturel> zip' _ [] = []
2020-09-26 20:04:39 +0200 <fluturel> zip' [] _ = []
2020-09-26 20:04:53 +0200 <fluturel> How do i post multiline code
2020-09-26 20:05:14 +0200 <geekosaur> use a pastebin, ideally
2020-09-26 20:05:27 +0200 <geekosaur> @where paste
2020-09-26 20:05:28 +0200 <lambdabot> Help us help you: please paste full code, input and/or output at eg https://paste.tomsmeding.com
2020-09-26 20:05:29 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net)
2020-09-26 20:05:55 +0200 <dsal> fluturel: You could also use ;
2020-09-26 20:06:09 +0200rcdilorenzo(~rcdiloren@cpe-76-182-87-188.nc.res.rr.com) (Remote host closed the connection)
2020-09-26 20:06:13 +0200 <fluturel> ski: https://pastebin.com/JLshNdsN
2020-09-26 20:06:24 +0200 <fluturel> dsal: already made a pastebin, but thank you
2020-09-26 20:06:53 +0200 <dsal> ; is helpful if you want lambdabot to run the code. :)
2020-09-26 20:07:06 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 20:07:38 +0200 <ski> fluturel : yep, that looks fine :)
2020-09-26 20:07:50 +0200 <tomsmeding> nineonine: https://codeforces.com/blog/entry/55311 that's the algorithm that I know, I can try functionalising it
2020-09-26 20:07:50 +0200 <fluturel> ski: i vwas wondering if there is a better way to rewrite the last two lines. I mean,. they are the same thing, just in onecase the first list finishes its elements first
2020-09-26 20:08:13 +0200chaosmasttter(~chaosmast@p200300c4a7105f0120adba39e14d4586.dip0.t-ipconnect.de)
2020-09-26 20:08:16 +0200 <ski> fluturel : you could replace them with zip' _ _ = []
2020-09-26 20:08:19 +0200 <fluturel> or the other way around actually
2020-09-26 20:08:29 +0200 <ski> as long as that defining equation is after the recursive one
2020-09-26 20:08:33 +0200 <nineonine> tomsmeding, that would be great :)
2020-09-26 20:09:04 +0200HarveyPwca(~HarveyPwc@c-98-220-98-201.hsd1.il.comcast.net) (Quit: Leaving)
2020-09-26 20:09:12 +0200 <ski> fluturel : btw, the brackets around the recursive call are redundant. and you could use `:' in place of `++'
2020-09-26 20:09:35 +0200 <fluturel> ski: actually yeah, you are right. If it doesn't match with the first pattern, the second will catch it regardless and return an empty list
2020-09-26 20:09:44 +0200 <fluturel> ski: oh, didn't know that
2020-09-26 20:10:11 +0200justanotheruser(~justanoth@unaffiliated/justanotheruser)
2020-09-26 20:10:47 +0200 <fluturel> ski: just to clarify, which brackets? These: [(x,y)] ?
2020-09-26 20:11:25 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 246 seconds)
2020-09-26 20:11:27 +0200 <ski> fluturel : one argument for not replacing them like that would be that, the way you've written the defining equations, you could actually have them in any order. and you can understand them in isolation, as true statements about your function. but if you have the patterns in the base case overlap with the patterns in the recursive case, then you can't understand the base case in isolation
2020-09-26 20:11:36 +0200 <ski> fluturel : no, the round brackets
2020-09-26 20:11:39 +0200 <dsal> fluturel: (zip' xs ys)
2020-09-26 20:11:53 +0200 <ski> ("around the recursive call")
2020-09-26 20:11:55 +0200 <dsal> hlint will tell you things like that.
2020-09-26 20:12:26 +0200 <fluturel> is hlint for emacs a thing?
2020-09-26 20:12:32 +0200 <dsal> Just a cli tool
2020-09-26 20:12:42 +0200 <dsal> But probably.
2020-09-26 20:13:40 +0200acidjnk_new(~acidjnk@p200300d0c723789624d205acd1b15fd8.dip0.t-ipconnect.de)
2020-09-26 20:13:58 +0200Saten-san(~Saten-san@ip-213-49-124-100.dsl.scarlet.be)
2020-09-26 20:14:04 +0200 <ski> fluturel : .. but in some situations, one can replace a lot of extra cases, with just a single "catch-all"/"default" case, at the price of having overlapping cases
2020-09-26 20:14:15 +0200 <fluturel> I am going to look more into defining the !!? operator and working with Maybe, as i have something to learn from there, but i think this is the more elegant solution. Not gonna lie, i feel quite proud of it :)
2020-09-26 20:14:45 +0200 <nineonine> tomsmeding: btw, I used the solution from that SO answer and it seems to work fine. Many thanks again!
2020-09-26 20:14:46 +0200 <ski> yes, this is the idiomatic solution
2020-09-26 20:14:56 +0200 <nineonine> not SO, but SE
2020-09-26 20:15:20 +0200 <ski> fluturel : i was just thinking that, doing it without explicit pattern-matching, could possibly be an interesting exercise
2020-09-26 20:15:23 +0200 <fluturel> ski: i see what you mean, i guess for more complicated patterns, understanding them in isolation is better, but here overlapping them won't be such a burden for a reader
2020-09-26 20:15:39 +0200 <tomsmeding> nineonine: yes it does seem to work fine indeed; I'm kind of surprised that it does though
2020-09-26 20:15:40 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 272 seconds)
2020-09-26 20:15:47 +0200 <tomsmeding> also, it contains non-tail recursion, while this one doesn't: https://paste.tomsmeding.com/cj6pnnXi
2020-09-26 20:15:51 +0200 <ski> (btw, of course `!!' itself is defined, using pattern-matching. and the function you'd call from `!!?' also would be)
2020-09-26 20:15:53 +0200 <tomsmeding> but feel free to use the SE one :p
2020-09-26 20:16:00 +0200 <nineonine> will do, thx :D
2020-09-26 20:16:13 +0200 <tomsmeding> (oh not choose2 but binomCoef of course)
2020-09-26 20:16:27 +0200 <nineonine> I don't quite understand though why isn't it included in base
2020-09-26 20:16:35 +0200 <nineonine> it seems somewhat useful sometimes
2020-09-26 20:16:52 +0200 <nineonine> maybe because it is extremely inefficient? dunno
2020-09-26 20:17:20 +0200 <dsal> base is too big. Things in base should be very useful all the time.
2020-09-26 20:17:44 +0200 <nineonine> I agree
2020-09-26 20:17:55 +0200 <tomsmeding> there is also not really a canonical implementation
2020-09-26 20:18:15 +0200 <tomsmeding> the overflow problem can be solved by either going to Integer or to Double, but people won't expect that
2020-09-26 20:18:24 +0200 <tomsmeding> since the algorithm can overflow before the correct answer would
2020-09-26 20:18:32 +0200 <dsal> Or Scientific!
2020-09-26 20:18:44 +0200 <fluturel> ski: is !! defined recursively with pattern matching as well? That would make sense, but i thought it would be a built-in or something, written directly in the target language in the compiler to make it faster. I may be spewing nonsense, but it is what i thought
2020-09-26 20:19:09 +0200 <ski> fluturel : yes
2020-09-26 20:19:13 +0200 <ski> it's not built-in
2020-09-26 20:19:25 +0200 <ski> just a library operation, defined in Haskell
2020-09-26 20:19:26 +0200 <dsal> @fluturel There's a source link in the doc pages. !! is a bit fancy: https://hackage.haskell.org/package/base-4.14.0.0/docs/src/GHC.List.html#%21%21
2020-09-26 20:19:26 +0200 <lambdabot> Unknown command, try @list
2020-09-26 20:19:26 +0200 <dolio> I've never needed binomial coefficients in my programs in like 15 years of writing Haskell.
2020-09-26 20:19:30 +0200 <dolio> Maybe that's why it's not in base.
2020-09-26 20:19:32 +0200 <dsal> @src (!!)
2020-09-26 20:19:32 +0200 <lambdabot> xs !! n | n < 0 = undefined
2020-09-26 20:19:32 +0200 <lambdabot> [] !! _ = undefined
2020-09-26 20:19:32 +0200 <lambdabot> (x:_) !! 0 = x
2020-09-26 20:19:32 +0200 <lambdabot> (_:xs) !! n = xs !! (n-1)
2020-09-26 20:19:39 +0200geekosaur(42d52102@66.213.33.2) (Ping timeout: 245 seconds)
2020-09-26 20:19:49 +0200 <dsal> lambdabot's @src will show you a simple, idealized implementation, but not necessarily what GHC will do.
2020-09-26 20:20:58 +0200hackageconfig-value 0.8 - Simple, layout-based value language similar to YAML or JSON https://hackage.haskell.org/package/config-value-0.8 (EricMertens)
2020-09-26 20:21:22 +0200 <fluturel> dsal: i'm having a bit of trouble with the src there, but i get the gist
2020-09-26 20:21:53 +0200 <dsal> foldr has a few magic bits that takes intuition a bit of time to catch up with.
2020-09-26 20:22:18 +0200 <fluturel> i didn't get to foldr yet
2020-09-26 20:22:22 +0200 <dsal> That's why @src shows you a trivial, functionally equivalent version. :)
2020-09-26 20:22:34 +0200 <ski> `| k > n = undefined' ought to be `| k > n = 0', arguably
2020-09-26 20:22:45 +0200 <dsal> I use foldr a *lot*, but foldr + laziness means you can fold infinite lists meaningfully.
2020-09-26 20:22:47 +0200 <fluturel> @src foldr
2020-09-26 20:22:47 +0200 <lambdabot> foldr f z [] = z
2020-09-26 20:22:47 +0200 <lambdabot> foldr f z (x:xs) = f x (foldr f z xs)
2020-09-26 20:23:27 +0200 <dsal> foldr is like, the default catamorphism. If you have a bunch of stuff and you want some kind of potentially smaller transformation of it, that's foldr.
2020-09-26 20:23:32 +0200 <oats> I forget, is foldl the one that's discouraged, or foldr
2020-09-26 20:23:45 +0200 <dsal> The problem with *that* foldr implementation is that it works in far fewer cases than the real one.
2020-09-26 20:23:48 +0200 <c_wraith> generally you want foldl' instead of foldl
2020-09-26 20:23:51 +0200 <dsal> oats: foldl should basically never be used.
2020-09-26 20:24:00 +0200 <oats> that's what I thought
2020-09-26 20:24:00 +0200 <fluturel> dsal: why?
2020-09-26 20:24:11 +0200 <dsal> fluturel: why which?
2020-09-26 20:24:26 +0200 <fluturel> dsal: why should foldl nver be used?
2020-09-26 20:24:28 +0200hackageconfig-schema 1.2.1.0 - Schema definitions for the config-value package https://hackage.haskell.org/package/config-schema-1.2.1.0 (EricMertens)
2020-09-26 20:24:49 +0200 <dsal> fluturel: Oh, just dumb behavior. foldl' is what you want if you think you want foldl most of the time. foldr is the default, though.
2020-09-26 20:25:06 +0200 <oats> https://github.com/hasura/graphql-engine/pull/2933#discussion_r328821960
2020-09-26 20:25:10 +0200 <dsal> foldl' is strict on the accumulator. foldl has to build up a giangantic thunk before doing anything.
2020-09-26 20:25:50 +0200 <oats> tldr, foldl is too lazy and leaks memory
2020-09-26 20:25:59 +0200 <fluturel> foldr is kind of like reduce in CL?
2020-09-26 20:26:23 +0200 <dsal> fold, foldl, foldr, etc... are all that type of catamorphism, yeah.
2020-09-26 20:26:25 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Remote host closed the connection)
2020-09-26 20:26:36 +0200 <dsal> :t foldr -- the real foldr works on a lot more than lists, though.
2020-09-26 20:26:36 +0200HarveyPwca(~HarveyPwc@2601:246:c180:a570:29df:3b00:ad0e:3a06)
2020-09-26 20:26:37 +0200 <lambdabot> Foldable t => (a -> b -> b) -> b -> t a -> b
2020-09-26 20:27:06 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 20:27:10 +0200 <fluturel> so anything that belongs to the Foldable typeclass
2020-09-26 20:27:18 +0200 <dsal> "has an instance of" yeah
2020-09-26 20:27:29 +0200 <oats> “When the accumulation function is strict, use foldl' to consume the list in constant space, since the whole list is going to have to be traversed, anyway.
2020-09-26 20:27:38 +0200 <oats> When the accumulation function is lazy in its second argument, use foldr to do work incrementally to improve streaming and work-saving.
2020-09-26 20:27:40 +0200 <dsal> You can make a thing, make your thing foldable, and a *lot* of functionality comes about for free.
2020-09-26 20:27:40 +0200 <oats>
2020-09-26 20:28:14 +0200raehik(~raehik@cpc96984-rdng25-2-0-cust109.15-3.cable.virginm.net) (Ping timeout: 258 seconds)
2020-09-26 20:28:15 +0200 <dsal> :t sum -- e.g., you get stuff like this for free
2020-09-26 20:28:17 +0200 <lambdabot> (Foldable t, Num a) => t a -> a
2020-09-26 20:29:10 +0200 <fluturel> what is "t a"? Why is there no `->` inbetween?
2020-09-26 20:29:27 +0200hackagehookup 0.5 - Abstraction over creating network connections with SOCKS5 and TLS https://hackage.haskell.org/package/hookup-0.5 (EricMertens)
2020-09-26 20:30:00 +0200 <fluturel> sorry for my very beginner questions :)
2020-09-26 20:30:39 +0200 <{abby}> fluturel: `t a` is the type constructor `t` applied to the type `a`; if you set (for example) t = Maybe then you get `Maybe a`, for t = [] (lists) you get `[] a` (commonly spelled `[a]`), etc
2020-09-26 20:31:25 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 240 seconds)
2020-09-26 20:31:32 +0200 <dsal> You can colloquially read that as a "Foldable (thing of) Num" if you're being extra lazy.
2020-09-26 20:31:45 +0200rcdilorenzo(~rcdiloren@cpe-76-182-87-188.nc.res.rr.com)
2020-09-26 20:31:47 +0200 <fluturel> so t is a container of some sorts (or can be, for a type a)
2020-09-26 20:31:47 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-09-26 20:32:09 +0200justan0theruser(~justanoth@unaffiliated/justanotheruser)
2020-09-26 20:32:11 +0200 <ski> fluturel : yes. `t' specifies some kind of "container", and `a' the "element type", there
2020-09-26 20:32:21 +0200 <dsal> "Container" is often a lazy way to look at some of these things. It doesn't need to be a container per se, just Foldable.
2020-09-26 20:33:08 +0200 <ski> fluturel : and no worry, beginner questions are welcome in here
2020-09-26 20:33:58 +0200fresheyeball(~isaac@c-71-237-105-37.hsd1.co.comcast.net) (Quit: WeeChat 2.7.1)
2020-09-26 20:34:07 +0200justanotheruser(~justanoth@unaffiliated/justanotheruser) (Ping timeout: 240 seconds)
2020-09-26 20:34:14 +0200 <{abby}> dsal: I'd agree if we were talking about Monad & co but I honestly don't see a problem with referring to instances of Foldable as "containers"
2020-09-26 20:34:30 +0200 <fraktor> What is a foldable that is not also a container?
2020-09-26 20:34:48 +0200 <dsal> I can make a dumb obligatory example, but it's kind of pointless.
2020-09-26 20:34:49 +0200 <c_wraith> yeah... unlike many things, Foldable must actually contain (0 or more) values of a particular type
2020-09-26 20:34:59 +0200_vaibhavingale_(~Adium@203.188.228.27) (Ping timeout: 240 seconds)
2020-09-26 20:35:00 +0200 <dsal> If it's Foldable, it's probably containing things.
2020-09-26 20:35:05 +0200 <ski> (`Const c' is an "always empty" container type)
2020-09-26 20:36:05 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 20:38:28 +0200 <ski> fluturel : in the type `[Int]', which is more uniformly spelled as `[] Int', you can read `[]' as "list of". it specifies the type of container. but you can't have e.g. `foo :: []'. `foo' can't have type "list of", it must be a list of something (some type to use as element type)
2020-09-26 20:39:40 +0200 <ski> you could say that `[]', and other similar things, like `Maybe',`Either',`Map',`IO' are "incomplete types", requires one to specify some more type(s) after it, to get a concrete type, that you could use as the type of a value (perhaps an input value to, or an output value from, a function)
2020-09-26 20:40:31 +0200 <ski> one could also call these "parameterized types", or "type functions" (not to be confused with "function types", which are types of the shape `.. -> ..', like e.g. `[a] -> Int' or `Int -> [a] -> [a]')
2020-09-26 20:41:00 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 272 seconds)
2020-09-26 20:41:24 +0200v_m_v(~vm_v@2a02:aa12:3200:6480:f507:71a:9334:3099) (Remote host closed the connection)
2020-09-26 20:41:29 +0200 <ski> `[]' is like a function that consumes not values, but types (ordinary, concrete types, not type functions). so, if you pass it the type `Int', you get back the type of lists of `Int's
2020-09-26 20:44:52 +0200 <monochrom> It is useful to first look at "Maybe Int" syntactically and break it into the Maybe-ness and the Int-ness.
2020-09-26 20:45:17 +0200oisdk(~oisdk@2001:bb6:3329:d100:4c4c:f42f:20c9:6844)
2020-09-26 20:45:19 +0200 <monochrom> And then to also find in in horror that "[] Int" is legal syntax, too. That will put things in perspectives.
2020-09-26 20:46:21 +0200 <dsal> Why can't I use MayIntBe ?
2020-09-26 20:46:31 +0200dsalis angered by haskell's inconsistent syntax
2020-09-26 20:46:36 +0200 <monochrom> Haskell takes seriously the idea of isolating out the Maybe-ness, the []-ness. Other languages don't, and that's where they run into a severe limitation.
2020-09-26 20:47:12 +0200 <monochrom> Oh, for general mixfix syntax, please refer to Agda. >:)
2020-09-26 20:47:48 +0200oab(~oab@214.92-220-221.customer.lyse.net)
2020-09-26 20:48:21 +0200 <monochrom> User-definable mixfix could be a nice addition the next time the Haskell report is updated.
2020-09-26 20:48:31 +0200 <dolio> Agda doesn't let you arbitrarily divide tokens that weren't defined that way, though.
2020-09-26 20:48:41 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 20:49:00 +0200 <dolio> Mixfix design is a huge mess of tradeoffs, too.
2020-09-26 20:49:02 +0200 <monochrom> Yeah, not MayIntBe per se, but perhaps ^Int$
2020-09-26 20:49:22 +0200 <dolio> Like, you can't write `(a, b, c)` in Agda.
2020-09-26 20:49:48 +0200 <dolio> For tuples.
2020-09-26 20:50:14 +0200 <monochrom> Haskell 2050 will use GPT-5 to learn your favourite syntax from a corpus you provide! >:)
2020-09-26 20:51:02 +0200 <davve> i want brainf*ck
2020-09-26 20:51:04 +0200 <monochrom> "I'm done with manually changing the GHC grammar." -- SPJ in 2049.
2020-09-26 20:51:15 +0200Amras(~Amras@unaffiliated/amras0000)
2020-09-26 20:52:21 +0200 <monochrom> "I have found a way to integrate GPT-5 into the GHC parser. Committed in HEAD." -- Simon Marlow in 2050
2020-09-26 20:52:39 +0200 <dolio> I mean, I like Agda, but I wouldn't say its syntax is categorically better than Haskell's. It's just nice and not nice in different ways.
2020-09-26 20:53:20 +0200 <monochrom> I am wary of mixfix, actually
2020-09-26 20:53:45 +0200 <dolio> I think it might be bad for Haskell, actually.
2020-09-26 20:54:10 +0200 <dolio> Because you'd get people attempting really complicated mixfix syntax hacks like they do with type programming.
2020-09-26 20:54:24 +0200 <monochrom> haha
2020-09-26 20:54:24 +0200mu_(~mu@unaffiliated/mu) (Read error: Connection reset by peer)
2020-09-26 20:54:28 +0200directhex1(~directhex@195.206.169.184)
2020-09-26 20:54:29 +0200 <dolio> Struggling to get them to parse unambiguously.
2020-09-26 20:54:32 +0200 <monochrom> Yes
2020-09-26 20:55:04 +0200mu_(~mu@unaffiliated/mu)
2020-09-26 20:55:09 +0200geekosaur(42d52102@66.213.33.2)
2020-09-26 20:55:35 +0200 <fluturel> i wonder if there is a brainfuck channel. Brb
2020-09-26 20:55:42 +0200fluturel(~fluturel@82.137.14.51) (Quit: leaving)
2020-09-26 20:56:05 +0200 <monochrom> Hrm, they don't need to quit one channel to explore others.
2020-09-26 20:56:49 +0200fluturel(~fluturel@82.137.14.51)
2020-09-26 20:56:54 +0200 <fluturel> there is, but no one is on it
2020-09-26 20:57:13 +0200 <dolio> Joining any channel will create it.
2020-09-26 20:57:18 +0200 <monochrom> "Curiosity kills the cat. Dissatisfaction brings it back!"
2020-09-26 20:57:46 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 20:58:05 +0200 <fluturel> dolio: that's a bummer
2020-09-26 20:58:18 +0200fluturelis disappointed
2020-09-26 20:58:31 +0200 <monochrom> Maybe under another name.
2020-09-26 20:58:49 +0200mu_(~mu@unaffiliated/mu) (Client Quit)
2020-09-26 20:58:50 +0200 <dolio> Yeah, did you do the double hash version? It's what they want 'non-official' channels to be named nowadays.
2020-09-26 20:58:53 +0200 <monochrom> At least try all 4 possibilities: #brainfuck, ##brainfuck, #bf, ##bf
2020-09-26 20:59:32 +0200 <fluturel> i did not
2020-09-26 20:59:35 +0200 <fluturel> will do
2020-09-26 20:59:48 +0200fluturel(~fluturel@82.137.14.51) (Client Quit)
2020-09-26 21:00:13 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 21:00:43 +0200wroathe(~wroathe@c-73-24-27-54.hsd1.mn.comcast.net)
2020-09-26 21:00:50 +0200sand_dull(~theuser@185.217.69.182)
2020-09-26 21:02:04 +0200oisdk(~oisdk@2001:bb6:3329:d100:4c4c:f42f:20c9:6844) (Quit: My MacBook has gone to sleep. ZZZzzz…)
2020-09-26 21:02:25 +0200 <outer_passage> is it possible to have cabal show all ghc warnings for a project without recompiling the whole thing?
2020-09-26 21:02:57 +0200hnOsmium0001(uid453710@gateway/web/irccloud.com/x-lzobmyeruzzsqioe)
2020-09-26 21:03:15 +0200fluturel(~fluturel@82.137.14.51)
2020-09-26 21:03:24 +0200retropikzel_(~Retropikz@dyvyf3fs8gw7zbnhkmk4y-4.rev.dnainternet.fi) (Quit: Leaving)
2020-09-26 21:03:25 +0200 <fluturel> couldn't find anything
2020-09-26 21:03:57 +0200 <fluturel> although #bf was kinda weird, seems like it existed already
2020-09-26 21:04:14 +0200 <tomsmeding> fluturel: you don't have to leave one channel to join another ;)
2020-09-26 21:04:52 +0200 <tomsmeding> evidently there is one (1) person in ##brainfuck
2020-09-26 21:05:25 +0200 <tomsmeding> outer_passage: if with "the whole thing" you mean your project, and not the dependencies, then no
2020-09-26 21:05:27 +0200 <fluturel> i know, but i can't be bothered to remember how to open multiple tabs and navigate through them. I haven't used irssi in a long long time
2020-09-26 21:05:51 +0200 <tomsmeding> because ghc doesn't produce the warnings if it isn't told to do so, and if you don't turn on warning in a project, cabal will not tell ghc to produce warnings at all
2020-09-26 21:06:18 +0200 <tomsmeding> fluturel: there are other irc clients :)
2020-09-26 21:06:23 +0200kuribas(~user@ptr-25vy0i7b1r54f1gv0vq.18120a2.ip6.access.telenet.be) (Quit: ERC (IRC client for Emacs 26.3))
2020-09-26 21:07:19 +0200kenran(~maier@mue-88-130-62-149.dsl.tropolys.de)
2020-09-26 21:07:40 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 21:11:00 +0200v_m_v(~vm_v@2a02:aa12:3200:6480:f507:71a:9334:3099)
2020-09-26 21:12:41 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-09-26 21:14:06 +0200raehik(~raehik@cpc96984-rdng25-2-0-cust109.15-3.cable.virginm.net)
2020-09-26 21:17:01 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 264 seconds)
2020-09-26 21:17:45 +0200marmalodak(~marmaloda@c-73-202-176-57.hsd1.ca.comcast.net) (Quit: WeeChat 2.8)
2020-09-26 21:18:49 +0200oab(~oab@214.92-220-221.customer.lyse.net) ("Killed buffer")
2020-09-26 21:19:47 +0200knupfer(~Thunderbi@200116b82c2b4e00f43aaefffe71283d.dip.versatel-1u1.de)
2020-09-26 21:19:47 +0200knupfer(~Thunderbi@200116b82c2b4e00f43aaefffe71283d.dip.versatel-1u1.de) (Client Quit)
2020-09-26 21:19:58 +0200knupfer(~Thunderbi@200116b82c2b4e00d8f25cb26cf0082b.dip.versatel-1u1.de)
2020-09-26 21:20:01 +0200sand_dull(~theuser@185.217.69.182) (Ping timeout: 246 seconds)
2020-09-26 21:20:54 +0200svipal(5baf3116@91-175-49-22.subs.proxad.net) (Ping timeout: 245 seconds)
2020-09-26 21:21:11 +0200machinedgod(~machinedg@24.105.81.50)
2020-09-26 21:21:28 +0200 <ski> fluturel : "<monochrom> Hrm, they don't need to quit one channel to explore others."
2020-09-26 21:22:22 +0200 <ski> hm, you can use `Alt-2',`Alt-3' to switch between your channels, i think
2020-09-26 21:23:17 +0200 <geekosaur> there's also things like webchat.freenode.net where the channel tabs are graphical
2020-09-26 21:24:52 +0200justan0theruser(~justanoth@unaffiliated/justanotheruser) (Ping timeout: 260 seconds)
2020-09-26 21:25:21 +0200 <fluturel> ski: i remembered that as well, but those bindings are for switching between my terminal tabs, so no good. Typing /win <num> seems to work
2020-09-26 21:26:00 +0200 <ski> or `<esc> 2',`<esc> 3'
2020-09-26 21:27:15 +0200skialso bound `Alt-p' and `Alt-n' to previous and next. possibly you can already use `Alt' with arrow keys (left and right), too
2020-09-26 21:28:26 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net) (Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net)
2020-09-26 21:30:21 +0200Lycurgus(~niemand@98.4.96.130)
2020-09-26 21:30:22 +0200psutcliffe(~psutcliff@2a00:801:42d:ae17:bde1:9f2f:16be:1acb) (Quit: Leaving)
2020-09-26 21:31:31 +0200 <dsal> Since MarcelineVQ shamed me for not writing a README, I wrote one real quick: https://github.com/dustin/gopro
2020-09-26 21:31:58 +0200 <davean> fluturel: how are you managing to join a channel without it automaticly creating a tab?
2020-09-26 21:32:11 +0200 <davean> I wouldn't know how to do what you seem to be doing
2020-09-26 21:33:22 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net)
2020-09-26 21:35:14 +0200 <dsal> I realized when documenting this that a prospective user might be pretty sad when trying to bring this up and having to learn how to modify the database to point to different S3 bucket, and like, know how to use S3 and stuff. But I'll wait for a user, I guess. heh
2020-09-26 21:36:04 +0200snakemasterflex(~snakemast@213.100.206.23)
2020-09-26 21:36:45 +0200lyxia(~lyxia@poisson.chat) (Quit: WeeChat 2.8)
2020-09-26 21:38:02 +0200kenran(~maier@mue-88-130-62-149.dsl.tropolys.de) (Ping timeout: 256 seconds)
2020-09-26 21:39:10 +0200lyxia(~lyxia@poisson.chat)
2020-09-26 21:40:02 +0200Majiir(~Majiir@2601:18c:ca00:a400:211:32ff:fe42:6eda) (Quit: CUT THE HARDLINES!!)
2020-09-26 21:40:29 +0200_vaibhavingale_(~Adium@203.188.228.27)
2020-09-26 21:40:39 +0200 <fluturel> davean: i just did it the dumb way. Closing irssi and opening it again
2020-09-26 21:40:54 +0200fluturelis stupid
2020-09-26 21:41:23 +0200Lycurgusclaps 'is hands
2020-09-26 21:41:28 +0200 <davean> fluturel: I didn't even realize you could join a channel like that.
2020-09-26 21:41:51 +0200 <ski> `/join #bf' should work, to join that channel
2020-09-26 21:42:28 +0200 <ski> davean : how i did it, with ircII, initially
2020-09-26 21:42:49 +0200 <fluturel> ski: it does, but i didn't know how to get back to the haskell tab
2020-09-26 21:43:20 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 21:44:02 +0200 <fluturel> my lazyness only rivals Haskell's
2020-09-26 21:44:06 +0200Guest_84(59401d45@89-64-29-69.dynamic.chello.pl)
2020-09-26 21:44:07 +0200ericsagnes(~ericsagne@2405:6580:0:5100:45be:1ab8:9d1a:eec6) (Ping timeout: 240 seconds)
2020-09-26 21:44:39 +0200fxg(~fxg@unaffiliated/fxg)
2020-09-26 21:44:43 +0200Guest_84(59401d45@89-64-29-69.dynamic.chello.pl) (Remote host closed the connection)
2020-09-26 21:44:56 +0200 <sm[m]> dsal++ !
2020-09-26 21:45:48 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 21:46:28 +0200hackagex86-64bit 0.4.6.1 - Runtime code generation for x86 64 bit machine code https://hackage.haskell.org/package/x86-64bit-0.4.6.1 (PeterDivianszky)
2020-09-26 21:46:51 +0200 <fluturel> Say, if I have two generic types in a function declaration, they can be the same when i use the function, right?
2020-09-26 21:47:01 +0200flex14(~flex14@2601:280:c780:7ea0:d233:9ddf:c010:c113)
2020-09-26 21:47:27 +0200 <fluturel> sum' :: (Num a, Num b) => [a] -> b
2020-09-26 21:47:31 +0200 <geekosaur> they can be, but you can't know what they are so you can't check for the specific case where they're the same
2020-09-26 21:47:31 +0200 <koz_> fluturel: If you mean something like 'f :: a -> b -> a', yes, it is possible to have a and b both be the same type.
2020-09-26 21:47:55 +0200 <koz_> The only difference that use of a different type variable makes is that the types are _allowed_ to be different.
2020-09-26 21:47:59 +0200 <koz_> (not forced)
2020-09-26 21:48:06 +0200 <geekosaur> and that particular signature looks like a problem to me, tbh
2020-09-26 21:48:10 +0200 <fluturel> yeah, that's what i thought as well
2020-09-26 21:48:26 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net) (Quit: Free ZNC ~ Powered by LunarBNC: https://LunarBNC.net)
2020-09-26 21:48:27 +0200 <fluturel> but ghci complains and i can't figure out why
2020-09-26 21:48:35 +0200fxg(~fxg@unaffiliated/fxg) (Client Quit)
2020-09-26 21:48:38 +0200 <koz_> fluturel: What exact complaint are you seeing?
2020-09-26 21:48:39 +0200 <dsal> fluturel: what's the complaint?
2020-09-26 21:48:46 +0200 <geekosaur> :t (+)
2020-09-26 21:48:48 +0200 <lambdabot> Num a => a -> a -> a
2020-09-26 21:48:49 +0200 <koz_> geekosaur is right that the signature looks suspect.
2020-09-26 21:49:06 +0200 <fluturel> Couldn't match expected type 'b' with type 'a'
2020-09-26 21:49:15 +0200 <monochrom> "use the function" is the opposite of "implement the function"
2020-09-26 21:49:18 +0200 <dsal> That makes sense. Where would b come from?
2020-09-26 21:49:19 +0200vicfred(~vicfred@unaffiliated/vicfred)
2020-09-26 21:49:24 +0200 <fluturel> and then some more lines about 'a' and 'b' being rigid types
2020-09-26 21:49:25 +0200Tuplanolla(~Tuplanoll@91-159-68-239.elisa-laajakaista.fi)
2020-09-26 21:49:34 +0200 <monochrom> Everything the user can do, the implementer cannot.
2020-09-26 21:49:45 +0200Lycurgus(~niemand@98.4.96.130) (Quit: Exeunt)
2020-09-26 21:49:50 +0200 <geekosaur> you told the compiler they *could* be different. then you presumably used (+)
2020-09-26 21:49:52 +0200 <geekosaur> :t (+)
2020-09-26 21:49:54 +0200 <lambdabot> Num a => a -> a -> a
2020-09-26 21:50:09 +0200 <koz_> Which says 'the types gotta be the same, yo'.
2020-09-26 21:50:25 +0200 <fluturel> Well, i thought that since i am summing things of type a in a list of type [a], the ghci can finfer that the output is b, but it can't
2020-09-26 21:50:38 +0200 <koz_> fluturel: How does it do that exactly?
2020-09-26 21:50:40 +0200 <dsal> Well, you're specifically saying it can be any type as long as it's a Num
2020-09-26 21:50:49 +0200 <koz_> Suppose a ~ Int and b ~ some matrix type?
2020-09-26 21:51:10 +0200 <koz_> How exactly do you go from 'an Int produced by summing other Ints' to 'some matrix type'?
2020-09-26 21:51:24 +0200 <fluturel> well, you can't..
2020-09-26 21:51:25 +0200aplainzetakind(~johndoe@captainludd.powered.by.lunarbnc.net)
2020-09-26 21:51:37 +0200falafel_(~falafel@2605:e000:1527:d491:f090:20fe:cddf:2a1a)
2020-09-26 21:51:45 +0200 <geekosaur> but that's what you told it with that signature
2020-09-26 21:51:45 +0200 <koz_> fluturel: But your signature says that you can.
2020-09-26 21:51:53 +0200 <koz_> So GHC is disagreeing with the signature.
2020-09-26 21:52:11 +0200 <fluturel> I see
2020-09-26 21:52:17 +0200 <koz_> (I think I owe geekosaur a soda, lol)
2020-09-26 21:52:41 +0200Majiir(~Majiir@2601:18c:ca00:a400:211:32ff:fe42:6eda)
2020-09-26 21:54:05 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 240 seconds)
2020-09-26 21:54:24 +0200Saten-san(~Saten-san@ip-213-49-124-100.dsl.scarlet.be) (Quit: WeeChat 2.9)
2020-09-26 21:54:55 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 21:55:03 +0200 <dsal> I set up github actions for all my haskell projects, and then at some point, all of them started failing.
2020-09-26 21:55:30 +0200 <fluturel> let's say the function doesn't do a sum, but it does something else depending on the input. Let's say if it gets an empty list, it returns a double (for some reason). Then it wouldn't complain anymore, would it? Because it sees that in certain cases, b is the same as a, an int, but sometimes it isn't, so my signature would be correct
2020-09-26 21:56:35 +0200 <geekosaur> with respect to a type signature, your implementation does not choose the types; the caller does
2020-09-26 21:56:39 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt) (Remote host closed the connection)
2020-09-26 21:56:57 +0200ericsagnes(~ericsagne@2405:6580:0:5100:b877:8b34:4984:caf9)
2020-09-26 21:57:06 +0200 <geekosaur> so your signature tells a caller that it can request a Double result from an [Int], for example
2020-09-26 21:57:28 +0200 <koz_> fluturel: The best way to think of a signature like that (namely, with type variables) is that the caller of the function is allowed to set those variables to be anything, provided those things are both instances of Num.
2020-09-26 21:57:36 +0200 <geekosaur> your implementation, on the other hand, does not get to pick Double for an empty list or Int otherwise; it has to be the same type in both cases
2020-09-26 21:57:45 +0200 <koz_> Therefore, you as the _implementer_ must, in all cases, accomodate absolutely any such choice, now and forever.
2020-09-26 21:58:03 +0200 <koz_> Having it work _some of the time_ or for _some choices_ of arguments or types isn't sufficient.
2020-09-26 21:58:13 +0200 <koz_> Essentially, this is a contract between you and your caller.
2020-09-26 21:58:21 +0200 <ski> @quote freedom.is
2020-09-26 21:58:21 +0200 <lambdabot> monochrom says: in fact, freedom is the freedom to write 2.2 = 4
2020-09-26 21:58:23 +0200 <ski> @quote freedom.is
2020-09-26 21:58:24 +0200 <lambdabot> monochrom says: in fact, freedom is the freedom to write 2.2 = 4
2020-09-26 21:58:28 +0200 <ski> hm
2020-09-26 21:58:32 +0200 <koz_> Which says 'as long as you ensure that a and b are both instances of Num, then I will have this work'.
2020-09-26 21:58:41 +0200 <ski> @quote freedom.is.your
2020-09-26 21:58:41 +0200 <lambdabot> monochrom says: Programming is a dialectic class struggle between the author and the user. My freedom is your slavery. Your ignorance is my strength.
2020-09-26 21:58:47 +0200 <sm[m]> dsal: stack casa timeouts ? this was affecting folks recently
2020-09-26 21:58:47 +0200 <koz_> And therefore, those facts are the only things you are allowed to use.
2020-09-26 21:59:33 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 260 seconds)
2020-09-26 21:59:46 +0200 <dsal> I don't even quite understand. It's been this way for a month or so. I got it all set up and then it all broke and I've just not gone into figuring it out. I figured if all of them were broken, it might work itself out.
2020-09-26 22:00:07 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 240 seconds)
2020-09-26 22:00:11 +0200shad0w_(~shad0w_@160.202.37.29) (Ping timeout: 246 seconds)
2020-09-26 22:01:40 +0200dhil(~dhil@11.29.39.217.dyn.plus.net) (Ping timeout: 246 seconds)
2020-09-26 22:02:29 +0200chaosmasttter(~chaosmast@p200300c4a7105f0120adba39e14d4586.dip0.t-ipconnect.de) (Quit: WeeChat 2.9)
2020-09-26 22:02:43 +0200 <int-e> oh monochrom... but what if the user is also the programmer?
2020-09-26 22:02:52 +0200 <ski> > (2 . 2) 4
2020-09-26 22:02:54 +0200 <lambdabot> 2
2020-09-26 22:03:10 +0200 <int-e> that Num instance again :-(
2020-09-26 22:03:34 +0200 <int-e> @undef
2020-09-26 22:03:35 +0200 <lambdabot> Undefined.
2020-09-26 22:06:06 +0200 <fluturel> koz_ : I understand what the type signature entails, i was asking more something like: can a function return different types depending on what the caller inputs?
2020-09-26 22:06:32 +0200 <geekosaur> it cannot
2020-09-26 22:06:46 +0200 <geekosaur> that's what I was saying earlier
2020-09-26 22:06:58 +0200 <geekosaur> >> your implementation, on the other hand, does not get to pick Double for an empty list or Int otherwise; it has to be the same type in both cases
2020-09-26 22:07:14 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 22:07:15 +0200 <fluturel> Then it was i who misunderstood, i am sorry
2020-09-26 22:07:21 +0200ggole(~ggole@2001:8003:8119:7200:7423:d49d:a274:5670) (Quit: Leaving)
2020-09-26 22:08:07 +0200 <fluturel> Haskell is giving me the headaches and i am tired
2020-09-26 22:08:07 +0200 <ski> the caller can pick a different type, that's used both as input type and output type
2020-09-26 22:08:11 +0200 <Cale> It can produce different types of result based on the type of the argument...
2020-09-26 22:08:14 +0200 <geekosaur> (that's what the compiler meant by "rigid", by the way)
2020-09-26 22:08:30 +0200 <Cale> but not the value of the argument
2020-09-26 22:08:46 +0200 <ski> but you, as the implementor, can't decide to pick different output types here, depending on what input values you see (you can't even detect which types of input you're getting)
2020-09-26 22:09:11 +0200 <fluturel> yeah, so no reflection
2020-09-26 22:09:39 +0200 <fluturel> I can only guarantee that if it is an instance of Num, the function behaves correctly, no funny business
2020-09-26 22:10:06 +0200 <fluturel> If it isn't, the caller gets an error
2020-09-26 22:10:15 +0200 <dsal> You *can* write that function, but it's usually a bad idea.
2020-09-26 22:11:06 +0200 <fluturel> by that function, you mean the one with the signature i showed earlier?
2020-09-26 22:11:13 +0200 <dsal> yeah
2020-09-26 22:11:22 +0200takuan(~takuan@178-116-218-225.access.telenet.be) (Remote host closed the connection)
2020-09-26 22:11:24 +0200 <Cale> Which function?
2020-09-26 22:11:27 +0200geekosaur(42d52102@66.213.33.2) (Remote host closed the connection)
2020-09-26 22:11:27 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 240 seconds)
2020-09-26 22:11:33 +0200 <fluturel> at this point, i don't think i want to
2020-09-26 22:12:26 +0200 <fluturel> Cale: sum' :: (Num a, Num b) => [a] -> b
2020-09-26 22:13:16 +0200 <Cale> Not which doesn't ignore the elements of the input list...
2020-09-26 22:13:20 +0200 <Uniaika> *
2020-09-26 22:13:32 +0200 <Uniaika> evening
2020-09-26 22:13:44 +0200dhil(~dhil@11.29.39.217.dyn.plus.net)
2020-09-26 22:14:21 +0200 <pie_> in haskell combinator libraries does something like "many eof" hang? because it does hand in python's parsy library and i want to know if i should file a bug report of if thats reasonable behavior
2020-09-26 22:14:26 +0200 <Cale> With Integral a, you could convert them to Integer and then to b from there
2020-09-26 22:14:31 +0200 <dsal> Right. You'd need more constraints to do something slightly useful, which is converting from whatever type to another type, but doing that conversion where you need it would make everything easier.
2020-09-26 22:14:37 +0200 <pie_> the eof parser just checks if the "index" in the "stream" is >= the length...
2020-09-26 22:15:35 +0200 <monochrom> int-e: In that case, I took a Bernard Shaw quote and brought it to a new level: "I argue with myself all the time, it adds sparks to my debates."
2020-09-26 22:16:30 +0200 <monochrom> But really, we know what "put on your user hat" and "put on your implementer hat" mean, and how to do it.
2020-09-26 22:16:31 +0200 <Cale> pie_: It probably depends on the library, but at least ReadP manages to parse (many eof) successfully on an empty input.
2020-09-26 22:16:45 +0200dsf_(~dsf@2605:e000:1c0b:47c2:6014:cd97:238c:74bb)
2020-09-26 22:17:21 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt)
2020-09-26 22:17:40 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 265 seconds)
2020-09-26 22:17:54 +0200_vaibhavingale_(~Adium@203.188.228.27) (Quit: Leaving.)
2020-09-26 22:17:55 +0200 <Cale> (and on a nonempty input)
2020-09-26 22:18:16 +0200_vaibhavingale_(~Adium@203.188.228.27)
2020-09-26 22:18:16 +0200_vaibhavingale_(~Adium@203.188.228.27) (Client Quit)
2020-09-26 22:18:26 +0200directhex1(~directhex@195.206.169.184) (Remote host closed the connection)
2020-09-26 22:18:28 +0200dsf(~dsf@cpe-75-82-64-167.socal.res.rr.com) (Ping timeout: 246 seconds)
2020-09-26 22:18:33 +0200_vaibhavingale_(~Adium@203.188.228.27)
2020-09-26 22:19:01 +0200_vaibhavingale_(~Adium@203.188.228.27) (Client Quit)
2020-09-26 22:19:46 +0200 <pie_> Cale: my actual problem is that it hangs
2020-09-26 22:20:01 +0200 <pie_> what it looks like in python: eof.many().parse("") jhangs
2020-09-26 22:20:41 +0200 <Cale> Applying many to a parser which accepts an empty string is usually going to be dangerous
2020-09-26 22:20:42 +0200 <pie_> and im not sure what to do about it because im trying to do something like any_line.many(), where a variant is line can be an empty at the end of the file...
2020-09-26 22:20:44 +0200 <pie_> hm
2020-09-26 22:20:52 +0200 <pie_> Cale: yeah
2020-09-26 22:21:33 +0200 <pie_> so what i actually have is any_line = (not eof or newline).many() << (eof | newline)
2020-09-26 22:21:43 +0200 <pie_> and i run into the problem when i do any_line.many()
2020-09-26 22:21:53 +0200 <pie_> and idk how to restructure it
2020-09-26 22:21:55 +0200Kaeipi(~Kaiepi@47.55.157.9) (Remote host closed the connection)
2020-09-26 22:21:57 +0200 <pie_> so that it works
2020-09-26 22:22:14 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt) (Ping timeout: 256 seconds)
2020-09-26 22:23:09 +0200 <pie_> oh hm maybe i should just (text << (newline | eof)) | (empty line << newline)
2020-09-26 22:25:09 +0200 <pie_> (pseudocode)
2020-09-26 22:26:02 +0200m4lvin(~m4lvin@w4eg.de) (Quit: m4lvin)
2020-09-26 22:26:03 +0200 <Turmfalke> pie_: In parsec you could use something like `manyTill (newline <|> eof)`
2020-09-26 22:26:22 +0200m4lvin(~m4lvin@w4eg.de)
2020-09-26 22:26:35 +0200 <Turmfalke> `manyTill anyChar (newline <|> eof)` actually
2020-09-26 22:26:52 +0200 <Cale> Turmfalke: Well, but could you apply many to *that*?
2020-09-26 22:26:58 +0200 <monochrom> This feels like a wild goose chase because first of all there is no reason to believe that python's parsy has remotely the same semantics as parsec or megaparsec.
2020-09-26 22:27:19 +0200 <monochrom> (in particular how much backtracking happens)
2020-09-26 22:27:27 +0200 <Turmfalke> Cale: Why not?
2020-09-26 22:27:51 +0200 <Turmfalke> Hhm, ah...
2020-09-26 22:27:51 +0200Guest_2(59401d45@89-64-29-69.dynamic.chello.pl)
2020-09-26 22:28:05 +0200 <Cale> eof accepts on empty input, and many doesn't like parsers which accept on empty input
2020-09-26 22:28:29 +0200|Kin|(~|Kin|@178.162.212.214)
2020-09-26 22:29:12 +0200 <pie_> cool i think it works, thanks for rubbr ducking :D
2020-09-26 22:29:58 +0200 <pie_> monochrom: i dunno id assume most monadic parser combinators behave at least somewhat similar?
2020-09-26 22:30:37 +0200 <Cale> They're *somewhat* similar, but there are differences when you get to subtle issues like this one
2020-09-26 22:30:55 +0200 <pie_> hm
2020-09-26 22:31:26 +0200 <pie_> it doenst help that i dont really understand how it works
2020-09-26 22:31:32 +0200 <Cale> (The one I tried first is completely okay with parsing many eof, even though the list of parses it gives you is infinite)
2020-09-26 22:31:48 +0200 <pie_> i guess laziness helps
2020-09-26 22:31:58 +0200 <monochrom> "similar" is not enough
2020-09-26 22:32:07 +0200 <monochrom> C and Rust are "similar".
2020-09-26 22:32:18 +0200 <monochrom> Lisp and Agda are "similar"
2020-09-26 22:32:21 +0200 <sm[m]> you could prototype it in both haskell and python, for extra insight & testing
2020-09-26 22:32:24 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de)
2020-09-26 22:32:27 +0200knupfer(~Thunderbi@200116b82c2b4e00d8f25cb26cf0082b.dip.versatel-1u1.de) (Ping timeout: 240 seconds)
2020-09-26 22:32:30 +0200 <monochrom> Tuesday is like Monday, but different.
2020-09-26 22:32:42 +0200 <pie_> monochrom: i accept that as fair but i assumed this would be an issue where similar is sufficient
2020-09-26 22:32:47 +0200 <Cale> There are only a few problems you can run into though, so asking about how Haskell libraries deal with it isn't bad
2020-09-26 22:32:51 +0200 <monochrom> http://www.vex.net/~trebla/humour/tautologies.html
2020-09-26 22:33:13 +0200Guest_2(59401d45@89-64-29-69.dynamic.chello.pl) (Remote host closed the connection)
2020-09-26 22:33:24 +0200 <pie_> if it would not have been sufficient, i assumed i would probably have been told so
2020-09-26 22:33:52 +0200 <monochrom> Different parser combinators are going to be very likely disagree on the detailed semantics of <|>. That's where "similar" fails.
2020-09-26 22:34:00 +0200 <dolio> Seems like a lot of assumptions going on. :)
2020-09-26 22:34:06 +0200 <pie_> and haskell is probably the community with largest overlap between parser combinators and "uh ive got some parser combinator libary in antoher language here :P"
2020-09-26 22:34:13 +0200 <pie_> dolio: so it goes, but feedback loops
2020-09-26 22:34:42 +0200 <pie_> dolio: i need help with a library but first i must construct the universe ;p
2020-09-26 22:35:09 +0200 <monochrom> For example ReadP in base supports ambiguous grammars fully, <|> is perfectly ideal fair choice, all possibilities of "p <|> q" really happen.
2020-09-26 22:35:44 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 22:35:48 +0200 <monochrom> But parsec and megaparsec beg to differ. "p <|> q" becomes simply p if p consumes at least one character/token.
2020-09-26 22:35:56 +0200 <pie_> (i knew the problem was that the parser wasnt "consumptive" (as opposed to productive :P), but my brain didnt get from point a to point b on actually fixing it till i rubber ducked it i guess. anyway, much ado about nothing)
2020-09-26 22:36:08 +0200 <monochrom> (overridable if you use "try p <|> q")
2020-09-26 22:36:37 +0200 <pie_> monochrom: i see. so they "commit" it if consumes?
2020-09-26 22:36:43 +0200 <monochrom> Yes
2020-09-26 22:36:47 +0200juuandyy(~juuandyy@90.166.144.65)
2020-09-26 22:36:47 +0200v_m_v(~vm_v@2a02:aa12:3200:6480:f507:71a:9334:3099) (Remote host closed the connection)
2020-09-26 22:36:48 +0200 <sm[m]> megaparsec has some automatic backtracking but I always forget the details
2020-09-26 22:37:07 +0200 <pie_> i might not mind explicit backtracking
2020-09-26 22:37:12 +0200thir(~thir@p200300f27f0fc60094e773283d7bf825.dip0.t-ipconnect.de) (Ping timeout: 260 seconds)
2020-09-26 22:37:15 +0200 <pie_> maybe implicit backtracking is half my issues
2020-09-26 22:37:36 +0200 <pie_> at least uhh... i think the library does implicit backtracking...idek
2020-09-26 22:37:42 +0200 <pie_> i just know i get stuck a lot :P
2020-09-26 22:37:45 +0200 <sm[m]> you're flying blind :)
2020-09-26 22:37:49 +0200 <monochrom> A priori I have no reason to believe parsy's <|> behaves as ReadP or as parsec or as something else.
2020-09-26 22:37:58 +0200 <pie_> yeah
2020-09-26 22:38:09 +0200 <dolio> Could be PEG.
2020-09-26 22:38:32 +0200 <monochrom> A posteriori if you have being working at the level of "I think they are all similar" then I know for sure you don't know either.
2020-09-26 22:38:32 +0200 <pie_> sm[m]: i did at one point think of rewriting it in haskell but i figured maybe i should get stuck with one thing at at a time :P
2020-09-26 22:39:06 +0200 <sm[m]> I can understand that.. but if I couldn't get the insight on the python side I would do it, just to (probably) understand what's happening
2020-09-26 22:39:17 +0200 <pie_> *nod*
2020-09-26 22:39:27 +0200 <sm[m]> but surely you can introspect and get the parse state from parsy somehow ?
2020-09-26 22:39:47 +0200adam_wespiser(~adam_wesp@209.6.42.110) (Ping timeout: 240 seconds)
2020-09-26 22:40:15 +0200 <pie_> well, idk about the graph of parser computations but the (stream, index) dumping function _has_ been helping
2020-09-26 22:41:33 +0200 <pie_> havent had much time to work on it since yesterday, now im going to try to figure out what this adhoc human format's offsides-rule is and how to parse it...
2020-09-26 22:41:40 +0200rotty(rotty@ghost.xx.vu) (Ping timeout: 256 seconds)
2020-09-26 22:42:33 +0200 <monochrom> Yeah you do have the extra uphill battle of still trying to decide what rule you want to enforce.
2020-09-26 22:42:43 +0200carter01(47b896d8@pool-71-184-150-216.bstnma.fios.verizon.net)
2020-09-26 22:42:58 +0200 <monochrom> This is how ECMAScript happened. :)
2020-09-26 22:43:02 +0200 <pie_> heh
2020-09-26 22:43:27 +0200 <pie_> honestly i wish id just have a copy of the program that made it or something
2020-09-26 22:44:03 +0200 <monochrom> Yeah that would help.
2020-09-26 22:44:33 +0200rotty(rotty@ghost.xx.vu)
2020-09-26 22:46:10 +0200bitmagie(~Thunderbi@200116b8069cc400d57e23bacd856e4d.dip.versatel-1u1.de) (Quit: bitmagie)
2020-09-26 22:46:11 +0200 <carter01> Has anyone set up haskell language server with Coc here? I just get this error: Launching server "languageserver.haskell" using command haskell-language-server-wrapper failed.
2020-09-26 22:47:05 +0200fluturel(~fluturel@82.137.14.51) (Ping timeout: 240 seconds)
2020-09-26 22:47:33 +0200danvet_(~Daniel@2a02:168:57f4:0:efd0:b9e5:5ae6:c2fa) (Ping timeout: 272 seconds)
2020-09-26 22:47:44 +0200 <Uniaika> carter01: I do
2020-09-26 22:47:49 +0200 <Uniaika> but I don't get your error
2020-09-26 22:48:04 +0200 <carter01> sad life
2020-09-26 22:48:11 +0200 <Uniaika> what does haskell-language-server-wrapper says if you run it in your project's directory?
2020-09-26 22:49:11 +0200 <carter01> It doesn't say anything. Im using stack and when I run it at the top level it just doesn't do anything. It's only when I open a particular file that it starts up
2020-09-26 22:50:13 +0200 <carter01> Which makes sense right? I just open things using neovim, so opening a directory structure wouldnt do much with haskell language server
2020-09-26 22:50:45 +0200wroathe(~wroathe@c-73-24-27-54.hsd1.mn.comcast.net) (Ping timeout: 240 seconds)
2020-09-26 22:50:47 +0200 <dolio> haskell-language-server-wrapper is an executable.
2020-09-26 22:50:56 +0200 <dolio> What happens if you just run it in a terminal?
2020-09-26 22:51:06 +0200 <carter01> idk one sec
2020-09-26 22:52:16 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 22:52:17 +0200 <Uniaika> yes sorry, that's what I meant
2020-09-26 22:52:26 +0200adam_wespiser(~adam_wesp@209.6.42.110)
2020-09-26 22:54:01 +0200 <carter01> oh no worries! Im just trying to locate where that wrapper is
2020-09-26 22:54:16 +0200 <dolio> That might be the problem. :)
2020-09-26 22:54:41 +0200 <dolio> When I was trying to set things up, it was expected to be in my path.
2020-09-26 22:55:05 +0200sand_dull(~theuser@185.217.69.182)
2020-09-26 22:55:31 +0200 <carter01> yeah I don't have that in my path so that probably is the problem!
2020-09-26 22:55:36 +0200 <carter01> thank you!
2020-09-26 22:57:18 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl) (Ping timeout: 256 seconds)
2020-09-26 22:57:48 +0200 <Uniaika> carter01: I download it directly from the GH releases
2020-09-26 22:57:59 +0200 <Uniaika> then rename it to remove the -Linux part
2020-09-26 23:00:01 +0200|Kin|(~|Kin|@178.162.212.214) ()
2020-09-26 23:02:20 +0200o1lo01ol1o(~o1lo01ol1@bl8-213-81.dsl.telepac.pt)
2020-09-26 23:04:23 +0200 <carter01> I used ghcup to install it I think. But im not sure that added it to my path. I also used that to install ghc, but im not sure that added it to my path either
2020-09-26 23:04:45 +0200 <carter01> I just need to figure how to correctly add the right files to my path
2020-09-26 23:05:27 +0200 <carter01> Im also not sure if doing ghcup install hls adds the haskell-language-server or the haskell-language-server-wrapper. So I gotta figure that out lol
2020-09-26 23:06:20 +0200justanotheruser(~justanoth@unaffiliated/justanotheruser)
2020-09-26 23:14:17 +0200carter01(47b896d8@pool-71-184-150-216.bstnma.fios.verizon.net) (Remote host closed the connection)
2020-09-26 23:15:31 +0200wroathe(~wroathe@c-68-54-25-135.hsd1.mn.comcast.net)
2020-09-26 23:16:20 +0200juuandyy(~juuandyy@90.166.144.65) (Quit: Konversation terminated!)
2020-09-26 23:18:29 +0200Jeanne-Kamikaze(~Jeanne-Ka@static-198-54-131-92.cust.tzulo.com) (Quit: Leaving)
2020-09-26 23:19:57 +0200kaimi1(~kaimi@178.239.168.171)
2020-09-26 23:20:41 +0200Jeanne-Kamikaze(~Jeanne-Ka@static-198-54-131-140.cust.tzulo.com)
2020-09-26 23:20:50 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Remote host closed the connection)
2020-09-26 23:23:27 +0200 <[exa]> is there some nice idiom that would work like `map` except working specially with first and last element (including the case when first is last) ?
2020-09-26 23:24:32 +0200koz_o O O (mapEnds)
2020-09-26 23:24:37 +0200mmohammadi9812(~mmohammad@188.210.108.97) (Quit: I quit (╯°□°)╯︵ ┻━┻)
2020-09-26 23:24:48 +0200 <MarcelineVQ> some kinda Palindrome view
2020-09-26 23:26:31 +0200brewmarche(~brewmarch@aftr-62-216-202-61.dynamic.mnet-online.de)
2020-09-26 23:26:57 +0200hackagehaskell-gi 0.24.5 - Generate Haskell bindings for GObject Introspection capable libraries https://hackage.haskell.org/package/haskell-gi-0.24.5 (inaki)
2020-09-26 23:27:11 +0200__monty__(~toonn@unaffiliated/toonn) (Quit: leaving)
2020-09-26 23:29:52 +0200aarvar(~foewfoiew@50.35.43.33)
2020-09-26 23:30:45 +0200merijn(~merijn@83-160-49-249.ip.xs4all.nl)
2020-09-26 23:30:48 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 23:31:34 +0200DirefulSalt(DirefulSal@gateway/vpn/privateinternetaccess/direfulsalt) (Remote host closed the connection)
2020-09-26 23:32:26 +0200DirefulSalt(DirefulSal@gateway/vpn/privateinternetaccess/direfulsalt)
2020-09-26 23:32:59 +0200cr3(~cr3@192-222-143-195.qc.cable.ebox.net)
2020-09-26 23:35:18 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 258 seconds)
2020-09-26 23:38:10 +0200mananamenos(~mananamen@84.122.202.215.dyn.user.ono.com) (Ping timeout: 256 seconds)
2020-09-26 23:40:38 +0200justanotheruser(~justanoth@unaffiliated/justanotheruser) (Ping timeout: 246 seconds)
2020-09-26 23:41:21 +0200justanotheruser(~justanoth@unaffiliated/justanotheruser)
2020-09-26 23:41:22 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)
2020-09-26 23:42:47 +0200sand_dull(~theuser@185.217.69.182) (Ping timeout: 240 seconds)
2020-09-26 23:44:01 +0200ryansmccoy(~ryansmcco@193.37.254.27) (Ping timeout: 264 seconds)
2020-09-26 23:44:49 +0200ryansmccoy(~ryansmcco@156.96.151.132)
2020-09-26 23:44:52 +0200falafel_(~falafel@2605:e000:1527:d491:f090:20fe:cddf:2a1a) (Ping timeout: 260 seconds)
2020-09-26 23:45:27 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net) (Ping timeout: 240 seconds)
2020-09-26 23:45:56 +0200snakemasterflex(~snakemast@213.100.206.23) (Ping timeout: 272 seconds)
2020-09-26 23:47:42 +0200brewmarche(~brewmarch@aftr-62-216-202-61.dynamic.mnet-online.de) (Quit: This computer has gone to sleep)
2020-09-26 23:49:07 +0200isovector1(~isovector@172.103.216.166) (Ping timeout: 240 seconds)
2020-09-26 23:51:02 +0200heatsink(~heatsink@107-136-5-69.lightspeed.sntcca.sbcglobal.net)