»ö« Welcome to Perl 6! | perl6.org/ | evalbot usage: 'p6: say 3;' or /msg camelia p6: ... | irclog: irc.perl6.org or colabti.org/irclogger/irclogger_log/perl6 | UTF-8 is our friend! 🦋
Set by Zoffix on 25 July 2018.
leont I suspect it is -_- 00:01
TreyHarris The killing isn't the issue; the inability to suppress backtrace output and exit 0 rather than with an error code is. 00:08
nadim_ there's a ticket already github.com/rakudo/rakudo/issues/2014 00:11
nadim_ and here github.com/rakudo/rakudo/issues/2695 00:20
TreyHarris nadim_: Ah, I see (I came back to this window after coding up a version with traps and handlers in every single scope, and then another one without a MAIN, and then a third one with a unit MAIN, wish I had come back earlier to see ;-) 00:23
nadim_ :) 00:24
I tried catching the exceptios and the signal to no end 00:25
TreyHarris Hm, those tickets... they don't give any workarounds and there aren't any responses, so I guess this isn't solvable. Damn; my project was to switch all my Perl 5 text-munging scripts into Perl 6, but all of them that have indefinite output use this same trick 00:27
Guess line-by-line text-munging remains Perl 5's forte, not Perl 6's. 00:28
TreyHarris Too bad; turns out grammars can be pretty useful for this sort of thing 00:40
leont I'm wondering if a little bit of NativeCall can work around this 00:50
But it sure is ugly :-/ 00:51
TreyHarris From some quick checks, it seems like every "scripting" language I have on-hand deals with this silently--a SIGPIPE handler is installed that exits gracefully. 00:54
Looks to be an interesting sort of marker of what's a "scripting" language and what's not, actually. 00:55
leont That's not because they handle it, but because the default behavior is to kill the process 00:56
This is good for command line tools, and bad for networking applications
perl6 has the other default, which is fine, but appears to lack a way to restore the POSIX behavior. 00:57
What does "No appropriate parametric role variant available for 'NativeCall::Native'" even mean?
TreyHarris Are you sure? Golang's behavior is to do the command-line thing if the SIGPIPE is on stdout or stderr, but to throw an exception on any other file descriptor 00:58
That seems right and doesn't seem bad for networking applications
leont Then it probably ignores the SIGPIPE, and just handles the EPIPE 00:59
TreyHarris I mean, unless you're running as a CGI, which lots of Perl 5 is still doing, but I don't imagine is something you want for new applications
leont Though I think handling this in a signal handler possible (at least on Linux)
TreyHarris leont: right. But since at an OS level you install a handler on a signal basis, not a "signal if following conditions are true", they did install a signal handler even when it ended up doing default behavior 01:00
leont Go's behavior sounds like a sensible default, actually. 01:06
But I don't think nqp offers enough signalling logic to actually implement it. 01:08
ugexe does libuv? docs.libuv.org/en/v1.x/signal.html 01:11
leont moar explicitly sets SIGPIPE to ignore 01:13
leont Ha! 01:17
paste.scsys.co.uk/585019 01:18
TreyHarris There's an old an well-known gotcha with that... the most recent write-up I could find of the issue is here: stackoverflow.com/questions/524658...sub-doesnt
I think the Camel book, back when it was more Unix-specific, actually said you should only set a SIGPIPE handler to ignore, die, or leave it alone and let Perl and the OS deal with it 01:19
leont (actually, that int64 should probably be a long)
Yeah, I can't think of many cases where handling SIGPIPE is useful 01:20
TreyHarris It's a weird one in that it's catchable but ultimately not really handleable since in most cases you're going to get killed again with SIGPIPE while handling SIGPIPE 01:21
leont Yeah, it's probably dying again when flushing or some such 01:22
perryprog Is there a plan to add (better) support for multi-dimension list comprehensions with inter-list dependencies? 01:23
TreyHarris Anyone have a suggestion for a module to use as a model for POD documenting all your classes, methods, properties and arguments? I'm still getting the hang of it--it's lighter-weight than some languages' doc extraction tools I've used before and heavier than others 01:51
There seems to be some DWIMminess about where you can put POD referring to a particular argument or property, too, and I don't totally understand it (though it seems to work fine) 01:52
Ah, that latter part is explained in the POD doc in perl6/doc. I see now; clever. I'd still like to look at a CPAN module that uses all the inline documentation stuff well 01:57
antoniogamiz morning o/ 05:43
antoniogamiz roles is OOP? 06:43
jmerelo We have 147 answers in the survey so far. Less than last year 06:52
I'll leave it running for a while, but I don't think it's going to get many more.
BTW, today is the day, right?
releasable6: status
releasable6 jmerelo, Next release in ≈12 hours. 6 blockers. 258 out of 635 commits logged (⚠ 3 warnings)
jmerelo, Details: gist.github.com/1d27e95764d113c271...7e2fa3da42
jmerelo Or maybe not...
jmerelo Has anyone seen this? metacpan.org/pod/FFI::Platypus It says it could be a bridge to Perl 6 (from perl 5). It's like NativeCall, in reverse. Maybe. 07:12
El_Che mm 07:26
jmerelo El_Che: hey 07:29
jmerelo notable6: Antonio Gámiz writes aboug GSoC19 dev.to/antoniogamiz/gsoc-2019-1k1h 08:19
notable6 jmerelo, Noted!
nadim_ Good morning! 08:30
jmerelo nadim_: hey! 08:31
nadim_ I have noticed, at many occassions, that running test sometimes fail for nothing. Tests pass when re-running them. this happened when running them in parallel or not.
jmerelo nadim_: might be a flapper 08:32
nadim_ I noticed that this happens wuite often when I checkout another branch. Anyone else having the problem?
a flapper?
jmerelo nadim_: yep, a test that sometimes fails, sometimes not.
nadim_: but it also depends on how it fails. There are some unsolved problems somewhere that cause errors when there are lots of tests, for instante. 08:33
nadim_ not in this case, it happens when code changes are made, after the first fail, they always succeed.
here is a message I get: Cannot iterate over a VMNull type object
nadim_ that looks like something from the guts of P6 not my code 08:34
I don't even know what a VMNull is :)
I'd report this but it is not really reproducible, that's why I ask if other have the same problem 08:36
jmerelo nadim_: then it's the second class. Yep, we have that problem. D#1951 08:37
synopsebot_ D#1951 [open]: github.com/perl6/doc/issues/1951 [bug][build][meta] Intermitent problems with some builds
nadim_ Ah! IMHO it could be related to the caching of libraries. I did a very unscientific experiment, when changing branches (when I got many errors) I also removed the lib/.precompiled directory and I didn't get any errors. 08:40
Geth doc: 026349b9f3 | (JJ Merelo)++ | doc/Type/IO/ArgFiles.pod6
Revises for #2827, finds nothing wrong, really
08:54
doc: 602c30e8e8 | (JJ Merelo)++ | doc/Type/IO/ArgFiles.pod6
Some clarifications closes #2827
synopsebot_ Link: doc.perl6.org/type/IO::ArgFiles
jmerelo nadim_: it might, but then it might not. It fails when we run the tests in Travis, for instance... 08:55
nadim_: the (apparently related) Rakudo bug is still open: R#1810
synopsebot_ R#1810 [open]: github.com/rakudo/rakudo/issues/1810 [MoarVM][regression] Recent regression "ctxlexpad needs an MVMContext"
nadim_ I update the first ticket with what I know 09:00
skyte hi 09:24
jmerelo hi, skyte 09:30
skyte I wrote a simple module , how to publish it on perl6 modules 09:34
jmerelo skyte: I assume you don't have a CPAN identity 09:35
skyte: and also that your module is in GitHub. Can we take a look?
skyte I am a fresh , this is my git address github.com/skyter10086/Date-Util 09:37
jmerelo skyte: it would benefit from a few more tests... including the methods of the class 09:38
skyte: you should test date_cmp and date_diff
skyte ok , I will check Test docs. 09:39
jmerelo skyte: also, did you check out DateTime? docs.perl6.org/type/DateTime
skyte: at any rate, publishing in the ecosystem is just a matter of editing a file in the ecosystem repo and asking for a pull request. Check out instructions here: docs.perl6.org/language/modules#Up...ule_to_p6c 09:41
skyte I 've checked Date .docs.perl6.org/type/Date
jmerelo skyte: DateTime does have a cmp operation, for instance: docs.perl6.org/type/DateTime#sub_i...Bcmp%C2%BB and most arithmetic operators.
skyte All right . I will take a look at that . Thank you! 09:42
jmerelo skyte: you're welcome. Good luck!
sena_kun before publishing it, it won't hurt to check if DateTime can't do the same in a line or two, and ad more test coverage. but as an exercise, it doesn't look bad. :)
jmerelo sena_kun++ 09:43
skyte Got it! Thank you all guys! 09:45
Woodi hi #perl6 :) 10:15
nadim_: is it possible to take 'engine' of DDT and use it to display .html files with hierarchically ? 10:16
pmurias jmerelo: where should I send grammar nitpicks in the GSoC blog post? 11:24
yoleaux 19 Jun 2019 09:54Z <nine> pmurias: In general we hold the top level script/program or even it's caller responsible for setting up the required repository chain. A "use lib" in a script doesn't hurt.
jmerelo pmurias: of course, right there. 11:25
pmurias: you mean the one that was published by antoniogamiz? 11:26
pmurias jmerelo: yes, you mean in the comments?
jmerelo pmurias: wait, you mean English grammar, right? I was about to point you to the github repo, but I guess you don't mean that :-)
pmurias: yep, in the comments might be a good place. He's around here from time to time also, but just went out... 11:27
pmurias: also Twitter: @antonio_d_luffy
pmurias jmerelo: re past discussion about exercises in courses I think they have a ton of value for well motivated people just starting out programming 11:31
jmerelo: as opposed to more experienced just skimming through the tutorial 11:32
jmerelo pmurias: that's still a book. With exercises. 11:44
pmurias: if there's no correction, grading or feedback it's not actually a course. 11:45
pmurias: the value comes from accepting the challenge, but also someone telling you if the solution fulfills the pedagogic objectives that the exercise is related to. 11:47
nadim_ Woodi: DDT generates HTML, there's a role for that 11:58
nadim_ Woodi: hmm, after a reread I am not sure anymore about what you want to do, can you give me a better description? 12:02
AlexDaniel notable6: weekly Antonio Gámiz writes aboug GSoC19 dev.to/antoniogamiz/gsoc-2019-1k1h 12:13
notable6 AlexDaniel, Noted!
AlexDaniel gah I'll try to fix notable6 asap :)
Geth doc: bb093dd439 | Coke++ | doc/Language/system.pod6
pass finicky links test
13:17
doc: c057c2362d | Coke++ | doc/Type/Metamodel/MROBasedMethodDispatch.pod6
Add 'method', fixes compilation error
doc: 77e94152b5 | Coke++ | doc/Type/Proc/Async.pod6
allow code to compile
synopsebot_ Link: doc.perl6.org/language/system
Link: doc.perl6.org/type/Metamodel::MROB...odDispatch
Link: doc.perl6.org/type/Proc::Async
pmurias gist.github.com/pmurias/4b34add3cf...6fc7bc96fd - example of using a node.js module in rakudo.js 13:29
pmurias does a scheme where at compile time stubs a created for node.js modules that will get required at compile time seem sane? 13:59
s/a/are/
Woodi nadim_: I would like to give .html file as input and get colored hierarchies like in examples you posted ~2 days ago... 15:02
Geth doc: 612fcacea0 | (JJ Merelo)++ | doc/Language/functions.pod6
Adds index, and also add examples. Closes #2835
15:31
synopsebot_ Link: doc.perl6.org/language/functions
El_Che 1080p is a lot louder 15:34
AlexDaniel weekly: www.youtube.com/watch?v=Q_oM27VJ1mo (alien sounds stop at 10 minute mark) 15:37
notable6 AlexDaniel, Noted!
El_Che AlexDaniel: indeed 15:39
that's a lot nice
r
perlbot El_Che: No output.
El_Che r: shut up
perlbot El_Che: 5===SORRY!5=== Error while compiling /tmp/gQvfJGmbKE␤Undeclared routines:␤ shut used at line 1␤ up used at line 1. Did you mean 'uc'?␤␤[Exited 1] 15:40
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routines:
shut used at line 1
up used at line 1. Did you mean 'uc'?
5===SORRY!5=== Error while compiling <tmp>
Undeclared routines:
shut used at line 1
up used at line 1. Did you mean 'uc'?
Kaiepi releasable6, status 15:42
releasable6 Kaiepi, Next release in ≈3 hours. 6 blockers. 258 out of 638 commits logged (⚠ 3 warnings)
Kaiepi, Details: gist.github.com/d63577c482887f6277...446bbc2e46
Kaiepi >6 blockers
damn
Kaiepi i was hoping the release would be ready for the weekend since i'm starting my grant work either today or tomorrow and won't have time to improve the openbsd ports for moar/nqp/rakudo outside of weekends 15:44
jmerelo AlexDaniel: ^^^ how's the release going? 15:48
kawaii Still a number of blockers due to the Blin results jmerelo 15:50
All were bisected so hopefully not too long 15:51
antoniogamiz these lines in htmlify.p6 are duplicated github.com/perl6/doc/blob/612fcace...fy.p6#L330 15:53
AlexDaniel I'll be able to work on it full time starting from tomorrow or so, but meanwhile you all can help :)
antoniogamiz: indeed, weird
AlexDaniel antoniogamiz: it was added in this commit: github.com/perl6/doc/commit/9484ff...0e5ae22927 15:55
antoniogamiz: looks like a mistake to me, feel free to remove it
antoniogamiz AlexDaniel: ok :)
Geth doc: 26236dff03 | Antonio++ (committed using GitHub Web editor) | htmlify.p6
deletes duplicated code
15:56
nadim_ Woodi: can you give me the link you posted? so far I have no idea of how things should look like. 16:15
is it a rendering of a DOM tree?
Geth ¦ problem-solving: AlexDaniel self-assigned Moving tickets between rakudo and problem-solving repos is impossible github.com/perl6/problem-solving/issues/46 16:22
jmerelo antoniogamiz: yep, roles is pretty much OOP. Not the OOP they say they teach in your school, but real OOP 16:23
Woodi nadim_: o, looks timotimo++ posted that screenshots: distracted-gates-4eb889.netlify.com/ 16:24
jmerelo antoniogamiz: please open an issue with the duplicated lines in htmlify.p6
antoniogamiz I have already deleteh them 16:25
Should I do it anyway?
antoniogamiz deleted* 16:25
Woodi nadim_: I mean html>body>p><div>... hierarchies coloring...
jmerelo antoniogamiz: yep, it's always convenient to open issues even if you're going to do the work inmediately. It helps everyone else keep track of the motives.
antoniogamiz ok, I will do it then :) 16:26
nadim_ Woodi: I posted that link :) 16:29
Woodi: do you have something to parse your HTML with already? 16:30
AlexDaniel fwiw Gumbo is currently better than ever 16:32
the segfault was recently fixed, and the module is also much faster now compared to a year ago or so
wamba my @male;my @female;@female = 1, {++$ - @male[$_] } ... *;@male = 0, {++$ - @female[$_]} ... *;say @male.head(31);say @female.head(31) 16:41
evalable6 (0 0 1 2 2 3 4 4 5 6 6 7 7 8 9 9 10 11 11 12 12 13 14 14 15 16 16 17 17 18 19)
(1 1 2 2 3 3 4 5 5 6 6 7 8 8 9 9 10 11 11 12 13 13 14 14 15 16 16 17 17 18 19)
Woodi nadim_: nothing yet. I wonder how to do such thing 16:42
nadim_ Woodi: find a HTML parser on cpan, or convert your html to json. once you have a data structure, once you have that you can render it with DDT. You'll need a filter per type in your data structure but that's easy. 17:10
Woodi nadim_: that probably will do. but I imagined some general "colourer" for hierarchical data... but will try that first 17:38
nadim_ Woodi: that's what DDT does! 17:46
the link you reposted is a hierarchical data rendered by DDT 17:47
moritz isn't DDT some kind of pestozid? :D
nadim_ if you mean Basil pesto, then maybe ;) 17:50
nadim_ m: 'abcd'.cob: 2 18:43
camelia No such method 'cob' for invocant of type 'Str'. Did you mean any of these?
comb
cos

in block <unit> at <tmp> line 1
nadim_ m: 'abcd'.comb: 2
camelia ( no output )
nadim_ m: dd 'abcd'.comb: 2
camelia ("ab", "cd").Seq
nadim_ m: dd 'abcd'.comb: 'x'
camelia ().Seq
nadim_ m: dd 'abcd'.comb: 0 18:44
camelia ("a", "b", "c", "d").Seq
nadim_ m: dd 'abcd'.comb: -1
camelia ("a", "b", "c", "d").Seq
nadim_ m: dd 'abcd'.comb: Inf
camelia Cannot resolve caller comb(Str:D: Num:D); none of these signatures match:
(Str:D: *%_ --> Seq:D)
(Str:D: Int:D $size is copy, $limit = *, *%_ --> Seq:D)
(Str:D: Str $pat, *%_ --> Seq:D)
(Str:D: Str $pat, $limit, *%_ --> Seq:D)…
nadim_ m: dd 'abcd'.comb: Na
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared name:
Na used at line 1
nadim_ m: dd 'abcd'.comb: NaN
camelia Cannot resolve caller comb(Str:D: Num:D); none of these signatures match:
(Str:D: *%_ --> Seq:D)
(Str:D: Int:D $size is copy, $limit = *, *%_ --> Seq:D)
(Str:D: Str $pat, *%_ --> Seq:D)
(Str:D: Str $pat, $limit, *%_ --> Seq:D)…
nadim_ comb can be called with -1, 0, 'x' but not Inf, nor NaN, shouldnt it handle them? 18:45
tobs nadim_: what do you imagine it doing for NaN? 18:51
ugexe or Inf for that matter 18:58
what is the first digit of Inf?
oops wrong argument
tobs Inf would blend in well with the explanation of "Int argument is like /. ** {1..$arg}/", i.e. return everything, like a "sufficiently large number" 19:00
nadim_ IMHO, Inf should return the whole string 19:03
ugexe i was thinking you meant Inf.comb, not "...".comb(Inf)
nadim_ as for NaN, what's the differentwith "hello Dolly"?
ugexe: ah, no I meant .comb(Inf)
ugexe m: say Inf.comb 19:04
camelia (I n f)
nadim_ lol!
tobs nadim_: comb has a candidate for strings.
nadim_ I see them in the error message
tobs I meant: it turns the string into a regex that it combs for. To me that's sensible and expected. I don't know what I would expect for a NaN 19:08
nadim_ true 19:10
Inf could still return the whole string though 19:11
Woodi nadim_: I thinked DDT takes Perl6 internal data format... 19:14
nadim_ Woodi: it does 19:15
nadim_ Is there a HTML parser somewhere? 19:45
MasterDuke nadim_: Gumbo 19:46
nadim_ MasterDuke:++ 19:48
Woodi: here's a google's index rendered by ddt via Gumbo zealous-dijkstra-8778e9.netlify.com/ 20:07
you'll need to pre process Gumbo's parsing result to get back the HTML elements from the XML::Element 20:09
nadim_ MasterDuke: do you know any Perl6 HTML parser, one that returns a Match. 20:20
timotimo is there a Dom::Tiny or so? 20:20
MasterDuke nadim_: don't know 20:23
modules.perl6.org/dist/DOM::Tiny:cpan:HANENKAMP 20:26
cpan-p6 New module released to CPAN! ProcStats (0.1.2) by 03LEMBARK
New module released to CPAN! ProcStats (0.0.3) by 03LEMBARK
New module released to CPAN! ProcStats (0.0.2) by 03LEMBARK
Kaiepi ===SORRY!=== 20:44
finish_code_object
???
evalable6 Stub code executed
in block <unit> at /tmp/yjHR2Lf_yi line 1
Kaiepi shut up evalable6
masak no, that was funny :) 20:47
AlexDaniel Kaiepi: where's that? 20:52
AlexDaniel Kaiepi: any golf for that weird thing? 20:52
Kaiepi it happens on my freebsd vps when i try to install Cro::WebSocket
Kaiepi i'd have no clue where to begin to golf it 20:52
AlexDaniel Kaiepi: can you try removing precomp files first? 21:00
who knows…
I've seen some really weird errors that magically go away 21:01
guifa So let’s say you did this 21:04
p6: say "abcabcabc".match(/ab/):g.Str
camelia ab ab ab
guifa That takes the main match object and stringifies. But let’s say I wanted to stringify each of the sub matches 21:05
p6: say "abcabcabc".match(/ab/):g».Str
camelia 5===SORRY!5=== Error while compiling <tmp>
Missing « or »
at <tmp>:1
------> 3say "abcabcabc".match(/ab/):g».7⏏5Str
guifa the hyper operator doesn’t seem to work on account of the adverb. 21:06
(yes I know I can just say .match(/ab/,:g) but this is for code golf ;-) )
Kaiepi AlexDaniel, deleting precomp files fixed it 21:08
i just updated from a pretty old version of perl 6
nadim_ Who's the kng of profiling, apart lizmat? DDT is a slug, rendering a 1000 lines Dom::Tiny parsed data was 150 times slower than dd! before I start rendering part in parallel I'd like to speed up things first. 21:27
where do I start?
xinming_ releasable6: status
releasable6 xinming_, Next release will happen when it's ready. 6 blockers. 258 out of 638 commits logged (⚠ 3 warnings)
xinming_, Details: gist.github.com/7edf07402f4deb8759...1ed4d8897b
AlexDaniel nadim_: timotimo? :) 21:28
MasterDuke:
nadim_ AlexDaniel: sound like a good idea and he uses DDT
.tell timotimo hi, if you have 5 min could you point at where this DDT speed demon spends 10 secs to generate 1000 line (dd is 150 times faster), gist.github.com/nkh/f8d41e0748c325...b0f24f142. install the latest 21:37
yoleaux nadim_: I'll pass your message to timotimo.
nadim_ mehhh! MoarVM panic: Internal error: zeroed target thread ID in work pass. when runnning a test with --profile. shall I report this? 21:43
AlexDaniel nadim_: yeees 21:44
nadim_ well, I though "let's run it again, for science" I got a rendering ... and a segfault! 22:01
nadim_ github.com/rakudo/rakudo/issues/3006 22:12
MasterDuke nadim_: looks like the most expensive function is sprintf 22:39
MasterDuke then Bool on Matches 22:42