Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2017-07-06

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:05 mr-foobar joined #perl6
00:13 Actualeyes joined #perl6
00:15 Cabanossi joined #perl6
00:19 Geth ¦ doc: 5f5d2227d4 | (Will "Coke" Coleda)++ | doc/Language/pragmas.pod6
00:19 Geth ¦ doc: Document 'use strict' (really 'no strict')
00:19 Geth ¦ doc:
00:19 Geth ¦ doc: Fixes #799
00:19 Geth ¦ doc: review: https://github.com/perl6/doc/commit/5f5d2227d4
00:21 lookatme morning
00:23 kyan joined #perl6
00:28 MasterDuke DrForr_'s Perl6::Parser could probably be used to rename variables
00:41 obra joined #perl6
00:45 Cabanossi joined #perl6
01:10 travis-ci joined #perl6
01:10 travis-ci Doc build errored. Will "Coke" Coleda 'Document 'use strict' (really 'no strict')
01:10 travis-ci https://travis-ci.org/perl6/doc/builds/250579592 https://github.com/perl6/doc/compare/6beae1e8d60a...5f5d2227d4e8
01:10 travis-ci left #perl6
01:10 buggable [travis build above] ✓ All failures are due to timeout (1), missing build log (0), GitHub connectivity (0), or failed make test (0).
01:39 aborazmeh joined #perl6
01:39 aborazmeh joined #perl6
01:48 ilbot3 joined #perl6
01:48 Topic for #perl6 is now »ö« Welcome to Perl 6! | https://perl6.org/ | evalbot usage: 'p6: say 3;' or rakudo:,  or /msg camelia p6: ... | irclog: http://irc.perl6.org or http://colabti.org/irclogger/irclogger_logs/perl6 | UTF-8 is our friend!
01:49 TEttinger joined #perl6
02:15 Cabanossi joined #perl6
02:16 noganex_ joined #perl6
02:25 skids joined #perl6
03:10 Geth ¦ whateverable: 54cc2c99dc | MasterDuke17++ | Coverable.p6
03:10 Geth ¦ whateverable: Initial version of Coverable6
03:10 Geth ¦ whateverable: review: https://github.com/perl6/whateverable/commit/54cc2c99dc
03:11 coverable6 joined #perl6
03:17 mr-foobar joined #perl6
03:20 raschipi coverable6: HEAD grep=SETTING say ‘hello’; say ‘world’
03:21 coverable6 raschipi, https://gist.github.com/b262aacd68958349443702dec7e0091e
03:42 |oLa| joined #perl6
03:47 raiph joined #perl6
03:58 Cabanossi joined #perl6
04:21 tardisx joined #perl6
04:28 Cabanossi joined #perl6
04:50 uberbaud joined #perl6
04:58 wamba joined #perl6
05:01 astj joined #perl6
05:01 xtreak joined #perl6
05:06 amits2878 joined #perl6
05:09 casdr_ joined #perl6
05:11 mst_ joined #perl6
05:12 mls_ joined #perl6
05:14 jkva__ joined #perl6
05:17 eviltwin_b joined #perl6
05:19 cpage___ joined #perl6
05:20 perlawhirl .tell zengargoyle I've used str[pf]time via NativeCall before. See: https://gist.github.com/0racle/3f4a51b2a6aa1c5ee898e24e95b9e704
05:20 yoleaux perlawhirl: I'll pass your message to zengargoyle.
05:20 ufobat joined #perl6
05:23 perlawhirl .tell zengargoyle I've also played around with pure Perl 6 parsing and formatting under https://github.com/0racle/p6-dately , but that was just a rather diabolical sketch... here be dragons.
05:23 yoleaux perlawhirl: I'll pass your message to zengargoyle.
05:24 john51 joined #perl6
05:28 navyakhare joined #perl6
05:35 sacomo joined #perl6
05:43 Cabanossi joined #perl6
05:58 Grauwolf joined #perl6
06:01 tyil joined #perl6
06:04 b7j0c joined #perl6
06:05 b7j0c it doesn't look like perl6 has direct support for `-pi -e` like perl5 (perl pie!) is there something I am missing? I still reach for perl5 for my perl pie but would love to upgrade
06:14 moritz b7j0c: you could add support for -i to perl6
06:14 moritz b7j0c: many people would love you for it
06:14 b7j0c until they saw my patch, then they would vote me off the island! but I'll keep it in mind!
06:15 b7j0c actually maybe that would make a fun project, if only to learn how I failed
06:15 moritz and it's not like you'd be on your own; folks over in #perl6-dev would be happy to help you
06:15 llfourn b7j0c: https://github.com/dnmfarrell/Perl6-One-Liners # might be of interest
06:16 b7j0c sounds like a challenge! well I guess I could just start by looking at what perl5 does...anyway, thanks!
06:16 mr-foobar joined #perl6
06:21 kybr joined #perl6
06:23 awwaiid joined #perl6
06:26 MilkmanDan joined #perl6
06:28 Cabanossi joined #perl6
06:44 rindolf joined #perl6
06:57 espadrine joined #perl6
07:01 domidumont joined #perl6
07:07 parv joined #perl6
07:08 domidumont joined #perl6
07:11 Geth ¦ ecosystem: f85dcb45c9 | seatek++ (committed using GitHub Web editor) | META.list
07:11 Geth ¦ ecosystem: Update META.list
07:11 Geth ¦ ecosystem: review: https://github.com/perl6/ecosystem/commit/f85dcb45c9
07:24 darutoko joined #perl6
07:29 nadim_ joined #perl6
07:33 abraxxa joined #perl6
07:39 dakkar joined #perl6
07:44 xtreak joined #perl6
07:58 AlexDaniel joined #perl6
07:58 Cabanossi joined #perl6
07:59 nadim_ joined #perl6
08:01 jonas1 joined #perl6
08:29 Cabanossi joined #perl6
08:43 saman joined #perl6
08:56 astj_ joined #perl6
08:59 Cabanossi joined #perl6
08:59 astj joined #perl6
09:01 xtreak joined #perl6
09:26 zakharyas joined #perl6
09:27 Juerd zengargoyle: Thanks for the explanation. It went over my head, but I'll check it out -- and look up the things in the manual that I don't understand yet -- when I have time. :)
09:34 zakharyas joined #perl6
09:36 cfa joined #perl6
10:05 nadim_ good morning, there must be other ways to write this: @a.map: {$_++} ;  # wehre the code could be a simple operator like in the example or a tad more complex code
10:08 jnthn @a>>++
10:08 jnthn @a.map(*++)
10:08 jnthn .++ for @a
10:09 jnthn Beware that the first will descend into nested structure
10:09 nadim_ ok, ans say I want to set all elements to a specific value, say 7.
10:09 nadim_ good to know
10:09 jnthn m: my @a = 1,2,3; @a >>=>> 7; say @a
10:09 camelia rakudo-moar 15a933: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Missing << or >>␤at <tmp>:1␤------> 3my @a = 1,2,3; @a >>=>7⏏5> 7; say @a␤    expecting any of:␤        infix␤        infix stopper␤»
10:09 jnthn m: my @a = 1,2,3; @a >>[=]>> 7; say @a
10:09 camelia rakudo-moar 15a933: OUTPUT: «[7 7 7]␤»
10:10 jnthn Like that
10:10 nadim_ cool
10:10 jnthn The >> poitning at the 7 means to upgrade it to pretend it's a list of 7s
10:10 nadim_ map { ...} is mre redable but it is good to know
10:11 nadim_ I need to look at a nice hyper operator blog entry
10:11 ggoebel joined #perl6
10:12 nadim_ m: my @a = ^3; .=7 for @a ; dd @a
10:12 camelia rakudo-moar 488abd: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Preceding context expects a term, but found infix .= instead␤at <tmp>:1␤------> 3my @a = ^3; .=7⏏7 for @a ; dd @a␤»
10:13 nadim_ m: my @a = ^3; .++ for @a ; dd @a
10:13 camelia rakudo-moar 488abd: OUTPUT: «Array @a = [1, 2, 3]␤»
10:14 nadim_ m: my @a = ^3; {.=7} for @a ; dd @a
10:14 camelia rakudo-moar 488abd: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Preceding context expects a term, but found infix .= instead␤at <tmp>:1␤------> 3my @a = ^3; {.=7⏏7} for @a ; dd @a␤»
10:14 timotimo you can also my @a = 1, 2, 3; @a = 7 xx @a; say @a.perl
10:14 timotimo m: my @a = 1, 2, 3; @a = 7 xx @a; say @a.perl
10:14 camelia rakudo-moar 488abd: OUTPUT: «[7, 7, 7]␤»
10:14 geekosaur remember that = does the op= thing, so you can't use the .op for op-as-method
10:15 jnthn m: my @a = 1,2,3; @a[*] = 7 xx *; say @a
10:15 camelia rakudo-moar 488abd: OUTPUT: «[7 7 7]␤»
10:15 jnthn There's also that way
10:18 astj_ joined #perl6
10:23 bjz joined #perl6
10:26 Zoffix joined #perl6
10:27 Zoffix Anyone feel like it's time for modules.perl6.org to switch into more of a metacpan.org interface? i.e. not load all the modules on a single page, but just show a search box by default.
10:28 Zoffix One extra piece of info soon to be added is CPANTesters reports + we already have some currently-hidden extra info ( http://modules.perl6.org/todo ) that could well be presented when searching for a module
10:29 Zoffix Not sure what the progress of http://modules.zef.pm/ is. Currently it has a... Unicorn dinasaur puking up a rainbow
10:31 Zoffix Oh right, and the more pressing reason to do it is to also show modules available on CPAN.
10:32 Zoffix + handle same-name-differnet-authors cases
10:33 Zoffix So there's a whole ton of info ready to be included, and including it all on one page is a bit too much. And already on slower networks it takes too long to load all the modules, and it'll take even longer the more of them we have, hence the proposal to switch to search-box-only style
10:36 timotimo yeah i can see that
10:36 wamba joined #perl6
10:42 geekosaur it's needed that for a while imo
10:50 nadim_ Zoffix++
11:08 zakharyas joined #perl6
11:10 lizmat Zoffix: +1 on switching to more of a metacpan.org interface
11:10 gdonald joined #perl6
11:12 Zoffix OK. I'll poke at it some time soon then.
11:20 mr-foobar joined #perl6
11:28 Cabanossi joined #perl6
11:51 bjz joined #perl6
11:58 Cabanossi joined #perl6
11:58 mr-foobar joined #perl6
12:01 nadim_ joined #perl6
12:06 nadim joined #perl6
12:07 [Coke] who is hosting the existing docs.perl6.org site?
12:07 Zoffix We are on www.p6c.org
12:07 moritz it runs on... right
12:08 [Coke] so, "us"
12:08 [Coke] I'd like to consider moving it from a static site to a perl6 live app (with a caching reverse proxy in front of it.)
12:09 Zoffix Big +1 on that
12:09 moritz then you should investigate traffic numbers, and expected memory usage of that app
12:10 moritz http://www.p6c.org/stats/ might help
12:11 moritz (we could also run the web app on hack, which has more memory, and put the caching proxy on www.p6c.org; then instabilities in the app can't take down the main perl6.org site)
12:12 Zoffix m: say "{33930/30.25/24/60/60} req/min average"
12:12 camelia rakudo-moar e20817: OUTPUT: «0.012982 req/min average␤»
12:12 Zoffix Yeah, I think we're safe on memory usage :)
12:12 moritz and since the two run on the same physical machine, networkin should be pretty fast
12:12 Zoffix The modules.perl6.org web app runs on www.p6.org
12:12 moritz Zoffix: spike usage is much more interesting than average
12:13 moritz modules.perl6.org is p5, no?
12:13 Zoffix Oh, I missed the "perl6" in the plans
12:13 Zoffix My last attempt to do that ended in failure.
12:16 Rawriful joined #perl6
12:22 mingdao joined #perl6
12:23 bjz_ joined #perl6
12:26 xtreak joined #perl6
12:28 Cabanossi joined #perl6
12:51 raschipi joined #perl6
12:51 mr-foobar joined #perl6
12:54 Khisanth joined #perl6
13:01 bjz joined #perl6
13:02 domm joined #perl6
13:03 konsolebox joined #perl6
13:03 Zoffix left #perl6
13:08 bjz_ joined #perl6
13:24 mr-foobar joined #perl6
13:27 AlexDaniel joined #perl6
13:35 AlexDaniel joined #perl6
13:36 AlexDaniel joined #perl6
13:43 ufobat zoffix?
13:44 ufobat how can i add the 2 files to the ticket?
13:45 ufobat ah he left, sorry
13:46 AlexDaniel [Coke]: re “from a static site to a perl6 live app”… my experience of using p6 instead of p5 for whateverable bots was extremely painful, and while it got more or less stable, I'm still suffering from time to time
13:46 [Coke] ufobat: which ticket?
13:46 AlexDaniel [Coke]: I'd say that you wuold need a person responsible for the whole thing to accomplish something like that
13:46 [Coke] AlexDaniel: putting a caching proxy in front of it should eliminate a lot of the pain.
13:47 [Coke] AlexDaniel: yah, that'd be me, I guess.
13:47 AlexDaniel [Coke]: not if the damn thing runs out of memory… or crashes from time to time randomly
13:47 AlexDaniel in a way it's good because you'll report a lot of bugs
13:47 AlexDaniel which will help rakudo in general
13:47 AlexDaniel but what I'm trying to say is… just don't expect this to be easy and painless… not at all
13:48 [Coke] AlexDaniel: I have some small experience working with Perl 6. Thanks for the heads up, though. :)
13:48 AlexDaniel [Coke]: well, one thing is perl 6, another thing is long-running processes with perl 6 :)
13:49 ufobat https://rt.perl.org/Public/Bug/Display.html?id=131707 [Coke], i've forgotton to add the files
13:50 ufobat can i just reply to the email i'd received because of zoffix comment on the ticket? will this work?
13:51 Zoffix joined #perl6
13:51 Zoffix ufobat: ?
13:51 skids joined #perl6
13:51 mr-foobar joined #perl6
13:52 Zoffix ufobat: the A and B files? There's attach a file button. But even copy-pasting the code is sufficient
13:53 Zoffix ufobat: yeah, probably will work to just reply. Just hit "reply to all"
13:55 ufobat did that :)
13:55 ufobat let us see if it worked
13:56 ufobat btw: the files are copy pasted in here: http://www.nntp.perl.org/group/perl.perl6.users/2017/07/msg3967.html
14:08 brabo joined #perl6
14:08 mr-fooba_ joined #perl6
14:09 Zoffix left #perl6
14:10 mr-foob__ joined #perl6
14:23 gradio_ joined #perl6
14:23 gradio_ left #perl6
14:30 alimon joined #perl6
14:33 brabo joined #perl6
14:36 AlexDaniel joined #perl6
14:45 brabo joined #perl6
14:52 espadrine joined #perl6
14:55 AlexDaniel m: say ‘hello’.append(42)
14:55 camelia rakudo-moar c585f3: OUTPUT: «Cannot resolve caller append(Str: Int); none of these signatures match:␤    (Any:U \SELF: |values is raw)␤  in block <unit> at <tmp> line 1␤␤»
14:55 khw joined #perl6
14:56 AlexDaniel er, uhm…
14:56 AlexDaniel why?
14:57 AlexDaniel I mean… why would Any have .append if you can't append to anything?
14:58 AlexDaniel just trying to understand
14:58 perigrin m: say 'hello'.append('42')
14:58 camelia rakudo-moar c585f3: OUTPUT: «Cannot resolve caller append(Str: Str); none of these signatures match:␤    (Any:U \SELF: |values is raw)␤  in block <unit> at <tmp> line 1␤␤»
14:58 perigrin curious
14:58 Geth ¦ specs: ef72ef9f0a | (Zoffix Znet)++ (committed using GitHub Web editor) | v6d.pod
14:58 Geth ¦ specs: List De-magicalize '-' in IO::Handle.open
14:58 Geth ¦ specs: review: https://github.com/perl6/specs/commit/ef72ef9f0a
14:59 jnthn AlexDaniel: auto-viv
14:59 [Coke] it's a different solution to the problem .contains has.
15:00 timotimo m: my $foo; $foo.append("hi"); say $foo.perl
15:00 camelia rakudo-moar c585f3: OUTPUT: «$["hi"]␤»
15:00 AlexDaniel timotimo: oh… Oh. Well, that looks alright
15:00 timotimo that's why the candidate is Any:U
15:00 AlexDaniel I see now
15:01 Geth joined #perl6
15:01 colomon_ joined #perl6
15:04 AlexDaniel [Coke]: well, I'm happy to hear that we are finally considering that there might be a problem somewhere…
15:04 troys joined #perl6
15:07 [Coke] sorry, "the problem"
15:07 [Coke] I'm not getting dragged into that ticket, thankyouverymuch.
15:08 stmuk_ I suppose cross-compilation isn't possible (unless maybe two moars, one native, one target arch were used somehow)?
15:11 colomon joined #perl6
15:18 kyan joined #perl6
15:42 leont joined #perl6
15:45 astj joined #perl6
16:07 mr-foobar joined #perl6
16:10 domidumont joined #perl6
16:14 Cabanossi joined #perl6
16:15 timotimo gdonald: hey, your rosettacode example with .read(1) instead of .getc has a problem
16:16 timotimo gdonald: read returns a buf, and when you regexmatch that it'll just call .Str on it, which then lookn like "Buf.new(0x21)"
16:18 dj_goku joined #perl6
16:20 timotimo gdonald: i recommend using $TTY.read(1).decode('latin1')
16:20 timotimo (i say latin1 because if there's a multi-character utf8 sequence, you'll have trouble decoding it with only the first byte)
16:23 gdonald Fixed, thanks.
16:23 timotimo yw
16:25 domidumont joined #perl6
16:32 astj joined #perl6
16:36 TimToady gdonald: if you want UTF-8 input, you can do something more like: repeat { $buf ~= $TTY.read(1) } until try my $s = $buf.decode;
16:38 TimToady (with a my $buf = Buf.new; before it)
16:44 wamba joined #perl6
16:46 nadim joined #perl6
16:46 bwisti joined #perl6
16:49 nicq20 joined #perl6
17:20 gdonald Good to know :)  For my current use case I'm going with latin1 since it just feeds a simple given/when menu system.
17:22 leont joined #perl6
17:25 |oLa| joined #perl6
17:32 timotimo TimToady: but if you put an ansi escape code in, like arrow keys, that'll make the program unresponsive?
17:40 nadim within a for loop, is it possible to pop out some of the element that the for loop will process next? I can do it a list and a while but curious about if it is possible. I also hope it is not.
17:44 [Coke] pop out?
17:45 ChoHag joined #perl6
17:45 nadim remove elements from the list the for loop will handle
17:46 ptolemarch joined #perl6
17:46 timotimo m: my @foo = <a b c d e f g h>; for @foo { .say; if ^5.pick == 1 { say "shift: " ~ @foo.shift } }
17:46 camelia rakudo-moar c3e3ff: OUTPUT: «Potential difficulties:␤    Precedence of ^ is looser than method call; please parenthesize␤    at <tmp>:1␤    ------> 3a b c d e f g h>; for @foo { .say; if ^57⏏5.pick == 1 { say "shift: " ~ @foo.shift ␤a␤b␤c␤d␤e␤f␤g␤h␤»
17:47 timotimo m: my @foo = <a b c d e f g h>; for @foo { .say; if (^5).pick == 1 { say "shift: " ~ @foo.shift } }
17:47 camelia rakudo-moar c3e3ff: OUTPUT: «a␤b␤c␤d␤e␤f␤g␤h␤»
17:47 timotimo haha, it didn't do it once
17:47 timotimo m: my @foo = <a b c d e f g h>; for @foo { .say; if (^5).pick == 1 { say "shift: " ~ @foo.shift } }
17:47 camelia rakudo-moar c3e3ff: OUTPUT: «a␤b␤c␤d␤shift: a␤f␤g␤shift: b␤»
17:49 timotimo as you can see if you shift from the beginning, you'll also skip an extra element
17:50 jamesaxl joined #perl6
17:58 Cabanossi joined #perl6
18:00 setty1 joined #perl6
18:02 [Coke] mutating the list as you go is a bad idea. you can use NEXT to skip one, though.
18:07 timotimo not NEXT, next :)
18:09 [Coke] oohs, ETOOMANYCAPS
18:09 [Coke] *oops
18:11 dct joined #perl6
18:22 bpmedley joined #perl6
18:25 epony joined #perl6
18:27 TimToady timotimo: I've had no trouble with the arrow keys, since they basically come in as ASCII
18:27 timotimo oh, of course that works
18:27 TimToady I do have an additional level of lookahead to handle them that I didn't show
18:28 timotimo i'm working on something that also wants arrow keys
18:28 TimToady basically an @INPUT array I append chars to, so for an escape the @INPUT[0] eq "\e"
18:29 TimToady then I just do sub-switch statements to handle the options within that
18:30 TimToady and basically any time I want to look at the front of @INPUT I make sure there's something there first, in case the sequence was split, which it certainly will be with .read(1)
18:30 timotimo right
18:33 nhywyll joined #perl6
18:39 sjn good *, #perl6 :)
18:39 zengargoyle .tell perlawhirl thanks for p6-dately, that looks sorta like my first thoughts before reading the strptime man page and thinking about locale and stuff. dragons indeed.
18:39 yoleaux 05:20Z <perlawhirl> zengargoyle: I've used str[pf]time via NativeCall before. See: https://gist.github.com/0racle/3f4a51b2a6aa1c5ee898e24e95b9e704
18:39 yoleaux zengargoyle: I'll pass your message to perlawhirl.
18:39 yoleaux 05:23Z <perlawhirl> zengargoyle: I've also played around with pure Perl 6 parsing and formatting under https://github.com/0racle/p6-dately , but that was just a rather diabolical sketch... here be dragons.
18:40 AlexDaniel joined #perl6
18:42 * sjn is diving into src/core/Main.pm
18:43 |oLa| joined #perl6
18:43 zengargoyle .tell Juerd checking out this years DC vim plugins is on my todo list (to see what's changed).  i think i can come up with a simple binding that at least DWIMs within a function scope.
18:43 yoleaux zengargoyle: I'll pass your message to Juerd.
18:44 sjn can anyone here give me a quick hint on what Parameter.usage-name() is for?
18:44 Juerd zengargoyle: Would be nice!
18:44 yoleaux 18:43Z <zengargoyle> Juerd: checking out this years DC vim plugins is on my todo list (to see what's changed).  i think i can come up with a simple binding that at least DWIMs within a function scope.
18:45 zengargoyle Zoffix++ on MetaCPAN-ization of modules.perl6.org
18:46 timotimo sjn: i assume it throws out $ and $. and such and puts in --
18:46 sjn aah
18:47 * sjn isn't that much into NQP, but that makes sense
18:53 TimToady m: my @a = 1,2,3; @a X= 7; say @a
18:53 camelia rakudo-moar c3e3ff: OUTPUT: «[7 7 7]␤»
18:53 sjn allright, next question; I've got a MAIN method where I'm using a subset as a type for one of the parameters
18:53 TimToady you guys missed the easy one...
18:53 TimToady nadim: ^^^
18:54 sjn subset Filename of Str where { .IO ~~ :f };
18:55 sjn the usage text that is generated for this one -- sub MAIN (Filename :$in) { ... } -- is "Str"
18:55 sjn well, it's "--in=<Str>"
18:55 sjn I'd expect the usage statement to list "--in=<Filename>"
18:56 Zoffix joined #perl6
18:56 Zoffix m: subset Filename of Str where { .IO ~~ :f }; -> Filename $ {}.signature.params.say
18:56 camelia rakudo-moar c3e3ff: OUTPUT: «(Str $ where { ... })␤»
18:56 sjn meaning, it looks like $param.type.^name doesn't show the subset type name
18:56 Zoffix Don't look like it's up in there :/
18:57 moritz the problem is that parameters need to distinguish between nominal and constraint types
18:57 Zoffix zengargoyle: it might not happen overnight tho. More exciting things showed up this afternoon.
18:57 moritz (for multi sorting)
18:57 sjn right. it sucks for documentation purposes though
18:57 Zoffix m: subset Filename of Str where { .IO ~~ :f }; -> Filename $ {}.signature.params[0].constraints.say
18:57 moritz and $param.type is the nominal type, which is Str here
18:57 camelia rakudo-moar c3e3ff: OUTPUT: «all((Filename))␤»
18:58 Zoffix m: subset Filename of Str where { .IO ~~ :f }; -> Filename $ {}.signature.params[0].constraint_list.head.say
18:58 camelia rakudo-moar c3e3ff: OUTPUT: «(Filename)␤»
18:58 Cabanossi joined #perl6
18:58 Zoffix m: subset Filename of Str where { .IO ~~ :f }; -> Filename $ {}.signature.params[0].constraint_list.head.HOW.^name.say
18:58 camelia rakudo-moar c3e3ff: OUTPUT: «Perl6::Metamodel::SubsetHOW␤»
18:59 Zoffix So how come `repeat { $buf ~= $TTY.read(1) } until try my $s = $buf.decode;` instead of just $TTY.readchar ?
18:59 Zoffix So how come `repeat { $buf ~= $TTY.read(1) } until try my $s = $buf.decode;` instead of just $TTY.getc ?
19:00 Zoffix or .readchars(1)
19:00 zengargoyle a char isn't a byte?
19:00 Zoffix TimToady: are ZEN slices meant to be list-coercive? Like @()?
19:01 zengargoyle where a byte is a keypress?
19:01 Zoffix zengargoyle: sure, but it's looping until it can decode in UTF8
19:02 Zoffix Ah, k, .getc/.readchars would wait for combiners.
19:02 zengargoyle i would guess something goes before the 'until' to check for other things.
19:03 Zoffix m: dd 42[]; dd @(42)
19:03 camelia rakudo-moar c3e3ff: OUTPUT: «42␤(42,)␤»
19:03 Zoffix TimToady: ^ basically aiming to do that return same thing. There's a 2013 chat log somewhere of you saying they should be the same
19:04 Zoffix Make Any.ZEN-POS do `self.list` and Positional.ZEN-POS just be `self`
19:09 TimToady m: say 42[] ~~ Positional
19:09 camelia rakudo-moar c3e3ff: OUTPUT: «False␤»
19:09 TimToady m: say 42.list ~~ Positional
19:09 camelia rakudo-moar c3e3ff: OUTPUT: «True␤»
19:09 zengargoyle if you have a Grammar and Actions, where's the best place to catch Exceptions and rethrow something else?
19:10 TimToady surely that would depend on the language in question
19:10 TimToady a sane language should already have most of the info available at the original throw point, I'd think
19:11 moritz zengargoyle: you could also have a Compiler object that takes care of instantiating Grammar and Action, and also of catching some exceptions or other
19:11 TimToady other than that, it's all just methods, so at worst you'd have to interpose a normal method with a CATCH
19:11 zengargoyle in my case, it's only DateTime.new throwing and pretty much i want them all to be X::Time::Spec::at::InvalidDate
19:12 zengargoyle but i create DateTime in various places, but really only need to catch it once.
19:12 moritz so write a small function that wraps DateTime.new ?
19:13 fran_ joined #perl6
19:13 zengargoyle i could wrap the whole G.parxe("whatever", :$actions) and catch there, but is thare a place in Actions ... hehe moritz++
19:14 zengargoyle i sorta thought catch at every DateTime.new and rethrow or wrap the whole thing and throw.
19:15 seatek joined #perl6
19:16 zengargoyle it's just that users who wanted to use the Grammar/Actions directly would face DateTime Exceptions instead of my Exceptions.  but i don't see much of a better way.
19:16 druonysuse joined #perl6
19:17 Zoffix m: subset MeowName of Str where .so; with -> MeowName $ where 42 {}.signature.params[0] { my $subset-name = do given .constraint_list.first: {not .DEFINITE} { $_ === Nil ?? $_ !! .^name }; dd "--<$subset-name>"
19:17 camelia rakudo-moar c3e3ff: OUTPUT: «5===SORRY!5=== Error while compiling <tmp>␤Missing block␤at <tmp>:1␤------> 3?? $_ !! .^name }; dd "--<$subset-name>"7⏏5<EOL>␤    expecting any of:␤        postfix␤        statement end␤        statement modifier␤        stateme…»
19:17 moritz sub dt(|c) { CATCH { X::Time::Spec::at::InvalidDate.new(|c).throw }; DateTime.new(|c) }
19:17 pilne joined #perl6
19:17 moritz and then just use dt(...) instead of DateTime.new(...)
19:17 Zoffix sjn: ^ maybe something along those lines stuck over here will do the trick: https://github.com/rakudo/rakudo/blob/nom/src/core/Main.pm#L142-L144
19:18 sjn yeah, I was looking at the same lines
19:18 sjn was wondering about why $simple-const was there
19:18 zengargoyle moritz: guess that's Generating Good Parse Errors :P
19:18 sjn japhb: maybe you can tell us? :) ^
19:18 zengargoyle oh, that dt()'ll work nicely i guess.
19:19 Zoffix oh right, it's already raking through .constraint_list
19:19 sjn exactly
19:21 * zengargoyle is still on the fence about checking valid things in the Grammar level, or just letting DateTime complain....
19:21 zengargoyle probably will let DateTime worry about things. :)
19:22 zengargoyle shoulders of giants or somebody else's problem. :P
19:26 Zoffix Oh that stuff's for positionals. The named are here: https://github.com/rakudo/rakudo/blob/nom/src/core/Main.pm#L121-L130
19:27 Zoffix m: -> {}.say
19:27 camelia rakudo-moar c3e3ff: OUTPUT: «->  { #`(Block|61917592) ... }␤»
19:27 Zoffix And `_block` bit, I'm guessing in 2011 ^ that used to have `_block` in it and that piece of code was trying to filter out `where` clauses
19:27 Zoffix And needs updating
19:27 * Zoffix &
19:27 Zoffix left #perl6
19:30 seatek When you add a new module to ecosystem, and your build errors because you screwed up your json, does the add/build process know enough to try again later? ;)
19:34 rindolf joined #perl6
19:50 |oLa| joined #perl6
19:54 TimToady joined #perl6
19:55 jamesaxl joined #perl6
20:06 Zoffix joined #perl6
20:07 Zoffix seatek: yeah. It might take up to 2hrs tho
20:07 Zoffix buggable: eco meta::test
20:07 buggable Zoffix, Nothing found
20:07 Zoffix buggable: eco test::meta
20:07 buggable Zoffix, Test::META 'Test a distributions META file': https://github.com/jonathanstowe/Test-META
20:08 Zoffix seatek: you should use that ^ module to prevent issues like that
20:09 Zoffix buggable: eco
20:09 buggable Zoffix, Out of 849 Ecosystem dists, 0 have warnings, 1 have errors, and 0 have no tags in META file. See https://modules.perl6.org/update.log for details
20:14 Cabanossi joined #perl6
20:14 mr-foobar joined #perl6
20:31 bjz joined #perl6
20:32 seatek Zoffix: yeah i did after it failed again. i just too used to leaving trailing ","'s on everything ;)
20:32 timotimo m: my $foo; $foo.VAR does role :: { has $.a; has $.b; }; $foo = 99; my $a = 0; $a += $foo for ^100; say $foo; say $a
20:32 camelia rakudo-moar edadbe: OUTPUT: «Cannot assign to an immutable value␤  in block <unit> at <tmp> line 1␤␤»
20:32 timotimo m: my $foo; $foo.VAR does role :: { has $.a; has $.b; }; $foo = 99
20:32 camelia rakudo-moar edadbe: OUTPUT: «Cannot assign to an immutable value␤  in block <unit> at <tmp> line 1␤␤»
20:32 timotimo this is a bug, right?
20:32 timotimo i've seen the code that might be responsible for this
20:35 TEttinger joined #perl6
20:41 jcast joined #perl6
20:43 mr-foobar joined #perl6
21:15 aindilis joined #perl6
21:22 kyan joined #perl6
21:22 cdg joined #perl6
21:40 mr-foobar joined #perl6
21:44 Cabanossi joined #perl6
21:50 bjz joined #perl6
22:07 cog__ joined #perl6
22:08 ChoHag joined #perl6
22:13 mr-foobar joined #perl6
22:14 Cabanossi joined #perl6
22:25 kyan joined #perl6
22:26 cog_ joined #perl6
22:32 bjz joined #perl6
22:37 skids joined #perl6
22:39 Lambd0x joined #perl6
22:41 Lambd0x Hi there. I need help to get GTK-Simple module installed wioth zef. It's been failing since two days ago. I managed to reduce the errors, but it still fails thought :(
22:43 mr-foobar joined #perl6
22:47 Ven joined #perl6
22:48 timotimo still download trouble? (:
22:48 timotimo :(
22:49 Geth ¦ doc: 37bd0120cd | (Will "Coke" Coleda)++ | doc/Language/variables.pod6
22:49 Geth ¦ doc: clarify meaning
22:49 Geth ¦ doc: review: https://github.com/perl6/doc/commit/37bd0120cd
22:54 Lambd0x timotimo, ye.
22:54 Lambd0x In fact, building problem.
22:55 Lambd0x timotimo, https://pastebin.com/6PzuJJwK
22:56 bjz joined #perl6
22:56 timotimo 501 Protocol scheme 'https' is only supported if IO::Socket::SSL is installed <U
22:58 Lambd0x timotimo, I got it installed :D
22:59 timotimo that's problematic, then
22:59 Lambd0x ye.
23:00 timotimo you can clone the gtk simple repo, throw out the Build.pm (all it does is download stuff) and download all the dlls manually and put them into the target directory
23:02 Lambd0x timotimo, see this
23:02 Lambd0x timotimo, https://pastebin.com/HkyjRCSr
23:03 timotimo well, that's strange
23:03 timotimo did someone change the dlls on there?
23:03 Lambd0x Not that I'm aware of.
23:03 timotimo changed march 24th 2015
23:04 timotimo the libatk on the web server has the sha256 1ff7464eda0c7ec9b87d23a075f7486c13d74c02a3b5d83a267ad091424185d9
23:05 timotimo that's what it expects
23:05 Lambd0x timotimo, What is odd is this: it builds ok for Linux. Maybe that's why the module itself in Perl6 modules is presented as not passed.
23:05 timotimo https://github.com/perl6/gtk-simple/blob/master/Build.pm#L86  -  can you git clone that and put like a $blob[^128].perl.say and a $blob.elems.say in there?
23:05 ugexe https://github.com/perl6/gtk-simple/blob/master/Build.pm#L54 I woud guess its this
23:06 timotimo of course it builds ok on linux, it doesn't need to download any dlls for linux
23:07 ugexe e.g. maybe those hashes were made with different line ending data than before the proc refactor
23:08 Lambd0x timotimo, wait what is for me do once I download this build.pm?
23:08 timotimo no, you have to clone the complete repository
23:09 timotimo then you have to "zef install ." from inside the folder after you made your changes
23:09 Lambd0x ok
23:10 timotimo ugexe: you think we should force_no_encode?
23:11 mr-foobar joined #perl6
23:13 nadim Zoffix: the changed to Data::Dump::Tree are up. I have also added the base class needed to make a UI with folding.
23:14 ugexe i'm seeing if the same hash error happens on 2017.05
23:18 Lambd0x timotimo,
23:18 Lambd0x https://pastebin.com/Paw0vquh I don't see anything
23:20 gdonald joined #perl6
23:21 cdg joined #perl6
23:21 ugexe hmm i cant get openssl installed on windows / 2017.05
23:22 nadim timotimo: my part is done in Daa::Tree::Dumper, I mailed azawawi, let's see when he can integrate it in a curses interface we can call from scripts.
23:23 ugexe `zef look GTK::Simple` will put you in the proper directory. edit the Build.pm file and comment out this line (https://github.com/perl6/gtk-simple/blob/master/Build.pm#L93). then run `zef --debug install .`
23:24 BenGoldberg joined #perl6
23:24 travis-ci joined #perl6
23:24 travis-ci Doc build passed. Will "Coke" Coleda 'clarify meaning'
23:24 travis-ci https://travis-ci.org/perl6/doc/builds/250963904 https://github.com/perl6/doc/compare/5f5d2227d4e8...37bd0120cde1
23:24 travis-ci left #perl6
23:25 Zoffix nadim: cool
23:25 Zoffix buggable: testers f878354a-6183-11e7-89a5-c5f577a92919
23:25 buggable Zoffix, Proc::Q:ver(1.001003) test result PASS. See more at https://temp.perl6.party/buggable/3381928159846521499383507.txt
23:25 Zoffix using it for this dump ^
23:25 nadim timotimo: but you talked about a terminal interface, without curses, that should be trivial
23:25 timotimo Lambd0x: what does your modified Build.pm look like?
23:26 ugexe or copy all of these to the proper location https://gtk-dlls.p6c.org/
23:26 nadim Zoffix: nice to see it used :)
23:26 nadim we need to find a nopaste that takes color
23:27 Lambd0x ugexe, I can, however I've no idea where to place each one yet.
23:29 nadim Zoffix: you can eliminate all those spurious .Str if you want to, as well as all the {3}, @1 and other decoration.
23:29 nadim Zoffix: adding a title is a good idea too
23:33 astj joined #perl6
23:33 nadim Zoffix: https://github.com/nkh/P6-Data-Dump-Tree/blob/master/README.md#display_info--true
23:34 ugexe Lambd0x: if you do `zef look GTK::Simple` you put them inside a subdirectory there of resources\blib\lib\GTK
23:34 Lambd0x Yes
23:35 Lambd0x I've just done it, will see if it works. I've deactivated the checksum
23:38 Lambd0x The module, gets installed.
23:38 Lambd0x But the code then doesn't work with Windows it seems.
23:39 AlexDaniel joined #perl6
23:43 mr-foobar joined #perl6
23:44 Cabanossi joined #perl6
23:44 ugexe https://github.com/perl6/gtk-simple/issues/60 maybe related?
23:47 ugexe maybe installing a more up-to-date GTK would fix it... https://github.com/tschoonj/GTK-for-Windows-Runtime-Environment-Installer/releases/download/2017-06-27/gtk3-runtime-3.22.16-2017-06-27-ts-win64.exe
23:47 Lambd0x No, it's G-LIB-GIO error it's related to GTK+ schemas
23:49 geekosaur hm. does gtk actually get properly installed, or just the dlls put into place? these days you need to run a bunch of setup stuff for e.g. schema registration
23:50 ugexe the dlls are just put into place
23:50 ugexe ...also they would be renamed which causes some dlls to not work anymore
23:51 ugexe which is the case with open ssl
23:51 Lambd0x ugexe, I've installed what you suggested. But no effect.
23:52 geekosaur that could do it too... gtk does a fair amount of dynamic loading of dlls, so they need to be findable by the names they had at build time
23:54 ugexe that could be tested by uninstall GTK::Simple, then running the code that uses GTK::Simple ala `perl6 -Ipath/to/GTK/Simple/base my-script.pl6`
23:54 ugexe by not installing it they wont get renamed
23:56 Lambd0x ok. Will see about.
23:58 cpage__ joined #perl6

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

Perl 6 | Reference Documentation | Rakudo