Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2016-01-02

Perl 6 | Reference Documentation | Rakudo

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:00 Util joined #perl6
00:00 perlpilot joined #perl6
00:00 jojotus_ joined #perl6
00:00 d4l3k_ joined #perl6
00:00 dalek joined #perl6
00:00 tipdbmp joined #perl6
00:00 tony-o joined #perl6
00:00 psch joined #perl6
00:01 JimmyZ joined #perl6
00:01 emdashcomma joined #perl6
00:01 mattp__ joined #perl6
00:01 frew joined #perl6
00:01 ZoffixWin joined #perl6
00:01 ZoffixWin joined #perl6
00:01 deniska joined #perl6
00:01 deniska joined #perl6
00:01 lsm joined #perl6
00:01 xnrand joined #perl6
00:01 ggherdov_ joined #perl6
00:01 Axord joined #perl6
00:01 hacst joined #perl6
00:02 skarn joined #perl6
00:02 integral joined #perl6
00:02 integral joined #perl6
00:02 inokenty joined #perl6
00:03 vike joined #perl6
00:05 mindos joined #perl6
00:06 pnu joined #perl6
00:09 olinkl joined #perl6
00:10 clkao joined #perl6
00:10 nzkindest joined #perl6
00:12 BenGoldberg joined #perl6
00:13 nzkindest Happy new year everyone
00:14 TimToady likewise!
00:14 parisba joined #perl6
00:17 _nadim Is ther a mesh operator, like Z, that doesnt stop at the end of the shortest list
00:18 TimToady well, hypers, if you don't mind APL semantics
00:19 TimToady but there's never been consensus on what the semantics for "missing" values should be on something Z-ish but over longest list
00:19 TimToady so xx * is where it's at
00:20 TimToady or bind to an optional parameter with a defualt
00:21 _nadim that I don't know how to do, or  undertand. given to lists, how does one do that?
00:21 TimToady well, that's assuming you have something that is returning (x,y),(x,y),(x),(x) that you -> to a map block
00:22 TimToady roundrobin can do that if you know which one's gonna run out first, but there's no easy answers here
00:23 TimToady well, I guess even roundrobin wouldn't group pairs
00:23 TimToady we did spec that a list ending in * would automatically repeat the final arg, but I dunno where that ended up
00:23 _nadim OK, I'll generate the equivalent length lists or append data manually. Thanks
00:24 TimToady m: say 1,2,3 Z+ 4, *
00:24 camelia rakudo-moar 3568c1: OUTPUT«(5 6 7)␤»
00:24 TimToady I guess it got hacked into Z anyway
00:24 TimToady so maybe that'd work for you
00:26 TimToady m: say (1,2),(3,4),(5,6) ZX~ <a b>, *
00:26 gfldex S03: "For any kind of zip or dwimmy hyper operator, any list ending with * is assumed to be infinitely extensible by taking its final element and replicating it:"
00:26 camelia rakudo-moar 3568c1: OUTPUT«((1a 1b 2a 2b) (3a 3b 4a 4b) (5a 5b 6a 6b))␤»
00:26 Zoffix joined #perl6
00:27 TimToady looks like it'll replicate a list for you too
00:27 TimToady it's slightly shorter than <a b> xx *
00:27 TimToady and in theory works even if you don't know the last element
00:28 TimToady m: my @mystery = <a b>,<c d>; say (1,2),(3,4),(5,6) ZX~ @mystery, *
00:28 camelia rakudo-moar 3568c1: OUTPUT«((1a b 1c d 2a b 2c d) (3a b 3c d 4a b 4c d) (5a b 5c d 6a b 6c d))␤»
00:29 TimToady m: my $mystery = <a b>,<c d>; say (1,2),(3,4),(5,6) ZX~ |$mystery, *
00:29 camelia rakudo-moar 3568c1: OUTPUT«WARNINGS for /tmp/UykNSmCF3H:␤Useless use of constant value c d in sink context (lines 1, 1, 1, 1)␤((1a 2a) (3b 4b) (5b 6b))␤»
00:29 TimToady m: my $mystery = (<a b>,<c d>); say (1,2),(3,4),(5,6) ZX~ |$mystery, *
00:29 camelia rakudo-moar 3568c1: OUTPUT«((1a 1b 2a 2b) (3c 3d 4c 4d) (5c 5d 6c 6d))␤»
00:29 TimToady there we go
00:29 TimToady it replicates the <c d> even though we can't use xx directly on the final element of the list
00:30 TimToady I dunno if that was implemented for hypers
00:30 TimToady m: my $mystery = (<a b>,<c d>); say (1,2),(3,4),(5,6) «X~» |$mystery, *
00:30 camelia rakudo-moar 3568c1: OUTPUT«This Seq has already been iterated, and its values consumed␤(you might solve this by addding .cache on usages of the Seq, or␤by assigning the Seq into an array)␤  in block <unit> at /tmp/0yeZfU20WA line 1␤␤»
00:31 TimToady m: my $mystery = (<a b>,<c d>); say (1,2),(3,4),(5,6) »X~« |$mystery, *
00:31 camelia rakudo-moar 3568c1: OUTPUT«Lists on either side of non-dwimmy hyperop of  are not of the same length␤left: 3 elements, right: 2 elements␤  in block <unit> at /tmp/y0U1vqp6Te line 1␤␤»
00:31 TimToady m: my $mystery = (<a b>,<c d>); say (1,2),(3,4),(5,6) »X~» |$mystery, *
00:31 camelia rakudo-moar 3568c1: OUTPUT«This Seq has already been iterated, and its values consumed␤(you might solve this by addding .cache on usages of the Seq, or␤by assigning the Seq into an array)␤  in block <unit> at /tmp/hDBdwTCMW5 line 1␤␤»
00:31 TimToady well, it don't work too good...
00:32 _nadim hmm, I am not that lucky :) I get either some totaly weird output, a compile error or a segfault depending on what I try. my list contain strings
00:32 TimToady m: my $mystery = (<a b>,<c d>); say ((1,2),(3,4),(5,6)) »X~» (|$mystery, *)
00:32 camelia rakudo-moar 3568c1: OUTPUT«This Seq has already been iterated, and its values consumed␤(you might solve this by addding .cache on usages of the Seq, or␤by assigning the Seq into an array)␤  in block <unit> at /tmp/Y6lMvP8Hyf line 1␤␤»
00:32 TimToady m: my $mystery = (<a b>,<c d>); say ((1,2),(3,4),(5,6)) «X~» (|$mystery, *)
00:32 camelia rakudo-moar 3568c1: OUTPUT«This Seq has already been iterated, and its values consumed␤(you might solve this by addding .cache on usages of the Seq, or␤by assigning the Seq into an array)␤  in block <unit> at /tmp/A2ziai8pOC line 1␤␤»
00:32 TimToady m: my $mystery = (<a b>,<c d>); say ((1,2),(3,4),(5,6)).cache «X~» (|$mystery, *)
00:32 camelia rakudo-moar 3568c1: OUTPUT«This Seq has already been iterated, and its values consumed␤(you might solve this by addding .cache on usages of the Seq, or␤by assigning the Seq into an array)␤  in block <unit> at /tmp/WEU4X2viq2 line 1␤␤»
00:32 TimToady m: my $mystery = (<a b>,<c d>); say ((1,2),(3,4),(5,6)).cache «X~» (|$mystery.cache, *)
00:32 camelia rakudo-moar 3568c1: OUTPUT«This Seq has already been iterated, and its values consumed␤(you might solve this by addding .cache on usages of the Seq, or␤by assigning the Seq into an array)␤  in block <unit> at /tmp/Bt6BjgAPHh line 1␤␤»
00:33 * TimToady scratches head
00:33 TimToady in any case, Z is more intended for lists, and hypers more for matrices and such
00:34 TimToady (which is why the precedence is so different)
00:35 sprocket joined #perl6
00:35 _nadim in my case i just want to take two lists and print them side by side
00:35 TimToady oh, I see Mouq++ already brought up the ,* trick
00:35 _nadim looks like I'll have to generate elements to fill in
00:35 Rotwang m: say 0 == 0e0, 0 ∈ (0e0,)
00:35 camelia rakudo-moar 3568c1: OUTPUT«TrueFalse␤»
00:35 Rotwang why is that? ^
00:36 TimToady sets are type based
00:36 TimToady m: say 0 === 0e0
00:36 camelia rakudo-moar 3568c1: OUTPUT«False␤»
00:36 Zoffix m: say 0.WHAT, 0e0.WHAT
00:36 camelia rakudo-moar 3568c1: OUTPUT«(Int)(Num)␤»
00:36 dalek doc: 1962a97 | (Wenzel P. P. Peppmeyer)++ | doc/Language/operators.pod:
00:36 dalek doc: doc list expension with * for Zip operators
00:36 dalek doc: review: https://github.com/perl6/doc/commit/1962a97ef2
00:36 dalek doc: 8247afb | (Wenzel P. P. Peppmeyer)++ | doc/Language/operators.pod:
00:36 dalek doc: Merge pull request #310 from gfldex/master
00:36 dalek doc:
00:36 dalek doc: doc list expension with * for Zip operators
00:36 dalek doc: review: https://github.com/perl6/doc/commit/8247afbc35
00:36 Rotwang I see, thanks!
00:37 Rotwang btw. where are the unicode operators documented?
00:37 Rotwang can't find them here: http://doc.perl6.org/language/operators
00:37 Zoffix Rotwang, http://doc.perl6.org/language/setbagmix
00:38 Zoffix which should probably be least mentioned on /operators
00:38 gfldex Rotwang: in gerneral with the class they operate on
00:40 gfldex Zoffix: i disagree. If we put every operator that is defined in core in there, that list would be far to long. We should however mention that operators are documented with their class in general, unless there is no class.
00:41 eddiejr joined #perl6
00:42 Rotwang gfldex: so for example ∘ operator should be documented along with Block?
00:43 Zoffix How to call methods from the same object? I'm doing self.handle-event here https://github.com/zoffixznet/perl6-IRC-Client/blob/master/lib/IRC/Client.pm6#L43 but now I'm getting an error here https://github.com/zoffixznet/perl6-IRC-Client/blob/master/lib/IRC/Client.pm6#L75 saying "Cannot understand @!plugs in this context", even though that code was working fine before I moved it into a method
00:45 gfldex Rotwang: Callable seams better, see https://github.com/rakudo/rakudo/blob/nom/src/core/operators.pm#L655
00:46 aindilis joined #perl6
00:47 gfldex Zoffix: that should work. Could you try @tmp := @!plugs and replace the @!plugs before .grep?
00:47 dalek ecosystem: fe4516e | (brad clawsie)++ | / (4 files):
00:47 dalek ecosystem: Merge pull request #1 from perl6/master
00:47 dalek ecosystem:
00:47 dalek ecosystem: update from upstream
00:47 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/fe4516e41c
00:47 dalek ecosystem: 528bf43 | (brad clawsie)++ | META.list:
00:47 dalek ecosystem: Add Hash::Consistent
00:47 dalek ecosystem:
00:47 dalek ecosystem: see https://github.com/bradclawsie/Hash-Consistent
00:47 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/528bf437be
00:47 dalek ecosystem: 07d23bb | (Zoffix Znet)++ | META.list:
00:47 dalek ecosystem: Merge pull request #110 from bradclawsie/master
00:47 dalek ecosystem:
00:47 dalek ecosystem: Added Hash::Consistent
00:47 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/07d23bb897
00:48 Zoffix gfldex, says  "Cannot understand @!plugs in this context ... my @tmp := @!plugs⏏;"
00:50 gfldex Zoffix: try self!replay
00:50 Zoffix What's that and how do I try it?
00:50 gfldex err self!plugs
00:51 gfldex m: class C { has $!s; has @!s }
00:51 camelia rakudo-moar 3568c1: ( no output )
00:51 Zoffix "Private method call to plugs must be fully qualified with the package containing the method"
00:52 gfldex now i'm as much confused as you are :(
00:52 Zoffix What was the signature syntax to get the invocant in a variable?
00:53 Zoffix m: class C { has $.s = 42; method bar ($foo:) { say $foo.s } }; C.new.bar
00:53 camelia rakudo-moar 3568c1: OUTPUT«42␤»
00:53 Zoffix k
00:53 gfldex m: my method m(Any:D $s:){}
00:53 camelia rakudo-moar 3568c1: ( no output )
00:54 Zoffix No love if I explicitly use a variable instead of self. >_<
00:54 gfldex @!plugs should work, so there is something really odd going on
00:54 Rotwang gfldex: thanks
00:55 Zoffix m: class Foo { has @!s = <foo bar>; method bar { self.ber }; method ber {say @!s} }; Foo.new.bar
00:55 camelia rakudo-moar 3568c1: OUTPUT«[foo bar]␤»
00:55 itaipu joined #perl6
00:55 Zoffix hm
00:55 lichtkind joined #perl6
00:56 gfldex Zoffix: if i clone IRC::Client, how do i test that?
00:56 Zoffix gfldex, perl6 examples/bot.pl6
00:56 * gfldex clones
00:57 gfldex Zoffix: i get the same error
00:59 llfourn joined #perl6
00:59 dalek perl6-examples: b052f85 | (Rodrigo Siqueira)++ | categories/shootout/mandelbrot.p6:
00:59 dalek perl6-examples: Mandelbrot Set algorithm in Perl6
00:59 dalek perl6-examples:
00:59 dalek perl6-examples: Generates the Mandelbrot Set fractal using Perl 6. To be submitted to "The Computer Language Benchmarks Game".
00:59 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/b052f859b7
00:59 dalek perl6-examples: 018a746 | (Zoffix Znet)++ | categories/shootout/mandelbrot.p6:
00:59 dalek perl6-examples: Merge pull request #40 from rsiqueira/patch-2
00:59 dalek perl6-examples:
00:59 dalek perl6-examples: Mandelbrot Set algorithm in Perl6
00:59 dalek perl6-examples: review: https://github.com/perl6/perl6-examples/commit/018a7462ff
01:01 Zoffix I'm an idiot
01:02 Zoffix gfldex, I totally missed that it's not a `unit class IRC::Client` but a `class IRC::Client { ... }` and I declared the .handle-event method outside of those curlies
01:03 gfldex Zoffix: i just spotted line 70 as well :)
01:04 gfldex however, it should have complained because it's method out of a class and not my method
01:04 gfldex m: class C {}; method foo(){}
01:04 camelia rakudo-moar 3568c1: OUTPUT«Potential difficulties:␤    Useless declaration of a has-scoped method in mainline (did you mean 'my method foo'?)␤    at /tmp/NOgngVXFhB:1␤    ------> 3class C {}; method7⏏5 foo(){}␤»
01:05 Zoffix Yeah, probably
01:05 gfldex may be worth to find out why it didn't complain like that
01:05 gfldex but it's nice to see that you expect rakudos error message to be awesome :)
01:06 gfldex TimToady++ # for successful propaganda
01:08 dalek rakudo-star-daily: dac4f99 | coke++ | log/ (8 files):
01:08 dalek rakudo-star-daily: today (automated commit)
01:08 dalek rakudo-star-daily: review: https://github.com/coke/rakudo-star-daily/commit/dac4f99452
01:09 [Coke] (2015.12.1) we have a lot of stuff to iron out before we do a post christmas release.
01:12 ugexex joined #perl6
01:13 ugexex m: say $*CWD.abspath.WHAT; say $*CWD.absolute.WHAT; # docs say abspath returns string and absolute returns an IO::Path
01:13 camelia rakudo-moar 3568c1: OUTPUT«(Str)␤(Str)␤»
01:13 Zoffix I created a ticket for my LTA error in the conversation above: https://rt.perl.org/Ticket/Display.html?id=127117
01:14 Zoffix Hm. The other question is: why is the error shown twice? Seems like it's trying to compile it twice
01:16 zwu joined #perl6
01:17 gfldex Zoffix: maybe you should like the git repro URL and the commit the wrong error showed up on that RT
01:18 Zoffix I don't understand what you just said. What do you mean "like the git repro URL"?
01:18 zwu I tried to understand how the module / package related with the file structures, a naive code failed in one file module A { class B {}; } use A::B; #failed
01:18 gfldex s/like/link/ i cloned the module that have a look, so that is helpful
01:19 * gfldex is out of proper english
01:19 zwu Output is "could not find A::B"
01:19 zwu However, I do can use the my $s = A::B.new;
01:20 Zoffix gfldex, I reduced it to a much smaller example that I included in the ticket
01:20 Zoffix (same error)
01:20 gfldex sorry, i missed that
01:22 gfldex zwu: if it's a class inside a module you use 'use A'. Given that B is export it should show up in the local scope.
01:23 gfldex zwu: have a look at this failry simple example: https://github.com/nxadm/StrictNamedArguments
01:23 zwu gfldex, thanks, still failed for that module A { class B{}} use A;
01:24 gfldex zwu: you would start examples/basic.p6 with 'perl6 -I ./lib examples/basic.p6' from the modules root
01:24 _nadim I core dumped at least 20 times tonight, running concurent code, what surprised me the most is that it happens after I made a few modifications, the second run is fine as are all the runs after.
01:24 gfldex _nadim: i have the same problem. It's totally random. Do you use Lock.new ?
01:30 _nadim No, I use Channel, start, await
01:30 SwellJoe joined #perl6
01:31 pjscott joined #perl6
01:36 thundergnat joined #perl6
01:36 ugexex have you inspected during all those times if its taking place in the same thread or not?
01:36 ugexex regardless of you using start { }
01:37 thundergnat Hey, #perl6 peeps
01:37 thundergnat Should panda work with github tags for module versions?
01:37 ugexex start { } might schedule your work on the current thread if it can
01:39 thundergnat I've been trying to install Data::Dump::Tree and panda is distinctly unhappy. The only thing I can see "wrong" is that the ecosystem link points to a tagged version rather than master.
01:39 _nadim thundergnat: yes the source url indicated the tag, or the lates in whatever branch, master normaly
01:39 thundergnat It seems to be the only one in the ecosystem so far that does that.
01:40 pjscott joined #perl6
01:40 thundergnat It seems like it SHOULD work... but doesn't yet.
01:40 thundergnat At least not for me.
01:40 _nadim it is, I wrote it, but we had a discussion this morning about it and using the tags is what should work
01:41 _nadim i guess that makes me the gunea pig
01:41 thundergnat Hmm. I keep getting the error -> fetch stage failed for Data::Dump::Tree: Unable to handle source 'https://github.com/nkh/P6-Data-Dump-Tree/
01:41 wamba joined #perl6
01:41 _nadim thundergnat: you can always clone it an do "panda install ." to install from the local code
01:41 thundergnat _nadim heh, lucky you.
01:42 _nadim yeah, it's my day ;)
01:42 thundergnat Yeah, I know, I just figured I would raise the issue on channel in case it was unknown.
01:42 Zoffix thundergnat, can you run panda update?
01:42 thundergnat Did
01:42 Zoffix thundergnat, that module had an incorrect URL earlier today... hm
01:42 Zoffix k, then I dunno
01:43 _nadim I saw an update , I can check, 1 mn
01:43 thundergnat Just did again and tried again... still same failure.
01:43 Zoffix Oh, I may know
01:43 Zoffix v1.0.0 doesn't match \w+ which is probably used somewhere
01:44 thundergnat oooo, that seems likely.
01:44 _nadim the ecosystem is up to date
01:44 _nadim thundergnat: will you open a ticket?
01:44 thundergnat Sure.
01:44 _nadim thanks.
01:45 _nadim and please install with git and test the module :)
01:46 thundergnat _nadim Yeah, plan to, Looks like a cool/useful module.
01:47 ugexex source-url":"https://github.com/nkh/P6-Data-Dump-Tree/"
01:47 ugexex thats not valid
01:48 ugexex s{/}{.git}
01:48 ugexex s{/$}{.git} rather
01:48 _nadim thundergnat: the filters are fun to play with. It's not very fast but it it is readable. Let me know if you have problems or if you want to use it in any specific way. I need input
01:49 Zoffix ugexex, why is it not valid?
01:49 Zoffix Those URLs get normalized and half our ecosystem would be broken if it were invalid.
01:49 ugexex because the ecosystem isnt build on the url in the meta file?
01:50 _nadim you mean that it should be "https://github.com/nkh/P6-Data-Dump-Tree.git"?
01:50 ugexex yes
01:50 Zoffix It will get normalized back to https://github.com/nkh/P6-Data-Dump-Tree/
01:50 _nadim hmm, well it get redirected by git hub so i guess that it is as good to use the .git address
01:51 Zoffix ugexex, what do you mean by "because the ecosystem isnt build on the url in the meta file?"?
01:51 ugexex why is the ecosystem modifying meta files?
01:51 Zoffix Because people put all sorts of URLs in there and we coerce them to fewer options for our tooling to handle
01:53 Zoffix But, it does look like you're right
01:53 ugexex but unless it explicitly has a license that allows you to do that im not sure you should
01:53 Zoffix panda install Text::Wrap fails with same error
01:54 Zoffix ugexex, it's generating metadata. I highly doubt licensing applies on that aspect
01:55 Zoffix (this discussion is moot though, as we're moving onto the PAUSE system anyway)
01:55 ugexex i personally dont care, im just channeling my inner project manager
01:55 * Zoffix works on the commit to fix this issue
01:57 dalek ecosystem: 32efec1 | (Zoffix Znet)++ | server/updatelist.pl:
01:57 dalek ecosystem: Normalized HTTPS URLs need to have .git
01:57 dalek ecosystem:
01:57 dalek ecosystem: Otherwise panda fails to install them (see http://irclog.perlgeek.de/perl6/2016-01-02#i_11817181)
01:57 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/32efec18c7
01:57 Zoffix thundergnat, _nadim ^ that should fix the install issue whenever the http://ecosystem-api.p6c.org/projects.json gets updated
01:58 thundergnat _nadim https://rt.perl.org/Public/Bug/Display.html?id=127118
01:58 thundergnat Hah! Zoffix, you keep fixing bugs just before I can report them!
01:59 pierre-vigier joined #perl6
02:00 llfourn joined #perl6
02:00 _nadim Zoffix: is that what panda updat does?
02:01 Zoffix _nadim, no, panda update fetches that list. And that list is updated with a cronjob being run somewhere
02:01 awwaiid gfldex++ # for all the doc work
02:02 _nadim Then I just have to get asleep and it will be fine by morning (if I don't break something else ;))
02:02 Zoffix :)
02:06 pjscott joined #perl6
02:07 pjscott joined #perl6
02:07 yurivish_ joined #perl6
02:13 dalek ecosystem: 535c1f7 | (Zoffix Znet)++ | server/updatelist.pl:
02:13 dalek ecosystem: Fix code formatting
02:13 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/535c1f7b01
02:14 pjscott joined #perl6
02:15 Zoffix k, it got updated and panda update; panda install Text::Wrap now works for me
02:15 Zoffix Should work for Data::Dump::Tree too
02:16 Zoffix thundergnat, if you can confirm the install works for Data::Dump::Tree (or Text::Wrap, if you already installed Data::Dump::Tree), then please close your ticket
02:16 Zoffix Run panda update first
02:17 thundergnat 'k, I'll give it a try.
02:18 thundergnat hmmm. Now I get a new and different failure...
02:19 thundergnat Failed to copy '/lib/Data/Dump/Tree/ExtraRoles.pm' to '/home/steve/.perl6/share/perl6/site/sources/31496E05158CBFE737C208168641BEF9FE417
02:19 thundergnat May need to nuke and start over...
02:19 Zoffix nah wait
02:19 thundergnat 'k
02:20 Zoffix thundergnat, that's an error with the META file in that distro. The '/lib' should be 'lib'
02:20 * Zoffix submits a PR
02:21 thundergnat Ah.
02:21 Zoffix _nadim, sent: https://github.com/nkh/P6-Data-Dump-Tree/pull/3
02:23 thundergnat Zoffix:  While you're at it, shouldn't "author" : "Nadim Khemir", be "authors" : ["Nadim Khemir"], ?
02:23 thundergnat oops. too late
02:24 leont Rumor has it PRs are cheap
02:24 yoleaux 31 Dec 2015 18:46Z <TimToady> leont: I'd use something like: .return with $!exit-status.status;
02:24 thundergnat leont heh. I've heard that.
02:25 Zoffix Never too late with git rebase :)
02:25 Zoffix And yeah, it should be "authors" : ["Nadim Khemir"] (PR Updated)
02:25 _nadim never too late when I can do that too
02:26 Zoffix :D
02:26 thundergnat :D
02:26 _nadim hmm, that went through Test::META without problem
02:26 FROGGS_ joined #perl6
02:27 pjscott joined #perl6
02:28 pjscott I installed raked on OS X with "brew install rakudo-star" and this put perl6 in /usr/local/bin but no panda. What's the preferred way of installing panda from this position?
02:28 pjscott s/raked/rakudo/ # damn autocorrect
02:29 ugexex well technically an absolute path is fine if existed. it used to be a trick to install modules to {$PREFIX} long ago
02:29 Zoffix Test::META checks for file's existence though
02:29 * Zoffix investigates why that did not work correctly
02:31 Zoffix pjscott, three things: (1) R* comes with panda, so it's weird that you did not receive it. Are you sure it's not installed elsewhere? (2) rakudo-star for the Christmas release hasn't been released yet to my knowledge, so your rakudo is way old. (3) You can still get panda with git clone https://github.com/tadzik/panda.git; perl6 bootstrap.pl; Not exactly sure *where* that would install it though
02:33 pjscott "whereis panda" doesn't find it. The brew command didn't gripe.  Note that this was *brew*, not *rakudobrew*
02:33 pjscott Following OS X instructions on http://rakudo.org/how-to-get-rakudo/
02:33 Zoffix Yeah, everyone's on holidays, so I think that's why the Rakudo Star distro hasn't been updated yet
02:33 Zoffix m: say '/'.IO.child('dev').e; say '/'.IO.child('/dev').e
02:33 camelia rakudo-moar 3568c1: OUTPUT«True␤True␤»
02:34 Zoffix ^ cause of Test::META not detecting the '/lib' problem
02:34 pjscott Hmm, looks pretty Christmassy to me: bash-3.2$ perl6 -v
02:34 pjscott This is Rakudo version 2015.12 built on MoarVM version 2015.12
02:34 pjscott implementing Perl 6.c.
02:34 Zoffix And `authors` is optional, which is why it's not complaining about it
02:35 Zoffix pjscott, no idea then :| I don't see a 2015.12 release on http://rakudo.org/downloads/star/
02:35 Zoffix You can problably rakudobrew with the 4 commands listed here: http://perl6.org/downloads/
02:36 pjscott ==> Installing rakudo-star
02:36 pjscott ==> Downloading https://homebrew.bintray.com/bottles/rakudo-star-2015.12.el_capi
02:36 pjscott Yes, I can, I've done it that way before but I wanted to try the 'brew' version.
02:36 Zoffix Ah
02:45 ZoffixWin joined #perl6
02:45 ZoffixWin joined #perl6
02:48 molaf_ joined #perl6
02:49 pjscott joined #perl6
02:51 xpen joined #perl6
02:57 pjscott joined #perl6
02:59 pierre-vigier joined #perl6
03:01 llfourn joined #perl6
03:02 awwaiid rakudo.org doesn't even mention the 2015.12 release on the front page :(
03:03 llfourn o/
03:03 flussence you're right; the only process for a new user to get 2015.12 right now is via rakudobrew. Everything else via that domain is a dead end
03:06 awwaiid tangentally, is debian packaging waiting for the next Star?
03:06 flussence unfortunately that site's had a bus factor of 0 over christmas, so there's nothing we can do about it until the people who can show up
03:06 flussence debian packaging is, IIRC, mostly the same set of people...
03:10 noganex_ joined #perl6
03:24 llfourn m: say ForeignCode; # What is this for?
03:24 camelia rakudo-moar 3568c1: OUTPUT«(ForeignCode)␤»
03:25 flussence from the name, I'm guessing Inline::$foo?
03:25 llfourn hmm yes I thought something like that too
03:25 flussence oh, docs/announce/2013.04
03:26 flussence it's for autoboxing stuff on native ints and nqp stuff, sounds like
03:26 llfourn well spotted. But I think that means low level code rather than native types.
03:28 llfourn m: role { sub foo { }; BEGIN &foo.^find_method("clone").^name.say } # .clone is a ForeignCode when it should be getting the one from Mu :(
03:28 camelia rakudo-moar 3568c1: OUTPUT«ForeignCode␤»
03:28 llfourn this only happens inside roles
03:29 llfourn (I think)
03:30 llfourn ah no nvm it's always like that .clone just breaks when it's inside a role...
03:30 zwu just understand the module and search interface L<CompUnitRepo::Local::File> and L<CompUnitRepo::Local::Installation>, my question is: each file is a compunit, which is the search based for the Local::File,
03:31 llfourn zwu: I didn't understand the question part
03:31 zwu however, if I have multiple embedded module in a single file, how can I make the use module; work
03:31 llfourn zwu: 'use' only works for compunits. If you use the compunit you will get all the modules,classes roles etc inside
03:32 pjscott joined #perl6
03:32 zwu such as module X{ sub x is export {} ; module Y { sub y is export {} };} ;
03:33 zwu use X::Y;
03:33 llfourn zwu: give "import" a short instead of use
03:33 llfourn shot*
03:34 llfourn import => for packages (like module), use => for compunits like X/Y.pm use X::Y;
03:34 zwu yes, "use" is actually combination of "need" and "import"
03:34 brad_ joined #perl6
03:34 llfourn zwu: actually it isn't. I wrote that lie on the docs before I knew it wasn't true ;_;
03:35 brad_ So do anyone have a redesign of the Perl6 logo?
03:35 llfourn zwu: I promise to fix it soon sorry!
03:36 llfourn zwu: but FYI the design docs say it should be like that but the implementation has decided to go a different way that probably makes more sense.
03:37 zwu in so, if I have distributed the same module in a file.pm and embedded in another module, kind like of partial in c#, will the two same modules being merged and imported?
03:38 ugexe joined #perl6
03:38 llfourn zwu: I think so in that the things that the "embedded" modules "is export" will be merged.
03:39 llfourn "is export" doesn't care about what module it's in if I remember correctly
03:39 llfourn it works on the compunit level -- but take that with a grain of salt
03:43 llfourn zwu: ah so I kinda re-read your question. Whether the modules are notionally merged or not I'm not sure but the exported symbols should be merged at least.
03:43 pjscott joined #perl6
03:45 xxpor_lap joined #perl6
03:51 zwu thanks
03:52 zwu I like the flexibility that perl 6 has designed.
03:53 llfourn zwu: yep it sure it designed well :)
03:53 llfourn *it sure is
03:58 pjscott joined #perl6
04:00 pierre-vigier joined #perl6
04:00 ParsonsNose joined #perl6
04:00 colomon joined #perl6
04:02 bpmedley_ joined #perl6
04:05 xxpor_lap joined #perl6
04:06 pjscott joined #perl6
04:09 molaf_ joined #perl6
04:11 kaare_ joined #perl6
04:17 dcymbala joined #perl6
04:18 dcymbala Hi all - I'm new to perl6 and had questions on writing a new module - which email list would be best?
04:19 AlexDani` joined #perl6
04:19 awwaiid dcymbala: the users list might work
04:21 dcymbala Hi awwaiid - perl6-users@perl6.org is what you mean?
04:22 Mouq dcymbala: Often the best place to ask questions is actually here, though maybe not at this hour
04:22 dcymbala I understand
04:22 awwaiid dcymbala: yep!
04:22 dcymbala thanks!
04:22 awwaiid and yeah, here is grea
04:22 awwaiid great
04:24 dcymbala Is there a preference to provide classes over roles or vice versa in modules?
04:28 ParsonsNose My gut feel is that you should avoid exposing roles in an API but prefer them internally. But there are many people here with more valuable opinions than I
04:45 gfldex ParsonsNose: roles are interfaces and as such one might want to test if a class or a sub-class implements that role. It may be worth it to export it with a tag ofc.
04:51 sprocket joined #perl6
05:11 awwaiid Progress on Inline::Ruby -- this now works: say EVAL('[2, 6, 8, 4]', :lang<Ruby>).sort.slice(1,2).to_s; #=> "[4, 6]"
05:12 awwaiid Also: EVAL('Time', :lang<Ruby>).now.to_s #=> 2016-01-02 00:12:20 -0500
05:14 nige1 joined #perl6
05:26 vendethiel joined #perl6
05:27 zwu joined #perl6
05:27 dcymbala gfldex: I suppose I could define a Role in one module and then have a class implement it in another.
05:27 zwu how to call superclass's method if it has been overrided
05:28 zwu should I use the meta object?
05:34 labster joined #perl6
05:34 gfldex m: class A { method m () { say 'A::m' } }; class B is A { method m () { say 'B::m'; nextsame } }; B.new.m;
05:34 camelia rakudo-moar 3568c1: OUTPUT«B::m␤A::m␤»
05:34 gfldex zwu: ^^^
05:35 gfldex m: class A { method m () { 'A::m' } }; class B is A { method m () { nextsame } }; say B.new.m;
05:35 camelia rakudo-moar 3568c1: OUTPUT«A::m␤»
05:38 gfldex m: class A { method m () { 'A::m' } }; class B is A { method m () { 'B::m' ~ nextsame } }; class C is B { method m () { 'C::m' ~ nextsame } }; say C.new.m;
05:38 camelia rakudo-moar 3568c1: OUTPUT«A::m␤»
05:39 gfldex zwu: please note the MMD can complicate things. see http://design.perl6.org/S12.html#Calling_sets_of_methods
05:40 awwaiid gfldex: wasn't that last one supposed to say like: C::mB::mA::m ?
05:40 gfldex no, nextsame will do odd things to return values
05:41 awwaiid ah
05:41 awwaiid maybe it doesn't return
05:41 nbrown joined #perl6
05:41 gfldex you basicly send the method call back to the dispacher and ask him to call the next candidate
05:43 SwellJoe joined #perl6
05:45 xpen joined #perl6
05:45 Cabanossi joined #perl6
05:45 awwaiid gfldex: you ever ready ruby docs? If you look at say http://ruby-doc.org/core-2.2.0/String.html and roll over some of the entries there is a "click to toggle source" link, does what it says. I'm thinking something like that for reference docs which would show a block from roast
05:53 pjscott joined #perl6
05:54 gfldex m: class A { method m () { 'A::m' } }; class B is A { method m () { 'B::m' ~ nextsame } }; class C is B { method m () { 'C::m' Z~ self.WALK(:name<m>, :super)>>.(self) } }; say C.new.m;
05:54 camelia rakudo-moar 3568c1: OUTPUT«(C::mA::m)␤»
05:55 gfldex if you need the return value of the parents class methods (there is MMD), this is one way. I think there is another but can't quite remember.
05:57 labster joined #perl6
05:57 gfldex m: class A { method m () { 'A::m' } }; class B is A { multi method m () { 'B::m' ~ nextsame }; multi method m (A:D:) { 'B::m2' } }; class C is B { method m () { 'C::m' Z~ self.WALK(:name<m>, :super)>>.(self) } }; say C.new.m;
05:57 camelia rakudo-moar 3568c1: OUTPUT«(C::mB::m2)␤»
06:13 pjscott joined #perl6
06:14 bitmap joined #perl6
06:16 _Vi joined #perl6
06:17 skids joined #perl6
06:20 pjscott joined #perl6
06:25 pjscott joined #perl6
06:27 dalek doc: e36415e | skids++ | doc/Type/Scalar.pod:
06:27 dalek doc: Clarify language and narrow an unitentionally wide C<>
06:27 dalek doc: review: https://github.com/perl6/doc/commit/e36415ed0c
06:28 * skids wonders if there is a way to exempt Scalar.pod from sutolisting Any/Mu methods since those methods delegate.
06:29 sprocket has anyone encountered an “Invalid GC status observed; aborting” error before?
06:29 ugexe m: my %meta = "/home/camelia/star-2015.09/share/perl6/META6.json".IO.slurp.&from-json.hash; CompUnit::RepositoryRegistry.repository-for-name('home').install(Distribution.new(|%meta), %(%meta<provides>.map({.key => .value.IO.absolute("/home/camelia/star-2015.09/share/perl6/")})));
06:29 camelia rakudo-moar 3568c1: ( no output )
06:30 sprocket currently rebuilding the latest rakudo, but wondering if it’s something else i’ve done to cause that error
06:30 ugexe m: use JSON::Fast;
06:30 camelia rakudo-moar 3568c1: OUTPUT«Use of uninitialized value % of type Any in string context␤Any of .^name, .perl, .gist, or .say can stringify undefined things, if needed.  in any load_module at src/Perl6/World.nqp line 978␤»
06:30 skids sprocket: new one on me.
06:30 sprocket skids: we’ll see what the latest build has to say then :)
06:34 ugexe m: say CompUnit::RepositoryRegistry.repository-for-name("site").Str.IO.child("dist").dir[0].IO.slurp.&from-json.hash<depends>
06:34 camelia rakudo-moar 3568c1: OUTPUT«[[]]␤»
06:34 ugexe CU is generating messed up `depends`
06:34 ugexe on install
06:34 Psyche^_ joined #perl6
06:36 ugexe should be using |%(%meta.grep(?*.value.elems)) to generate Distribution
06:37 vividsnow joined #perl6
06:37 ugexe i mean doing the above fixes that, but shouldnt be neccesary rather
06:40 vividsnow joined #perl6
06:41 awwaiid I think I'm starting to be able to articulate this idea better...
06:43 awwaiid The "Perl 6 Design Documents" say that Roast is the official specification. But right now Roast links to Synopsis docs; I think we need to reverse those links. We need to be able to link to specific parts of Roast from design docs and user docs. For the user docs, I also want a list of the link-able things we have not yet linked, which will serve as a TODO list.
06:43 vividsnow joined #perl6
06:45 xpen joined #perl6
06:46 peyman joined #perl6
06:46 awwaiid Basically a new type of special-comment in roast, and deprecate the L<S0*/...> links. I've been using things like "#| DOC: String comparison with eq and ne", embedded in S03-operators/equality.t ideally attached to a block of tests.
06:47 peyman hello
06:47 awwaiid greetings peyman
06:47 peyman whats happening
06:47 awwaiid talking to myself
06:47 awwaiid actually, going to bed :)
06:47 peyman thats ok as long as nobody sees you
06:48 awwaiid ya
06:48 peyman sure g'night
06:48 awwaiid g'night :)
06:57 AlexDaniel m: say ‘have fun working on perl’.wordcase(:filter(&uc), :where(*.chars > 3 ))
06:57 camelia rakudo-moar 3568c1: OUTPUT«HAVE fun WORKING on PERL␤»
06:58 vividsnow joined #perl6
07:01 pierre-vigier joined #perl6
07:08 _Vi joined #perl6
07:13 AlexDaniel m: say NaN cmp 42
07:13 camelia rakudo-moar 3568c1: OUTPUT«More␤»
07:15 skids Is now a good time to pull nom vis-a-vis panda/curli/ecosystem issues?
07:15 vividsnow joined #perl6
07:16 AlexDaniel it seems like it does string comparison with NaN, is it correct?
07:17 AlexDaniel hm, perhaps it is
07:21 vividsnow joined #perl6
07:21 perigrin AlexDaniel: cmp would yes I think.
07:21 skids AlexDaniel: well design docs say it should do a "canonical" compare a-la eqv.
07:22 TimToady design docs are incomplete there
07:23 vividsnow joined #perl6
07:24 TimToady deciding to treat NaN as stringy is a fairly recent decision
07:24 TimToady it doesn't really fit into any orderable Numeric or composite type
07:25 TimToady so string is the best default we have
07:25 perigrin too bad you can't return "Not A Truth" :)
07:26 TimToady but there's no perfect solution here, so the best we can be is a kind of mostly consistent most of the time
07:27 TimToady so cmp is really quite a bit more forgiving than eqv is
07:27 skids Yeah it's not like there's an IEEE value for "not orderable"
07:28 virtualsue joined #perl6
07:28 itaipu joined #perl6
07:28 TimToady we consider it kind of antisocial to refuse to return a list in some order merely because some of the values are not the same type
07:30 CIAvash joined #perl6
07:35 azawawi joined #perl6
07:35 azawawi hi
07:35 azawawi happy 2016 #perl6
07:36 grondilu m: say NaN < 42
07:36 camelia rakudo-moar 3568c1: OUTPUT«False␤»
07:36 azawawi question, are the lexical scoping of Perl 6 the same as Perl in all aspects? Are there any differences?
07:37 azawawi A nice thing to do also is to add a Perl 6 entry with examples to https://en.wikipedia.org/wiki/Scope_%28computer_science%29#By_language
07:38 grondilu but NaN is a Numeric thing fundamentally, I don't get why it should be treated as a String by cmp.
07:38 vividsnow joined #perl6
07:39 grondilu oh wait, cmp can not return False, I forgot that.
07:39 grondilu maybe it should just die.
07:41 perigrin grondilu: TimToady just said that would be antisocial though
07:41 grondilu ok, did not pay enough attention
07:42 vividsnow1 joined #perl6
07:43 hankache joined #perl6
07:43 hankache Happy new year #perl6
07:44 bitmap joined #perl6
07:44 skids azawawi: Perl 6 made many more aspects of the language subject to lexical scoping.
07:45 azawawi cool then we need to add a new Perl 6 entry to that wikipedia article.
07:45 AlexDaniel m: say [5, -Inf, 10, Inf, 25, NaN, 35].sort
07:45 camelia rakudo-moar 3568c1: OUTPUT«(-Inf 5 10 25 35 Inf NaN)␤»
07:47 vividsnow joined #perl6
07:48 ugexe joined #perl6
07:49 AlexDaniel m: say [-Inf, Inf, 0, True, False, NaN].sort
07:49 camelia rakudo-moar 3568c1: OUTPUT«(-Inf 0 False True Inf NaN)␤»
07:49 grondilu AlexDaniel: is that ok to you?
07:49 AlexDaniel m: say [-Inf, Inf, True, False, 0, NaN].sort
07:49 camelia rakudo-moar 3568c1: OUTPUT«(-Inf False 0 True Inf NaN)␤»
07:50 AlexDaniel grondilu: I think that it is, but this ↑ – I'm not sure…
07:50 AlexDaniel ah wait, it is stable
07:50 AlexDaniel that's why
07:51 Tonik joined #perl6
07:51 azawawi do we have a raspberry pi rakudo star release?
07:51 skids azawawi: See the very top of S04 for a description of Perl 6 scoping
07:52 azawawi skids: thx
07:57 ChoHag Can I create an anonymous code reference which returns from its containing block?
07:57 _nadim joined #perl6
07:58 AlexDaniel m: say Bool.invert
07:58 camelia rakudo-moar 3568c1: OUTPUT«Use of uninitialized value of type Any in string context␤Any of .^name, .perl, .gist, or .say can stringify undefined things, if needed.  in block <unit> at /tmp/mwyroG9HZg line 1␤Cannot call invert(Bool); none of these signatures match:␤  in block <…»
07:58 vividsnow joined #perl6
07:58 ChoHag ie. sub foo { my $bar = sub { return-from-foo 42 if ... }; $bar("baz") }
07:58 AlexDaniel ChoHag: hmm, have you tried “return” ? :)
07:58 AlexDaniel I think that it should work
07:59 AlexDaniel m: sub foo { my $x = { return ‘blah’}; $x() }; say foo
07:59 camelia rakudo-moar 3568c1: OUTPUT«blah␤»
08:00 ChoHag That doesn't quite prove it.
08:00 azawawi i am planning on doing regular rakudo star releases for RPi for 2016 (starting with 2015.12) with https://github.com/cspencer/perl6-raspberry-pi and https://github.com/cspencer/perl6-raspberry-pi-device-ds18b20
08:00 ChoHag m: sub foo { my $x = { return ‘blah’}; $x(); say "still in foo"; }; say foo
08:00 camelia rakudo-moar 3568c1: OUTPUT«blah␤»
08:00 ChoHag That does.
08:00 AlexDaniel ChoHag: indeed :)
08:01 ChoHag m: sub foo { my $x = -> $bar { return "blah-$bar" }; $x("baz"); say "still in foo"; }; say foo
08:01 camelia rakudo-moar 3568c1: OUTPUT«blah-baz␤»
08:01 ChoHag Good good...
08:01 ChoHag hmm
08:01 ChoHag m: sub foo { my $x = { return "blah-$^bar" }; $x("baz"); say "still in foo"; }; say foo
08:01 camelia rakudo-moar 3568c1: OUTPUT«blah-baz␤»
08:02 ChoHag m: sub foo { my $x = { "just blah-$^bar" }; $x("baz"); say "still in foo"; }; say foo
08:02 camelia rakudo-moar 3568c1: OUTPUT«still in foo␤True␤»
08:02 ChoHag Excellent.
08:03 azawawi DrForr: ping
08:03 AlexDaniel what happens if you pass that sub somewhere else? What would this “return” mean then?
08:03 vividsnow joined #perl6
08:04 AlexDaniel and how do you “return” without returning from the outer sub?
08:04 AlexDaniel that is, if you want this anonymous sub to return some value
08:04 azawawi .tell DrForr Any update on the OpenCV bindings for Perl 6? Can you please share your WIP github repo?
08:04 yoleaux azawawi: I'll pass your message to DrForr.
08:06 ChoHag AlexDaniel: I think { ... } and sub { ... } are different.
08:06 AlexDaniel ChoHag: right! Indeed
08:06 AlexDaniel that answers the second question… maybe
08:07 ChoHag m: sub foo { my $bar = { "don't return $^this" }; my $baz = $bar("anything"); say "still in foo"; return $baz }
08:07 camelia rakudo-moar 3568c1: ( no output )
08:07 ChoHag m: sub foo { my $bar = { "don't return $^this" }; my $baz = $bar("anything"); say "still in foo"; return $baz }; say foo
08:07 camelia rakudo-moar 3568c1: OUTPUT«still in foo␤don't return anything␤»
08:08 ChoHag m: sub foo { my $bar = sub { return "don't return $^this" }; my $baz = $bar("anything"); say "still in foo"; return $baz }; say foo
08:08 camelia rakudo-moar 3568c1: OUTPUT«still in foo␤don't return anything␤»
08:12 vividsnow joined #perl6
08:13 darutoko joined #perl6
08:15 avalenn joined #perl6
08:16 virtualsue joined #perl6
08:16 ChoHag m: my Bool $something = True; say "? $something";
08:16 camelia rakudo-moar 3568c1: OUTPUT«? True␤»
08:17 ChoHag I got this: Cannot call Str(Bool: ); none of these signatures match: (Bool:D $: *%_)
08:17 ChoHag m: sub foo (Bool :$something) { say "? $something" } foo(:something)
08:17 camelia rakudo-moar 3568c1: OUTPUT«5===SORRY!5=== Error while compiling /tmp/E01uT91gxh␤Strange text after block (missing semicolon or comma?)␤at /tmp/E01uT91gxh:1␤------> 3Bool :$something) { say "? $something" }7⏏5 foo(:something)␤    expecting any of:␤        infix␤…»
08:17 ChoHag m: sub foo (Bool :$something) { say "? $something" }; foo(:something)
08:17 camelia rakudo-moar 3568c1: OUTPUT«? True␤»
08:18 ChoHag Hmm
08:21 pierre-vigier joined #perl6
08:23 vividsnow joined #perl6
08:25 dalek ecosystem: 49a1dee | cspencer++ | META.list:
08:25 dalek ecosystem: Added RPi::Device::DS18B20 to ecosystem.
08:25 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/49a1dee7a0
08:25 dalek ecosystem: 056ca1c | (Zoffix Znet)++ | META.list:
08:25 dalek ecosystem: Merge pull request #111 from cspencer/master
08:25 dalek ecosystem:
08:25 dalek ecosystem: Added RPi::Device::DS18B20 to ecosystem.
08:25 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/056ca1c3e9
08:28 vividsnow joined #perl6
08:29 domidumont joined #perl6
08:32 azawawi ZoffixWin: ping
08:33 ZoffixWin azawawi, pong
08:33 azawawi ZoffixWin: just noticed the merge of RPi::Device::DS18B20
08:33 azawawi ZoffixWin: im planning on doing some RPi work for rakudo star on 2016 :)
08:33 azawawi ZoffixWin: regular rakudo star release
08:33 ZoffixWin sweet
08:34 azawawi ZoffixWin: that way we do not waste the time of people trying out Perl 6 on RPi
08:34 vividsnow joined #perl6
08:35 domidumont joined #perl6
08:35 azawawi ZoffixWin: also given i played with OpenCV lately a lot on python im planning on doing stuff with DrForr hopefully to get OpenCV bindings ready
08:35 ChoHag Is there an equivalent to prove(1) for perl6?
08:35 ChoHag Or Test::*?
08:35 ChoHag of
08:35 azawawi ZoffixWin: attract scientific + hobbyist community that is
08:35 ZoffixWin prove -e 'perl6' is what I use
08:36 ZoffixWin azawawi, good plan. I recall RabidGravy compiling P6 on RPi and it was taking ages
08:36 azawawi ChoHag: to be exact prove -e 'perl6 -Ilib' if you're using your local directory (not installed)
08:37 azawawi ChoHag: prove -e "perl6 -Ilib"
08:37 azawawi ZoffixWin: doing anything on RPi takes ages lol
08:37 skids ChoHag: Rakudo ships with a Test module in ./lib and the roast repo has numerous submodules for running the spectests.
08:38 azawawi ZoffixWin: perlbrew took like 4 hours if i recall correctly on the older B model
08:38 AlexDaniel azawawi: holy…
08:39 azawawi AlexDaniel: 512MB
08:39 ZoffixWin :o
08:39 ChoHag I've seen Rakudo's tests but didn't pay a great deal of attention to how they're run, given that they need to deal with the chicken & egg problem which compilers face.
08:39 azawawi it will be slower given the lower memory and paging that occurs
08:40 ChoHag azawawi: It's the need to add -I and friends *within the -e argument* that I wondered about a perl 6 aware prove.
08:41 azawawi ChoHag: i see
08:42 azawawi come to think of it, why are we using 'prove' and not something in perl6 like 'prove6'?
08:42 ChoHag It's fine though, it works. I didn't really expect there to be something specific yet.
08:42 ChoHag From the other angle, can I make perl 5 exec itself with perl6 when it encounters use v6 rather than telling me off?
08:43 vividsnow joined #perl6
08:43 azawawi ofcourse given this tweet "SunSpider Javascript benchmark completes in 4452.1ms on Raspberry Pi 2, compared with 23692.7ms on Raspberry Pi Model B+.". I think the new RPi2 will be way faster for perl6
08:44 azawawi http://www.raspberry-projects.com/pi/pi-hardware/raspberry-pi-2-model-b/rpi2-model-b-hardware-general-specifications
08:48 ChoHag Or, can I make prove consider the #!?
08:49 vividsnow joined #perl6
08:50 skids There is a TAP::Harness module in the ecosystem -- not sure how complete it is.
08:56 azawawi to be exact, 'perlbrew install perl-5.16.1' takes like 12,667 seconds ~ 3.5 hours on RPi 1 B model (512MB)
08:56 azawawi newer perls can take more (running the test suite takes most of the time)
08:56 ChoHag If only there was some way of building things on one machine to run on another...
08:57 wamba joined #perl6
08:57 ChoHag FWIW, the core stack (master/nom, not the tagged releases) builds successfully on openbsd 5.7.
08:57 azawawi ChoHag: the fun thing when it fails lol
08:57 vividsnow1 joined #perl6
09:02 sunnavy joined #perl6
09:04 vividsnow joined #perl6
09:05 azawawi ChoHag: im going to try build instructions at http://test.asenjo.nl/index.php/Perlbrew # cross compiling for RPi
09:06 azawawi ChoHag: and later try to apply them to rakudo hopefully. This will speed building/testing a lot for RPi
09:06 azawawi The problem is i have an older RPi model and not the newer one (1GB) so i couldnt test on it atm
09:15 pjscott joined #perl6
09:20 nine azawawi: leont++ is working on a test harness (prove6) for Perl 6
09:20 azawawi nine: cool
09:20 ChoHag Where did panda's bootstrap.pl install its modules to?
09:22 nine ChoHag: CompUnit::RepositoryRegistry.repository-for-name("site") with fallback to ~/.perl6
09:22 nine Oooh! There's a bug!
09:22 nine m: say CompUnit::RepositoryRegistry.repository-for-name("home")
09:22 camelia rakudo-moar 3568c1: OUTPUT«inst#/home/camelia/.perl6/2015.12-69-g3568c1e␤»
09:22 azawawi ChoHag: on my machine, it looks to be ~/.rakudobrew/moar-2015.12/panda
09:22 nine oh, not a but at all
09:24 bitmap joined #perl6
09:24 nine not even a bug
09:24 ChoHag Is not installing any .pm or .pm6 files a bug or a feature?
09:25 ChoHag A Microsoft style feature.
09:29 firstdayonthejob joined #perl6
09:38 nige1 joined #perl6
09:47 krunen joined #perl6
09:48 RabidGravy joined #perl6
09:53 RabidGravy marning!
09:55 lizmat good *, #perl6!
09:55 lizmat RabidGravy o/
09:55 lizmat Best wishes for 210 Perl 6 !
09:55 lizmat *sigh*
09:55 TEttinger heh
09:55 lizmat 201 Perl 6
09:55 lizmat still not quite awake
09:56 ChoHag 210? Is that like half a 420?
09:56 ChoHag Because that's not a good idea while still waking up.
09:57 ChoHag God that joke was lame.
09:57 RabidGravy 116
09:57 lizmat yeah... I know... :-(
09:57 lizmat it can only get better this year  (I hope :-)
09:59 bpetering joined #perl6
09:59 z8 joined #perl6
10:00 bpetering Happy new year everyone and congrats to * for getting to v6.0.0
10:01 azawawi RabidGravy: hi :)
10:01 bpetering I have some NativeCall questions if anyone can help
10:03 pierre-vigier joined #perl6
10:03 pierre-v_ joined #perl6
10:05 moritz \o
10:05 bpetering Firstly, is it currently possible in Rakudo to interface with a function that takes a pointer and writes back through that pointer?
10:05 moritz yes
10:06 bpetering e.g. my Pointer[int32] $p (and the C code sets $p.defer
10:06 bpetering hai moritz, long time :)
10:06 moritz sub foo($x is rw) is native(...) for example
10:06 moritz or you can declare a CArray
10:06 moritz because arrays and pointers are really interchangable in C land
10:08 bpetering moritz: thanks. will try both approaches for my use case
10:09 moritz bpetering: you're welcome. Are you aware of https://doc.perl6.org/language/nativecall ?
10:09 moritz feedback and/or improvements to that page would be very much appreciated
10:09 RabidGravy azawawi, yo! you good?
10:09 bpetering moritz: yep, I'm following that but getting segfault when I'm not expecting it
10:09 rindolf joined #perl6
10:10 bpetering I'll do what I can to improve it seeing I'm coming back to perl6 after a few years away
10:10 moritz huh, it doesn't even mention the "is rw" trick
10:10 user74747 joined #perl6
10:11 bpetering (happy to contribute sorta-newbie eyes)
10:11 azawawi RabidGravy: yup... looking at http://www.numberempire.com/2016
10:11 RabidGravy bpetering, you may find (in the case of an unexpected segfault) that perl6-gdb-m and/or perl6-valgrind-m may help
10:12 bpetering RabidGravy: cheers, I'll see what I can find out
10:18 apejens joined #perl6
10:18 masak good antenoon, #perl6
10:19 apejens hey, I get an error when I do `rakudobrew build-panda`: https://gist.github.com/omega/4b7def9db6598539b887
10:19 apejens just installed rakudobrew and built moar 2015.12
10:20 lnrdo joined #perl6
10:21 RabidGravy woah, that's a good one
10:21 RabidGravy :)
10:21 RabidGravy isn't it something to do with setting some environment variable <mumble and hand wave>?
10:22 apejens http://perl6.org/downloads/ I tried following the quick start thingy
10:22 apejens I can run perl6
10:23 RabidGravy I think someone else reported this a few momths ago and they tracked it down to being some Perl 5 specific environment being set for some reason
10:23 apejens hmm
10:24 RabidGravy I think it's one of PERL5LIB, PERLLIB or similar
10:24 apejens yeah, I have PERL5LIB set
10:25 RabidGravy what happens if you do "PERL5LIB=  rakudobrew build-panda"?
10:25 apejens yeah, that works, just tested
10:25 spider-mario joined #perl6
10:26 RabidGravy cool
10:27 apejens and it's only a problem during teh bootstraping of the deps
10:28 RabidGravy I'm not sure that anyone actually found out *why* this was happening
10:28 nige1 joined #perl6
10:29 lnrdo joined #perl6
10:30 bitmap joined #perl6
10:35 llfourn joined #perl6
10:36 RabidGravy "494   494 37045 META.list"  - ooh so getting there
10:41 CIAvash joined #perl6
10:41 vendethiel joined #perl6
10:44 bpetering moritz: the 'is rw' trick still isn't working, and CArray is doing something I think is equivalent
10:44 bpetering here's what I'm up to... https://gist.github.com/bpetering/02f5062933ba6db2933f
10:45 bpetering the idea is to "init", take a pointer-to-pointer and give back an initialized object through the p-t-p
10:46 bpetering anyway, on the last line of test.pl6, i get
10:46 bpetering "Invocant requires an instance of type NativeCall::Types::Pointer[foo], but a type object was passed."
10:46 bpetering can anyone tell me if I'm doing anything silly there?
10:47 moritz bpetering: uhm, I might be confused, but aren't you using one pointer level too much?
10:47 moritz Pointer[...] AND is rw?
10:48 bpetering if you look at test.c, that's the correct C API I'm coding to
10:49 bpetering as for the perl6, i'm less certain
10:49 moritz maybe try with one level of pointering first?
10:49 [Tux] csv-ip5xs        50000    19.785    19.672
10:49 [Tux] test             50000    23.612    23.499
10:49 [Tux] test-t           50000    13.045    12.932
10:50 [Tux] And a happy new year to all
10:51 lizmat [Tux] o/
10:57 bpetering moritz: one level of pointering works fine, but when it comes to C constructs with two levels of indirection I can't get it working
10:58 bpetering so suggestion #1 for language/nativecall is "explain how to do **pointer things"
10:58 moritz CArray[CArray[foo]] ?
10:59 moritz also, have you tried Pointer[Pointer[foo]] ?
10:59 bpetering that's where I'm getting confused, since foo is already "is repr('CPointer')"
10:59 bpetering I'm assuming that "is repr..." gives me one level of pointering
10:59 bpetering does it?
11:00 RabidGravy yeah
11:01 RabidGravy it works fine for things where you have an init function that returns a pointer to a "handle" and pass that to all the other functions
11:01 RabidGravy for instance
11:03 bpetering the library I'm trying to attach with NativeCall has an extra level of indirection
11:03 bpetering you declare a pointer, pass the address of *that*, and the init function fills it in with the address of an object
11:03 RabidGravy but the pointer to a pointer interface here it is entirely possible that no-one has used it before :)
11:03 bpetering RabidGravy: that's what I'm suspecting
11:03 bpetering :o)
11:04 RabidGravy yeah so, I' go with "my Pointer[foo] $a = Pointer[foo].new"
11:04 RabidGravy I'd
11:05 RabidGravy in the first instance
11:05 pierre-vigier joined #perl6
11:05 RabidGravy m: use NativeCall;  my Pointer[foo] $a = Pointer[foo].new;
11:05 camelia rakudo-moar 3568c1: OUTPUT«5===SORRY!5=== Error while compiling /tmp/Jhw5DFKNCS␤An exception occurred while parameterizing Pointer␤at /tmp/Jhw5DFKNCS:1␤Exception details:␤  5===SORRY!5=== Error while compiling ␤  Cannot invoke this object␤  at :␤»
11:05 _mg_ joined #perl6
11:06 RabidGravy m: use NativeCall;  class foo is repr('CPointer') {}; my Pointer[foo] $a = Pointer[foo].new;
11:06 camelia rakudo-moar 3568c1: ( no output )
11:06 bpetering RabidGravy: that line works for me with Rakudo 2015.12
11:06 bpetering (but I also have 'foo' defined ;)
11:06 RabidGravy yeah, confusing error message from rakudo there
11:06 nine Sounds like sub init-foo(Pointer is rw) is native(...) { * }; my $p = Pointer.new; init-foo($p); should do the trick?
11:07 RabidGravy yeah, there is a little bit of that
11:07 nine One day I will replace the CArray[OpaquePointer] in Inline::Perl5 with that...
11:08 moritz wasn't there something about "is rw" in nativecall only working with natives?
11:09 nine moritz: Could be. I'm a bit out of date WRT NativeCall advances in the past yesr
11:09 RabidGravy bpetering, so this interface is in reality a 3rd party library you can't change?
11:11 moritz bpetering: if "is repr('CPointer')" gives you one level of pointer, doing both Pointer and is rw gives you total of three levels of pointer
11:11 bpetering RabidGravy: it's libgit2, so I can't really change it :)
11:11 RabidGravy because if so and if all else fails I would go with making a tiny helper wrapper
11:11 RabidGravy in C
11:12 bpetering moritz: thanks, that's clearer than the docs are currently
11:12 RabidGravy yeah the nativecall docs probably could do with some love
11:12 dakkar joined #perl6
11:13 bpetering RabidGravy: I might go the wrapper route for now, since libgit2 is on the most-wanted nativecall list
11:13 bpetering cheers
11:14 bpetering Other improvements to language/nativecall:
11:14 bpetering what type/syntax to use for C structs with bitfields
11:15 bpetering why/when to use is repr('CPointer') vs plain is Pointer
11:15 RabidGravy yeah, I don't think there is anything for that right now
11:15 RabidGravy I think I'd go with some  uint8 $!fields and then some accessor methods to pick the bits out
11:16 itaipu joined #perl6
11:16 bpetering RabidGravy: that makes sense, I'd make the accessor methods return Int/Bool for width >1/1
11:16 bpetering (also assuming bit-fields pack on 8-bit boundaries, I can't remember)
11:17 bpetering Two other things I'm unclear about reading languages/nativecall for first time
11:17 bpetering 1) are there any gotchas with translating certain C semantics like "volatile" into Perl 6 terms?
11:18 bpetering 2) any issues to be aware of with threading/reentrancy?
11:18 bpetering So, the above, and how to sanely handle multiple levels of pointers
11:19 bpetering I'm happy to write things up but I don't myself understand any of this yet :o(
11:19 nine bpetering: well do you still have questions WRT multiple levels of pointers?
11:19 RabidGravy 1) dunno 2) depends on the library I think - some libraries keep static data which shags concurrency
11:20 Skarsnik joined #perl6
11:20 bpetering RabidGravy: i infer from that that threading/reentrancy is a per-library issue, might be worth making that clear in the docs
11:21 RabidGravy bear in mind you are treading a path not so well trodden with this stuff, of the nearly 500 modules in the ecosystem there are only two dozen that use NativeCall
11:22 bpetering nine: I still can't get my example working. Updated gist: https://gist.github.com/bpetering/031934a05ca1242a7def
11:23 bpetering RabidGravy: yeah. I couldn't see any existing NativeCall code that does what I'm trying to
11:23 nine bpetering: have you tried sub foo_init(foo is rw) ... ; my $p = foo.new; foo_init($p)?
11:23 fjk joined #perl6
11:24 hankache joined #perl6
11:25 bpetering nine: "Method 'deref' not found for invocant of class 'foo'"
11:25 lnrdo joined #perl6
11:25 bpetering I'm trying to call .deref since (to my mind) I want to remove one layer of pointers
11:25 nine bpetering: if that doesn't work, this should do the trick: sub foo_init(CArray[foo]) ... ; my $foo_ptr = CArray[foo].new; $foo_ptr[0] = foo.new; foo_init($foo_ptr);
11:26 nine bpetering: I don't see a reason for deref??
11:26 nine bpetering: is rw means, "don't pass this as is, but pass a pointer to it". Just like foo_init(&myfoo) in C
11:29 bpetering yay!
11:29 Skarsnik hm, your code should work x)
11:29 bpetering nine: that last example ends up working
11:29 Skarsnik hellp
11:29 Skarsnik *hello
11:30 bpetering (_shutdown sees the same pointer)
11:30 nige1 joined #perl6
11:30 bpetering o/ Skarsnik
11:30 RabidGravy yay!
11:30 bpetering thanks everyone :)
11:31 bpetering Ok, that's the really annoying bit
11:31 bpetering I think I'm unblocked for the rest of libgit2 now (it doesn't do that very often)
11:31 bitmap joined #perl6
11:32 Skarsnik you can put say $p.WHAT before the deref in your original code?
11:32 Skarsnik I mean the gist you linked x)
11:33 hankache hello everyone!
11:33 hankache haapy new year
11:33 hankache happy**
11:33 nine bpetering: "is rw" works just as well: https://gist.github.com/niner/6cc82bfcbb6615acadd0
11:33 nine Skarsnik: ^^^
11:35 bpetering Skarsnik: 'say $p.WHAT' just results in segfault
11:36 bpetering nine: that's awesome
11:36 Skarsnik hm, that's really bad x)
11:37 bpetering moritz: the reason "is rw" didn't work in the beginning is because I wasn't calling foo.new
11:38 bpetering nine: that's a much nicer way to do it
11:40 bpetering I reckon it'd be worth putting a few examples into nativecall docs (with C code) that show how to handle cases like this one
11:40 bpetering I wouldn't have gotten to a solution without asking here
11:41 * bpetering offers to (I had commit access to the spec tests years ago but have lost it)
11:41 Skarsnik That does not work to just class foo is repr('CStruct') {}; and playing with Pointer[foo] Pointer[Pointer[foo]]
11:41 RabidGravy yeah, that segfaulting shouldn't happen, but I imagine it would be very difficult to fix as the Ponter is as near to the metal  as it gets in Perl 6 and may not have the infrastructure to support that
11:41 Skarsnik ?
11:42 bpetering Skarsnik: as far as I can tell, no
11:42 Skarsnik it should
11:42 bpetering Skarsnik: I'll try and get that case working for you
11:42 RabidGravy bpetering, I think you hit the channel at the optimum time :)
11:42 Skarsnik anyway afk lunch
11:45 vividsnow joined #perl6
11:46 RabidGravy bpetering++ # make these things so we don't have to
11:47 bpetering RabidGravy: thanks :)
11:47 bpetering definitely right time
11:48 bpetering Skarsnik: no joy. segfaults all the way
11:48 rindolf joined #perl6
11:54 ugexe joined #perl6
12:02 spider-mario joined #perl6
12:07 pierre-vigier joined #perl6
12:09 kid51 joined #perl6
12:11 dalek rakudo/nom: 42326d1 | lizmat++ | src/core/Array.pm:
12:11 dalek rakudo/nom: Fix for RT #127093
12:11 dalek rakudo/nom:
12:11 dalek rakudo/nom: It turned out that somehow the default value of the ContainerDescriptor
12:11 dalek rakudo/nom: for a typed, shaped array, wasn't set.  By setting it explicitely, the
12:11 dalek rakudo/nom: described problem goes away.  Perhaps this has something to do with the
12:11 dalek rakudo/nom: fact that you cannot set default values on shaped arrays yet.
12:11 dalek rakudo/nom:
12:11 dalek rakudo/nom: Jonathan: I was wondering whether the .new of ContainerDescriptor should
12:11 dalek rakudo/nom: not just set the default attribute with the :of value if no :default is
12:11 dalek rakudo/nom: specified.  OTOH, I'm not sure how to detect :default not being passed
12:11 dalek rakudo/nom: in nqp.
12:11 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/42326d1b72
12:11 Skarsnik bpetering, hm that pretty sad
12:15 iH2O joined #perl6
12:17 bpetering Skarsnik: if you think so... it's workaroundable for me for now
12:17 zengargoylew joined #perl6
12:17 bpetering m: my $s = "foo"; explicitly-manage($s);
12:17 camelia rakudo-moar 3568c1: OUTPUT«5===SORRY!5=== Error while compiling /tmp/IoWrdUz_vz␤Undeclared routine:␤    explicitly-manage used at line 1␤␤»
12:18 bpetering why do I get "undeclared routine" there?
12:18 bpetering m: use NativeCall; my $s = "foo"; explicitly-manage($s);
12:18 camelia rakudo-moar 3568c1: ( no output )
12:18 bpetering ah
12:20 RabidGravy gah, I thought I had got my head round sub-signatures in traits, but it seems I haven't
12:25 RabidGravy ah yes, I had to make more than one candidate
12:25 * RabidGravy gets his refactoring thang on
12:29 loren joined #perl6
12:30 loren Evening, #Perl 6
12:30 lizmat loren o/
12:31 Skarsnik that look like a type https://github.com/rakudo/rakudo/blob/nom/lib/NativeCall.pm6#L89 it should probably be char x)
12:31 RabidGravy eh up
12:31 loren lizmat, o//
12:32 RabidGravy Skarsnik, "signed" , isn't a "char" a uint8
12:33 Skarsnik char is signed
12:33 Skarsnik there is uchar and uint8 in the list that use this
12:35 ChoHag How can I write a test to prove that a class exists (and can be subclassed)?
12:36 Skarsnik if ::("classnmae") ?
12:36 RabidGravy use Test; ok ::('Int')
12:36 RabidGravy m: use Test; ok ::('Int')
12:36 camelia rakudo-moar 42326d: OUTPUT«not ok 1 - ␤␤# Failed test at /tmp/bItGc9i1RI line 1␤»
12:36 RabidGravy eh?
12:36 ChoHag Quite.
12:37 Skarsnik m: use Test; ok ::('Core::Int')
12:37 camelia rakudo-moar 42326d: OUTPUT«not ok 1 - ␤␤# Failed test at /tmp/icW_3ywoB9 line 1␤»
12:37 RabidGravy m: use Test; ok ::('Int').defined
12:37 camelia rakudo-moar 42326d: OUTPUT«not ok 1 - ␤␤# Failed test at /tmp/HrTF2p8PBL line 1␤»
12:38 RabidGravy is why
12:38 lizmat m: use Test; ok ::('Int').DEFINITE
12:38 camelia rakudo-moar 42326d: OUTPUT«not ok 1 - ␤␤# Failed test at /tmp/BxocsWQnER line 1␤»
12:38 lizmat hmmm
12:38 lizmat m: use Test; ok ::('Foo')
12:38 camelia rakudo-moar 42326d: OUTPUT«not ok 1 - ␤␤# Failed test at /tmp/2bOf50rx3U line 1␤»
12:41 RabidGravy use Test; ok ::("Foo") ~~ Failure ?? False !! True
12:41 RabidGravy m: use Test; ok ::("Foo") ~~ Failure ?? False !! True
12:41 camelia rakudo-moar 42326d: OUTPUT«not ok 1 - ␤␤# Failed test at /tmp/BLhCTmhqyf line 1␤»
12:41 RabidGravy m: use Test; ok ::("Int") ~~ Failure ?? False !! True
12:41 camelia rakudo-moar 42326d: OUTPUT«ok 1 - ␤»
12:42 RabidGravy may even merit a sub in Test:  type-ok or somesuch
12:44 lucasb joined #perl6
12:44 ChoHag I want to write more than 0 tests before I start adding to existing test modules.
12:44 Skarsnik how the hell t/04/04.t passed in NC
12:44 ChoHag Now I have 1, so I'm on my way.
12:45 dalek rakudo/nom: e63d878 | lizmat++ | src/core/Variable.pm:
12:45 dalek rakudo/nom: We don't need a try to have a CATCH
12:45 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/e63d8785cb
12:48 RabidGravy as to be able to sub-class it's probably something in the manner of
12:48 SwellJoe joined #perl6
12:48 RabidGravy m: role F {}; class G {};  G.^add_parent(F);
12:48 camelia rakudo-moar 42326d: OUTPUT«Parents cannot be added to a class after it has been composed␤  in any add_parent at gen/moar/m-Metamodel.nqp line 787␤  in block <unit> at /tmp/hX6_aCV1pI line 1␤␤»
12:49 Actualeyes joined #perl6
12:50 RabidGravy m: role F {}; my $g :=  Metamodel::ClassHOW.new_type(name => "G"); $g.^add_parent(F);
12:50 camelia rakudo-moar 42326d: ( no output )
12:50 RabidGravy m: role F {}; my $g :=  Metamodel::ClassHOW.new_type(name => "G"); $g.^add_parent(F); $g.^compose
12:50 camelia rakudo-moar 42326d: OUTPUT«Cannot find method 'mro'␤  in any compute_mro at gen/moar/m-Metamodel.nqp line 931␤  in any compose at gen/moar/m-Metamodel.nqp line 3003␤  in block <unit> at /tmp/50Pp8pueeL line 1␤␤»
12:50 RabidGravy m: class F {}; my $g :=  Metamodel::ClassHOW.new_type(name => "G"); $g.^add_parent(F); $g.^compose
12:50 camelia rakudo-moar 42326d: ( no output )
12:51 RabidGravy yeah, so if it craps out when you compose you can't inherit from it :)
12:52 ChoHag Under what circumstances would it be impossible to inherit from a class?
12:52 RabidGravy well, well a "type" if it's a role as above
12:54 bpetering /quit
12:54 RabidGravy probably stuff that is pretending to be a class but doesn't have ClassHOW as an ancestor of its HOW
12:55 RabidGravy which is not impossible given enough crack
12:56 RabidGravy m: enum F <a b>; my $g :=  Metamodel::ClassHOW.new_type(name => "G"); $g.^add_parent(F); $g.^compose
12:56 camelia rakudo-moar e63d87: ( no output )
12:57 RabidGravy obviously I need more crack
12:57 iH2O left #perl6
12:59 flaviusb joined #perl6
13:02 cpage_ joined #perl6
13:08 ChoHag Can a Failure not be assigned to typed variables? Any more?
13:08 gfldex ChoHag: it can
13:09 ChoHag m: my Str $thing = Failure.new("wtf?")
13:09 camelia rakudo-moar e63d87: OUTPUT«Earlier failure:␤ wtf?␤␤Final error:␤ Type check failed in assignment to $thing; expected Str but got Failure␤  in block <unit> at /tmp/gZ6NaVERq3 line 1␤␤»
13:09 pierre-vigier joined #perl6
13:09 ChoHag m: my Str $foo = fail("wtf?"); say so $foo ~~ Failure;
13:09 camelia rakudo-moar e63d87: OUTPUT«wtf?␤  in block <unit> at /tmp/DYPEHfZlar line 1␤␤»
13:10 ChoHag m: my Str $foo = fail("wtf?"); say "Still here."; say so $foo ~~ Failure;
13:10 camelia rakudo-moar e63d87: OUTPUT«wtf?␤  in block <unit> at /tmp/WUF376qNaE line 1␤␤»
13:10 lucasb 'fail' always throws; Failure.new does not
13:11 ChoHag m: sub foo { fail "wtf?" }; my Str $thing = foo; say "OK"; say so $thing ~~ Failure;
13:11 camelia rakudo-moar e63d87: OUTPUT«Earlier failure:␤ wtf?␤  in sub foo at /tmp/hSVZe4cmI3 line 1␤  in block <unit> at /tmp/hSVZe4cmI3 line 1␤␤Final error:␤ Type check failed in assignment to $thing; expected Str but got Failure␤  in block <unit> at /tmp/hSVZe4cmI3 line 1␤␤»
13:11 lucasb I always thought 'fail' was just shortcut for Failure.new, but apparently it's not
13:12 _nadim joined #perl6
13:12 ChoHag Still can't assign the Failure to Str $foo.
13:13 nige1 joined #perl6
13:13 lizmat m: say Failure.^mro   # the probable reason
13:13 camelia rakudo-moar e63d87: OUTPUT«((Failure) Nil (Cool) (Any) (Mu))␤»
13:13 lucasb ChoHag: yes, I agree
13:14 lizmat m: my Cool $a = Failure.new
13:14 camelia rakudo-moar e63d87: ( no output )
13:14 ChoHag m: my Str $thing = Failure.new("wtf?") but Str
13:14 camelia rakudo-moar e63d87: OUTPUT«Cannot mix in non-composable type Str into object of type Failure␤  in block <unit> at /tmp/tGHnOLIYZD line 1␤␤»
13:14 ChoHag Didn't think so.
13:16 bonsaikitten https://bpaste.net/show/047e0947db71 I have no idea why make install implodes :(
13:17 AndyDee Worth a watch if anyone is having a little break or so : https://www.youtube.com/watch?v=kwxHXgiLsFE
13:18 rindolf Hi all! Sup?
13:19 ChoHag So am I not supposed to be able to assign a Failure to a typed object?
13:19 ChoHag I'm reasonably sure I could before, although it's been a while since I wrote that part of the code.
13:20 Skarsnik m: my Str $f = Nil;
13:20 camelia rakudo-moar e63d87: ( no output )
13:21 xpen joined #perl6
13:21 spider-mario joined #perl6
13:21 Skarsnik bonsaikitten, what did you do? give us more context ^^
13:24 gfldex bonsaikitten: could you change 'M_RUNNER = perl6-m' to 'M_RUNNER = perl6-m --ll-exception' in the Makefile to make it more talkative?
13:26 lucasb well, it's at least a little inconsistent that failures do *not* respect subroutine return type constraints, but it *does* respect type constraints in variables
13:27 ChoHag It's kind of annoying. I was using it to trick a class into being instantiated before I had all the required values, then supplying them afterwards.
13:27 ChoHag And why is an idle VM using ~35% of the host CPU?
13:27 Skarsnik m: use NativeCall; my Pointer[Pointer[int32]] $a. say $a.WHAT;
13:27 camelia rakudo-moar e63d87: OUTPUT«5===SORRY!5=== Error while compiling /tmp/N0Q8v0AJG4␤Two terms in a row␤at /tmp/N0Q8v0AJG4:1␤------> 3Call; my Pointer[Pointer[int32]] $a. say7⏏5 $a.WHAT;␤    expecting any of:␤        infix␤        infix stopper␤        statement e…»
13:28 Skarsnik m: use NativeCall; my Pointer[Pointer[int32]] $a; say $a.WHAT;
13:28 camelia rakudo-moar e63d87: OUTPUT«(NativeCall::Types::Pointer[NativeCall::Types::Pointer[int32]])␤»
13:31 spider-mario joined #perl6
13:32 lucasb yeah, I found the ticket I was looking for: https://rt.perl.org/Public/Bug/Display.html?id=126631
13:32 lucasb m: Exception.new.fail; say 'hi'
13:32 camelia rakudo-moar e63d87: ( no output )
13:32 lucasb ^^ I think this is the same case
13:33 lucasb the fail subroutine was fixed, but the issue still lives in the Exception.fail method
13:36 Skarsnik RabidGravy, https://gist.github.com/Skarsnik/31a1099ceb0ea595e173 do you think it's fine like this? (I really don't like the .new on $ptr2) It work but maybe a is alloc trait could be more explicit x)
13:37 ChoHag Shouldn't an unhandled Failure report itself?
13:37 ChoHag m: sub foo { my $bar = Failure.new("wtf"); True }; foo
13:37 camelia rakudo-moar e63d87: ( no output )
13:39 lucasb I think this only happens in sink context
13:39 ChoHag According to Failure.pm it's checked for whenever the Failure's DESTROY is called.
13:45 bonsaikitten gfldex: https://bpaste.net/show/782742b7f6a1
13:45 bonsaikitten Skarsnik: I'm trying to upgrade from 2015.11 to .12 :)
13:47 gfldex bonsaikitten: please nuke your rakudo/install or whatever is your --target
13:47 ChoHag That's not it.
13:47 bonsaikitten gfldex: the what in the what?
13:48 ChoHag Smells to me like precompilation as non-root into the prefix rather than workdir.
13:49 ChoHag Besides, installing at this early juncture into /usr is insanity.
13:49 gfldex bonsaikitten: in that one month the module loader code was changed quite heavily, leading to all sorts of problems
13:49 regreg joined #perl6
13:50 virtualsue joined #perl6
13:50 gfldex ChoHag: somebody has to test it at some point. That way it's him not you who gets burned. :)
13:50 bonsaikitten I always find the best bugs
13:50 ChoHag I already got burned :)
13:50 Skarsnik and 2012.12 is still buggy for it?
13:51 ChoHag bonsaikitten: Build with and install into a prefix under your user's control. And in general don't mix pre- or early-release code with your base system.
13:52 bonsaikitten ChoHag: since this is a relatively pristine chroot ... already there, mate :)
13:52 ChoHag Well if it's just for rakudo then go nuts.
13:53 ChoHag But ISTR issues around the build process requiring write access to the install location.
13:53 ChoHag Run as root or, preferably, install elsewhere.
13:53 bonsaikitten or sandbox it
13:53 bonsaikitten if it tries to misbehave it dies :)
13:53 ChoHag It's perl. Misbehaving is what it's for.
13:55 nine ChoHag: I'd just write use Test; use MyClass; class MySubClass is MyClass {}; MySubClass.new; plan 1; ok; # that way you test that MyClass does exist and is subclassable.
13:57 RabidGravy Skarsnik, that looks sane-ish at least
13:57 Skarsnik I did not change a thing
13:57 Skarsnik I am just addding test in 04-pointer.t x)
13:58 ChoHag I prefer to have my tests fail individually than have the entire script blow up where possible.
13:58 ChoHag Plus I can't .new because there are required attributes, but that's another story.
13:59 leont joined #perl6
14:00 moritz m: say ::('Int') !~~ Failure
14:00 camelia rakudo-moar e63d87: OUTPUT«True␤»
14:00 moritz m: say ::('Nosuchclass') !~~ Failure
14:00 camelia rakudo-moar e63d87: OUTPUT«False␤»
14:00 moritz m: say ::('Nosuchclass').^name
14:00 camelia rakudo-moar e63d87: OUTPUT«Failure␤»
14:03 darutoko joined #perl6
14:08 RabidGravy ChoHag, maybe use eval-live-ok and put the class definition in a string?
14:09 RabidGravy ouch
14:10 pierre-vigier joined #perl6
14:10 RabidGravy m: class Foo:ver<v0.0.1> {}; say Foo.^ver
14:10 camelia rakudo-moar e63d87: OUTPUT«vv.0.0.1␤»
14:10 RabidGravy IT'S VERSION BOUNCING TIME!
14:10 Skarsnik ?
14:10 Skarsnik that... interesting
14:10 perlawhirl joined #perl6
14:11 RabidGravy all my modules that are versioned like that have the v which is not what is intended
14:11 nash joined #perl6
14:12 ChoHag Why are private multi-methods not supported?
14:12 Skarsnik It's most likely a bug
14:12 cygx joined #perl6
14:12 cygx m: class Foo:ver(v1) {}; class Bar:ver<1> {}; say Foo.^ver; say Bar.^ver
14:12 camelia rakudo-moar e63d87: OUTPUT«v1␤v1␤»
14:13 RabidGravy yeah, it's not a bug, it's my brane being useless
14:13 perlawhirl m: say (1...Inf).grep(*.is-prime)[10000];
14:13 Skarsnik Union in C are not named?
14:13 camelia rakudo-moar e63d87: OUTPUT«(timeout)»
14:13 ChoHag RabidGravy: Seems like it might make sense to treat versions of 'v.*' as '*'.
14:13 perlawhirl m: say (1...Inf).grep(*.is-prime)[100];
14:13 camelia rakudo-moar e63d87: OUTPUT«547␤»
14:14 deniska joined #perl6
14:14 lizmat I'm still not sure it is a good idea to allow versioning on a class  :-(
14:14 perlawhirl Was just looking at perl6 examples... are the Euler solutions neglected? Looking at this: http://examples.perl6.org/categories/euler/prob007-polettix.html
14:14 ChoHag Why?
14:14 RabidGravy ChoHag, I made some code that hacks around it in META6 but it's doing what is being asked for here
14:15 RabidGravy lizmat, not so sure my self
14:15 RabidGravy anyway off out to the shops and maybe the pub
14:15 timotimo o/
14:17 masak perlawhirl: what makes you think they're neglected?
14:18 perlawhirl the one i posted... would it not be better as: say (1...Inf).grep(*.is-prime)[10000];
14:19 perlawhirl is faster on my machine, less verbose
14:19 cygx perlawhirl: also, probabilistic and using a built-in instead of low-level
14:20 virtualsue joined #perl6
14:20 perlawhirl cygx: exactly... showing off perl's operators
14:21 wamba joined #perl6
14:21 cygx perlawhirl: feel frww to add your own version to https://github.com/perl6/mu/tree/master/examples/euler
14:21 cygx *free
14:21 perlawhirl cygs: k
14:21 cygx jold on, I think that's the wrong repository
14:21 xpen joined #perl6
14:22 cygx (fails at typing more than ordinary today)
14:22 masak perlawhirl: people's tastes differ, but using a built-in to trivially get an answer does not feel to me like solving a Euler problem. I'm none the wiser afterwards.
14:22 masak (but I can also argue the other side of that. "if there's a one-line solution to something, then we should use that")
14:24 cygx perlawhirl: here we go: https://github.com/perl6/perl6-examples/tree/master/categories/euler
14:24 perlawhirl I guess I understand... a one-liner implementation is a Rosetta Code solution; a low-level implementation is more of a Euler solution.
14:25 cygx depends on what you're trying to show off
14:26 masak it does. I wouldn't mind having both solutions :)
14:26 perlawhirl cygs: you right... though my own prejudice is i that the faster solution should win out.
14:27 masak faster, more elegant, simpler
14:27 nanis joined #perl6
14:29 cygx (but successible to attacks via pseudoprimes in a cryptographic setting)
14:29 cygx *susceptible
14:30 perlawhirl :D was about to correct you... i understood
14:30 masak cygx: I'm not sure that's applicable here, though
14:31 perlawhirl nah... euler puzzles, like most programming puzzle, favour simple solutions. like error checking is unneccessary overhead
14:31 iH2O joined #perl6
14:31 nine m: class Foo:ver(v0.0.1) {}; say Foo.^ver
14:31 camelia rakudo-moar e63d87: OUTPUT«v0.0.1␤»
14:31 leont Searching for cryptographic primes uses different algorithms than what imagine we use for smallish numbers
14:32 nine .tell RabidGravy class Foo:ver(v0.0.1) {}; say Foo.^ver
14:32 yoleaux nine: I'll pass your message to RabidGravy.
14:32 cygx and now for something completely different: anyone else amazed by the fact that of all things, Oracle is apparently succeeding at bringing the Parrot vision to fruition?
14:33 leont There is some irony in there, yes
14:33 cygx nine: already brought to RabidGravy's attention
14:35 * cygx is talking about Graal/Truffle, cf eg http://lists.ruby-lang.org/pipermail/jruby/2015-December/000262.html or https://www.youtube.com/watch?v=OUo3BFMwQFo )
14:38 nbrown joined #perl6
14:39 nbrown joined #perl6
14:40 _mg_ joined #perl6
14:41 hankache joined #perl6
14:44 ChoHag I'd say Oracle want their own java ecosystem, but they have one.
14:44 ChoHag Or rather, it.
14:44 ChoHag Maybe part of Oracle hasn't realised that they bought Sun yet?
14:45 ChoHag Part of them still doesn't realise that they have ZFS, for example.
14:45 pmurias joined #perl6
14:46 pmurias cygx: from a quick look at it Graal/Truffle seems like it would be really awesome for Perl 6
14:47 arthur_ joined #perl6
14:49 virtualsue_ joined #perl6
14:51 Skarsnik the fact that is written in java sounds scary x)
14:52 nowan joined #perl6
14:52 vendethiel joined #perl6
14:52 ChoHag They've written a VM in java?
14:52 ChoHag That sounds redundant, but nothing from Orrible would surprise me.
14:55 pmurias ChoHag: they have added support for having your own jit for your dynamic language runnning on top of the jvm, with a tool to generate such a git
14:58 pmurias IMHO Graal/Truffle is one of the most promising ways to get killer speed for Perl 6
15:00 vividsnow joined #perl6
15:00 leont It is interesting for sure
15:00 virtualsue joined #perl6
15:00 blub +
15:00 blub oops
15:04 zakharyas joined #perl6
15:08 mscha joined #perl6
15:08 dalek rakudo/nom: 3ea4dff | lizmat++ | src/core/Variable.pm:
15:08 dalek rakudo/nom: Make error messages on "is default/dynamic" better
15:08 dalek rakudo/nom:
15:08 dalek rakudo/nom: This is really the result of trying to make "is default/dynamic" work
15:08 dalek rakudo/nom: on shaped arrays.  This has failed, because at the moment the trait
15:08 dalek rakudo/nom: code is run, the shaped array does not have a descriptor initialized
15:08 dalek rakudo/nom: yet.  Which means we're trying to look up attributes in a type object,
15:08 dalek rakudo/nom: and thus fail.
15:08 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/3ea4dff5d3
15:11 pierre-vigier joined #perl6
15:11 pierre-vigier joined #perl6
15:15 AlexDaniel joined #perl6
15:16 perlawhirl left #perl6
15:31 timotimo has anybody been able to figure out where the "The Perl Jam 2" guy found the "only scalars are considered safe" concept?
15:31 _mg_ joined #perl6
15:31 Skarsnik No idea
15:33 timotimo since i have no clue about p5, how likely is it that he found that concept somewhere vs. that he just plain made it up?
15:33 lizmat <cynic mode=on>the guy is only interested in looking good for his boss</cynic>
15:34 pmurias timotimo: what's the "only scalars are considered safe" concept?
15:34 lizmat fwiw, having this guy work for the company he works for, would be a reason for me to never do business with that company
15:34 timotimo lizmat: hey now, you're just giving him more food for his "the perl community is mad, evil and aggressive" thing
15:35 timotimo pmurias: did you see the "The Perl Jam 2" talk?
15:35 pmurias no?
15:35 lizmat timotimo: I'm stating a business reason
15:35 timotimo https://media.ccc.de/v/32c3-7130-the_perl_jam_2#video
15:36 stmuk_ booo
15:36 timotimo BBIAB
15:37 autarch timotimo: I've been doing p6 for about 17 years and I've never heard anyone say "only scalars are considered safe" or anything like that
15:37 autarch I'm not sure given this guy attention is a good idea, btw - when someone says something ridiculous arguing with them is not necessarily useful
15:38 timotimo it's not about p6, it's about p5
15:38 stmuk_ its a mix of a little good stuff with a lot of FUD
15:38 timotimo also, on media.ccc.de alone it has 25k views, no clue how many on youtube on top of that ...
15:39 timotimo people will very likely be believing what he says and thinking perl5 is Really Bad™
15:39 BinGOs he'll do p6 next time.
15:39 cygx as far as I could see, the take-away of that talk: enable taint mode
15:39 timotimo yeah, so what? p6 doesn't have 20 year old modules that are already very deprecated and warned against that he can claim are "perl6 core" and deconstruct in a silly manner
15:39 leont It does feel like arguing with him is like playing chess with a pigeon, he'll shit on the board and proclaim himself a winner anyway
15:40 cygx timotimo: yes, our code modules are only 10 years old ;)
15:40 bpmedley joined #perl6
15:40 cygx *core
15:40 timotimo no, our core modules are Test.pm, lib.pm (if it's still in there?), and NativeCall.pm
15:41 cygx I'd include the setting with that
15:41 timotimo our rakudo star modules, however, that's something we should be giving special care to anyway
15:41 timotimo not just because we have someone out there who would like to give a talk on how terrible our stuff is.
15:42 timotimo in general, i expect it'd be a good idea to pretend there's someone out to shit all over your project all the time :P
15:42 timotimo let fear inform your every decision
15:42 timotimo anyway, BBIAB
15:43 nexysno_ joined #perl6
15:44 autarch actually, Test.pm has a lot of issues ;) I'm working on something I hope can supercede it soonish
15:44 autarch I really don't want to see p6 paint itself into the corner that p5 has with tests
15:48 nine There is no lib.pm anymore
15:50 khw joined #perl6
15:51 pjscott joined #perl6
15:51 lucasb joined #perl6
15:52 dalek doc: 099bf5c | lizmat++ | doc/Language/setbagmix.pod:
15:52 dalek doc: Emphasize actual code point values of set ops
15:52 dalek doc: review: https://github.com/perl6/doc/commit/099bf5c479
15:52 pmurias timotimo:
15:53 leont autarch: actually, I have a similar project (though in a very early stage), we should talk
15:53 autarch leont: yeah, definitely - basically I'm working on a minimal Test::Stream implementation
15:54 hankache yeay!! keep up the good work!!
15:54 autarch although long term I'd really love to move us away from TAP - TAP is really not a very good protocol, unfortunately
15:54 leont I could have said exactly the same, it seems it's the obvious good idea
15:54 autarch or maybe we just need TAP14
15:54 lizmat afk&
15:54 leont I've been on the fence about that for some time
15:54 autarch there's a lot of information missing from TAP as it stands currently
15:54 autarch like timing, subtests, more structured diagnostics, etc.
15:55 leont Agreed. Extended diagnostics and better subtests could help, but it's all hacks on top of it
15:55 azawawi joined #perl6
15:55 azawawi moritz: ping
15:55 awwaiid true, but the simplicity of starting out with TAP is hard to beat
15:56 Skarsnik hello azawawi, I merged your work on PG array in DBIish
15:56 azawawi is http://irclog.perlgeek.de/perl6/search down?
15:56 nexysno_ joined #perl6
15:57 hankache azawawi not working for me
15:57 azawawi Skarsnik: thx but unfortunately it was not 100% finished
15:57 autarch leont: well, that's why I say it'd be TAP14 rather than just jamming stuff into the space TAP currently doesn't parse
15:58 autarch https://github.com/autarch/perl6-Test-Stream - here's my WIP
15:58 moritz azawawi: pong
15:58 Skarsnik azawawi, well feel free to refork DBIish, at least you will not have to bother with merging your change
15:58 azawawi moritz: happy new year first of all :)
15:59 moritz azawawi: same to you
15:59 * leont should push mine to github too
15:59 azawawi moritz: also i thank you for all the years you maintained http://irclog.perlgeek.de/perl6/today. :)
16:00 azawawi moritz++
16:00 azawawi moritz: that saying it seems that http://irclog.perlgeek.de/perl6/search is giving "Internal Server Error". Any chance you could please fix it?
16:02 azawawi any Encode::Detect for perl 6?
16:02 moritz azawawi: willl take a look at it; most likely the OS updated broke it
16:02 leont Awesome, it doesn't load with a "Failed to open file /home/leon/.rakudobrew/moar-nom/install/share/perl6/site/dist/096147B105DF24C279985A3228849EACD85B1C83: no such file or directory" error
16:03 lnrdo joined #perl6
16:03 autarch leont: do you mean my code or yours?
16:03 leont Mine
16:03 autarch ok, cause mine won't even compile, I'd guess ;)
16:03 azawawi i like the 096147B105DF24C279985A3228849EACD85B1C83 part :)
16:03 leont (I tried running tests before pushing)
16:04 autarch azawawi: I think there are plans to fix that so it has a sane filename
16:04 ugexe joined #perl6
16:04 leont (whatever, it's a stub anyway)
16:05 cygx autarch: I believe the filename is supposed to stay, but the error reporting is supposed to list the original one
16:05 Actualeyes left #perl6
16:05 autarch ah, ok
16:05 moritz azawawi: http://irclog.perlgeek.de/perl6/search/?nick=moritz&amp;q=foo works again, thanks for the report
16:09 zwu joined #perl6
16:10 leont https://github.com/Leont/test-stream6
16:10 azawawi moritz: thx
16:10 azawawi moritz++
16:10 azawawi autarch: cool
16:11 autarch leont: heh, we started on opposite ends of the implementation
16:11 dalek nqp: ed8ed36 | (Pawel Murias)++ | src/vm/js/ (6 files):
16:11 dalek nqp: [js] Add very basic start of an implementation of the nativecall ops.
16:11 dalek nqp:
16:11 dalek nqp: Pass t/nativecall/01-basic.t
16:11 dalek nqp: review: https://github.com/perl6/nqp/commit/ed8ed3646a
16:11 leont Pretty much :-p
16:11 autarch leont: I'm trying to get away from some of the p5 Test::Stream design decisions - conflating results with todo and skip events, for example
16:12 autarch I think that'll make it easier to handle other output formats for one thing
16:12 leont I did the same for skip, but not for todo. I did consider it.
16:12 kk_ joined #perl6
16:12 autarch it also makes dispatching event receivers easier since you can have a multi dispatch on the event type distinguish between test output, todo, skip, etc.
16:12 timotimo pmurias: you highlighted me; was there something you wanted to say?
16:13 autarch my reasoning is that non-TAP formats may want to handle this quite differently
16:13 leont Yeah, I split up all types of plans into different types, but I wasn't sure if that'd make sense for testing events too, mainly from the emitter's point of view
16:13 autarch like maybe a non-TAP format has some output it prints before a set of todo tests - so the todo event should come in separately
16:13 pierre-vigier joined #perl6
16:13 leont You mean setting the $TODO?
16:14 pierre-vigier joined #perl6
16:14 autarch leont: Test.pm6 has a todo() sub as opposed to a global
16:14 autarch which was a good design choice
16:14 CIAvash joined #perl6
16:14 leont I don't really like either, but I'm not sure what'd be better
16:15 leont A todo block may be nice, but lacks some of the flexibility that a variable has (for conditionally setting it)
16:15 pmurias timotimo: just pressed enter by accident :/, was meaning to complain about that talk (and the speaker in it) being ultra annoying, then decided not so as not to diverge the discussion
16:16 autarch well, providing a Proxy variable is always an option - the actual provider of test tools to .t files can do whatever it wants to do
16:16 leont True
16:18 timotimo pmurias: that's just because he's french. he can't help it!
16:18 leont Wasn't planning to really tackle it until I had a Test::Context equivalent.
16:18 timotimo (just a silly stereotype, i know)
16:18 stmuk_ what happens if one ecosystem module lists the same dependency as another which is already installed? the panda install of the second will fail without --force?
16:18 leont There is a good idea in there, even if I'd implemented it differently than Exodist did
16:19 stmuk_ oh "errornous" is mispelt as well
16:19 autarch leont: what's the good idea?
16:19 leont Not having to deal with $Test::Builder::Level
16:19 autarch ah, right, that is definitely something to avoid
16:20 hankache stmuk_ yes
16:20 autarch I hadn't event gotten that far because I wasn't thinking about the Test.pm6-equivalent side of things yet
16:21 autarch I note that with p6 we can write things like "temp context() = new-context()"
16:21 stmuk_ shouldn't it just skip the installed dependency?
16:22 autarch I wonder if there's a way to inject LEAVE blocks into the caller's scope - then you can just write 'new-context();'
16:22 leont I suspect a todo block is the cleanest thing in most cases. It could just be a filter that turns all test results in todo events.
16:22 autarch yeah, that would probably be the nicest to read
16:23 xpen joined #perl6
16:23 hankache stmuk_ yes but i got no idea what is going on
16:23 leont Some solution for conditional todo is needed too, but that's uncommon enough that it shouldn't be optimized for
16:24 hankache stmuk_ https://github.com/tadzik/panda/issues/269
16:25 autarch leont: that's very simple ... todo-if $boolean, { ... }, 'reason for todo'; - or something like that
16:25 autarch if boolean is true, emit the Todo event, if not, don't
16:25 leont Yeah, though I dislike the comma there (but getting rid of that is probably not worth it)
16:26 stmuk_ hankache: thanks that's useful
16:30 leont autarch: splitting out todo does complicate subtests :-/
16:30 autarch leont: why?
16:30 kkrev joined #perl6
16:31 leont I have different types for simple tests and subtests, so splitting out todo means adding two classes instead of one. May be able to handle that with roles, but…
16:31 autarch I'm not sure you need to separate tests and subtests
16:32 kkrev is rakduobrew + panda broken? http://pastebin.com/tgipKUx3
16:32 autarch I think the only difference is what goes in the summary when one ends, but if there's a separate "Finalize" event or something like that, that could trigger the "end of .t" summary
16:32 leont It's the difference between a scalar and an array, really
16:34 RabidGravy joined #perl6
16:35 leont (I'm joining the subtest early, I suppose one could join it later too, but that may get tricky with multi-threading)
16:36 autarch leont: I think that should be left up to the event listener, not the emitter
16:36 leont Maybe
16:36 autarch if you're running in parallel you set up one listener per thread, then do ... whatever you want in each listener
16:36 autarch and have some sort of orchestrator object that manages all the listeners, doing the right thing when one receives a Finalize event
16:37 timotimo kkrev: can you tell us perl6 --version for this? i'll look into the test failure of shell::command
16:37 timotimo (need to build an up-to-date perl6 first)
16:40 stmuk_ I have installed a module (HTML::Parser::XML) but 'use HTML::Parser::XML' fails in the REPL
16:42 Rotwang quick question: in src/core/Mu.pm I see multi sub infix:<=:=>($?)      { Bool::True }
16:42 Rotwang How infix can get one argument?
16:43 lucasb when reducing
16:43 cygx m: say [=:=] 42
16:43 camelia rakudo-moar 3ea4df: OUTPUT«True␤»
16:43 AlexDaniel I've just realized that you can write a whole program inside double quotes
16:43 AlexDaniel m: say “{sub foo { say ‘hello world’; return ‘test’}; foo }”
16:43 camelia rakudo-moar 3ea4df: OUTPUT«hello world␤test␤»
16:44 Rotwang second question, what is $?
16:44 Rotwang some kind of "garbage container"?
16:44 lucasb anonimous scalar variable?
16:44 cygx Rotwang: optional anonymous scalar parameter
16:44 lucasb *anonymous :)
16:44 Rotwang cool,thanks!
16:45 nexysno_ joined #perl6
16:45 cygx which means zero-arg =:= is true as well
16:45 AlexDaniel m: say “{sub foo { say ‘hello world’}; ‘test’ }”; foo
16:45 camelia rakudo-moar 3ea4df: OUTPUT«5===SORRY!5=== Error while compiling /tmp/vKHbpVAIKM␤Undeclared routine:␤    foo used at line 1␤␤»
16:45 cygx m: say [=:=]
16:45 camelia rakudo-moar 3ea4df: OUTPUT«True␤»
16:46 lucasb I wish a single "$" meant "my $", not "state $", since using 'my' is more common, but ok, I can live with it
16:47 leont Subtests are annoyingly full of complications :-/
16:48 dalek specs: 71d0c0c | util++ | S32-setting-library/Containers.pod:
16:48 dalek specs: [S32::Containers] Change duplicate =item of `pairs` into `antipairs`; Fix typo from db834e73 .
16:48 dalek specs: review: https://github.com/perl6/specs/commit/71d0c0c1fa
16:48 dalek specs: b0657be | util++ | S32-setting-library/Containers.pod:
16:48 dalek specs: [S32::Containers] Add =item for `enum`.
16:48 dalek specs: review: https://github.com/perl6/specs/commit/b0657be1c9
16:51 AlexDaniel m: say “{“{“{“{“{“{“uhh!”}”}”}”}”}”}”
16:51 camelia rakudo-moar 3ea4df: OUTPUT«uhh!␤»
16:52 zwu the calling set of method is so cool. I have another question, is there any convenient call method wrapper that automatically captures all exceptions and returns a default value if the method fails
16:54 nexysno_ joined #perl6
16:54 lucasb zwu: maybe (try foo()) // 'default value'
16:57 nexysno_ joined #perl6
16:59 kkrev timotimo, I blew away the rakudo directory and rebuilt everything from scratch and now no problems. No idea what the issue was.
16:59 timotimo ah, OK
16:59 timotimo hopefully it was just an outdated version of rakudo or some old modules sticking around that should ahve been cleared or something like that
17:00 vendethiel lucasb: well, I argued for that as well, but in hindsight I recognize it's more useful that way
17:00 cygx reminds me of the windows experience in the days of yonder: "Have you tried rebooting yet?"
17:02 lucasb vendethiel: the "state $" thing? ok. but some new user will eventually use it inside subroutines and get surprised to see previous results getting cached :)
17:02 vendethiel then the way the learned it is wrong ;-)
17:02 mst the whole point of state over my is caching, no?
17:03 mst I mean, that's what makes it ... state ...
17:03 vendethiel mst: the point is "lone $"
17:03 mst ah
17:04 mst what's that even for? :)
17:04 lucasb to be honest, I don't know why 'state' outside subroutines work
17:04 lucasb (I'll try with p5, just a sec)
17:04 sprocket hello, p6!
17:05 lucasb hum, ok, no warnigs with P5 too
17:05 flussence $ is kinda like a capacitor, needs something on the left hand side of the statement to be useful because you can't refer to it again in that scope
17:05 TimToady sprocket: howdy!
17:05 sprocket i’m experiencing some odd behaviours with perl6 on my raspberry pi, was wondering if anyone might have any insight
17:05 mst flussence: oh, right, so basically you'd do something like sub () { $ = foo() }
17:05 mst flussence: to memoize the foo() call?
17:06 flussence yep, though with more //=
17:06 sprocket i’d written bindings onto the wiringPi library, and one of the subroutines allows one to register a callback function
17:06 AlexDaniel lucasb: why should it only work inside subroutines?
17:06 blub left #perl6
17:06 AlexDaniel m: for ^5 { state $s; say $s += 50 }
17:06 camelia rakudo-moar 3ea4df: OUTPUT«50␤100␤150␤200␤250␤»
17:06 sprocket but it seems everytime that an interrupt happens and the callback is supposed to be run, perl6 dies with a GC error: “Invalid GC status observed; aborting”
17:07 lucasb AlexDaniel: well, that was how I learned about 'static' variables in C. but ok, Perl is more flexible
17:07 sprocket i suppose that’s actually more of a MoarVM thing than perl6, actually
17:07 TimToady yeah, and most of the pi people hang out there too
17:07 leont Don't know about state in p6, but in p5 it gets tricky to intuit about it when closures come into play
17:07 * flussence reads backlog then goes to fix these f'ing github notifications to actually notify me, because I only saw Zoffix's bug report there by chance...
17:09 TimToady though the pifolk are a rare breed, due to the need for extreme patience :)
17:09 RabidGravy sprocket, is there a supply involved somehow?  I've seen that trying to schedule a Supply.interval on the GTK::Simple scheduler
17:09 yoleaux 14:32Z <nine> RabidGravy: class Foo:ver(v0.0.1) {}; say Foo.^ver
17:10 sprocket RabidGravy: no supply yet…the section of code in MoarVM that die’s is dealing with interrupts however, and as that’s how the callback function was supposed to be called, i had suspicions they were related
17:10 RabidGravy nine, yeah it's just my stupid I'd been writing :ver<v0.0.1> everywhere
17:10 vendethiel- joined #perl6
17:11 sprocket however, it’s been a long time since i’ve done any interrupt related stuff, so i’m just making assumptions
17:12 timotimo sprocket: you may have to read the "gc_enter_from_interrupt" thing again; what "interruption" means in this case is mostly "one thread wants to GC and others have to join in so that it can start"
17:12 TimToady is it possible that interrupts are running on a different stack?
17:12 RabidGravy :)
17:12 TimToady I could imagine that would confuse a GC
17:12 timotimo interrupts like posix signals are handled on a dedicated thread
17:12 sprocket TimToady: i have no idea :)
17:13 timotimo then they are handed off to other parts because what you can do in a signal handler is extremely limited
17:13 sprocket TimToday: is that sometime i’d have to worry about, or MoarVM would be concerned with?
17:13 RabidGravy TimToady, well I know there are at least two people *here* making stuff for the RPi (except i got pre-empted by something else)
17:13 TimToady timotimo: if the GC examines the stack, and it's in an unexpected place...
17:13 timotimo we don't use the C stack, though :)-
17:13 timotimo moar bytecode stack frames are on the heap
17:13 mst flussence: I keep meaning to write a bot so my github notifications arrive in irssi rather than by email
17:14 TimToady Moar itself has various things on the C stack
17:14 TimToady some of which are related to GC
17:15 timotimo right
17:15 timotimo but it doesn't let the GC loose on the C stack, that's what i meant
17:15 RabidGravy and I blame ZoffixWin for the pre-emption :)
17:15 sprocket is it possible for me to generate a more usefull (moar useful?) backtrace?
17:15 timotimo sprocket: MVM_JIT_DISABLE usually gets rid of the "??" stack frames
17:15 llfourn joined #perl6
17:16 TimToady isn't jit already disabled on RPi?
17:16 sprocket timotimo: is that an $ENV variable, or a compile time flag?
17:16 timotimo an env variable
17:16 timotimo oh, raspberry pi?
17:16 TimToady did you try --ll-exception?
17:16 timotimo yeah, if it's a 32bit x86 or an arm processor we can't jit
17:16 TimToady (yet)
17:16 timotimo http://doc.perl6.org/language/operators#Hyper_Operators  -  i think the part "Hyper operators are defined recursivly on nested arrays" wants to read "unary hyper operators" or be fixed another way
17:17 timotimo yeah, can't jit yet. x86 jit would be super annoying because of the low amount of registers
17:17 timotimo and arm jit would be a totally new piece of work, as the instruction set is so different
17:19 sprocket TimToady: running with --ll-exception now
17:19 RabidGravy with some arm processors you could jit to a subset of java bytecode and have the processor do the actual jit itself :)
17:19 timotimo haha, yeah
17:19 ugexex joined #perl6
17:20 timotimo m: (1, (1, 2), 2, (3, 4), 4).duckmap(*.++) # maybe this shouldn't work, but what it should definitely not do is time out ...
17:20 sprocket —ll-exception didn’t work - it looks like it’s Moar that’s having a panic, not perl6
17:20 camelia rakudo-moar 3ea4df: OUTPUT«(timeout)»
17:20 sprocket line 255 is the error i’m getting: https://github.com/MoarVM/MoarVM/blob/master/src/gc/orchestrate.c
17:21 mst sprocket: maybe try running the moar test suite and see if that blows up?
17:21 timotimo sprocket: you can attach gdb, let it break in the line before it panics and then "print MVM_dump_backtrace(tc)" to get the perl6-level backtrace
17:21 _nadim joined #perl6
17:21 sprocket timotimo: will do
17:21 timotimo mst: moar doesn't have its own test suite, though. we rely on the nqp test suite to test stuff
17:21 lucasb moar doesn't have a test suite, has it?
17:21 mst or listen to the people like timotimo with less generic advice
17:21 mst ah
17:21 timotimo :)
17:22 ugexex this darn linode DoS is seriously effecting my irc idling
17:23 mst ok, what I meant was "run the lowest level test suite you can find"
17:23 mst since that's often a common debuggering approach
17:24 xpen joined #perl6
17:24 timotimo the nqp tests don't exercise multi-threading much, i fear
17:24 timotimo if at all
17:26 pmurias timotimo: there is t/concurrency
17:27 lucasb m: (1).duckmap({die})
17:27 camelia rakudo-moar 3ea4df: OUTPUT«(timeout)»
17:28 timotimo OK
17:28 timotimo lucasb: nice golf ;)
17:28 dnmfarrell joined #perl6
17:30 patrickz joined #perl6
17:31 pmurias timotimo: I haven't worked on expanding that as node.js doesn't support threading
17:31 timotimo yeah, that's fair
17:31 timotimo no worries, you're still doing excellent work :)
17:31 timotimo also ... i thought it supports threading now?
17:31 timotimo anyway, gotta be AFK for a bit
17:34 firstdayonthejob joined #perl6
17:37 dnmfarrell Hey folks, I'm running the latest Perl6 and panda, and for my distribution, Pod-Perl5 the tests all pass when run locally. However if I do "panda install ./", ("The spawned process exited unsuccessfully (exit code: 1)"). Anyone have a hunch as to what could have changed? Repo is here: https://github.com/dnmfarrell/Pod-Perl5
17:38 pierre-vigier joined #perl6
17:39 pierre-vigier joined #perl6
17:39 timotimo dnmfarrell: that sounds like tests aborted? doesn't it give more info up above?
17:40 dnmfarrell timotimo: yeah the tests fail with a variety of things: strings not initialized or expected counts of Pod tokens are wrong etc.
17:41 lucasb that is the same message kkrev had in the backlog and he said nuking everything and starting again fixed it
17:41 lucasb I mean, the message 'The spawned process exited unsuccessfully'
17:41 dnmfarrell Does Panda create a "blib" style directory?
17:42 timotimo lucasb: that message means absolutely nothing
17:42 timotimo lucasb: it's what panda says when the tap suite returns non-success
17:42 timotimo which means tests failed
17:42 lucasb yes, it's pretty vague, sorry :)
17:43 SwellJoe joined #perl6
17:43 timotimo but yeah, maybe nuking the rakudo install folder helps; could be a stale module in the installation cache that still uses the old versioning scheme
17:43 dnmfarrell I can only find files like "~/.rakudobrew/moar-nom/install/share/perl6/site/resources/E056605C0EECCF0E15C1CD8BD30FD092C74B683D "
17:43 dnmfarrell ok
17:43 dnmfarrell let me try it
17:44 timotimo ... or was that only for precomp?
17:45 dnmfarrell lol, I nuked the install dir and now I get: ".rakudobrew/bin/panda: Argument list too long"
17:45 RabidGravy dnmfarrell, no blib anymore
17:45 Skarsnik damn we have nothing to parse yml file?
17:45 mst there's several YAML modules IIRC
17:45 Skarsnik oh I was searching only yml ><
17:45 mst of course, YAML is usually a terrible idea :)
17:45 Skarsnik json syntax is annoying
17:45 autarch hmm, there's no destructuring return declarations? sub foo (--> Int, Str) { ... }
17:45 dnmfarrell I was wondering if some files are not being copied across during the build phase, as the module has a lot of sample pod files that are used by the unit tests
17:46 autarch I can declare (--> List) but that's not very useful
17:46 Skarsnik autarch, to say it can return multiple object?
17:46 leont Skarsnik: I have written a YAML parser, it's in the module list as YAMLish
17:46 autarch Skarsnik: to say it will return exactly N things of X, Y, Z types
17:46 TimToady autarch: a subset type might work
17:46 autarch TimToady: ah, yeah, that probably would
17:47 RabidGravy autarch, I've used subsets for this
17:47 autarch but is returning more than one value discouraged or something? it seems like this is harder than it should be
17:47 dnmfarrell ok I'm rebuilding moar and then panda, let's see if that does the trick
17:47 RabidGravy e.g https://github.com/jonathanstowe/Audio-Libshout/blob/master/lib/Audio/Libshout.pm#L313
17:47 leont autarch: Returning a Slip may be what you want
17:48 leont But no you can't destructure it
17:48 TimToady the question is how you expect the caller to deal with it downstream
17:48 Skarsnik or I will go with ini format x)
17:49 TimToady it's pretty easy to return things that only work right when bound, not when assigned
17:49 sprocket argh, i don’t with my gdb skills are sharp enough to handle this issue :)
17:49 timotimo https://www.reddit.com/r/perl6/comments/3z5wiq/pascals_triangle_and_modules/
17:49 TimToady sprocket: one can improve one's skills... :P
17:49 timotimo sprocket: it'd also be interesting to see what the exact value is that it complains about
17:50 pmurias timotimo: there is a threads module for node.js by au++ but it seems to be only web-worked-style threads
17:50 lnrdo joined #perl6
17:51 autarch TimToady: can I write "my ($int, $str) = returns-int-and-str()" ?
17:51 sprocket TimToady: working on it! ;)
17:51 pmurias timotimo: which are not powerful enough for Perl 6
17:51 TimToady yes, it works with scalars, but falls down as soon as you want to return a list or array early
17:51 autarch I guess my bigger question is ... what's the best practice for a sub that returns multiple unrelated values (as opposed to a list or array)?
17:52 lucasb return multiple values is to return a list, right?
17:52 nine dnmfarrell: panda doesn't create a blib anymore. Couldn't find a reason to create one.
17:52 lucasb iiuc, there is no multiple return values like Common Lisp
17:52 TimToady well, there's also rw params
17:52 autarch but a list implies "0+ values" - what if I'm trying to say "I'm returning 2 values"
17:53 sprocket timotimo: what do i have to do to get that value?  will that be displayed in the MVM_dump_backtrace(tc)?
17:53 autarch this is something we can do easily in p5, so I'd think there's some (better?) way to do this in p6
17:53 TimToady our backtraces are not good at displaying values yet
17:53 dnmfarrell nine: that's good to know, thanks
17:53 autarch rw params seems grossly C-ish - I'm not a huge fan ;)
17:53 mst blib is mostly only important for C compilation anyway
17:54 mst within pp perl5 modules it's basically a big no-op
17:54 TimToady nevertheless, putting unrelated things together is also a smell
17:54 leont Well, it's also used to fix up executables in p5
17:54 TimToady and params can type-check, and can force the user to agree to a particular in/out contract
17:55 leont And generating man-pages
17:55 nadim joined #perl6
17:55 TimToady but it may also mean that the problem is not sufficiently decomposed
17:55 nine mst: that's how I saw it. We compile C libs to resources/libraries/ anyway, so I removed the useless copying.
17:55 leont It's mainly there just so make install is litterallly only copying files, nothing more
17:55 nine autarch: if your sub returns multiple, unrelated things, maybe your sub is doing too much?
17:55 nine autarch: too many unrelated things
17:55 timotimo sprocket: no, it'd show up in "bt full", though
17:55 mst leont: due to local::lib centric usage for so many years I always forget about the man pages
17:56 dnmfarrell bah, I rebuilt moar and panda with rakudobrew, now trying to install Pod::Perl5 returns "Could not find Shell::Command in: ...". panda won't install Shell::Command either
17:56 lucasb I think he just wants to return a "tuple", a fixed N-elements list, that make sure every element is of the right type. Did I get it right?
17:56 leont nine: I can think of many valid use-cases, for example a row from a database
17:56 timotimo sprocket: actually, looking at the code it should already show the exact value? or maybe i'm looking in the wrong place
17:57 timotimo oh, maybe i was
17:57 flussence bonsaikitten: STOP RIGHT THERE. There's already a patch for that bug, and it's only going to be needed for 2015.12: https://gitlab.com/flussence/perl6-overlay/blob/master/dev-lang/rakudo/files/2015.12/0001-Fix-make-install-when-nqp-is-distro-installed.patch
17:57 bonsaikitten flussence: oh hello there :)
17:57 Skarsnik is there a keyweord to say : export everything in this module?
17:57 sprocket timotimo: here’re the results from ‘bt full’: http://pastebin.com/yTziRKsH
17:57 flussence fixing that one was *fun*
17:57 timotimo and then it wouldn't show up, either
17:58 bonsaikitten flussence: why are you hiding such things in random places and not, like, bugtrackers and stuff? :)
17:58 leont Skarsnik: why would you do that?
17:58 timotimo sprocket: that's not the thread that'd have given that error, though
17:58 Skarsnik to not write is export on everything
17:58 timotimo sprocket: you can try "thread apply all bt full"
17:58 flussence bonsaikitten: cause my code's a horrible mess at the best of times and I'd like to at least not inflict a version 1 of it on anyone else :)
17:58 bonsaikitten flussence: so you just hide it so I have to re-find the bugs? peh.
17:59 leont IMHO you already have to write too little, given that "is export" default to default export (really!?)
17:59 flussence I've been poking upstream to do a 2015.12.1 with this stuff in it, cause gentoo's not the only one having problems...
17:59 leont exporting is useful, but easily overused
17:59 Skarsnik leont, I mean in the module
17:59 leont I know
18:00 Skarsnik it's more a file to say "Here some class I will use everywhere"  than a real module
18:00 bonsaikitten greeeeeeeeeeh
18:00 timotimo sprocket: did you set a breakpoint to the line that panics?
18:00 bonsaikitten flussence: please to use website that uses html
18:00 bonsaikitten can't browse that junk :(
18:00 bonsaikitten I'm mildly impressed by the level of idiocy involved
18:00 flussence oh right, gitlab is one of those ajax things... sorry :(
18:01 flussence want me to throw it on gh instead? I can do that.
18:01 bonsaikitten at least my mind doesn't filter it as ad like bitbucket
18:01 sprocket timotimo: output from “thread apply all bt full”: http://pastebin.com/Enh2yBGe
18:01 bonsaikitten flussence: a tarball would also work ;)
18:01 flussence oh that's easy, https://gitlab.com/flussence/perl6-overlay/repository/archive.tar.bz2?ref=master
18:04 timotimo sprocket: that's weird. what did this program exit with?
18:04 sprocket “Invalid GC status observed; aborting”
18:05 _mg_ joined #perl6
18:06 flussence bonsaikitten: I should add though, this build system is like, fractally awful. I spent most of christmas week trying to push QA fixes up to them, that's mainly why I haven't tried to get gentoo guys involved yet
18:06 ugexex fwiw blib originally made it easier to delete your local precompiled files instead of running a command to recursively delete *.moarvm|*.par|*.jar next to your *.pm (which is what the default output location was), as well as a way to test against either the source (-Ilib) or the precomp (-Iblib) to test for precompilation specific bugs
18:06 bonsaikitten flussence: I've debugged Semantic Mediawiki, it can't be THAT bad
18:06 flussence oh god
18:06 flussence alright, it's not *that* bed.
18:07 flussence */bad
18:07 flussence it *does*, however, try to make-install header files for MSVC...
18:08 flussence (you might wanna look at /usr/include after moarvm*.ebuild, if you haven't fixed it already...)
18:08 timotimo sprocket: yeah, but i see the call to MVM_panic nowhere
18:10 zwu joined #perl6
18:12 dnmfarrell ok, nuking rakudobrew and rebuilding moar and panda gets me back to the original test failures
18:12 nige1 joined #perl6
18:13 sprocket timotimo: sorry, this should have it: http://pastebin.com/NiuTuXhB
18:13 sprocket timotimo: still bad at gdb, but getting marginally getter :)
18:15 dnmfarrell this is the output when trying to install: https://github.com/dnmfarrell/Pod-Perl5/issues/4
18:15 nine leont: but rows from a database are related data and you'd return a List or Hash or even better an object for them.
18:16 Skarsnik maybe something cool will be to be able to have moar making a NC stuff backtrace
18:16 llfourn joined #perl6
18:18 timotimo sprocket: okay, try this: frame 1  , then   print tc->gc_status
18:19 ugexex joined #perl6
18:20 nexysno_ joined #perl6
18:22 sprocket timotimo: it’s complaining about the symbol table not being loaded - do i have to recompile moarvm with debug symbols enabled?
18:22 timotimo could be
18:22 timotimo i always build mine with --debug=3 --optimize=3
18:23 sprocket ah, ok.  i just have whatever rakudobrew installed for me, which likely doesn’t have those flags by default
18:24 timotimo ah, yeah
18:24 timotimo rakudobrew may have --moar-options available for you
18:24 timotimo but i don't know about it
18:25 sprocket i’ll check it out, and recompile somehow.  on a pi it takes a while, so i’ll check to see if you’re around in a bit :)
18:25 sprocket thanks for your help
18:25 timotimo it should be enough to recompile only moar in this case
18:26 timotimo you probably can go into the moar source folder wherever it is inside .rakudobrew
18:26 timotimo and then perl Configure.pl --... and then make install
18:26 sprocket ah, ok
18:26 ugexex i missed the rpi conversation... what is the problem? installing via rakudobrew?
18:27 TimToady a GC problem on interrupt
18:27 ugexex ah :(
18:28 sprocket ugexex: no, working out some issues with the wiringPiISR function which causes the GC to exit unhappily
18:28 TimToady we can't blame *everything* on rakudobrew :)
18:28 timotimo :)
18:29 hankache joined #perl6
18:29 Skarsnik We can!
18:30 TimToady well, I suppose we could at that.
18:30 hankache evening everyone
18:31 psy_ joined #perl6
18:32 ugexex donald trump can blame everything on anything
18:36 sprocket has rakudobrew become the scapegoat for everyone’s ills?
18:37 tadzik toolchain is a scapegoat for everything that breaks in core
18:37 pdcawley joined #perl6
18:37 mst that's part of the charm of working on it
18:37 mst you get to learn so much about core that way ...
18:37 * TimToady blames Unix
18:38 ugexex rakudobrew is my favorite part of the perl6 toolchain
18:38 * mst thinks
18:38 mst aha! I know!
18:38 * mst blames the author of 'patch' for enabling the entire thing
18:38 leont Heh!
18:38 TimToady "Smile when you say that."  --The Virginian
18:39 mst from ear to ear :D
18:42 vendethiel joined #perl6
18:44 * flussence wonders if that double-heredoc in moar's configure.pl is a practical joke on vim users...
18:48 _mg_ joined #perl6
18:52 RabidGravy in the "use Foo:ver<0.0.3>" is there a way to say "at least that version" rather than "exactly that version"?
18:52 timotimo hmm
18:52 flussence :ver(v0.0.3..*) ?
18:53 RabidGravy let me try that
18:55 leont Yeah, current semantics aren't well huffmanized
18:55 RabidGravy no, that's not it find META6:ver<0.0.3..*>
18:55 RabidGravy "Could not find META6:ver<0.0.3..*> in:"
18:56 flussence I've seen a form like :ver({$_ >= v0.0.3}) mentioned once or twice too...
18:57 timotimo i think it'd be nice to have the info be more computer-readable, so that instead of searching the whole space we can binary search or directly select
18:58 timotimo like, if you have a piece of code, nothing promises us that it's not like sha1 of supplied version matches "udaitrsnudiare"
18:58 timotimo but if we have a range with two end-points, or a version with * in it, that's much better
19:00 RabidGravy I'm not sure that the "exactly this version" is working properly either
19:00 leont Yeah, this idea of versioning is suboptimal
19:02 RabidGravy or rather, when I know I have v0.0.3 installed because the code works but I had to use --force to install it, use META6:ver<0.0.3> says not
19:02 RabidGravy but use META6:ver<0.0.2> (the version that was installed I forced over) is fine
19:03 nine m: use Test:ver({$_ eq EVAL "qw(6.c)", :lang<Perl5>}); plan 1;
19:03 camelia rakudo-moar 3ea4df: OUTPUT«5===SORRY!5=== Error while compiling /tmp/V9ev86dSDS␤EVAL is a very dangerous function!!! (use MONKEY-SEE-NO-EVAL to override,␤but only if you're VERY sure your data contains no injection attacks)␤at /tmp/V9ev86dSDS:1␤------> 3:ver({$_ eq EVAL…»
19:03 nine Bug!
19:03 nine RabidGravy: <> quotes a string, so :ver<0.0.3..*> expects "0.0.3..*" as version
19:04 RabidGravy yeah, I realised that
19:04 nine use META6:ver(0.0.3..*) should do the trick
19:04 hankache joined #perl6
19:06 pierre-vigier joined #perl6
19:06 RabidGravy well v0.0.3..*
19:07 RabidGravy and indeed it does
19:07 RabidGravy (doing a "panda update" and force installing the dependency again seemed to work as well)
19:07 RabidGravy everyone++ # this is all going swimmingly
19:09 nine m: sub foo(:$ver) { dd $ver }; foo :ver<* after v6.b>;
19:09 camelia rakudo-moar 3ea4df: OUTPUT«List $ver = $("*", "after", "v6.b")␤»
19:09 nine That ^^^ is what use Foo:ver<* after 6.b>; actually requires as version
19:10 autarch m: sub foo (*@a) { say .perl for @a }; foo( { foo => 42 }, { bar => 84 } )
19:10 camelia rakudo-moar 3ea4df: OUTPUT«:foo(42)␤:bar(84)␤»
19:11 autarch m: sub foo (*@a) { .say for @a }; foo( { foo => 42 }, { bar => 84 } )
19:11 camelia rakudo-moar 3ea4df: OUTPUT«foo => 42␤bar => 84␤»
19:11 autarch m: sub foo (*@a) { .say for @a }; foo( { foo => 42 }, { bar => 84, baz => 1 } )
19:11 camelia rakudo-moar 3ea4df: OUTPUT«foo => 42␤bar => 84␤baz => 1␤»
19:11 autarch m: sub foo (*@a) { say .perl for @a }; foo( { foo => 42 }, { bar => 84, baz => 1 } )
19:11 camelia rakudo-moar 3ea4df: OUTPUT«:foo(42)␤:bar(84)␤:baz(1)␤»
19:12 RabidGravy however panda doesn't like that sort of locution in the dependencies at all
19:12 autarch so how can I pass a list of hashes to a sub without turning into a list of pairs?
19:13 TimToady 6c+ means "after 6b"
19:13 autarch ah, another set of parens to wrap the whole thing
19:13 RabidGravy sub foo(Hash @hashes) ?
19:13 nine m: sub foo (*@a) { .say for @a }; foo( ${ foo => 42 }, ${ bar => 84, baz => 1 } )
19:13 camelia rakudo-moar 3ea4df: OUTPUT«foo => 42␤bar => 84, baz => 1␤»
19:13 nine autarch: ^^^
19:13 nine itemize them
19:13 autarch nine: ah, that's better - I think I need to better understand how that sigil prefix works
19:15 cdg joined #perl6
19:15 autarch nine: thanks
19:15 nine m: use Test:ver({$_ after v6.b});
19:15 camelia rakudo-moar 3ea4df: ( no output )
19:15 llfourn joined #perl6
19:15 nine mst: ^^^
19:16 mst nine: boo :)
19:31 RabidGravy .tell Zoffix, I updated Test::Meta with your suggestions but you will need to upgrade META6 manually too
19:31 yoleaux RabidGravy: What kind of a name is "Zoffix,"?!
19:31 RabidGravy .tell Zoffix I updated Test::Meta with your suggestions but you will need to upgrade META6 manually too
19:31 yoleaux RabidGravy: I'll pass your message to Zoffix.
19:32 yurivish_ joined #perl6
19:40 dalek doc: e089b27 | (Jake Russo)++ | bin/p6doc:
19:40 dalek doc: Add -n flag for no pager
19:40 dalek doc: review: https://github.com/perl6/doc/commit/e089b27a3c
19:40 dalek doc: 29406ea | sylvarant++ | bin/p6doc:
19:40 dalek doc: Merge pull request #301 from MadcapJake/master
19:40 dalek doc:
19:40 dalek doc: Yes this doesnt break anything ;)
19:40 dalek doc: review: https://github.com/perl6/doc/commit/29406ea1f1
19:46 autarch joined #perl6
20:00 nmp joined #perl6
20:02 pierre-vigier joined #perl6
20:03 pierre-vigier joined #perl6
20:04 FROGGS joined #perl6
20:06 Rotwang Whats the policy on advent calendar posts? If I found slight mistake should I report it, where?
20:06 wamba joined #perl6
20:07 awwaiid Are there any good examples of literate (inline) pod6 in a module I can look at?
20:12 Skarsnik there is nothing to avoid writing say $foo ~ $a.name.defined ?? $a.name !! ''
20:13 Skarsnik Rotwang, You can try here or in the comments
20:15 autarch Rotwang: there are a bunch of people with editing perms in here so here's probably good
20:16 Rotwang Day 23 – Webscale sorting of the sleepy kind
20:16 Rotwang DECEMBER 23, 2014 BY MORITZ
20:16 Rotwang I've added a comment
20:16 llfourn joined #perl6
20:21 Skarsnik m: my @tmp = (); say @tmp.join(',');
20:21 camelia rakudo-moar 3ea4df: OUTPUT«␤»
20:24 average joined #perl6
20:24 average http://i.imgur.com/U7EhJV4.jpg
20:25 timotimo omg, why does it do that
20:25 timotimo that's not a toothpick!
20:26 FROGGS it's just sitting behind it
20:26 Sqirrel joined #perl6
20:28 autarch Rotwang: I don't follow your comment on day 23 - are you saying that Seq.map is undefined?
20:30 autarch Rotwang: also, do you mind if I delete comments once they're fixed?
20:31 pdcawley joined #perl6
20:34 Skarsnik flussence, sqlite.h https://gist.github.com/Skarsnik/fedc2d7532d092bb32ac
20:35 flussence Skarsnik++ :D
20:35 Skarsnik I don't handle func ptr yet ^^
20:36 average gentlemen, may I make a proposal ?
20:36 flussence it even (mostly) recognises that weird double-pointer thing sqlite does for the DB handle
20:37 Skarsnik I realise I did not put $ in from on names lol
20:37 average I'll make my proposal later
20:38 Skarsnik flussence, they are pointer of funcptr?
20:40 flussence the thing sqlite3_open_v2 gives back, in the C code it's a **sqlite3 and I've never figured out why they do it that way
20:41 terjekv joined #perl6
20:41 pierre-vigier joined #perl6
20:42 terjekv I seem to have broken panda: ===SORRY!=== P6M Merging GLOBAL symbols failed: duplicate definition of symbol Find
20:43 terjekv This happens immediately upon loading, to the point where not even --help works.
20:43 sprocket timotimo: i think i found a better workaround for that issue we were talking about earlier :)
20:44 Exodist late to the party, and not reading all scrollback, but leont and autarch you should look at the Test2 repo, which incorperates changes from feedback you all have given. Skip is its own result, and there is a pr where I am stipping out the todo stuff (I don't just ignore feedback)
20:44 cdg joined #perl6
20:44 Skarsnik flussence, hm, I need the PP ast to get the #define SQLITE_FLOAT 1. or do you think just parsing them in perl6 could be enought?
20:44 timotimo sprocket: cool. do tell! but also, it'd be nice if we could figure out what's going wrong so it can be fixed forever
20:44 autarch Exodist: I kind of assumed you did certain things that way because of the limits of back compat too
20:44 autarch I think if we can get a core p6 Test::Stream real soon now we can have a bit more freedom with how it's designed
20:45 Exodist autarch, well, Test-Stream started as a Test-Builder refactor, so that is how things ended up that way, but I am working on removing more and more garbage like that and maintaining backwords compatability in better ways.
20:45 autarch makes sense
20:45 Exodist autarch, that worries me if only because the Test-Stream namespace is likely to fade in favor of Test2.
20:46 autarch what worries you?
20:46 mst it could end up being called Test2 in p6 as well
20:46 Exodist I am worried that P6 will move forward with a namespace p5 is likely going to let die.
20:46 sprocket timotimo: i was poking around the wiringPi code and it looks like the interupt handlers were doing some other their own pthread_* stuff - could that have had adverse affects with some of MoarVM’s pthread’ing?
20:46 Exodist then again thats probably not an issue
20:47 Exodist I am also worried that you might adopt the loader stuff from Test/Stream.pm, which is going away.
20:47 leont It's just a name, at this stage it doesn't matter much yet, back-compat far from being an issue yet
20:47 Exodist true.
20:47 leont No, loading stuff in p6 is quite different anyway
20:47 Exodist Ok.
20:47 autarch Exodist: yeah, the namespace is entirely open to change - but I don't think Test2 makes much sense in p6 land either
20:47 autarch there's barely a Test1
20:47 timotimo sprocket: if a callback comes from a thread other than what moar expects, things will explode, yeah
20:47 timotimo sprocket: maybe i can put in a sanity check that'll make the issue more easily visible.
20:48 sprocket timotimo: ok, then that was probably the issue
20:48 Exodist I *think* I am close to getting Test2 to a state where people can at least accept it. I would recommend judging its design decisions after they are finalized, not while people are still arguing both ways about certain thing.
20:48 sprocket timotimo: i think i can just do a work around in pure-Perl6, no NativeCall necessary
20:48 Exodist *things
20:49 sprocket timotimo: it looks like the wiringPi code was just monitoring a file handle in “/sys/class/gpio/*” for changes, then triggering the interupt
20:49 sprocket timotimo: so i’m hoping i can replicate that behaviour using just perl6, but without external wiringPi thread issues
20:50 timotimo yeah, should just be able to .IO.watch or what it's called
20:50 vendethiel joined #perl6
20:50 Exodist leont, speaking of that, I was hoping you would weigh in a bit on both pr's ont he test2 repo on github
20:51 flussence Skarsnik: most of the #defines there are really enums, but I guess sqlite has to be C89-compatible, so it can't just say "enum{}" in the C itself... things would be much easier if it did
20:52 sprocket timotimo:  IO::Notification.watch-path(..) i think?
20:53 timotimo IO has a watch method that calls that for you
20:53 sprocket oooh, ok, i’ll take a look
20:53 timotimo IO::Local in this case
20:53 pierre-vigier joined #perl6
20:54 Skarsnik flussence, Yes, but I still want the tool to extract this stuff, my first goal is not to generate whole binding just with it, but at least for a dev to use it and copy the output in his code
20:55 Skarsnik could be with a --define-as-enum="SQLITE_*"
20:55 Exodist anyway, leont, autarch my goal in voicing up here was 2 fold: 1) If you still have feedback to provide on my p5 test stuff please give it to me. I want to make the stuff in p5 as good as it can be. So if you do not like an implementation detail tell me so I can work on it before it is locked in.
20:56 Exodist 2) I would be happy to talk to you about why I am doing things 1 way or another in Test2/stream on p5, hopefully the knowledge sharing will avoid mistake repetition
20:57 awwaiid How can I have mutually dependent classes in separate files? I have RbValue.pm6 and RbObject.pm6 and they each refer to the other. Putting a use statement in each class seems to cause a looper during compile time
20:57 timotimo BBIAB
20:58 Skarsnik awwaiid, I think you can't and it's bad
20:58 Skarsnik I mean it's bad that you can't
20:58 awwaiid ah. I'm now exploring faking it with some class RbValue { ... } stubs
20:59 awwaiid when I have them all in one file it works fine, but I want to break this up a bit
20:59 Skarsnik I had the same issue. I removed the type constraint on one class
20:59 flussence Skarsnik: I tried writing some sqlite3 bindings by hand "for fun" a few weeks back, and it was picking all the defines out that made me give up, so I can say having a parser like this would definitely make those kind of modules 90% easier to write. :)
21:00 flussence even if it doesn't do everything perfect :)
21:00 Skarsnik well feel free to play around with it x)
21:02 pierre-vigier joined #perl6
21:03 RabidGravy sprocket, I was wondering about "#define FOO 1" kind of stuff whether you can generate a function that returned them in a manner that could be used to create an enum
21:04 RabidGravy sorry not sprocket
21:04 RabidGravy Skarsnik ^^
21:05 RabidGravy teach me to try and touch type when there's tab completion involved
21:07 * flussence handles irc input like nuclear reactor fuel rods because of things like that
21:07 dalek rakudo/nom: 261993c | (Dan Kogai)++ | src/core/Complex.pm:
21:07 dalek rakudo/nom: Decent sqrt()
21:07 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/261993c3c6
21:07 dalek rakudo/nom: b8a75b9 | lizmat++ | src/core/Complex.pm:
21:07 dalek rakudo/nom: Merge pull request #667 from dankogai/nom
21:07 dalek rakudo/nom:
21:07 dalek rakudo/nom: Decent sqrt()
21:07 dalek rakudo/nom: review: https://github.com/rakudo/rakudo/commit/b8a75b95b0
21:07 RabidGravy yeah like the look of that one
21:10 RabidGravy flussence, before I forget, y'know the spec-v1 branch of S22 you made, did you change the example version strings for "perl" and "version" to not have the "v"?
21:10 RabidGravy (too slack to look)
21:10 flussence yes
21:11 flussence I gave those special attention, cause they were what bothered me enough to do something in the first place :)
21:12 masak I find myself wanting to put a trait on a grammar rule -- has anyone done that before?
21:13 krunen joined #perl6
21:13 RabidGravy I've already added the meta6 thing to the META6 which underlies the Test::META, I'm going to make strings with "v" a warning for meta6 = v0 and fail hard later
21:15 flussence sounds like I better go s/v6/6/ all my modules :)
21:16 RabidGravy yeah, I've got lot of version stuff to sort out
21:16 autarch Exodist: another thing I'm doing differently in my prototype is treating the main test just like a subtest - they all get their own start & end events - this will make life easier for people implementing other output formats (like TeamCity)
21:17 dududuedu joined #perl6
21:18 flussence something else I want to clarify in that branch: which places should/n't allow module names with details like :auth/:ver appended
21:19 llfourn joined #perl6
21:19 RabidGravy well currently "depends" and friends it definitely doesn't work (with panda at least, ) though it should so fixing it might be good
21:20 Skarsnik I still want my extern-depends field in meta6 x)
21:20 flussence versioned modules doesn't work in "provides" at all either, and I think there might be a good case to allow it there
21:21 flussence Skarsnik: you mean like a C lib dependency list?
21:22 awwaiid bleh. I give up... shoving them all back into one file :(
21:22 Skarsnik should be allowed to have provide : ["Foo::v1"; "Foo:v2" ] or whatever the format look like
21:22 Skarsnik flussence, more generally anything that is not perl6 that the module need to run. it could be even just informative for panda x)
21:24 Skarsnik could be usefull for tool like dh_make that generate package from cpan
21:24 awwaiid Is this use circular-dependency bug-reported?
21:24 Exodist In Test2 subtests can be implemented multiple ways. Currently there is 1 implementation that works pretty well for Test-Builder back-compat. It would be easy for anyone to implement an alternative subtest implementation if they wanted, the mechanisms that make subtests possible are generic and anyone can use them to write their own.
21:25 flussence I was thinking about that a bit too... there's nothing obviously wrong with extending depends to allow things like "sndfile:from<native>:ver<1>". Perl 6 itself doesn't use that syntax of course, but there's nothing saying it has to be a valid perl6 «use» line either.
21:25 awwaiid yeah it is ... #126688
21:26 Skarsnik flussence, https://gist.github.com/Skarsnik/83bb883378bbf2b21b82 my though on it
21:26 pierre-v_ joined #perl6
21:28 flussence oh, yeah we definitely need a way to specify optional deps. CPAN's meta spec does something that looks similar.
21:29 leont No one ever really implemented the optional dependency section of CPAN Meta
21:29 RabidGravy flussence, Skarsnik yeah external dependencies would really help packagers I guess
21:30 leont Though stealing the format of prereqs is probably a good idea, it scales much better than flattened combinations of phase (build, test, runtime) and requiredness (required, recommended, suggested)
21:30 Skarsnik The 'can be provided' is like on win32 for my gumbo binding I probably want to build the lib aside the module
21:31 leont Having external dependencies in there is useful, but difficult to get right
21:31 Skarsnik I think even if it's just informationnal for panda/whatever install stuff. it's better than nothing
21:31 flussence optional deps would make debian peoples' lives easier (cause most apt PMs have a concept of "recommended"/"optional" deps already), native lib deps would make gentoo and arch efforts easier. Even if most of this stuff ends up totally useless to panda/zef/etc :)
21:32 leont But mapping libfoo to package foo-devel/libfoo-dev is not always straightforward
21:32 leont Specially in large packages that skip with many libraries (e.g. QT)
21:33 Skarsnik it's up to the distrib to make a choice
21:33 flussence that doesn't have to be our problem; we'll give the distros enough information, it's up to them to make good use of it
21:35 leont Fair enough
21:35 leont My biggest advice here would be to experiment before making promises
21:36 flussence going out of one's way to support specific distros' ways of doing things quickly leads to insanity, it's bad enough when there are accidental distro-specific assumptions caused by only testing in one place (and we've already got enough of those to fix...)
21:36 Skarsnik and even if it's only informative for something like DBIish it will be useful to give the name of the lib
21:38 RabidGravy yeah, if different OSes/Distributions are to be dealt with they should be individually in the ecosystem rather than one module trying to get them all
21:38 Skarsnik like I do panda install DBIish; "This module requiere the optionnal lib C 'mysqlclient' to work, the otionnal lib C 'Pq v5' to work, the optionnal lib C 'sqlite v3'
21:39 RabidGravy this is part of the reason I made LibraryCheck
21:40 RabidGravy it can warn up front rather than just failing all the tests with what (to the user) may be a confusing message
21:43 notbenh joined #perl6
21:44 El_Che spinning a solaris 11 vm, see if we get rakudo built there. No luck on solaris 10: libuv need porting before rakudo can even be attemted
21:44 flussence in general I'm leaning toward making declarative things out of everything that reasonably can be, because it's almost always preferable to executing code to get at metadata (/me glares at whoever thought sysvrc was a good idea)
21:46 Skarsnik damn, still opened https://github.com/google/gumbo-parser/issues/349
21:48 leont Yeah, declarative things are generally good :-)
21:50 pierre-vigier joined #perl6
22:01 autarch btw, before anyone else starts, I should mention that I'm working on porting Net::FullAuto to p6
22:02 RabidGravy which sounds great, but I don't know what it is :)
22:02 * RabidGravy looks
22:02 flussence time cube, perl 5 edition
22:02 masak "Fully Automate ANY Process with *Persistent* SSH/SFTP from One Host"
22:03 leont autarch: I wonder what the install side of that would like like in p6
22:03 SwellJoe joined #perl6
22:03 autarch just look at the Makefile.PL - https://metacpan.org/source/REEDFISH/Net-FullAuto-1.0000007/Makefile.PL
22:03 flussence I don't think unicode has a suitable one-character reaction for this
22:03 leont Yeah, that
22:03 vividsnow joined #perl6
22:03 RabidGravy ah cool
22:03 autarch it's a quick read - no more than 7,100 lines or so
22:04 pierre-vigier joined #perl6
22:04 RabidGravy I forsee fields of hirsute yaks
22:04 leont It solves various problems discussed here by «sudo apt-get install $package» (or yum, or whatever cygwin uses, etcetera)!
22:04 autarch I thought there actually was a p5 timecube module out there ... finds https://github.com/ltp/Acme-Timecube
22:06 pierre-vigier joined #perl6
22:06 Rotwang autarch: parameters of the sleepsort subroutine are: "*@values, :$factor" and in the body you can see: "await @unsorted.map:" and @values not being used in a subroutine
22:07 pierre-v_ joined #perl6
22:07 Rotwang so it should be await @values.map: instead
22:07 Rotwang code would work if @unsorted was defined in parent scope, but I guess it wasn't authors intention
22:08 Rotwang autarch: don't mind removing comments [:
22:09 autarch Rotwang: aha, now I get you, I'll fix day 23
22:10 autarch Rotwang: fixed - thanks for the bug spotting!
22:11 Praise joined #perl6
22:12 Rotwang autarch: I'm going through perl6 advent calendar backwards, there is a chance I'll find more
22:12 Skarsnik Have fun ^^
22:12 autarch Rotwang: sounds good - I don't get notified unless you comment on _my_ posts but you can ping me here
22:12 autarch and if I'm not around hopefully someone else will fix it
22:13 Rotwang Skarsnik: perl6 brought back joy of writing code to my life ;f
22:13 Rotwang it is going to be fun indeed
22:13 vendethiel joined #perl6
22:15 RabidGravy Rotwang, you may find things that use earlier experimental versions of some concurrency stuff, they probably should be left as-is with some comment with the new code rather than fixing
22:17 autarch RabidGravy: in the 2015 calendar, or just earlier?
22:18 RabidGravy earlier, I think all the changes were in before december
22:18 autarch it might be nice to go back to _everything_ pre-2015 and add some boilerplate to the top along the lines of "Perl 6 has changed a lot since this was written. Don't be surprised if this code no longer works."
22:18 * mst .oO If only we could to that with google results for CGI
22:18 RabidGravy there's stuff using earliest/winner whatever on channels
22:18 espadrine joined #perl6
22:19 leont mst: or online tutorials for perl5 in general :-/
22:20 Rotwang advetn calendar will be top spot on google search, so it should be accurate (should contain disclaimers that this or that has changed)
22:20 llfourn joined #perl6
22:22 pjscott joined #perl6
22:23 RabidGravy go back and kill Matt Wright and the author of cgi-lib.pl and we'll be cool
22:23 * virtualsue sighs
22:23 mst RabidGravy: cgi-lib.pl was neat for its time
22:24 mst FormMail ... managed to be new-user-friendly
22:24 mspo cgi is cool
22:24 mst about 85% of the tutorials I'd gladly 451 with a rubber hose
22:24 RabidGravy vector for a squillion spams
22:24 mst mspo: the protocol's great. the old libraries are ... old.
22:24 mspo mst: shocking :)
22:25 mst I used to have a cron job that ran over a shared hosting cluster every night
22:25 mspo mojo works as cgi
22:25 pierre-vigier joined #perl6
22:25 mst though people usually complain if you try to do that
22:25 El_Che I wonder how many time people have thought mst was "the" Matt
22:25 RabidGravy it was when people carried on using cgi-lib with perl 5 it all went wrong
22:25 mst whereas Web::Simple was actually designed to allow fatpackable CGI scripts
22:26 mst El_Che: I'm never entirely sure whether people are joking.
22:26 mst which is a shame, because it means I have to let them live
22:26 El_Che mst: I am pretty sure the feeling is mutual :)
22:26 El_Che (about the joking part)
22:26 mspo even fork per request is a good pattern for  a lot of stuff
22:28 mspo launch a unikernel via cgi on a docker or something ;)
22:28 moritz start a new docker container per request?
22:28 moritz SCNR
22:28 mspo sure
22:28 El_Che "oh, that guy there is from formmail.pl. He spends now his days hacking away in dbix/moose/catalyst just to get his karma right"
22:28 mspo moritz: why not?
22:28 El_Che (I am pretty sure I once heard something similar :)
22:28 El_Che )
22:29 moritz mspo: like, performance :-)
22:29 moritz mspo: and also it seems like pretty much overkill
22:29 RabidGravy I spent a good few years helping davorg unscrew the internet from the MSA stuff, it largely worked too
22:29 moritz I know, the theory is that a docker container should be lean, but you have to to take care of stuff like logging
22:31 moritz also you might want to keep some caches between requests
22:33 mst El_Che: bah, I'm not even old enough for that. I was 17 when I started maintaining a private fork of FormMail.PL out of sheer rage
22:33 mst that was the cron job. it overwrote people's screwed up insecure copies with mine.
22:33 El_Che :) :)
22:33 virtualsue there are a lot of people that ought to be allowed to re-architect websites i don't like
22:33 mst most people just bulk-uploaded their sites and wiped it out again sadly
22:34 virtualsue such as oracle.com ;-)
22:34 virtualsue *people here
22:34 mst I tried setting up a scanner to open tickets for customer support to talk to them, but that just killed my RT instance
22:34 moritz virtualsue: ah yes, one of my favorites
22:34 RabidGravy oh oracle.com is truly, truly awful
22:35 flussence moritz: you joke, but the Erlang people actually pulled that one off with VMs...
22:35 virtualsue interesting, plausible and not working thanks
22:35 leont Yeah, oracle's website is terrible
22:35 moritz flussence: well, the Erlang "process" is a lot more light weight than a UNIX process
22:35 El_Che about Oracle, has someone got moarvm built on solaris 11. Trying and failing atm
22:35 virtualsue but make it LOOK nice
22:36 leont Worst part is when they buy some company with a good website, and mess it all up :-/
22:36 moritz virtualsue: I don't even remember how it looks; I just remember the pain in trying to find the right download, and finding the right click path so I don't have enter my email address and 20+ other form fields
22:36 RabidGravy hasn't it looked the same since forever?
22:37 moritz dunno; I'm not a visual person
22:37 mspo but java
22:38 El_Che oracle support? no it had changed a few times. Always for the worst
22:38 ugexe joined #perl6
22:40 * flussence compiles openjdk nowadays for the sole reason of it being a ready-made 10 foot bargepole for not touching oracle with
22:41 El_Che sadly --very sadly-- openjdk does not always delivers and in does cases you're forced to use oracle jdk
22:42 El_Che e.g. for Shibboleth SSO. Openjdk results in hard locks every few months (on a busy setup). Oracle jdk works just fine
22:42 RabidGravy did IBM stop making jdks?
22:43 El_Che I don't think so, but probably only AIX people use it
22:43 vendethiel joined #perl6
22:45 RabidGravy I remember using their Win 3.11 version like a million years ago, it actuall worked too
22:46 virtualsue this is disheartening. i was being sarcastic and now look where we are
22:47 flussence RabidGravy: they had one as late as Java 6. I don't think I ever got that one working properly
22:48 RabidGravy it stopped me thinking about the six modules I have in various states of repair
22:48 Ven joined #perl6
22:50 virtualsue ;-)
22:50 nine on external dependencies: I really would not use any package names, those are distro dependent. I'd refer to package capabilities like library names.
22:50 El_Che ok, I give up this solaris moarvm thing for today. I'll watch a x-file episode. Feeling retro
22:51 nine nine@sphinx:~> zypper -q search --provides libperl.so
22:51 nine i | perl       | The Perl interpreter | package
22:51 Skarsnik we never talk about pagkages names ^^
22:51 Skarsnik just the libname
22:51 moritz that's in perl-base in Debian
22:52 nine moritz: exactly. Library names are much more stable than package names. And there should be a way to find a package providing a library for pretty much every distro.
22:53 El_Che $ dpkg -S libperl.so
22:53 El_Che libperl5.20: /usr/lib/x86_64-linux-gnu/libperl.so.5.20
22:53 El_Che libperl5.20: /usr/lib/x86_64-linux-gnu/libperl.so.5.20.2
22:53 Skarsnik .so is a bad idea
22:54 pmurias nine: won't we sometimes also need the dev package?
22:54 Skarsnik root@testperl6:~/piko/gptrixie# apt-file search libperl.so
22:54 Skarsnik libperl-dev: /usr/lib/i386-linux-gnu/libperl.so
22:54 nine well we can apply some $*VM.plattform-library-name there
22:55 El_Che Skarsnik: apt-file is not part of the default install
22:55 nine pmurias: we can also require certain header files. That may then pull in some -devel package
22:55 notbenh any one know if there's a way to make a lazy infinate list of a repeating range? for example 1..9,1..9,1..9
22:55 Skarsnik dpkg only search on installed stuff probably?
22:56 moritz notbenh: something like  flat (1..9) xx * maybe?
22:56 nine El_Che: doesn't have to be in the default install. It's needed only for creating the distro package for your module.
22:56 moritz m: my \seq = flat (1..9) xx *; say seq[5..11]
22:56 camelia rakudo-moar b8a75b: OUTPUT«(6 7 8 9 1 2 3)␤»
22:56 moritz notbenh: seems to work
22:56 notbenh moritz: rad thanks
22:57 pmurias nine: while installing modules using cpanm it's often annoying that you have to install external dependencies manually
22:58 pmurias nine: it would be great if panda (or it's future replacement) could install those for you
22:58 nine At least on openSUSE, Perl 5 packages are also package capabilities:
22:58 nine nine@sphinx:~> zypper -q se --provides 'perl(DBI)' | grep package
22:58 nine i | perl-DBI | Database independent interface for Perl | package
22:59 pmurias nine: re automatically finding the right packages, one possible problem is if there are two packages that provide a given lib/header
22:59 Skarsnik pmurias, I always use dh_make or the debian package to install perl module
23:00 pmurias Skarsnik: does it take care of doing stuff like installing libxml2?
23:01 nine pmurias: then the user has to decide which one to pick. Distributions have the same challenges and I know openSUSE has moved to capabilities instead of package names and I'm sure other distos do as well.
23:01 geck any rpm-based distro you can do deps based on file names
23:02 Skarsnik I think it's up to the distrib to patch panda/whatever if they want auto isntall
23:02 nine I can actually say sudo zypper in -C libperl.so to install the package providing this library
23:02 geck yum/dnf you have to look up, same with debian iirc
23:02 nadim joined #perl6
23:03 Skarsnik Two packages can provide the same file
23:03 geck yeah, that's the problem with that approach, you look it up then go "derp, which one?"
23:03 Skarsnik a (bad) example /usr/bin/cc
23:03 nine Skarsnik: my point is: with this you have to write code once to support a distro. That's much better than having to support all distros by every module.
23:04 BenGoldberg joined #perl6
23:04 Skarsnik That why it need to be in the meta file :)
23:09 ugexe that should be the job of a recommendation manager, of which the end user can decide which ones they wish to use
23:09 ugexe then you can do either
23:10 RabidGravy sure but having the info in the meta file makes it possible
23:10 ugexe sure, that was one of the original purposes of resources, a source of additional arbitrary rich meta data
23:11 ugexe not just a file mapping, although it can be its own field or whatever as well
23:12 pmurias nine: we can have both the ability to specify a header/file or a bunch of packages
23:12 Skarsnik unrelated, is a new rakudo release for soon or is there some blocking stuff?
23:16 Skarsnik https://rt.perl.org/Ticket/Display.html?id=112262 maybe than can be closed? x)
23:17 pjscott joined #perl6
23:19 joydon joined #perl6
23:20 lucasb joined #perl6
23:21 llfourn joined #perl6
23:22 RabidGravy yeah, even on the assumption parrot aint coming back any time real soon now ;-)
23:24 yqt joined #perl6
23:24 * masak somehow read that as "the assumption patron saint"
23:24 masak 'night, #perl6 :)
23:25 RabidGravy :)
23:26 Skarsnik 'night #perl6
23:26 lizmat gnight Skarsnik masak
23:29 lucasb if I reply to ticket in my email client, will it get attached to the same ticket or will end up creating a new one?
23:30 RabidGravy with the number it should attach
23:32 notbenh another question that I can't seem to find in the docs. Does p6 have a native memoize notion or do we still use the hash trick from p5?
23:33 leont is cached, I think
23:33 nadim joined #perl6
23:33 lucasb thanks, RabidGravy
23:34 RabidGravy "is cached" is speculated but not completely implemented, free for ecosystem implementation
23:35 RabidGravy m: sub foo($a) is cached { }
23:35 camelia rakudo-moar b8a75b: OUTPUT«5===SORRY!5=== Error while compiling /tmp/HExJmKT7oD␤Use of the 'is cached' trait is experimental; please 'use experimental :cached'␤at /tmp/HExJmKT7oD:1␤»
23:38 bitmap joined #perl6
23:44 zw joined #perl6
23:45 pjscott joined #perl6
23:45 zw hello, how to get partially applied function. I mean f($a, $b), g($b) = f("hello", $b).
23:47 ugexe .assuming
23:47 geekosaur &f.assuming("hello") ?
23:47 timotimo yup
23:48 lucasb m: say .signature for class C { multi method foo(1) {}; multi method foo(2) {} }.^can('foo')[0].candidates
23:48 camelia rakudo-moar b8a75b: OUTPUT«(C $: Int $ where { ... }, *%_)␤(C $: Int $ where { ... }, *%_)␤»
23:48 lucasb m: say .signature for role R { multi method foo(1) {}; multi method foo(2) {} }.new.^can('foo')[0].candidates
23:48 camelia rakudo-moar b8a75b: OUTPUT«(R $: Int $ where { ... }, *%_)␤»
23:48 lucasb ^^ I thinks this is related to https://rt.perl.org/Public/Bug/Display.html?id=127129
23:48 RabidGravy partial application was a feature I got quite excited about but have never actually used
23:49 zw thanks
23:50 lucasb iow, the class retains multiple multis, but roles do not (iiuc)
23:51 lucasb but I thinks this only shows when using multiple multis that have the same parameter type, but uses values to pattern match/dispatch
23:52 vendethiel RabidGravy: you need more functions, obviously :P (and more askele!)
23:53 lucasb anyone confirms (or not) my assumption? :)
23:53 dalek doc: 5d3f2f3 | lizmat++ | doc/Language/setbagmix.pod:
23:53 dalek doc: The codepoint in the header rendered way too ugly
23:53 dalek doc:
23:53 dalek doc: So move the actual codepoint information to the text.
23:53 dalek doc: review: https://github.com/perl6/doc/commit/5d3f2f3eb7
23:55 lizmat good night, #perl6!
23:58 lucasb one more data point: I my example, if you try to call foo(1), it works, but if you call foo(2) it fails because it can't find a suitable signature, even though the method was defined
23:58 lucasb *In my example;  (I'm making lots typos and mistake :)
23:58 timotimo oh, huh.
23:59 nzkindest joined #perl6

| Channels | #perl6 index | Today | | Search | Google Search | Plain-Text | summary

Perl 6 | Reference Documentation | Rakudo