»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_log/perl6 | UTF-8 is our friend! 🦋
Set by Zoffix on 25 July 2018.
sena_kun tbrowder, ping? 00:01
tbrowder yo?
sena_kun I am not sure if I can help you, but are you on `Perl 6 Advent Calender` tab in `My Sites` tab on wordpress, right? 00:02
tbrowder ya caught me finger-fumbling again!
yes, i’m on that site
sena_kun Then you can select `Blog Posts` and there is a switch, `Me | Everyone`, if you choose second one, it will show posts of others. 00:03
And you can edit those, I think.
I don't know if editor rights are needed or anything, because I can see those pages too, not sure if I have any rights given. 00:04
but, disregarding that, the thing I would really like to see is to know how can one set a posting time exactly at first minute of midnight. Day 13 has `01:01` set for me, Day 3 - `02:01`. 00:05
tbrowder ok, i’ve seen that, and used it for a list. at the moment i don’t want to edit any post, i want to ensure the scheduling sysem works and shows the correct date/time format. as an example, jjmerelo’s day 2 post is showing as day 1, and the scheduler format may have contributed to that 00:06
sena_kun oooh
00:06 leont left
sena_kun well, I think you can edit scheduled time too, but, unfortunately, I don't have a clue on how scheduling works in wordpress. :( 00:07
tbrowder you should be able to modify the schedule and do an update, but i think you have to click the update button twice
sena_kun oh, by the way, for me it is already Day 2 for 2 hours. 00:08
and I see `Day 2` post
tbrowder i’m working on improving the instructions but life is intervening. i hope we can get authors to fix formattng after the fact if necessary and update. the preview in wp is not 100% in my experience. 00:10
erg!
make sure you update schedule so date is correct first, then set time dials to 00 01 00:11
sena_kun well, anyway, I still have a full post to write from scratch, heh. ok, I guess it is a sleeping time for me. o/
>make sure you update schedule so date is correct first, then set time dials to 00 01 00:12
oh, thanks, did exactly so. \o/
00:12 sena_kun left
tbrowder and on the p6 site, not your own 00:12
00:15 qiqi joined
Geth doc: 6f3282af62 | Coke++ | doc/Type/Cool.pod6
space after comma
00:15
doc: 52e407d003 | Coke++ | util/manage-page-order.p6
spaces, not tabs
synopsebot_ Link: doc.perl6.org/type/Cool
squashable6 🍕🍕🍕 First contribution by coke++! ♥
00:15 p6bannerbot sets mode: +v qiqi 00:37 kensanata left 00:43 qiqi left 00:48 kurahaupo joined 00:49 p6bannerbot sets mode: +v kurahaupo 00:58 kurahaupo left 00:59 kurahaupo joined 01:00 p6bannerbot sets mode: +v kurahaupo, pecastro left 01:02 Hotkeys joined, p6bannerbot sets mode: +v Hotkeys 01:07 kurahaupo_ joined, kurahaupo left 01:08 p6bannerbot sets mode: +v kurahaupo_
atweiden-air has anyone got 2018.11 to compile on macos? 01:09
SmokeMachine .tell pmurias you should try MemoizedDOM... :) 01:11
yoleaux SmokeMachine: I'll pass your message to pmurias.
01:14 daemon joined, p6bannerbot sets mode: +v daemon, aindilis left 01:16 lizmat left 01:19 kurahaupo_ left 01:20 kurahaupo joined 01:21 p6bannerbot sets mode: +v kurahaupo
vrurg atweiden-air: I did a couple of minutes ago. 01:26
01:32 kurahaupo left
vrurg 2018.11 is amazingly fast on startup... 01:37
mornfall is it? 01:38
i'm intrigued
vrurg got used to startup times at ~1-1.5sec 01:40
But now it just happens. Instantly. 01:41
mornfall can i have that?
i don't quite believe you, but i'm willing to try
vrurg: which version did you use before? 01:42
vrurg I'm migrating from release to relase with rakudobrew. So, the last one was 2018.10. 01:44
mornfall okay i'm building moar 2018.11
rakudo is next
vrurg mornfall: I guess some extra module recompilation has been avoided somewhere in the startup chain. I was always wondering why is it slow when the only thing changed, say, is a test script. 01:45
vrurg takes his words back. 01:52
Don't know what it was but now timing doesn't display any speed up. 01:53
Looks like a conincidence of a couple of factors which led to the wrong impression.
mornfall yeah, it seemed rather implausible :p 01:55
at least i have proper checkouts of the tools or something
01:55 coet left
mornfall too bad i have no idea how to make pull requests 01:56
without going crasy, anyway
crazy*
vrurg mornfall: are you serious? It'd not a big deal with github. Just fork a repository, branch, work – and let github form and submit the request. 01:58
It's*
mornfall yeah, sounds like a good way to go crazy to me :p
i have a 2 line patch which took maybe 10 minutes to pin down including finding the right part of rakudo (VM.pm6 fwiw) 01:59
and i didn't have to use the mouse to do it either... github makes me sad :\ 02:00
vrurg With two lines I wouldn't even bother and just send a patch. 02:01
02:04 tmtvl left
mornfall okay i found 'hub' which appears to make github less insane 02:07
02:17 irdr left
atweiden-air vrurg: interesting. rakudobrew crashes for me during compilation ix.io/1v36 02:18
have also tried homebrew, similar error there
vrurg atweiden-air: Have you upgraded the system recently? XCode?
02:18 irdr joined 02:19 p6bannerbot sets mode: +v irdr
vrurg Looks like you need to recompile all 3rd party libs – for the sake of reliability. 02:20
atweiden-air vrurg: i did just recently upgrade llvm from 6.0.0 to 7.0.0 via homebrew 02:21
wasn't aware there was an option to recompile 3rd party libs in rakudobrew
02:22 araraloren joined, p6bannerbot sets mode: +v araraloren
vrurg atweiden-air: That's not about rakudobrew. In your output it complains about libsha1, libatomicops, libuv – all seems to be coming from a directory 3rdparty which neither rakudobrew nor rakudo itself has. 02:24
I use MacPorts, but could guess that 3rdparty is where homebrew installs stuff. 02:25
atweiden-air vrurg: that log is from rakudobrew
afaik rakudobrew pulls those deps down itself
btw this is moarvm failing to compile, not rakudo 02:26
02:27 graphene left 02:29 graphene joined 02:30 p6bannerbot sets mode: +v graphene
vrurg Could a llvm bug then... I'm not even sure what rakudobrew is using to compile on my system. Though I have llvm40 installed. 02:30
02:32 molaf left
mornfall cool, i think i can live with 'hub pull-request' (unless it dies with a mysterious error message because you forgot to push into your fork, anyway) 02:36
02:40 ChoHag_ left
vrurg atweiden-air: I gave llvm 7.0 a chance, and then another one, and it worked for me both times. Can you try building an older version? Say 2018.10? I would suspect it will fail too. 02:44
02:44 molaf joined 02:45 p6bannerbot sets mode: +v molaf 02:48 mephinet joined, p6bannerbot sets mode: +v mephinet 02:49 reu joined, p6bannerbot sets mode: +v reu 02:53 graphene left 02:54 graphene joined 02:55 p6bannerbot sets mode: +v graphene 02:56 ChoHag joined, p6bannerbot sets mode: +v ChoHag 02:59 kurahaupo_ joined 03:00 p6bannerbot sets mode: +v kurahaupo_ 03:05 zacts joined, p6bannerbot sets mode: +v zacts 03:11 ferreira joined 03:12 p6bannerbot sets mode: +v ferreira
atweiden-air vrurg: indeed 2018.10 compilation fails as well 03:16
vrurg There're outdated versions of libraries lurking somewhere. Try checking out if your XCode is the latest too. I would try total upgrade and recompile. Check if there is something in the environment left behind (some custom settings for specific compiles). 03:19
vrurg wonders why llvm complains about libs in moarvm build dir only? That's weird. 03:20
atweiden-air will try a reboot ....
vrurg Oh, first of all: rm -rf ~/.rakudobrew/moarvm-2018.11 03:22
atweiden-air yes, i do that each time
03:22 ChoHag left 03:26 atweiden-air left 03:39 zapwai left 03:59 ChoHag joined 04:00 p6bannerbot sets mode: +v ChoHag, kurahaupo joined 04:01 p6bannerbot sets mode: +v kurahaupo 04:03 kurahaupo_ left 04:04 zacts left 04:10 kurahaupo left, kurahaupo joined 04:11 p6bannerbot sets mode: +v kurahaupo, Sgeo_ joined 04:12 p6bannerbot sets mode: +v Sgeo_ 04:14 Sgeo left 04:15 kerframil left 04:21 kurahaupo left, kurahaupo joined, graphene left 04:22 p6bannerbot sets mode: +v kurahaupo 04:23 graphene joined, p6bannerbot sets mode: +v graphene 04:24 Sgeo_ left 04:28 ChoHag left, cibs joined 04:29 p6bannerbot sets mode: +v cibs 04:34 qiqi joined, kurahaupo left, kurahaupo joined, p6bannerbot sets mode: +v qiqi 04:35 p6bannerbot sets mode: +v kurahaupo 04:44 qiqi left 04:45 kurahaupo left, kurahaupo joined 04:46 p6bannerbot sets mode: +v kurahaupo, Sgeo joined 04:47 p6bannerbot sets mode: +v Sgeo 04:50 Cabanossi left 04:51 Cabanoss- joined, qiqi joined 04:52 p6bannerbot sets mode: +v Cabanoss-, p6bannerbot sets mode: +v qiqi 04:55 kurahaupo left 04:56 kurahaupo joined 04:57 p6bannerbot sets mode: +v kurahaupo 05:00 araraloren left
Geth doc: 9900c9a188 | (Richard Hainsworth)++ (committed using GitHub Web editor) | doc/Programs/03-environment-variables.pod6
Update 03-environment-variables.pod6

Change FormatCode F to C, since F is not usefully implemented. C<> changes the markup
05:06
squashable6 🍕🍕🍕 First contribution by finanalyst++! ♥
05:06 kurahaupo left 05:07 kurahaupo joined 05:08 p6bannerbot sets mode: +v kurahaupo 05:18 qiqi left 05:22 kurahaupo left, kurahaupo joined 05:23 p6bannerbot sets mode: +v kurahaupo 05:31 qiqi joined 05:32 p6bannerbot sets mode: +v qiqi 05:37 kurahaupo left, kurahaupo joined 05:38 p6bannerbot sets mode: +v kurahaupo 05:41 kurahaupo left 05:42 qiqi left 06:04 ChoHag joined 06:05 p6bannerbot sets mode: +v ChoHag 06:06 benjikun left 06:13 benjikun joined 06:14 p6bannerbot sets mode: +v benjikun 06:25 kurahaupo joined 06:26 p6bannerbot sets mode: +v kurahaupo 06:35 kurahaupo left 06:36 kurahaupo joined, p6bannerbot sets mode: +v kurahaupo 06:44 graphene left 06:45 kurahaupo left 06:46 graphene joined, kurahaupo joined, p6bannerbot sets mode: +v graphene, p6bannerbot sets mode: +v kurahaupo 06:56 kurahaupo left, andrzejku_ joined 06:57 kurahaupo joined, p6bannerbot sets mode: +v andrzejku_ 06:58 p6bannerbot sets mode: +v kurahaupo 07:07 kurahaupo left, kurahaupo joined 07:08 p6bannerbot sets mode: +v kurahaupo 07:18 kurahaupo left, kurahaupo joined 07:19 p6bannerbot sets mode: +v kurahaupo 07:28 kurahaupo left, graphene left 07:29 kurahaupo joined 07:30 graphene joined, p6bannerbot sets mode: +v kurahaupo, p6bannerbot sets mode: +v graphene 07:34 qiqi joined 07:35 p6bannerbot sets mode: +v qiqi 07:40 kurahaupo left 07:41 kurahaupo joined 07:42 p6bannerbot sets mode: +v kurahaupo 07:43 Sgeo left 07:45 Sgeo joined 07:46 p6bannerbot sets mode: +v Sgeo 07:52 kurahaupo left 07:53 kurahaupo joined, p6bannerbot sets mode: +v kurahaupo 08:03 kurahaupo left 08:04 kurahaupo joined, p6bannerbot sets mode: +v kurahaupo 08:16 kurahaupo left, kurahaupo joined 08:17 p6bannerbot sets mode: +v kurahaupo
Geth doc: 81df0c33c6 | (JJ Merelo)++ | doc/Language/exceptions.pod6
Revise and explain examples

Closes #2468 after most of the work has been done by @uzluisf
08:21
synopsebot_ Link: doc.perl6.org/language/exceptions
squashable6 🍕 JJ++ closed issue “Exceptions: `try` block …”: github.com/perl6/doc/issues/2468
08:21 jjmerelo joined, p6bannerbot sets mode: +v jjmerelo 08:26 kurahaupo left 08:30 gurmble joined, p6bannerbot sets mode: +v gurmble 08:31 kurahaupo joined 08:32 rindolf joined, p6bannerbot sets mode: +v kurahaupo 08:33 p6bannerbot sets mode: +v rindolf 08:44 qiqi left 09:06 Aceeri_ left 09:09 Manifest0 left 09:10 Manifest0 joined 09:11 p6bannerbot sets mode: +v Manifest0 09:16 rindolf left 09:21 qiqi joined, p6bannerbot sets mode: +v qiqi 09:39 yqt joined 09:40 p6bannerbot sets mode: +v yqt 09:43 rindolf joined, p6bannerbot sets mode: +v rindolf 09:52 qiqi left 09:53 hami joined, p6bannerbot sets mode: +v hami 09:57 hami left 10:15 rindolf left 10:19 jjmerelo left 10:33 rindolf joined, p6bannerbot sets mode: +v rindolf 10:40 qiqi joined 10:41 p6bannerbot sets mode: +v qiqi 10:43 kensanata joined, p6bannerbot sets mode: +v kensanata 10:51 qiqi left 10:55 lizmat joined, p6bannerbot sets mode: +v lizmat 10:56 coet joined, p6bannerbot sets mode: +v coet 11:03 rindolf left 11:07 wbn_ left, wbn joined 11:08 p6bannerbot sets mode: +v wbn 11:11 rindolf joined, sno left 11:12 pecastro joined, p6bannerbot sets mode: +v rindolf 11:13 p6bannerbot sets mode: +v pecastro 11:19 qiqi joined, p6bannerbot sets mode: +v qiqi 11:31 sena_kun joined, p6bannerbot sets mode: +v sena_kun 11:32 lichtkind left 11:40 robertle joined, p6bannerbot sets mode: +v robertle 11:44 lichtkind joined 11:45 p6bannerbot sets mode: +v lichtkind, ExtraCrispy left 11:47 qiqi left 11:52 qiqi joined 11:53 p6bannerbot sets mode: +v qiqi
scott what's a nice way to do this kind of thing, where `cycle` makes an infinite lazy list? 12:09
take 10 (cycle [1,2,3]) == [1,2,3,1,2,3,1,2,3,1]
Summertime [1,2,3] xx * 12:10
scott i found `|$x xx *` mentioned on a blog but it seems rather obscure
timotimo m: (|[1, 2, 3] xx *)[^10]
camelia ( no output )
timotimo m: (|[1, 2, 3] xx *)[^10].perl.say
camelia (1, 2, 3, 1, 2, 3, 1, 2, 3, 1)
timotimo m: flat([1, 2, 3] xx *)[^10].perl.say
camelia (1, 2, 3, 1, 2, 3, 1, 2, 3, 1)
Summertime oh right yeah needs the slip
timotimo no need for the |, you can use flat instead
Summertime but my character count! 12:11
timotimo well ... :)
12:11 dogbert17 joined
Summertime I wouldn't consider xx obscure, it is on the operators page of the documentation n' all 12:11
although a fair ways down
timotimo i think the obscure thing is having to combine three things 12:12
?
scott i mean, |, xx, and * all interacting for what could be .cycle
12:12 p6bannerbot sets mode: +v dogbert17
Summertime ah, yeah in that case 12:12
mornfall 'xx *' does seem to come up somewhat often 12:14
12:16 lizmat left
Summertime it could make more sense performance-wise to have something for containers seperate from xx too? since xx also re-evaluates the left side multiple times right? 12:16
timotimo we already optimize that when the value is static
Summertime m: (rand xx 10).say
camelia (0.058144186329716185 0.9723508447993349 0.3466275522323401 0.7530386225477884 0.28545861665026184 0.45543396888796783 0.7284208845806376 0.5768109343578602 0.28018795980570455 0.622501207127057)
Summertime ah oki
12:16 ufobat_ joined
timotimo m: my @foo = [1, 2, 3] xx 5; @foo[2][0] = "hello"; say @foo 12:17
camelia [[1 2 3] [1 2 3] [hello 2 3] [1 2 3] [1 2 3]]
timotimo ^- it clones the value each time instead of evaluating a piece of code
12:17 p6bannerbot sets mode: +v ufobat_
Summertime well, argument for compositing of so many things for something so simple, in python I think the equivilent is chain.from_iterable(repeat([1,2,3])), chain == flat, repeat(list,n) == xx, the concepts are portable across languages ^.^ 12:19
only thing different is default n value, instead of * 12:20
oh there is a cycle function there... foot in mouth I suppose (and need to go fix yesterday's AoC answer ;-;) 12:21
scott you may have guessed, but i'm also doing AoC stuff :P 12:22
i started this year practicing Julia, but got fed up when i repeatedly realized it would be a Perl 6 one-liner, so i'm switching to practicing p6 =) 12:23
lucasb hehe, me too was doing aoc day 1 12:24
I wanted that "|(lines».Int) xx *" somehow to create the cycled list, but doesn't work 12:25
for 2 reasons: bug with lines() and thunk xx :)
Summertime hypers and slips don't always interact quite nicely 12:26
lucasb I should try with "A xx B :!thunked"
Summertime I was aiming to do all of AoC in p6 this year, but at least in fedora's perl6 package, I get an event loop error for my day1part2 answer... still too lazy to build perl6 to make sure its not my distro's package's fault ;-; 12:27
timotimo what version do they ship at the moment?
Juerd What is AoC?
scott Juerd: adventofcode.com/
moritz Advent of Code?
yoleaux 1 Dec 2018 23:44Z <tbrowder> moritz: ^^^
Juerd Thanks
12:28 MasterDuke joined, p6bannerbot sets mode: +v MasterDuke, MasterDuke left, MasterDuke joined, herbert.freenode.net sets mode: +v MasterDuke, p6bannerbot sets mode: +v MasterDuke
Summertime This is Rakudo version 2018.04 built on MoarVM version 2018.04.1 / implementing Perl 6.c. 12:28
mornfall Summertime: building rakudo star is pretty easy, turns out :P 12:29
MasterDuke Summertime: i don't know what's involved, but using the whateverable bots you can set standard input and such which you can't do with camelia
*what's involved in your code 12:30
AlexDaniel` evalable: stdin foo bar
evalable6 AlexDaniel`, STDIN is set to «foo bar»
MasterDuke or yeah, building rakudo isn't all that complicated
Summertime I can replicate without any specific input, and its a fairly super-common case (adding to a container in a loop)
so I'm guessing fedora package issue 12:31
timotimo weird. what does that error actually look like?
oh
the "fd > stderr" assertion thing?
Summertime ye
in uv 12:32
timotimo a backtrace or something would be nice :S
MasterDuke huggable: debs 12:33
huggable MasterDuke, CentOS, Debian, Fedora and Ubuntu Rakudo packages: github.com/nxadm/rakudo-pkg/releases
mornfall sounds like someone closed a fd
that assertion doesn't seem to make any sense
MasterDuke Summertime: also, you can find packages for the newest releases there ^^^
mornfall (on the surface, that looks more like a bug in libuv than in moar or rakudo) 12:34
Summertime moar: src/unix/core.c:539: uv__close: Assertion `fd > STDERR_FILENO' failed.
Aborted (core dumped)
with --ll-exception
mornfall Summertime: you need to gdb into the core and ask for 'bt'
but it's perfectly legal to close stdin/stdout/stderr and following open() will just return one of those 12:35
(just like if you close stdin, the next open will return 0... some people mistakenly treat that as an error) 12:36
12:36 domidumont joined
MasterDuke Summertime: perl6-gdb-m 12:36
12:37 p6bannerbot sets mode: +v domidumont
Summertime give moment, trying to remember the smallest reproducable 12:37
mornfall github.com/Samsung/iotjs/issues/1246 12:39
12:39 kensanata left
mornfall (basically what i said above -- this will trip up if you ever close one of stdin/stdout/stderr) 12:39
why is your libuv compiled with assertions enabled is a different mystery entirely 12:40
Summertime mornfall, I think you might be too smart for your own good, it does only happen when a probably-closing action is done on stdin ($*ARGFILES.lines specifically in my case)
thanks for solving that part for me
-for your own good, + just super smart
12:41 coet left
Summertime $*IN.close; my @x; loop { @x.push(0) }; 12:43
probably could get reproducer smaller but
and I don't have gdb installed atm, and a bit tired to learn how to fight with gdb, I'll look into that tomorrow (along with compiling rakudo) 12:44
and I can compile it its just... non portable binaries ;-; I wanna be able to move them and their related files around, but the paths are hardcoded in 12:45
MasterDuke: I think I came across that before, but didn't realise that the package-building was set up to not require trust, so I'll definitely look into that now that I know that, thanks! 12:48
SmokeMachine .tell pmurias Any idea of why Im getting this error? www.irccloud.com/pastebin/4DYflois/ 12:49
yoleaux SmokeMachine: I'll pass your message to pmurias.
mornfall Summertime: what you want is to get libuv that's not a debug build
Summertime: are you sure you didn't build libuv yourself at some point, overriding the system/packaged one? 12:50
oooh nevermind
moarvm ships a copy of libuv /o\
Summertime if moarvm isn't forcing it on, and if fedora isn't doing some wacky splitting out dependencies stuff that I'm mistakenly overriding, I'll file a downstream bug tomorrow 12:51
mornfall Summertime: i think moarvm defaults to using its own, and perhaps the fact it uses a debug build is a bug (which may have been fixed since) 12:53
Summertime: fedora people probably want to pass --has-libuv to ./Configure.pl in moarvm
at first sight, it seems that libuv gets the same cflags as the rest of moarvm, so perhaps your moarvm is a debug build too (which would possibly make it abysmally slow :p) 12:58
timotimo: running with --profile on This is Rakudo version 2018.11 built on MoarVM version 2018.11 gives me Unhandled exception in code scheduled on thread 4 Invocant of method 'CALL-ME' must be a type object of type 'List', not an object instance of type 'List'. 13:02
(code runs okay without --profile)
Summertime they do pull out libuv as a seperate package, which p6 depends on (at least package-wise), I do find that p6 runs slower than I would expect though... 13:03
I'm too tired for this headache, I'm just going to install new packages and hope that solves everything
mornfall well, it's not super fast even in an optimized build, so that might mean nothing 13:04
Summertime feels pretty snippy when using any batchy kinda stuff, its just for-loops and appendy mutations seem to go ultraslow 13:05
tbrowder .tell jjmerelo i've edited your day 2 post a bit: adjusted the date/time published (p6 wp is on UTC, so you use the exact date an time of 00:01 which displays in the summary as 12:01 AM); also, removed the duplicate title and closed up some of the extra newlines inside obvious paras. you may want to tweak the content by hand some more. i would like you to completely update day 2 content later following the procedures i'm 13:08
updating in perl6/advent (when i finish them later today). BTW, i haven't seen you use cuddled elses before!!
yoleaux tbrowder: I'll pass your message to jjmerelo.
mornfall timotimo: (but fwiw, the profile now renders okay with moarperf, so there's some good news too) 13:11
13:11 lizmat joined, p6bannerbot sets mode: +v lizmat 13:15 MasterDuke left
Summertime yep, works absolutely fine with packages from that repo, so its fedora's packages I need to go start a fite with 13:16
13:44 andymcd joined, p6bannerbot sets mode: +v andymcd 13:45 andymcd left
lucasb m: say (1,2,2,3,3,3).categorize({$_}) 13:48
camelia {1 => [1], 2 => [2 2], 3 => [3 3 3]}
lucasb m: say (1,2,2,3,3,3).categorize(*)
camelia Doesn't make sense to categorize with itself
in block <unit> at <tmp> line 1
SmokeMachine m: say (1,2,2,3,3,3).categorize(*.self) 13:51
camelia {1 => [1], 2 => [2 2], 3 => [3 3 3]}
lucasb
^^ with regard "Doesn't make sense" :-) 13:52
tbrowder imho wordpress is a terrible platform for our advent articles. i just looked at perladvent.org and its basic look is good and could be dressed up for us. i’ll bet it’s lots easier to use and maintain than what we have (which is beautiful for sure—when the formatting is right). 14:00
14:01 ufobat_ left 14:08 pmurias joined, p6bannerbot sets mode: +v pmurias
pmurias SmokeMachine: hi 14:09
yoleaux 01:11Z <SmokeMachine> pmurias: you should try MemoizedDOM... :)
12:49Z <SmokeMachine> pmurias: Any idea of why Im getting this error? www.irccloud.com/pastebin/4DYflois/
pmurias SmokeMachine: maybe if I could have a look at what you are compiling I would have a better idea 14:10
lucasb I share tbrowder opinion with regard wordpress 14:14
14:14 pmurias left
lucasb I never did any post in my life, but I guess wordpress doesn't give much freedom in contrast with a self-hosted static html solution 14:14
14:15 pmurias joined, p6bannerbot sets mode: +v pmurias
lucasb I admire the perl5 advent. I think they organize their event in a private mailing list. I don't think it's a bad idea to borrow their ideas for next year. Hosting things in perl6.github.io/advent 14:16
SmokeMachine pmurias: it’s the same code as in the 6pad but in different files... 14:19
tbrowder we obviously have good web design people here—the docs pages look pretty nice to me. should be able to have somthing similar for advent. author submits md file named yyyy-mm-dd and site tiols take care of md2html and scheduling at the right time!
SmokeMachine pmurias: sorry, I’m not with my Mac now...
tbrowder s/tiols/tools/
author can then update via webeditor as needed. 14:21
SmokeMachine pmurias: perl6.github.io/6pad/#ada3d7e0a425...426a97039f
tbrowder comments and notifications are nice to have but i don’t know how that would work except maybe via github webhooks 14:22
pmurias SmokeMachine: I'll add into onto my pile of stuff to investigate/fix 14:23
SmokeMachine pmurias: could it be because I’m trying to use use and different files? 14:27
tbrowder one example of a wordpress irritant to me: the title is used as a key to a post. thus some articles wind up with double titles because there is a separate, special title block in the wp editor which has to be filled and sometimes the title in the html content is not removed by the author.
pmurias SmokeMachine: I have to try running it myself, I haven't seen that exact error before 14:28
tbrowder (must lower blood pressure...)
14:29 qiqi left 14:30 tmtvl joined 14:31 p6bannerbot sets mode: +v tmtvl 14:33 Woodi joined, masak joined
sena_kun m: enum <one>; say one.HOW; given one { when Int && $_.HOW ~~ Metamodel::ClassHOW { say "Bad"; }; when Int && $_.HOW ~~ Metamodel::EnumHOW { say "Good" } } 14:33
camelia Perl6::Metamodel::EnumHOW.new
Bad
14:34 masak is now known as Guest98771, p6bannerbot sets mode: +v Woodi, p6bannerbot sets mode: +v Guest98771
sena_kun is it just me or a second part(which checks if it's an Int or an enum) gets ignored? 14:34
m: enum <one>; if one ~~ Int && one.HOW ~~ Metamodel::ClassHOW { say "Bad" } elsif one ~~ Int && one.HOW ~~ Metamodel::EnumHOW { say "Good" } 14:35
camelia Good
14:36 kybr joined, p6bannerbot sets mode: +v kybr 14:39 caa51h joined
tobs m: enum <one>; say one.HOW; given one { when $_ ~~ Int && .HOW ~~ Metamodel::ClassHOW { say "Bad"; }; when $_ ~~ Int && .HOW ~~ Metamodel::EnumHOW { say "Good" } } # sena_kun 14:40
camelia Perl6::Metamodel::EnumHOW.new
Good
14:40 p6bannerbot sets mode: +v caa51h
SmokeMachine pmurias: if any news, please let me know... 14:40
sena_kun tobs, thanks. is explicit $_ usage sets topic for `.HOW` to be called on? 14:42
tobs sena_kun: given sets $_, and .HOW is (always) just shorthand for $_.HOW 14:43
sena_kun tobs, if $_ is set by given and .HOW is called on it, why my condition fail then?
tobs I think you using "Int && some-bool" above is what creates the problem. Did you mean "$_ ~~ Int && some-bool"?
sena_kun I did, but shouldn't `when Int` be equivalent to `when $_ ~~ Int`, ah, hmm, no. 14:44
it likely shouldn't.
14:44 pmurias left
tobs it should, but I think it's different when you use && too 14:44
sena_kun yeah, that might be it.
anyway, thanks! 14:45
14:45 pmurias joined, p6bannerbot sets mode: +v pmurias 14:47 pmurias left 14:51 pmurias joined, p6bannerbot sets mode: +v pmurias 15:02 clarkema joined, p6bannerbot sets mode: +v clarkema
clarkema Hi all 15:03
Suppose I have two lists of equal length, one of values and one which is a 'mask', containing just True or False. What's the best way to get a new list, containing only the values from the first list where the corresponding position in the 'mask' list is True? 15:04
I've been playing around with a grep, trying to get the index of the first list and compare with that slot in the mask list, but that doesn't feel right
lucasb m: say ((1,2,3) Z=> (True,False,True)).grep(*.value)».key 15:06
camelia (1 3)
lucasb there must be some better way :)
sena_kun that have to be about right, I think 15:08
clarkema lucasb: interesting idea!
15:09 coet joined, p6bannerbot sets mode: +v coet
sena_kun m: my @mask = True, False, True; my @a = do gather { for <a b c>.kv -> $i, $v { take $v if @mask[$i] } }; say @a; 15:10
camelia [a c]
clarkema is there a way to get the index in a grep?
sena_kun doesn't create a zipped list just to throw things away.
lucasb m: my @mask = True,False,True; say ({ $^x if @mask[$^i] } for <a b c>.kv) # based on sena_kun's 15:13
camelia (a c)
clarkema There really _is_ MTOWTDI 15:16
tobs m: my @values = 1,2,3; my @mask = True, False, True; say @values[@mask.grep(*.so, :k)] 15:18
camelia (1 3)
clarkema AoC is such a good source of interesting questions 15:19
15:27 zakharyas joined, p6bannerbot sets mode: +v zakharyas
SmokeMachine m: say ((1,2,3) Z=> (True,False,True)).Set 15:35
camelia set(1 3)
clarkema In this particular case I need the order to be preserved -- they're going to get stitched back together into a string 15:36
lucasb day 2? 15:37
clarkema yup 15:38
lucasb ah, the "find the two strings that differ in exactly 1 character" part? let me think :) 15:44
15:44 coet left, coet|CAD joined, p6bannerbot sets mode: +v coet|CAD, coet|CAD left
clarkema Yup, fine them and then report the answer, which is the string without the differenting character 15:44
hence the mask idea ;) 15:45
I mean you can just do it using grep over a zip of pairs, but I wanted to try playing around
15:45 coet joined, p6bannerbot sets mode: +v coet, coet left 15:47 coet joined, p6bannerbot sets mode: +v coet, coet left 15:48 coet joined, p6bannerbot sets mode: +v coet
SmokeMachine m: my &a := {$^a if $^b}; say flat <a b c> Z[&a] (True, False,True) 15:48
camelia (a c)
tobs SmokeMachine: That was on the tip of my tongue :) 15:50
clarkema SmokeMachine: nice! 15:52
15:53 rindolf left 15:55 carl^ joined 15:56 carl^ left, rindolf joined 15:57 p6bannerbot sets mode: +v rindolf 15:58 rindolf left 16:00 rindolf joined, p6bannerbot sets mode: +v rindolf
tobs I haven't read the task, but finding strings which differ in exactly one character sounds like a job for the one junction 16:01
m: my @strings = "abcd", "abde", "abce", "1bce", "123d"; say ([X] @strings xx 2).grep: -> ($s, $t) { one [Zne] ($s, $t)».comb } 16:02
camelia ((abcd abce) (abde abce) (abce abcd) (abce abde) (abce 1bce) (1bce abce))
tobs alas, I get each pair twice, effectively because *I* don't care about ordering but X does 16:03
16:06 jmerelo joined 16:07 p6bannerbot sets mode: +v jmerelo
jmerelo squashable6: status 16:07
squashable6 jmerelo, The date for the next SQUASHathon is not set
jmerelo Right
lucasb m: { say ($^a, $^b) if ($^a.comb Z $^b.comb).flat.grep({ $^x !eq $^y }) == 1 } for ($_ X $_ given <ab ac jk xy>).flat 16:08
camelia (ab ac)
(ac ab)
lucasb ^^ me too get double pairs
16:15 pmurias left, noyb joined, pmurias joined, p6bannerbot sets mode: +v pmurias, noyb left
Xliff m: say <ab>.comb Z <ac>.comb 16:19
camelia ((a a) (b c))
16:19 xinming_ joined
tbrowder .ask moritz how do you feel about adding a new top-livel tab on perl6.org for Advent? that would be a convenient place to move from Wordpress. then we could mark it WIP until it is satisfatory—hopefully in time for next year. 16:19
lucasb private leaderboard in aoc? hey let's create one for we #perl6 :-)
Xliff m: say <ab>.comb X <ac>.comb
camelia ((a a) (a c) (b a) (b c))
lucasb my rank position is over 10k, hehe 16:20
16:20 p6bannerbot sets mode: +v xinming_
Xliff m: say <ac>.comb X <jk>.comb 16:20
camelia ((a j) (a k) (c j) (c k))
tbrowder we could use the theming and all you use now on wp
clarkema Yeah, I ignore the global board
it's a waste of time on the UK/EU timezone -- I'm certainly not getting up at 5am on a Sunday to compete ;) 16:21
lucasb 169430-b1c331b2 <-- code
clarkema: yeah, me too :-)
16:22 xinming left
lucasb nice, clarkema! I'm anonymous user. I just created a throwaway reddit account for this :) 16:23
16:24 pmurias left
jmerelo tbrowder: do you mean using perl6.org itself? I kind of like wordpress.com, if not for anything else, for the convenience... 16:25
clarkema lucasb: i do like the idea of a #perl6 board, and using it to trigger discussion
moritz tbrowder: do we have a toolchain for a blog-like thing on perl6.org? 16:26
16:26 pmurias joined, p6bannerbot sets mode: +v pmurias 16:27 jmerelo left, jmerelo joined 16:28 p6bannerbot sets mode: +v jmerelo
sena_kun m: Any ~~ (10 => 'ten') 16:29
camelia No such method '10' for invocant of type 'Any'
in block <unit> at <tmp> line 1
sena_kun is this a bug?
jmerelo m: say (10 => 'ten').^name 16:30
camelia Pair
jmerelo sena_kun: definitely a weirdness
sena_kun I see. I wonder if it is worth a ticket.
jmerelo sena_kun: ~~ is equivalent to "ACCEPTS" 16:31
16:31 MilkmanDan joined, p6bannerbot sets mode: +v MilkmanDan
jmerelo m: say Any.ACCEPTS( (10=>ten)) 16:31
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
ten used at line 1. Did you mean 'tan'?
jmerelo m: say Any.ACCEPTS( (10=>ten))
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
ten used at line 1. Did you mean 'tan'?
jmerelo m: say Any.ACCEPTS( (10=>"ten"))
camelia True
jmerelo m: say Any ~~ (10=>"ten")
camelia No such method '10' for invocant of type 'Any'
in block <unit> at <tmp> line 1
lucasb it's the other way around, Pair.ACCEPTS
jmerelo m: say Any ~~ 10=>"ten"
camelia False => ten
jmerelo m: say (10=>"ten").ACCEPTS( Any ) 16:32
camelia No such method '10' for invocant of type 'Any'
in block <unit> at <tmp> line 1
jmerelo Precedence rules?
lucasb sena_kun: I would say it's worth an issue, yes. It's calling Pair.key on the subject, right?
x ~~ (foo=>10); # it's calling x.foo, why? 16:33
sena_kun Dunno. Just stumbled upon this, no more. Worse for me is that my design has turned out to be a mess, which is... not good. :) 16:34
creating a ticket...
jmerelo sena_kun++
tobs m: say "/tmp" ~~ :e 16:40
camelia No such method 'e' for invocant of type 'Str'
in block <unit> at <tmp> line 1
tobs m: say "/tmp".IO ~~ :e
camelia True
tobs That behaviour for pairs at least supports this syntax
lucasb ah, that was the intention, thanks for the reminder :-)
This use of P6 pairs it's what other languages have a Symbol data type for (I think) 16:42
well, expect that symbols are unique across the process and pairs don't 16:43
*except
clarkema yeah, they're definitely not the same as lisp-y symbols
tobs m: say "/tmp".IO ~~ :e & :!d
camelia False
clarkema I do wish they were available in p6 16:44
tobs it's kinda cute
Ulti is there some big thing Im missing on why Str can't be Positional? just wrote some ugly looking .comb / .substr / .join code and can't think of something nicer looking 16:49
it feels like I could shim that functionality in using substr, just wondering if/why that would be bad? 16:50
16:51 lizmat left
jmerelo Ulti: I suspect it's got something to do with Unicode. But I guess it's simply because it's better to consider a string a single thing. 16:52
Ulti yeah I just checked the docs Uni actually does do Positional
but you can kind of manipulate a Str in a similar way, Im just wondering if it really matters that underneath you're hiding things like bytes 16:53
Str is quite explicit in numerical things being grapheme level
I guess someone might want to remove a combining character or something so it gets unintuitive quickly
timotimo Ulti: there's a module in the ecosystem for python-ish strings, but i think it makes most code explode 16:54
Ulti orly why would code explode 16:58
timotimo because code in the core setting doesn't expect strings to behave like that :D
Ulti I guess for blah where blah on a string suddenly iterates characters is a big assumption change
but then most of the string like types are actually positional if you look at the type map 16:59
just make a type called String instead of Str :D
timotimo well, i guess :)
Ulti give it some nicer methods for common string tasks... feels like a fun module waiting to happen 17:00
timotimo make a sub that does comb/map/join all in one step and call it as a method syntactically?
Ulti you mean as an operator rather than the positional interface
timotimo yeah 17:01
Ulti yeah thats a nice solution to not break the world
timotimo m: sub smap(Str $a, Code $c) { $a.comb.map($c).join("") }; "hello".&smap(*.succ.uc).say
camelia IFMMP
17:03 clarkema left
Ulti feels super expensive though 17:03
unless that is heavily optimised away
to just point into the middle of a string :/
you really want to go through substr
which I assume does the pointer thing but knows how to jump around at a grapheme level rather than a byte level 17:04