[00:39] <dalek> nqp: 6f2993e | (Zoffix Znet)++ | tools/build/MOAR_REVISION:

[00:39] <dalek> nqp: Bump MoarVM Version

[00:39] <dalek> nqp:

[00:39] <dalek> nqp: Bring in latest changes for latest tests

[00:39] <dalek> nqp: http://irclog.perlgeek.de/perl6-dev/2016-09-23#i_13267048

[00:39] <dalek> nqp: review: https://github.com/perl6/nqp/commit/6f2993ed7b

[00:41] <dalek> rakudo/nom: 8aa0aa1 | (Zoffix Znet)++ | tools/build/NQP_REVISION:

[00:41] <dalek> rakudo/nom: Bump NQP

[00:41] <dalek> rakudo/nom:

[00:41] <dalek> rakudo/nom: Bring in latest changes for latest tests

[00:41] <dalek> rakudo/nom: http://irclog.perlgeek.de/perl6-dev/2016-09-23#i_13267048

[00:41] <dalek> rakudo/nom: review: https://github.com/rakudo/rakudo/commit/8aa0aa16cf

[00:52] <dalek> roast: 7dfe5a9 | (Zoffix Znet)++ | S17-procasync/stress.t:

[00:52] <dalek> roast: Do only 100 runs instead of 10000

[00:52] <dalek> roast:

[00:52] <dalek> roast: We don't need a test file that takes several times longer to run than the entire rest of the stresstest.

[00:52] <dalek> roast: review: https://github.com/perl6/roast/commit/7dfe5a9732

[00:53] <Zoffix> Someone was feeling ambitious...

[00:53] <yoleaux2> 23 Sep 2016 23:08Z <MasterDuke> Zoffix: i just realized why t/spec/S17-procasync/stress.t is failing for you (and lizmat i believe), nqp and rakudo haven't had their MOAR_REVISION and NQP_REVISION bumped to pick up jnthn's fix

[00:55] <Zoffix> MasterDuke++ yeah, that makes it pass for me now.

[01:34] <travis-ci> Rakudo build failed. Zoffix Znet 'Bump NQP

[01:34] <travis-ci> https://travis-ci.org/rakudo/rakudo/builds/162356167 https://github.com/rakudo/rakudo/compare/b3c92baad264...8aa0aa16cf01

[01:35] <MasterDuke> t/04-nativecall/13-union.t

[01:36] <MasterDuke> Zoffix: on one of my systems that test wouldn't consistently fail with only 100 iterations (pre jnthn's fix)

[01:38] <MasterDuke> btw all, my bad on adding that test before the MoarVM bump, i forgot i had built a custom MoarVM

[05:45] <japhb> .tell timotimo I believe you were asking about slowness of RenderQueue.enqueue in https://github.com/timo/cellular-automata-tests/blob/master/animated_blocks.p6 -- Guesses: postincrements, using increment on a native int, wasting the last increment of $inspos, returning a value (instead of Nil), taking $rect as an object (thus accessing XYWH using methods)

[05:45] <yoleaux2> japhb: I'll pass your message to timotimo.

[09:06] <psch> oh grr

[09:07] <psch> so there's java.util.Arrays.asList

[09:07] <psch> which you can throw an array into and get some List-implementing type back

[09:07] <psch> it's a varargs sig

[09:08] <psch> so with e.g. "Object[] objs = new Object[] { 1, 2.0, "foo" }; Arrays.asList(objs).get(0)" you get the original array back.  that is, the returned List contains objs at position 0

[09:09] <psch> the trick is to be explicit that you're already passing an array: Arrays.asList((Object[]) objs)

[09:09] <psch> doing that, we get 1 from *.get(0)

[09:09] <psch> which is a really, really weird way to implement argument flattening in my opinion

[09:09] <psch> ...not to mention i don't even know if i could still add elements afterwards, so it's probably not even real flattening

[09:10] <psch> haha, no, it's not

[09:10] <psch> if there's another arg after that you get that as *.get(1) and *.get(0) again has objs

[09:10] <psch> ffs java

[09:11] <[Tux]> This is Rakudo version 2016.09-36-g8aa0aa1 built on MoarVM version 2016.09-1-gdebb859

[09:11] <[Tux]> csv-ip5xs        9.254

[09:11] <[Tux]> test            17.681

[09:11] <[Tux]> test-t           7.352

[09:11] <[Tux]> csv-parser      17.937

[09:19] <dalek> rakudo/nom: 539a7d1 | peschwa++ | / (3 files):

[09:19] <dalek> rakudo/nom: Support marshalling of Positional to List<Object>

[09:19] <dalek> rakudo/nom:

[09:19] <dalek> rakudo/nom: ...as well as add a test.

[09:19] <dalek> rakudo/nom:

[09:19] <dalek> rakudo/nom: Typing generic lists as Positional.of() needs a cleaner way to

[09:19] <dalek> rakudo/nom: map types between Rakudo and Java than we have at the moment.

[09:19] <dalek> rakudo/nom: Suggestions welcome.

[09:19] <dalek> rakudo/nom: review: https://github.com/rakudo/rakudo/commit/539a7d17ff

[09:29] <psch> too bad there's no associative analogue to java.util.Arrays :l

[10:04] <lizmat> Files=1139, Tests=53043, 240 wallclock secs (13.26 usr  3.99 sys + 1450.70 cusr 138.57 csys = 1606.52 CPU)

[10:13] <Zoffix> MasterDuke, on mine it failed nearly instantly. It's fine if 100 iterations is not consistently failing on some boxes, as stresstests are run many times and these would show up as a flapper. Making a test file run for 12 minutes when the entire rest of the stresstest finishes in just 2 minutes all for the same of consistently catching a possible regression is just not worth it.

[10:13] <Zoffix> s/same/sake/;

[10:14] <travis-ci> Rakudo build passed. Pepe Schwarz 'Support marshalling of Positional to List<Object>

[10:14] <travis-ci> https://travis-ci.org/rakudo/rakudo/builds/162399103 https://github.com/rakudo/rakudo/compare/8aa0aa16cf01...539a7d17ffce

[11:12] <dalek> roast: 302947c | (Zoffix Znet)++ | / (2 files):

[11:12] <dalek> roast: Do not rely on Perl 6 Implementation's auxiliary files

[11:12] <dalek> roast: review: https://github.com/perl6/roast/commit/302947cc87

[11:24] <Zoffix> Goddam windows update made Chrome's history links colors blue and it's driving me insane. Such a jarring sight to my black scheme and there's apparently no way to change it.

[11:28] <nine> Zoffix: 12 minutes?? It's taking 4 minutes here. Which curiously is only 80 seconds more than the version reduced to 100 iterations

[11:29] <Zoffix> nine, what OS are you on? The 100 iterations take 7 seconds on my box

[11:29] <Zoffix> nine, and I extrapolated the 7 seconds it takes to run to 700 seconds it would've taken it to run. I aborted it without waiting for it to complete.

[11:30] <Zoffix> Even with 4 minutes that 200% longer than the entire test suite (on my box)

[11:32] <nine> Zoffix: Linux

[11:32] <Zoffix> ¯\_(ツ)_/¯

[11:33] <Zoffix> Actually, it takes 2 seconds: https://gist.github.com/zoffixznet/f399ba31af626e163829b1b95c630e15

[11:35] <dalek> roast: 92fb31d | (Zoffix Znet)++ | S17-procasync/stress.t:

[11:35] <dalek> roast: Bump number of iterations by 4x

[11:35] <dalek> roast: review: https://github.com/perl6/roast/commit/92fb31daa4

[11:36] <Zoffix> oh wait wrong loop :P

[11:37] <dalek> roast: 389e5e9 | (Zoffix Znet)++ | S17-procasync/stress.t:

[11:37] <dalek> roast: Bump number of iterations by 4x

[11:37] <dalek> roast: review: https://github.com/perl6/roast/commit/389e5e99e5

[11:38] <nine> I'll try again once my backup's finished. Maybe that's causing it to be so slow

[11:41] <mst_> Zoffix: whose is ilbot3 ?

[11:41] <Zoffix> mst, logger for http://irclog.perlgeek.de/perl6-dev/today

[11:41] <Zoffix> Oh, whose.... moritz's

[11:42] <mst> moritz_: hey, ilbot3 is now the only thing other than my in the old #p6dev - disconnect it and I'll turn off the lights on the channel on my way out? :)

[11:42] <mst_> GROUP

[11:42] <mst_> gah

[11:42] <Zoffix> heh

[11:43] <mst> fucking computers, how do they work

[12:12] <dogbert17> Zoffix: wrt to #129321, there are more detailed docs of deepmap at https://design.perl6.org/S32/Containers.html#List

[12:38] * Zoffix is busy with other stuff

[12:44] <Zoffix> But maybe you can read those docs, figure out how it's supposed to behave and submit a PR? :)

[12:45] <dogbert17> Uh oh :-) I can at least give it a shot

[12:52] * dogbert17 hmm might have spoken to soon, this nqp code looks quite impenetrable :(

[12:52] <Zoffix> :(

[12:53] <dogbert17> still, this part of the docs seems interesting "Elements that are not iterable are considered leaf values and mapped through the supplied expression."

[13:00] * dogbert17 wonders why he mentioned deepmap in the bug report when the problem is in duckmap, facepalm

[13:04] <Zoffix> .classify-list and .categorize-list are odd ducks. Completely unspecced too

[13:04] <Zoffix> Especially the Baggy.categorize-list vs. Hash.categorize-list, 'cause the latter offers "more" features that the former can.

[13:07] * Zoffix sees a rather heated discussion about them in 2013... :)

[13:10] * dogbert17 wrote the docs for the Baggy ones (borrowing from design.perl6.org in the process)

[13:12] * Zoffix will be expanding them today

[13:14] * dogbert17 vaugely remembers not writing docs for all variants (3)

[13:14] * dogbert17 returns to the duckmap code, won't give up so easily

[13:15] <Zoffix> dogbert17++

[13:20] <dalek> roast: c3393b6 | (Zoffix Znet)++ | S32-list/classify.t:

[13:20] <dalek> roast: Remove fudged test

[13:20] <dalek> roast:

[13:20] <dalek> roast: Subsumed by more comprehensive tests to be added today. The corresponding ticket

[13:20] <dalek> roast: will also be resolved at that time.

[13:20] <dalek> roast: review: https://github.com/perl6/roast/commit/c3393b671b

[13:34] <dogbert17> Zoffix: hmm, the doc in S32 is a bit vague as to what duckmap should do if 'expression' returns undef and the element in question doesn't contain subelements. Who do you think can clarify that, lizmat, moritz?

[13:34] <Zoffix> ¯\_(ツ)_/¯

[13:35] <dogbert17> I'll jump over to #perl6 and see if moritz is around ...

[13:36] <timotimo> i'd say TimToady should be able to clarify; if i remember correctly, he came up with duckmap and the other distinctions

[13:36] <yoleaux2> 05:45Z <japhb> timotimo: I believe you were asking about slowness of RenderQueue.enqueue in https://github.com/timo/cellular-automata-tests/blob/master/animated_blocks.p6 -- Guesses: postincrements, using increment on a native int, wasting the last increment of $inspos, returning a value (instead of Nil), taking $rect as an object (thus accessing XYWH using methods)

[13:38] <dogbert17> timotmo, thx

[13:39] <timotimo> japhb: i've already tried changing the increments to pre-increments and then to just additions on top of the original. i haven't tried passing X and Y as simple ints yet (and of course i could leave W and H out, as they are program-constant)

[13:43] <Zoffix> masak, I have a Q

[13:43] <dogbert17> .tell TimToady trying to do something about RT #129321. What should duckmap do/return if 'expression' returns undef and the element in question doesn't contain subelements? E.g. what should the following code return if anything? my @a = [1, "a"]; dd duckmap({ $_ ~~ Int ?? $_ !! Any }, @a);

[13:43] <yoleaux2> dogbert17: I'll pass your message to TimToady.

[13:44] <Zoffix> masak, I plan to make the code in this ticket throw: https://rt.perl.org/Ticket/Display.html?id=125923#ticket-history

[13:44] * masak looks

[13:44] <Zoffix> masak, BagHash.classify-list list works, but since BagHash can't nest, multi-level classify can't be done on it.

[13:45] <Zoffix> m: BagHash.new.classify-list( {.comb}, 20..40

[13:45] <Zoffix> )

[13:45] <camelia> rakudo-moar 539a7d: OUTPUT«===SORRY!=== Error while compiling <tmp>␤Unable to parse expression in argument list; couldn't find final ')' ␤at <tmp>:1␤------> gHash.new.classify-list( {.comb}, 20..40⏏<EOL>␤»

[13:45] <Zoffix> m: BagHash.new.classify-list( {.comb}, 20..40)

[13:45] <camelia> rakudo-moar 539a7d: OUTPUT«Earlier failures:␤ Type Int does not support associative indexing.␤  in block <unit> at <tmp> line 1␤␤Final error:␤ Cannot resolve caller postfix:<++>(Failure); none of these signatures match:␤    (Mu:D $a is rw)␤    (Mu:U $a is rw)␤    (In…»

[13:45] <masak> I... I never really grokked multi-level classify

[13:45] <masak> it kinda seemed to me like an extra layer of complexity looking for a problem

[13:46] <Zoffix> it just creates a new hash level for each item in the list returned in by the &mapper

[13:46] <Zoffix> m: dd % .classify-list( {.comb}, 20..40)

[13:46] <camelia> rakudo-moar 539a7d: OUTPUT«Hash % = {"2" => ${"0" => $[20], "1" => $[21], "2" => $[22], "3" => $[23], "4" => $[24], "5" => $[25], "6" => $[26], "7" => $[27], "8" => $[28], "9" => $[29]}, "3" => ${"0" => $[30], "1" => $[31], "2" => $[32], "3" => $[33], "4" => $[34], "5" => $[35], "6"…»

[13:46] <Zoffix> m: dd % .classify-list( {rand > .5 ?? <foo bar> !! <ber bor> }, ^10 )

[13:46] <camelia> rakudo-moar 539a7d: OUTPUT«Hash % = {:ber(${:bor($[1, 2, 3, 4, 7, 8])}), :foo(${:bar($[0, 5, 6, 9])})}␤»

[13:46] <masak> also, I've seen the name classify-list, but I haven't bothered learning what it is an how it differs from regular classify

[13:47] <masak> (though apparently, I see in that RT, I've submitted bugs on it)

[13:47] <Zoffix> classify takes List as an invocant and returns a classified Hash; classify-list takes a Hash/Baggy as an invocant and populates it by the provided list

[13:48] <masak> huh

[13:48] <Zoffix> feels like a bit of an overengineering to me, but I saw some heated debates about it in 2013, so I don't know if I want to bring it up again

[13:48] <masak> it's... an oddly invocant-modification-y method

[13:49] <Zoffix> Yeah, you mentioned that in 2013 too. :)

[13:49] <masak> I'm not surprised to learn I did! :P

[13:49] <Zoffix> :D

[13:49] * masak feels like diakopter, all reset and remembering nothing about previous discussions

[13:50] <masak> anyway, I'm not sure I can help in this case. sorry.

[13:50] <Zoffix> m: dd BagHash.new.classify-list( {rand > .5 ?? <foo bar> !! <ber bor> }, ^10 )

[13:50] <camelia> rakudo-moar 539a7d: OUTPUT«Earlier failures:␤ Type Int does not support associative indexing.␤  in block <unit> at <tmp> line 1␤␤Final error:␤ Cannot resolve caller postfix:<++>(Failure); none of these signatures match:␤    (Mu:D $a is rw)␤    (Mu:U $a is rw)␤    (In…»

[13:50] <Zoffix> ^ so this would throw

[13:50] <timotimo> there used to be an :into argument for classify or something, no?

[13:50] <Zoffix> I guess I didn't have a Q but an FYI :)

[13:50] <masak> the RT seems to clearly describe a bug, but I don't know about the likely cause or reasonable fixes

[13:51] <timotimo> that was seen as a design smell

[13:51] <masak> timotimo: :into -- whatever happened to %h.=stuff ?

[13:51] <timotimo> that was before you could call .classify-list on a hash or similar

[13:51] <timotimo> in fact, classify-list was the solution to that smell

[13:51] <Zoffix> masak, the cause is that BagHash cannot be nested. The code tries to nest it and instead of a nested Baggy gets an item count (Int) and it explodes when it tries to associative-index it.

[13:52] <Zoffix> hence why I'll make it throw on attempts to multi-level classify

[13:52] <timotimo> yeah, better make it throw a helpful error than that

[13:52] * masak starts writing stuff, but realizes it constitutes bikeshedding three years after the fact, and so removes it

[13:59] <timotimo> hehe

[13:59] <timotimo> are there already inspirations for your next blog post for strangelyconsistent? :)

[14:04] <masak> I have a list of such inspirations, yes

[14:05] <masak> not a lot of tuits to write, though :/

[14:05] <timotimo> i understand ;(

[14:11] <Zoffix> m: use nqp; say nqp::istype({['foo', 'ber']}(), Iterable)

[14:11] <camelia> rakudo-moar 539a7d: OUTPUT«1␤»

[14:11] <Zoffix> m: use nqp; say nqp::istype([['foo', 'ber']][0], Iterable)

[14:11] <camelia> rakudo-moar 539a7d: OUTPUT«0␤»

[14:11] <Zoffix> Why is it 0 in the second case?

[14:11] <timotimo> single argument rule

[14:12] <timotimo> m: say [['foo', 'ber']].perl

[14:12] <camelia> rakudo-moar 539a7d: OUTPUT«["foo", "ber"]␤»

[14:12] <timotimo> m: say [['foo', 'ber'],].perl

[14:12] <camelia> rakudo-moar 539a7d: OUTPUT«[["foo", "ber"],]␤»

[14:12] <Zoffix> m: use nqp; say nqp::istype([['foo', 'ber'],][0], Iterable)

[14:12] <camelia> rakudo-moar 539a7d: OUTPUT«1␤»

[14:12] <timotimo> m: say {['foo', 'ber']}.perl

[14:12] <camelia> rakudo-moar 539a7d: OUTPUT«-> ;; $_? is raw { #`(Block|66833472) ... }␤»

[14:12] <timotimo> oh, you're calling it

[14:12] <Zoffix> m: use nqp; say nqp::istype(%( 1 => ['foo', 'ber'] ){1}, Iterable)

[14:12] <camelia> rakudo-moar 539a7d: OUTPUT«1␤»

[14:13] <Zoffix> m: use nqp; say nqp::istype(%( 1 => <foo ber> ){1}, Iterable)

[14:13] <camelia> rakudo-moar 539a7d: OUTPUT«1␤»

[14:13] <Zoffix> m: dd % .classify-list: %(1 => <foo ber>), 1

[14:13] <camelia> rakudo-moar 539a7d: OUTPUT«Hash % = {"foo ber" => $[1]}␤»

[14:13] <Zoffix> Hm, OK. bug is elsehwere. Thanks

[14:14] <timotimo> YW

[14:47] <dalek> rakudo/nom: 9e4796d | (Zoffix Znet)++ | src/core/Hash.pm:

[14:47] <dalek> rakudo/nom: Remove trailing whitespace

[14:47] <dalek> rakudo/nom: review: https://github.com/rakudo/rakudo/commit/9e4796de8d

[14:49] <dalek> rakudo/nom: 3623490 | (Zoffix Znet)++ | / (2 files):

[14:49] <dalek> rakudo/nom: Fix broken multi-level Hash.classify-list with % or @ mappers

[14:49] <dalek> rakudo/nom:

[14:49] <dalek> rakudo/nom: The multi-item lists received from % and @ mappers arrive to us as items, so

[14:49] <dalek> rakudo/nom: the @keys contains a single item that gets used as a single hash classification

[14:49] <dalek> rakudo/nom: key.

[14:49] <dalek> rakudo/nom:

[14:49] <dalek> rakudo/nom: Coerce with @ to get correct number of keys.

[14:49] <dalek> rakudo/nom: review: https://github.com/rakudo/rakudo/commit/3623490efb

[15:32] <Zoffix> Actually, we don't have 129K tests in roast. We have more, because tests run in subtest()s are not reported in the count.

[15:37] <AlexDaniel> Zoffix: how did you get this number?

[15:37] <Zoffix> AlexDaniel, it's reported at the end by the harness

[15:37] <AlexDaniel> ah

[15:37] <timotimo> "how did you get this number? never call me again!"

[15:37] <AlexDaniel> thought about going through the whole history to make a graph :)

[15:39] <travis-ci> Rakudo build failed. Zoffix Znet 'Remove trailing whitespace'

[15:39] <travis-ci> https://travis-ci.org/rakudo/rakudo/builds/162434306 https://github.com/rakudo/rakudo/compare/539a7d17ffce...9e4796de8d80

[15:40] <Zoffix> t/04-nativecall/13-union.t

[15:46] <Zoffix> m: dd MixHash.new.classify-list: {$_}, lazy <a b b c>

[15:46] <camelia> rakudo-moar 362349: OUTPUT«("a"=>1,"c"=>1,"b"=>2).MixHash␤»

[15:46] <Zoffix> m: dd Hash.new.classify-list: {$_}, lazy <a b b c>

[15:46] <camelia> rakudo-moar 362349: OUTPUT«Failure.new(exception => X::Cannot::Lazy.new(action => "classify", what => Any), backtrace => Backtrace.new)␤»

[15:47] <Zoffix> I wonder what's the reasoning for adding... what looks to me as purely artificial...  restriction.

[15:50] <timotimo> we don't have lazy hashes, and they're kind of ... problematic :)

[15:50] <timotimo> lazy is a synonym for "could very well be infinite" in rakudo

[15:51] <Zoffix> ok

[16:20] <dalek> rakudo/nom: 72467f9 | peschwa++ | src/vm/jvm/runtime/org/perl6/rakudo/RakudoJavaInterop.java:

[16:20] <dalek> rakudo/nom: Rename a variable to be more self-documenting.

[16:20] <dalek> rakudo/nom: review: https://github.com/rakudo/rakudo/commit/72467f9811

[16:20] <dalek> rakudo/nom: 56c66ca | peschwa++ | / (4 files):

[16:20] <dalek> rakudo/nom: Add basic support for marshalling Hash to Java Map

[16:20] <dalek> rakudo/nom:

[16:20] <dalek> rakudo/nom: and add a test. Only supports Map<String, Object> as target type.

[16:20] <dalek> rakudo/nom: review: https://github.com/rakudo/rakudo/commit/56c66ca78d

[16:36] <dalek> rakudo/nom: e4e8238 | (Zoffix Znet)++ | src/core/Exception.pm:

[16:36] <dalek> rakudo/nom: Add X::Invalid::ComputedValue exception

[16:36] <dalek> rakudo/nom:

[16:36] <dalek> rakudo/nom: Purpose is to use it for conditions where argument values given to a method are

[16:36] <dalek> rakudo/nom: correct, but produce some invalid condition during the method's operation.

[16:36] <dalek> rakudo/nom:

[16:36] <dalek> rakudo/nom: Example:

[16:36] <dalek> rakudo/nom:

[16:36] <dalek> rakudo/nom: X::Invalid::ComputedValue.new(

[16:36] <dalek> rakudo/nom:     :name<mapper> :method<classify-list> :value('an Iterable item')

[16:36] <dalek> rakudo/nom:     :reason('BagHash cannot be nested and so does not support multi-level classification')

[16:36] <dalek> rakudo/nom: ).throw;

[16:36] <dalek> rakudo/nom:

[16:36] <dalek> rakudo/nom: Produces:

[17:52] <pmurias> is it expected that rakudo generates code that binds to a 'static' lexical?

[17:53] <timotimo> i'm not sure what a static lexical's semantics exactly are

[18:10] <Zoffix> <masak> timotimo: :into -- whatever happened to %h.=stuff ?

[18:10] <Zoffix> <timotimo> that was before you could call .classify-list on a hash or similar

[18:10] <Zoffix> Actually, turns out we still have :into

[18:10] <Zoffix> s: [], 'classify', \(:into, [])

[18:10] <SourceBaby> Zoffix, Sauce is at https://github.com/rakudo/rakudo/blob/e4e8238/src/core/Any.pm#L125

[18:11] <Zoffix> Which for some reason is now failing tests, after I fixed a bug :/

[18:12] <japhb> .ask timotimo Did you try `method enqueue(int $color, int $x, int $y --> Nil)` yet?  If so, did it make any difference?

[18:12] <yoleaux2> japhb: I'll pass your message to timotimo.

[18:20] <Zoffix> m: say <abc xyz>.classify( *.contains: any "a".."f" )

[18:20] <camelia> rakudo-moar e4e823: OUTPUT«{False => [abc xyz xyz xyz xyz xyz xyz], True => [abc]}␤»

[18:26] <Zoffix> m: my %h{Any}; %h{ any ^2 }.push: 42

[18:26] <camelia> rakudo-moar e4e823: OUTPUT«Cannot assign to a readonly variable or a value␤  in any  at gen/moar/m-Metamodel.nqp line 3173␤  in block <unit> at <tmp> line 1␤␤»

[18:26] <Zoffix> m: my %h; %h{ any ^2 }.push: 42

[18:26] <camelia> rakudo-moar e4e823: OUTPUT«Cannot assign to a readonly variable or a value␤  in any  at gen/moar/m-Metamodel.nqp line 3173␤  in block <unit> at <tmp> line 1␤␤»

[18:27] <Zoffix> RT: https://rt.perl.org/Ticket/Display.html?id=129349

[19:19] <dalek> rakudo/nom: 8f2279b | (Zoffix Znet)++ | src/core/ (3 files):

[19:19] <dalek> rakudo/nom: Improve Baggy.classify-list

[19:19] <dalek> rakudo/nom:

[19:19] <dalek> rakudo/nom: - Attempting to classify-list on immutable Baggies now throws useful error

[19:19] <dalek> rakudo/nom: - Giving lazy (infinite) lists to classify-list now produces exception,

[19:19] <dalek> rakudo/nom:     instead of hanging

[19:19] <dalek> rakudo/nom: - Attempting to multi-level classify Baggies now throws, explaining Baggies

[19:19] <dalek> rakudo/nom:     can't nest; Fixes RT#125923 [^1]

[19:19] <dalek> rakudo/nom:

[19:19] <dalek> rakudo/nom: [1] https://rt.perl.org/Ticket/Display.html?id=125923

[19:19] <dalek> rakudo/nom: review: https://github.com/rakudo/rakudo/commit/8f2279b155

[19:27] <dalek> roast: 816b913 | (Zoffix Znet)++ | S32-list/classify-list.t:

[19:27] <dalek> roast: Add tests for [Hash|Baggy].classify-list

[19:27] <dalek> roast: review: https://github.com/perl6/roast/commit/816b913d98

[19:27] <dalek> rakudo/nom: e8a61dc | (Zoffix Znet)++ | t/spectest.data:

[19:27] <dalek> rakudo/nom: Add S32-list/classify-list.t test file

[19:27] <dalek> rakudo/nom: review: https://github.com/rakudo/rakudo/commit/e8a61dc5cb

[19:58] <japhb_> Zoffix__: In IRC::Client, it would be nice to be able to detect if a message was directly to my bot (irc-to-me) during later stages of the event cascade, because I'd like my bot to handle both directed queries ('bot, blerg?') and non-directed commands it recognizes ('.fluux'), but only give a fallback confusion message ("I don't know how to blerg!") in the former case.

[20:00] * Zoffix__ isn't following that

[20:00] <japhb_> Zoffix__: I can see two ways to do that, one very specific (set a flag on the event when it would have considered irc-to-me in the cascade), and one more generic (add a user-code-settable field to messages so that the bot can pass information between cascade layers).  Do you have a preference?

[20:01] <japhb_> Zoffix: Which part is confusing?

[20:01] <Zoffix> the "fallback confusion message"

[20:02] <japhb_> I'm looking to create a bot that can respond to e.g. "bot, google foo" and ".google foo", but only indicate errors when it doesn't recognize a command directly addressed to it.

[20:02] <japhb_> So that another bot in the channel can handle ".bing foo", for instance.

[20:03] <japhb_> That way my bot doesn't pointlessly say "I don't know how to use bing; try 'help'" and then have another bot go and do it.

[20:04] <Zoffix> multi method irc-to-me ($ where /^ 'google' \s+ $<what>=.+/) { ... handle google ... }; multi method irc-to-me ($e) { "Don't know how to handle $e.text()" };  multi method irc-privmsg-channel ($ where /^ '.google' $<what>=.+/ ) { ... handle google... };

[20:04] <japhb_> Right, thought of that, but violates DRY

[20:06] * geekosaur would just factor out "handle google"

[20:08] <japhb_> geekosaur: Also considered that.  That cleans up the contents of the event handlers, but not the duplication of the where clauses.

[20:09] <japhb_> And the problem is that I'm expecting a lot of commands, it seems a bit silly to do all that duplicate event handling just because a true fallback like irc-all or irc-privmsg can't tell if the message originally was addressed directly to the bot, which seems generally useful.

[20:10] <Zoffix> Well, it can. Just match .text() to .server.current-nick() or whatever is it

[20:11] <Zoffix> japhb_, there's also alias() you may try

[20:55] <Zoffix> .tell japhb Here's one way of doing it: https://gist.github.com/zoffixznet/c47f02fc7772147eafdb72e0be1f6dcd  Feel free to open an Issue in the repo and I'll take a look at it. Will probably be just another subclass of IRC::Client::Message

[20:55] <yoleaux2> Zoffix: I'll pass your message to japhb.

[22:28] <ZoffixHack> telnet test

[22:29] <Zoffix> wtf... Can't connect my bots on hack.p6c.org, but telnet irc.freenode.net 6667 works fine :/

[22:47] * geekosaur sees an ipv6 address. could your bots be trying ipv6 instead of ipv4?

[22:48] <geekosaur> or vice versa, some telnets do ipv6

[22:52] <Zoffix> They're trying host

[22:52] <Zoffix> I don't know what IP they're trying

[23:09] <timotimo> would strace tell you?

[23:09] <Zoffix> ^ dalek joined

[23:09] * Zoffix tries again

[23:10] <Zoffix> \o/

[23:44] <Zoffix> Hm. The speculation for classify says "Please note that all Lists must have the same number of elements." in regards to multi-level classifications. What's the reason for that limitation?

[23:45] <Zoffix> And same for categorize :/

[23:46] <geekosaur> and they used ipv6

[23:47] <geekosaur> which is what they have been using, so apparently freenode lost ipv6 connectivity for a bit

[23:47] <geekosaur> (hm, except I think I am using ipv6, don't recall how I set up the znc...)

[23:53] <Zoffix> m: dd <a b c>.classify: sub ($) { return 'a' unless $++; <a b> }

[23:53] <camelia> rakudo-moar e8a61d: OUTPUT«Type Array does not support associative indexing.␤  in block <unit> at <tmp> line 1␤␤Actually thrown at:␤  in block <unit> at <tmp> line 1␤␤»

[23:53] <Zoffix> God, what mess I got myself into.

[23:54] <Zoffix> Because my new .classify-list doesn't care if all mapper's values are of the same depth

[23:54] <Zoffix> m: dd % .classify-list: sub ($) { return 'a' unless $++; <a b> }, <a b c>

[23:54] <camelia> rakudo-moar e8a61d: OUTPUT«Type Array does not support associative indexing.␤  in block <unit> at <tmp> line 1␤␤Actually thrown at:␤  in block <unit> at <tmp> line 1␤␤»

[23:54] <Zoffix> Oh

[23:54] <Zoffix> :}

[23:54] <Zoffix> wtf

[23:56] <Zoffix> m: my constant &m  = { $^a == 1 ?? 'cat1' !! <cat2 sub2> }; dd % .classify-list(&m, [1, 2, 3])

[23:56] <camelia> rakudo-moar e8a61d: OUTPUT«Hash % = {:cat1($[1]), :cat2(${:sub2($[2, 3])})}␤»

[23:56] <Zoffix> m: my constant &m  = { $^a != 1 ?? 'cat1' !! <cat2 sub2> }; dd % .classify-list(&m, [1, 2, 3])

[23:56] <camelia> rakudo-moar e8a61d: OUTPUT«Hash % = {:cat1($[2, 3]), :cat2(${:sub2($[1])})}␤»

[23:57] <Zoffix> m: dd % .classify-list: sub ($) { $++ ?? 'a' !! <a b> }, <a b c>

[23:57] <camelia> rakudo-moar e8a61d: OUTPUT«Trailing item in Hash.push␤  in block <unit> at <tmp> line 1␤Trailing item in Hash.push␤  in block <unit> at <tmp> line 1␤Hash % = {:a(${:b($["a"])})}␤»

[23:57] <Zoffix> waaat

[23:58] <Zoffix> shit, 500 lines of tests and I still missed something

[23:58] <Zoffix> m: dd % .classify-list: sub ($x) { $x eq 'a' ?? 'a' !! <a b> }, <a b c>

[23:58] <camelia> rakudo-moar e8a61d: OUTPUT«Type Array does not support associative indexing.␤  in block <unit> at <tmp> line 1␤␤Actually thrown at:␤  in block <unit> at <tmp> line 1␤␤»

[23:59] <Zoffix> m: dd % .classify-list: sub ($x) { $x == 1 ?? 'cat1' !! <cat2 sub2> }, [1, 2, 3]

[23:59] <camelia> rakudo-moar e8a61d: OUTPUT«Hash % = {:cat1($[1]), :cat2(${:sub2($[2, 3])})}␤»

[23:59] <Zoffix> wtf is the difference :/
