Perl 6 - the future is here, just unevenly distributed

IRC log for #perl6, 2016-11-18

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:09 atweiden-air m: https://gist.github.com/anonymous/9c7bd705b83be9610b8660643da6ee01
00:09 camelia rakudo-moar 53d7b7: OUTPUT«[DEBUG] $leading-whitespace: 2␤[DEBUG] $leading-whitespace: 5␤[DEBUG] $leading-whitespace: 8␤True␤»
00:10 samcv how can I get grammars to return multiple matches?
00:10 atweiden-air why is the $leading-whitespace variable additive?
00:11 atweiden-air i was thinking it may have something to do with $/
00:11 timotimo atweiden-air: it could be related to backtracking
00:12 atweiden-air i thought regex backtracked but not token
00:12 timotimo oh, i didn't realize
00:12 samcv yeah tokens don't backtrack
00:12 timotimo i'm not exactly sure when the assignment to a :my happens, maybe it's too early?
00:13 silug joined #perl6
00:13 timotimo oh, hah
00:13 timotimo yeah, $/<leading-whitespace> gets a list in it
00:13 timotimo because you're [ ]*-ing it
00:13 timotimo it'd probably be easier to have it in a separate token so you get a guaranteed fresh $/ for each line
00:14 atweiden-air ok, will try that
00:15 samcv https://gist.github.com/samcv/7c1fc86a742880a8234c208c642a0ea8 how can I make this find multiple matches?
00:15 samcv it's only returning the last match
00:16 sufrostico joined #perl6
00:17 atweiden-air samcv: do you want the Matches, or do you want to build an AST
00:17 AlexDaniel samcv: you asked for one url, you got one url
00:17 timotimo yeah, you're matching any amount of shit, then a <url>, then any amount of shit
00:18 timotimo you may want to use a regular regex match for url instead of trying to parse the whole string with your grammar
00:18 timotimo that'll give you things like "exhaustive" matching
00:18 timotimo or you can .comb it
00:18 samcv ah ok
00:18 samcv comb could be good, good suggestion
00:18 AlexDaniel you can also try something funny like <url> %% [.*?]
00:19 AlexDaniel <url>+ I mean
00:20 samcv ah AlexDaniel that works great
00:21 AlexDaniel though you should try throwing some large piece of text into it to see if it actually works great
00:21 samcv yeah that's what i'm going to do. and also benchmark it and try and find the fastest way to do it
00:21 samcv comb may work faster
00:21 AlexDaniel definitely
00:22 AlexDaniel and it's probably better
00:22 AlexDaniel (just comb me all urls out of it!)
00:24 sufrostico joined #perl6
00:26 AlexDaniel left one reminds me of Camelia http://imgur.com/Ggn2kCu
00:30 Actualeyes joined #perl6
00:39 sufrostico joined #perl6
00:39 pierre_ joined #perl6
00:40 pierre_ joined #perl6
00:43 cooper_ joined #perl6
00:53 kyclark joined #perl6
01:15 aborazmeh joined #perl6
01:15 aborazmeh joined #perl6
02:02 nadim joined #perl6
02:11 BenGoldberg joined #perl6
02:14 xtt joined #perl6
02:23 pierre_ joined #perl6
02:47 ilbot3 joined #perl6
02:47 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!
02:55 pierre_ joined #perl6
02:59 canopus joined #perl6
03:10 djbkd joined #perl6
03:22 kyclark joined #perl6
03:24 araujo joined #perl6
03:24 cooper_ joined #perl6
03:24 cooper_ joined #perl6
03:34 samcv is there a way to negate a regex match? my regex term { <allowed>+ <-sp - protected> }
03:35 samcv but that does not work
03:35 samcv there's a regex named protected btw
03:36 sQuEE joined #perl6
03:37 samcv err i guess it should be -ws
03:38 samcv my regex term { <allowed>+ <-ws -protected> } this does not work though
03:38 noganex joined #perl6
03:38 samcv is there a special way to define character classes as opposed to regexes?
03:38 samcv maybe it's because protected is a token and not of the correct type?
03:38 geekosaur that question sounds wrong
03:39 geekosaur if you want "don't match this regex", a negated charclass is not the way to do it
03:39 geekosaur unless the regex itself is a charclass and nothing else (and even then I don't think you can say it that way?)
03:39 samcv well the protected regex is just a character class
03:39 samcv yeah that's what it is
03:40 pierre_ joined #perl6
03:40 samcv either some way to define my own charclasses or just negate a regex should work, just 'don't match this'
03:41 timotimo does anybody want to implement boyer-moore substring finding in MoarVM?
03:51 mayathecat joined #perl6
04:03 AlexDaniel samcv: what about <!before … > ?
04:03 mayathecat joined #perl6
04:04 timotimo normally boyer moore is implemented in terms of 8bit characters
04:05 timotimo for the needle, that is
04:05 timotimo we normally have signed 32bit graphemes for our strings ...
04:05 timotimo so ideally the table for the skips would be made sparse
04:06 timotimo potentially a sorted list of graphemes that occur in the needle string
04:06 timotimo thankfully the size of that table is then at most the number of graphemes in the needle string
04:07 timotimo and since it's sorted, binary search can be employed
04:14 samcv AlexDaniel, my regex term { <allowed>+ <!after <protected>> } this works :)
04:14 samcv awesome
04:18 imcsk8 joined #perl6
04:21 dextertzu joined #perl6
04:23 pierre_ joined #perl6
04:38 khw joined #perl6
04:46 labster joined #perl6
04:48 pierre_ joined #perl6
05:00 garu joined #perl6
05:05 mst joined #perl6
05:20 Cabanossi joined #perl6
05:30 xtt joined #perl6
05:35 samcv ok well I created a module, your guys input is requested https://github.com/samcv/URL-Find/
05:35 samcv if anything should be tweaked
05:36 brillenfux joined #perl6
05:38 brillenfux_ joined #perl6
05:44 seatek oh that's a neat way to use the grammar-y stuff, samcv - wouldn't have thought to do that!
05:44 samcv :)
05:47 samcv later i might add more functions for like only grabbing the base url or the suffix, but so far seems pretty good with everything i've tested it with
05:48 samcv 95% sure no url's should use any of the reserved characters like & % for the last thing in the url
05:48 psch ? can be valid as last character, can't it?
05:49 pierre_ joined #perl6
05:49 psch (also you might be missing a few protocols, not sure if an exhaustive list is the right approach there)
05:50 psch like, file://, telnet://, mailto:// exist
05:50 samcv well psch after the ? you pass query strings, but if it ends in ?
05:50 samcv then that doesn't give any data
05:50 psch right, but it's useful on some websites to prevent server-side caching
05:50 samcv so it's probably somebody just doing https://google.com/thing?
05:50 samcv hmm
05:51 psch i think i saw it the most on imgur.com, where a given direct link to a picture wouldn't load without the ? at the end but would with it
05:52 samcv i could have a find-uris to find any uri and not just URL's
05:52 samcv but URL's are locations on the internet
05:52 samcv err Web
05:52 samcv since internet and web are different things
05:53 psch right, so file:// and mailto:// wouldn't belong
05:53 samcv yeah
05:54 samcv they're uri's so could have something to find all URI's maybe just anything that's ascii:// or something, would have to check the rules for generic URI's because i think they're different from url's
05:54 psch "Examples of popular schemes include http, ftp, mailto, file, data, and irc." says wikipedia though vOv
05:54 psch https://en.wikipedia.org/wiki/Uniform_Resource_Locator#Syntax
05:55 psch honestly, whatever satisfies your needs :)
05:55 samcv i could expand it though. seems like ftp https and http should be a little seperate though
05:56 samcv still not sure about the ? at the end. but it may be a special case where it does something differently
05:56 samcv since it's the query and i guess blank query must have some meaning
05:56 samcv psch, those are all fair things though that need to be considered
05:59 seatek Somebody should annotate this page with a warning about using EVAL in a loop https://docs.perl6.org/routine/EVAL -- how it will consume memory and that it's a known bug from forever, and to consider using Callable instead
06:00 seatek I can't find it to edit it ;)
06:00 wtw joined #perl6
06:02 psch seatek: https://github.com/perl6/doc/blob/master/doc/Type/Cool.pod6#L1208
06:03 brillenfux_ joined #perl6
06:03 seatek oo thanks psch !
06:07 wtw_ joined #perl6
06:09 dalek doc: ecd6226 | seatek++ | doc/Type/Cool.pod6:
06:09 dalek doc: warn the unsuspecting of EVAL atrocities.
06:09 synopsebot6 Link: http://doc.perl6.org/type/Cool
06:09 dalek doc: review: https://github.com/perl6/doc/commit/ecd6226832
06:09 seatek i figure that any bug that's been in the language for more than 5 years should be a documented "feature"
06:10 brillenfux__ joined #perl6
06:14 moritz it's not been in the language for that long, it's been in the compiler
06:14 moritz which is a kinda important distinction here
06:14 seatek not to any user
06:15 moritz though if it makes you happy, I'm not opposed to having links to known bug tickets in there, as long as somebody maintains them
06:15 moritz that is, removes them when closed
06:15 moritz even better would be have an "affects" field in RT, and then a possibility to dynamically list all the bugs that affect a certain function
06:15 seatek i'll be watching this one as long as i use perl -- it effects everyone using Crust stuff who tries using it in the way it's documented to be used
06:17 psch clearly we need to revive niecza /o\
06:17 moritz psch: please do!
06:18 psch i don't feel qualified, honestly :)
06:18 psch it would help with exactly this kind of misconception though, i suppose
06:18 seatek i'll gather the neighborhood cats and fruit offerings!
06:18 seatek yes
06:18 seatek yes it would
06:19 seatek there is no distinction except internally here
06:20 seatek i'm going to work on the documentation for Crust to offer Callables as an alternative in the meantime
06:21 psch hm, actually i wonder how CoreCLR is doing
06:22 seatek i so wish i knew enough to help out down in the machine room. maybe one day
06:23 psch seatek: well, it's mostly a matter of looking at tickets and then looking at source code
06:23 psch i didn't have any idea of compiler development before starting to contribute to rakudo
06:23 psch (i'm preetty sure that still shows sometimes though :) )
06:24 seatek ha! i've never even come close to compiler work before
06:24 ChoHag joined #perl6
06:24 domidumont joined #perl6
06:24 seatek you know tons. i'm still trying to get used to the basics!
06:25 seatek i can certainly imagine why people would not want to tackle memory leak problems
06:25 psch well, my first commit was on Jan 18 2014 so i did spend some time with the language and compiler :P
06:25 seatek yeah :)
06:25 psch note though that there's clearly people around that spent a lot more time with it
06:28 dalek doc: 50d6647 | gfldex++ | doc/Type/Cool.pod6:
06:28 synopsebot6 Link: http://doc.perl6.org/type/Cool
06:28 dalek doc: Revert "warn the unsuspecting of EVAL atrocities."
06:28 dalek doc:
06:28 dalek doc: This reverts commit ecd622683229423f557962933bc86952b70ecf6a.
06:28 dalek doc:
06:28 dalek doc: We do not warn about bugs in the docs. There are a way to many to add
06:28 dalek doc: them all, there is no sane way to decide what bug to pick and any bug is
06:28 dalek doc: an implementation detail. We do not doc implementation details in
06:28 dalek doc: general.
06:28 dalek doc: review: https://github.com/perl6/doc/commit/50d6647aee
06:28 darutoko joined #perl6
06:31 seatek I wasted almost 2 days of work trying to isolate what was going on -- and it was that bug. That isn't just a silly bug. That is a subtle bug, and it has a very wide scope.
06:32 brillenfux_ joined #perl6
06:33 pierre_ joined #perl6
06:35 gfldex seatek: the quality of the bug does not change the fact that it is an implementation detail. Also, there are at least 40 more subtle bugs. When are you going to add them too?
06:35 gfldex seatek: And you will have to watch RT and update the docs whenever a bug you added was fixed.
06:35 seatek I try to help people whenever I can. To me, that is more important.
06:36 seatek That bug is big, and it's been around for many years. It's not going anywhere any time soon most probably.
06:37 gfldex how do you know?
06:38 seatek It's a feature of the language
06:38 seatek Even if it's not ;)
06:38 seatek we tested it together
06:38 seatek it's been around for years
06:39 seatek everyone who uses Crust in the documented way will experience it
06:39 seatek and that's just one
06:39 psch seatek: the docs document roast, not rakudo
06:39 gfldex then you should send an PR with a workaround to crust
06:39 seatek it gets slower and slower and eats up more and more memory -- unless you use callables instead
06:40 seatek yes i intend to as soon as i work out a nice neat way to handle it... which i've almost got just right
06:42 dalek ecosystem: cc67a3e | (Samantha McVey)++ | META.list:
06:42 dalek ecosystem: Add URL::Find module
06:42 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/cc67a3e2dc
06:42 dalek ecosystem: 71e44e4 | RabidGravy++ | META.list:
06:42 dalek ecosystem: Merge pull request #267 from samcv/master
06:42 dalek ecosystem:
06:42 dalek ecosystem: Add URL::Find module
06:42 dalek ecosystem: review: https://github.com/perl6/ecosystem/commit/71e44e4634
06:43 seatek i think the documentation should link to related bugs
06:43 seatek i'd be happy to work on something like that, that will automate it
06:43 seatek ugh add to the stack
06:44 seatek EVAL would pull up a huge list
06:46 seatek it kinda bugs me using EVAL anyway for this stuff. or even callables. roles make so much more sense.
06:46 seatek probably nobody uses tags in RT
06:48 gfldex seatek: we do: https://rt.perl.org/Public/Search/Simple.html?q=perl6+%5Bconc%5D
06:49 seatek those are RT queues though aren't they?
06:50 psch no, we have only one perl6 queue
06:50 seatek ah ok nice :)
06:50 seatek yeah how about i use Crust for that with an EVAL
06:51 RabidGravy joined #perl6
06:51 seatek no i will look at that later
06:55 seatek gfldex: since you deleted the warning to others about EVAL, it falls on you to fix the EVAL bug. otherwise all the days of suffering others experience as a result will all your fault. even if they didn't bother to check any documentation. or even used EVAL. ;)
06:56 xtt Does anyone know if perl6 currently provide raw socket? I want to construct an icmp message but I can't find API
06:57 domidumont joined #perl6
07:01 domidumont joined #perl6
07:03 ufobat joined #perl6
07:04 domidumont joined #perl6
07:07 abraxxa joined #perl6
07:12 RabidGravy xtt, I think there's a module for it
07:12 neuraload joined #perl6
07:12 RabidGravy or I thought there was, I can't find it anymore
07:13 xtt oh sad
07:15 xtt RabidGravy Seems the doc does not explain how to construct that https://docs.perl6.org/type/IO::Socket::INET
07:15 seatek gfldex: ok finally got Crust working ok with callables and still being able to use their middlware. It does eliminate the memory problems, and the performance is about 300% better.
07:15 RabidGravy yes, because that only makes TCP sockets
07:15 domidumont joined #perl6
07:16 xtt :RabidGravy I thought since they have tcp api, raw_sock seems to be available somewhere
07:17 pierre_ joined #perl6
07:17 RabidGravy well IO::Socket::Async handles UDP as well, but no support currently for other packet types currently
07:18 RabidGravy you could look at  https://github.com/tokuhirom/p6-Raw-Socket (which is what I was thinking of,) and see if that can be made to do what you want
07:19 RabidGravy it appears that tokuhirom removed it from the modules list when the UDP support in IO::Socket::Async came along
07:20 silug joined #perl6
07:23 RabidGravy anyway off to the grindstone, have fun
07:24 pierre_ joined #perl6
07:27 firstdayonthejob joined #perl6
07:27 xtt RabidGravy thanks for this repo!
07:30 cpage_ joined #perl6
07:38 pierre_ joined #perl6
07:41 wamba joined #perl6
07:46 Xliff No MSIs for latest rakudo release?
07:48 Xliff *snarl* -- and 2016.7 MSI only installs to C: -- getting tight on the SSD.
07:54 xinming joined #perl6
07:56 imcsk8 joined #perl6
07:58 pierre_ joined #perl6
08:03 labster joined #perl6
08:03 seatek Xliff: somebody said he was going to make MSI's for Windows either last weekend or this weekend. So hopefully this weekend
08:10 Xliff seatek++: Thanks for the update.
08:10 Xliff WOOOO HOOOOO!
08:10 * Xliff does silly dance.
08:11 Xliff Just got to major milestone in this silly project I am working on.
08:11 Xliff Using silly OAuth authentication flow.
08:11 Xliff s/OAuth/"OAuth2"/
08:11 Xliff (scare quotes required)
08:12 Xliff Doing everything in the flow with a script. No browser. No webserver.
08:12 Xliff And I'm.... al... most.... THERE.
08:12 * Xliff does another silly dance.
08:12 seatek :)
08:13 Xliff Of course all of this is in an extremely cluttered test script.
08:14 Xliff Breaking it up into reusable parts will be tricky.
08:14 seatek the pain and the glory ;)
08:16 Xliff Yeah. This process is critical to the Webservice API I am trying to hook into.
08:16 Xliff I haven't even started with the applications, yet!
08:16 Xliff /o\
08:17 Xliff http://eveonline-third-party-documentation.readthedocs.io/en/latest/crest/index.html
08:17 seatek Just don't use any EVALs!
08:17 Xliff It's taken me a week and I have only gotten through the SSO!
08:17 * Xliff glares at seatek.
08:18 Xliff Dood would have to be desperate or insane to use any MONKEYS
08:18 seatek that looks nice and design'y
08:18 Xliff Of course, I could be pushed to be both.
08:18 Xliff Long way from that, tho
08:18 seatek yeah i don't like evals at all either
08:18 Xliff (And if you believe that, I have a bridge to sell you up north...)
08:19 * Xliff flees
08:20 seatek eve online stuff eh? that's funny. i was looking at json for wow addons the other day here. i think there must be a theme happening in perl here..
08:24 xinming joined #perl6
08:25 Xliff You're imagining it.
08:25 Xliff ;)
08:26 seatek i'm always doing that ;)
08:35 zakharyas joined #perl6
08:44 pierre__ joined #perl6
08:44 dextertzu joined #perl6
08:46 mtj_ joined #perl6
08:46 risou___ joined #perl6
08:49 petercommand joined #perl6
08:54 kurahaupo__ joined #perl6
09:00 labster joined #perl6
09:08 pmurias joined #perl6
09:08 pmurias seatek: what is Crust using EVAL for?
09:10 seatek reading in people's .p6sgi files -- the basis of their apps
09:11 pmurias shouldn't it only happen when the .p6sgi file changes?
09:11 seatek i just submitted a pull request to the Crust maintainer updating the readme.md file with info on how to use a callable instead
09:11 seatek one would think so!
09:12 seatek but using the callable make the memory leak stop... and increases performance by about 300%
09:12 seatek (in the case of middleware using sessions)
09:12 pierre_ joined #perl6
09:14 nadim joined #perl6
09:14 pmurias seatek: weird, the Crust source looks like it should be only calling EVAL once per Crust::Runner.run
09:15 g4 joined #perl6
09:15 g4 joined #perl6
09:16 seatek yes -- i didn't understand it either.. but if you pass a callable directly in there, where it's pulling in the source from whatever source, the memory leak disappears
09:17 seatek it's like the fact that it was eval'ed tainted it somehow
09:17 seatek which makes me crazy
09:20 seatek the odd thing too is that this EVAL bug uses up more memory, then seems to taper off.... ;)
09:20 rindolf joined #perl6
09:21 seatek pmurias: gfldex knows more about it than me i'm sure
09:21 gfldex i don't. I do however know where the search button on RT is.
09:22 seatek you did some test here that demonstrated it succinctly... if i'm remembering right
09:24 seatek it's much more pleasant using a Callable anyway. if such craziness can be pleasant. it needs a Role overhaul
09:26 DrForr I do something simpler with Prancer, IIRC.
09:26 Ulti joined #perl6
09:26 seatek DrForr: i need to check that out. are you still doing stuff with it, or has it been abandoned?
09:27 DrForr Not abandoned, just need to finish what's piled up before it.
09:27 seatek pmurias: one thing too -- the memory leak is GREATLY exacerbated if you use middlware with your call
09:27 seatek i know the feeling :(
09:28 seatek thinking i might be able to get back to my actual work tomorrow. :)
09:28 FROGGS joined #perl6
09:37 neuraload joined #perl6
09:40 ocbtec joined #perl6
09:46 labster joined #perl6
09:47 cognominal joined #perl6
09:50 Xliff And that's the bearer token done. SSO flow completed!
09:50 Xliff And now I crash.
09:50 seatek ;) happy temporary oblivion
09:52 tadzik ooh
09:52 tadzik C# 7.0 new features feels perl6-y :)
09:53 tadzik switch (shape) { case Rectangle s when (s.Length == s.Height): ... }
09:53 * stmuk_ fights perl5 carton
09:54 tadzik I like carton
09:54 tadzik what problems do you have with it?
10:00 stmuk_ just a large number of nasty deps .. it does work better than I expected for the task
10:00 stmuk_ not quite as deterministic as I would expect either
10:07 FROGGS mst: [OT] is there a IRC channel where I could post a Perl 5 job offer in Germany?
10:07 DrForr #perl.de on irc.perl.org? Maybe #perl_de or #perlde
10:08 FROGGS DrForr++ # #perlde exists
10:13 pierre_ joined #perl6
10:13 seatek pmurias: here's an example of how the EVAL leak can easily happen unexpectedly, too. Though of course it's expected with the .new being inside the loop, it could be very easily occluded somewhere. but i haven't been able to find any evidence of "taint", like it seemed, after minimal trying. https://gist.github.com/adaptiveoptics/4aee4f9c530b160af9b89915ee9bfebe
10:17 labster joined #perl6
10:21 seatek That little bit just ate up 14G on my system in a matter of a couple minutes.
10:24 jnthn seatek: What Rakudo version are you using, ooc?
10:24 seatek the latest production one... no test one
10:24 jnthn Am running that snippet here for a couple of minutes.
10:25 seatek 2016.10-48-gaaec517
10:26 jnthn Odd, here it reached a platteau after some seconds and hasn't grown since.
10:26 seatek it's saying, yum yum
10:26 seatek interesting
10:26 jnthn This is Rakudo version 2016.10-285-gee8ae92 built on MoarVM version 2016.10-50-g37d3be7
10:26 jnthn implementing Perl 6.c.
10:26 jnthn Is what I have.
10:27 seatek maybe it is better equipped to handle danger
10:27 jnthn Maybe...though the last EVAL leak fix I remember doing was all the way back in September
10:28 seatek this ticket was still open...  thank you jnthn for working on those. these are the big scary things to me
10:28 seatek i wish i knew enough to
10:28 seatek i'll work on that eventually
10:30 jnthn Well, there's two ways things can leak. Either a "real leak" (where the VM itself loses track of the memory and leaks it), which can be found with Valgrind, or where the VM itself is in control of the memory but doesn't release it for far too long. The latter class of bugs was once very hard to find, which is why I made the MoarVM heap profiler :)
10:31 jnthn (And found/fixed two EVAL bugs in the past using it.)
10:32 seatek that is SO handy. work more now to be lazy later. :) i'm trying to think what the symptoms seem more like...
10:35 seatek i dont' know enough to tell any difference. system behavior i think it could be either one
10:36 seatek system is still begrudgingly freeing up memory. ;)
10:37 pmurias jnthn: in case of Crust it seems the EVAL should be called only while loading the app
10:38 pmurias jnthn: actually EVALFILE
10:38 andrzejku joined #perl6
10:47 brrt joined #perl6
10:49 seatek jnthn pmurias - doing more broad testing... it seems that memory usage DOES level off when using Crust with EVAL, so maybe the memory issue in Crust isn't that exactly.
10:50 seatek yeah, EVALFILE in this case
10:51 jnthn If it levels off then it's not really a leak?
10:52 jnthn That doesn't explain the simple EVAL loop you posted earlier eating 14GB though. That would surely count as a leak. Except I can't reproduce it...
10:56 seatek yes - confirmed that memory usage is leveling off on the Crust with EVALFILE -- i've been letting 2 tests run a good long time here
10:57 seatek how strange that storing session id's is memory as hashes is slower than database lookups of those same keys
10:58 seatek i am not going to look at that. i've seen nothing
10:59 seatek so yes.. the memory eating does seem to have a cap -- which is reassuring with that EVAL
11:06 effbiai joined #perl6
11:06 effbiai hi, i've installed perl6 with fedora package repository (dnf install rakudo-star). how can i get the module manager (panda) installed from a repository?
11:14 wamba joined #perl6
11:16 seatek yes.... i've been doing longer-running tests at load and concurrency. there is an upper limit its hitting at about 2G
11:16 stmuk_ if its rakudo-star it will have panda already
11:17 seatek Taking EVAL out and using Callable instead is bringing it up to about 2/3 as much. so it that is reassuring about EVAL in this case. i freaked over nothing.
11:17 brillenfux joined #perl6
11:17 effbiai no, panda is not included in this package :(
11:18 seatek effbiai: i always install from the rakudo website -- the brew -- then you get it all, and the most current
11:18 stmuk_ effbiai: what does "perl6 -v" say?
11:18 DrForr effbiai: github.com/tadzik/panda if you need it.
11:19 effbiai This is Rakudo version 2016.07.1 built on MoarVM version 2016.07
11:19 effbiai implementing Perl 6.c.
11:19 seatek 2016.10 is the latest i think
11:19 effbiai i know
11:19 effbiai the problem with running a package that is manually installed in a production system is remembering to update and patch it..
11:20 effbiai that's why i'd like it from the repo
11:20 seatek yeah i hear you :)
11:21 seatek strangely, the Crust middleware... for sessions.. you can use in-memory cookie/session storage. i ran these tests using the same cookie so it didn't have to store and send new ones....
11:21 stmuk_ what does "rpm -qa|grep rakudo" say?
11:21 effbiai where will panda (github.com/tadzik/panda) install the modules by default?
11:21 effbiai # rpm -qa|grep rakudo-star
11:21 effbiai rakudo-star-0.0.2016.07-1.fc24.x86_64
11:22 stmuk_ http://rpms.famillecollet.com/rpmphp/zoom.php?rpm=rakudo-star
11:22 seatek but for the memory resident cookie lookups , performance was close to 20% slower than doing actual, real database lookups for those cookies.
11:22 seatek and i watched the database server toO!
11:23 rindolf joined #perl6
11:24 stmuk_ effbiai: I think you will have to contact the fedora packager
11:24 stmuk_ tell him its misnamed and isn't rakudo star either :)
11:24 seatek effbiai: it puts them in a subdirectory in your home folder... .rakudo-something
11:25 effbiai ok, thanks stmuk_ and seatek
11:25 seatek effbiai: it's all kept very neatly separated from your distribution's distribution
11:26 seatek it just knows to look there because of your path environment variable in your .bashrc
11:26 seatek you can swap it back and forth at any time
11:26 effbiai and what's the variable? PERL6LIB?
11:26 seatek that's for libraries
11:26 effbiai yeah, that was the question also :)
11:26 pmurias jnthn: do we have clearly defined rules when closures might be optimized in nqp or is it just do anything that doesn't break rakudo or nqp?
11:27 seatek the $PATH just has to include ~/.rakudobrew/bin
11:27 effbiai ..if i wanna use perl6 from rakudobrew
11:27 seatek yup
11:27 seatek and take that out if you don't
11:27 seatek they don't overlap
11:27 effbiai but if i only want to use panda to download modules, it's sufficient with PERL6LIB - right?
11:28 pmurias jnthn: as immediate blocks are visible by various introspection ops like nqp::caller etc.
11:28 seatek PERL6LIB in your environment gives a search order for libraries
11:28 effbiai (to show perl6 where to find it's modules)
11:28 effbiai ok, thanks
11:28 seatek sure
11:31 jnthn pmurias: NQP makes no attempts to have nqp::caller and friends not show the effects of its optimizations
11:32 jnthn pmurias: Rakudo is stricter: it won't do such optimizations if it spots construction of a pseudostash
12:12 AlexDaniel joined #perl6
12:19 effbiai joined #perl6
12:22 effbiai i'm getting an error when trying to install panda. seems like it fetches and builds File::Find, but when it's testing it the file cannot be found. full paste; https://zerobin.net/?5550cdaf3d4ac133#SV2q+6EBYOP2bAHBBIt/QrO/kTCqduqJFp6cejbUoIY=
12:32 effbiai nevermind - I was missing the TAP::Harness :>
12:40 dextertzu joined #perl6
12:58 AlexDaniel joined #perl6
13:12 zacts joined #perl6
13:34 [Coke] viki: doesn't look like 8b85121 fixed that, still getting the warning.
13:34 [Coke] (perl6/doc)
13:35 kyclark joined #perl6
13:35 AlexDaniel samcv: hey
13:37 viki [Coke]: what's the warning?
13:37 AlexDaniel m: sub find-urls ( Str $string, Numeric :$limit = ∞, :$ascii?) { say $limit }; find-urls(‘foo’)
13:37 camelia rakudo-moar 88152b: OUTPUT«Inf␤»
13:37 AlexDaniel m: sub find-urls ( Str $string, Numeric :$limit = ∞, :$ascii?) { say $limit }; find-urls(‘foo’, :limit(42))
13:37 camelia rakudo-moar 88152b: OUTPUT«42␤»
13:37 AlexDaniel samcv: why not this? ↑
13:38 AlexDaniel samcv: ah, you want it to be defined, then Numeric:D
13:39 AlexDaniel also, the method body can be shortened to just this: $string.comb($ascii ?? /<urlascii>/ !! /<url>/, $limit)
13:40 dalek doc: 2f2b0f3 | coke++ | doc/Type/Real.pod6:
13:40 synopsebot6 Link: http://doc.perl6.org/type/Real
13:40 dalek doc: Add closing > for C<>
13:40 dalek doc:
13:40 dalek doc: Fixes #1013
13:40 dalek doc: review: https://github.com/perl6/doc/commit/2f2b0f30d4
13:42 nadim_ joined #perl6
14:05 [Coke] viki: ^^ all set.
14:06 viki [Coke]++ thanks
14:17 zakharyas left #perl6
14:21 skids joined #perl6
14:28 kurahaupo joined #perl6
14:28 kurahaupo__ joined #perl6
14:38 kyclark joined #perl6
14:54 cdg joined #perl6
14:56 itaipu joined #perl6
14:59 khw joined #perl6
15:02 Actualeyes left #perl6
15:04 ggoebel joined #perl6
15:10 canopus joined #perl6
15:10 timotimo moritz: may i bounce an idea off of you?
15:11 timotimo would it be hard to accept renderings of our docs from travis-ci via upload and make them available via different vhosts on perl6.org?
15:17 moritz timotimo: depends on what kind of uploads/authentication travis supports
15:17 timotimo we ought to be able to figure out something smart ...
15:17 timotimo if we do, is that a sensible idea?
15:20 moritz yes
15:21 timotimo cool. i'll research ways to make the transfer secure and authenticated
15:21 timotimo but for now i'll AFK
15:23 sufrostico joined #perl6
15:25 cdg_ joined #perl6
15:34 acrussell_ joined #perl6
15:44 El_Che kickstart is going well. If every day lizmat and woolfie make a pledge it will be achieved in no time :)
15:51 lizmat well, we'd like to see it being a community supported thing  :-)
15:51 lizmat so please, don't let us stop you supporting this as well!
16:04 viki eh... fuck it, I'm in... for $50, to get monthly ebook drafts
16:05 richi235 joined #perl6
16:06 timotimo who was it again that runs bisectable? AlexDaniel?
16:06 AlexDaniel yes
16:06 AlexDaniel also MasterDuke has full access to it
16:08 timotimo ah yes, good
16:08 timotimo could you do me a favor? :)
16:08 AlexDaniel sure
16:08 timotimo i'd like to see how CORE.setting.moarvm's file size has evolved throughout your recorded history
16:08 timotimo and if it's possible also to see how "time perl6 -e ''" reports maxresidentk
16:09 AlexDaniel wanna have ssh access to do it yourself?
16:09 timotimo oh
16:09 timotimo well, that'd be cool :)
16:09 AlexDaniel I'd need your public key
16:09 timotimo a sec
16:10 timotimo https://github.com/timo.keys - the first one here is my desktop. i think the second one is my laptop. i'd like to have both installed if that's fine :)
16:10 Xliff joined #perl6
16:10 AlexDaniel sure
16:10 [Coke] viki;so, LTA that perl6 --doc is reporting the missing > at the end of the file rather than close to the C< that started it.
16:12 AlexDaniel timotimo: I'll PM you with details
16:12 timotimo ty
16:14 mohae_ joined #perl6
16:21 nicq20 joined #perl6
16:23 ufobat joined #perl6
16:50 araujo joined #perl6
16:50 araujo joined #perl6
16:56 araujo joined #perl6
16:56 mohae joined #perl6
17:14 * perlpilot just processed about 68000 lines of CSV with perl6 and is happy.
17:15 perlpilot It took about 5 seconds for what I was doing and that wasn't too long.
17:15 nicq20 left #perl6
17:15 sufrostico joined #perl6
17:16 FROGGS joined #perl6
17:16 FROGGS o/
17:20 timotimo perlpilot: yay
17:20 gregf_ joined #perl6
17:25 domidumont joined #perl6
17:32 sufrostico joined #perl6
17:37 timotimo https://i.imgur.com/17SMj1h.png  -  apparently our CORE.setting.moar file size over the last year and a half
17:38 viki What are the units? bytes?
17:38 psch accidentaly?
17:39 psch 2015.10 was definitely an interesting time, in any case
17:39 timotimo bytes, yes
17:40 timotimo https://gist.github.com/timo/48c1a72154ca6e23f0957f5c2ee346b1
17:40 timotimo spike of 2542180 bytes (123.626377252%)
17:40 timotimo 25f8469 - add function composition operator (1 year, 2 months ago) <TimToady>
17:40 timotimo can that be right?
17:41 psch wasn't that one of the first unicode ops in the setting..?
17:41 psch i might be completely off the mark there
17:42 timotimo we had set operations before, no?
17:42 psch hm, probably, yeah
17:43 psch that commit is really tiny too
17:43 psch hm, is there a git syntax for "commit after this ref"?
17:44 timotimo i know there'? a "commit before this ref"
17:44 psch i know $ref~$int for "before"
17:44 psch like, HEAD~1 shows the second most recent one
17:46 geekosaur "commit before this ref" is never ambiguous. "commit after this ref" often is, because git doesn't actually track branches/tags/etc. as distinct entities and there could be multiple "after" commits that apply to different branches etc.
17:46 psch geekosaur++, that's a good point actually
17:46 timotimo just grab the whole log with "git log", make sure it's --pretty=oneline or --oneline and use grep -B1 :P
17:47 timotimo (yeah, ideally you'd -g and eyeball it for merges and such ...)
17:47 timotimo actually
17:47 timotimo grep parent $your-id and -B 1 that?
17:47 timotimo well, -B 1 isn't enough for merge commits
17:50 timotimo anyway
17:51 timotimo i'm not very confident in my data ... i might have mishandled it at some point and gotten the wrong results
17:57 labster joined #perl6
18:20 moritz http://perl6.org now redirects to https://perl6.org/
18:20 firstdayonthejob joined #perl6
18:20 viki sweet. moritz++
18:22 timotimo FROGGS: i'm still a tiny bit irked that testers.perl6.org spikes cpu usage every few minutes :S
18:25 timotimo i've thought about doing it a bunch of times, but somehow i can't quite get a hold of this task >_<
18:26 FROGGS hmmmm
18:26 * [Coke] finds a ticket that was fixed, with tests, passing, 11 months ago, but never closed.
18:29 [Coke] Can someone with Windows 10 verify an RT for me?
18:29 [Coke] (RT #126992)
18:29 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=126992
18:35 ugexe Xliff: `perl6 -e 'use IO::Socket::SSL;'` *does* work though right?
18:36 Xliff yes
18:37 Xliff Actually, in many situations, HTTP::UserAgent will work. I have a script that is working right now that doesn't exhibit this problem, however it doesn't use Promises.
18:38 ugexe I think that error message is just wrong (https://github.com/sergot/http-useragent/blob/404ebebec8de035982e4205db8b29566047b98b7/lib/HTTP/UserAgent.pm6#L355)
18:38 Xliff I'm of the opinion that HTTP::UserAgent has issues depending on how it is used. However, for the life of me, I can't tell you what cases will cause the error and what will not.
18:38 ugexe i.e. it *is* a failure, but not for the reason the error message says
18:38 Xliff ugexe: That could be.
18:39 ugexe thread stuff is still wonky for all Perl6 HTTP modules
18:39 Xliff Please note, that this error occurs when OpenSSL 1.1 is used. My patch may fix some situations, but may fail with others due to NativeCall issues... (or libopenssl issues)
18:39 Xliff Works fine without threading.
18:39 Xliff At least as far as i can tell.
18:40 ugexe Yeah thats probably it. You could remove that `die` (but leave the ::('IO::Socket::SSL') ~~ Failure) to get the real error
18:54 viki Answer to why Kickstarter for LP6 and what O'Rly media brings to the table: https://www.reddit.com/r/perl/comments/5dbtpy/oreilly_learning_perl_6_kickstarter/da4aq2k/
18:54 ugexe I tried your script with Net::HTTP and get the same error. But if I add a `state $sleep += 2; sleep $sleep;` inside the for loop before the start block it instead gives: `Could not find symbol '&Transport' in block <unit> at test.pl6 line 26`
18:59 ugexe Xliff: this is working - something to do with the delay caused by sleep (works with HTTP::UserAgent too, but gives the Compress::Zlib error) https://gist.github.com/ugexe/b13730923b257f37e224a4eabb1e2db6
19:00 Xliff Ooh! Neat! ugexe++
19:02 davercc joined #perl6
19:17 * perlpilot wonders about the trend line for donations to the LP6 book if you remove lizmat's and woolfy's contribution.
19:18 nicq20 joined #perl6
19:19 viki $58/average
19:21 viki m: say (10000, 137 xx 22, 108 xx 6, 99 xx 2, 66 x 3, 50 xx 37, 25 xx 64, 10, 1, 1).flat.Bag
19:21 camelia rakudo-moar b5aa3c: OUTPUT«bag(99(2), 10000, 50(37), 108(6), 137(22), 1(2), 10, 666666, 25(64))␤»
19:21 sufrostico joined #perl6
19:22 viki m: say (10000, 137 xx 22, 108 xx 6, 99 xx 2, 66 xx 3, 50 xx 37, 25 xx 64, 10, 1, 1).flat.Bag
19:22 camelia rakudo-moar b5aa3c: OUTPUT«bag(66(3), 99(2), 10000, 50(37), 108(6), 137(22), 1(2), 10, 25(64))␤»
19:22 viki A typo produced 6 sixes! OMG IT"S A SIGN!
19:22 moritz a sign of a type :-)
19:23 moritz *typo
19:23 viki :D
19:23 moritz man, when you typo typo, you know you have a chronic lack of sleep
19:26 viki Hm one more now
19:26 lizmat perlpilot: please don't  :-)
19:26 viki m: say (10000, 137 xx 22, 108 xx 6, 99 xx 2, 66 xx 3, 50 xx 37, 25 xx 65, 10, 1, 1).flat.Bag.values.sum
19:26 camelia rakudo-moar b5aa3c: OUTPUT«139␤»
19:26 viki But weird that the sum gives 139 backers, but the total on the site shows 141
19:27 lizmat viki: good catch  :-)
19:28 chris2 joined #perl6
19:28 lizmat anyways, only 400$ away from 50%  :-)
19:28 viki \o/
19:28 perlpilot I'm trying to get us closer to 50%, but my phone is acting weird right now
19:28 lizmat perlpilot++
19:31 perlpilot ah, there it goes.  It was stuck and wouldn't let me enter an amount.
19:32 stmuk_ it was probably sending it to China
19:37 stmuk_ [Coke]: wrt RT#126992 it passes for me on Windows
19:37 synopsebot6 Link:  https://rt.perl.org/rt3//Public/Bug/Display.html?id=126992
19:37 viki So the butterfly on the cover is called a 「"Cracker" butterfly」? 😂😂😂
19:37 viki And here I thought we were a diverse bunch...
19:39 viki stmuk_: [Coke] thanks. Marked ticket as resolved.
19:39 stmuk_ I'm sure we have vim and emacs users!
19:44 lostinfog joined #perl6
19:45 RabidGravy I dunno, have we had anyone pitch up complaining that there isn't an Eclipse plugin yet
19:47 * lizmat is spectesting a fix for RT #130131
19:48 nicq20 Anyone notice if I'm doing something really dumb in the "check" sub? https://github.com/nicqrocks/p6-Watcher/blob/master/lib/Checker.pm6
19:49 viki MY EYES!
19:49 nicq20 IKR
19:50 domidumont joined #perl6
19:51 RabidGravy what is it doing that you don't expect it do be doing?
19:51 moritz nicq20: I don't understand why you use a promise when a simple timer would be enough
19:52 nicq20 If I place this in a loop, it segfaults after 256 runs.
19:52 moritz nicq20: nothing happens when the promise triggers
19:52 viki nicq20: looks fine to me, though I'd probably use a proper object instead of a string for the error
19:52 viki moritz: what's a simple timer?
19:52 moritz viki: my $time = now; ...; if now - $time >= 60 { ... }
19:53 viki Ah
19:53 RabidGravy if it segfaults, then you need to examine the gdb backtrace
19:53 moritz maybe the intent was to do something like await Promise.anyof($t, start { try to connect here })
19:54 nicq20 moritz: Using actual time is a much better idea now that you mention it...
19:54 nicq20 RabidGravy: How do I get the backtrace to show?
19:55 RabidGravy use 'perl6-gdbm-m' rather than 'perl6'
19:56 RabidGravy moarvm should never segfault with plain perl 6 code
19:56 moritz and then enter "run", wait for the segfault, and then "bt"
19:58 Cabanossi joined #perl6
19:58 nicq20 `bt` returns:
19:58 nicq20 0: unwind_after_handler, 1: MVM_frame_try_return, 2: MVM_interp_run, 3: MVM_vm_run_file, 4: main
19:59 nicq20 All from "libmoar.so"
19:59 FROGGS (for the logs, it is called "perl6-gdb-m" and the run command is implicit)
20:03 kyclark joined #perl6
20:03 * moritz would love to publish his blog post on his own p6 book project, but the brain feels like a big mushroom tonight
20:09 nicq20 Hmm... The debug mode does not seem to be saying much useful.  :/
20:11 FROGGS nicq20: usually you compile MoarVM with --debug=3 and then paste the "bt full" of the failing ode in a ticket
20:11 FROGGS code*
20:11 kurahaupo__ joined #perl6
20:12 nicq20 FROGGS: Do I specify the '--debug=3' when I run make or the Configure.pl?
20:13 FROGGS nicq20: Configure.pl
20:15 MilkmanDan joined #perl6
20:16 sufrostico joined #perl6
20:18 Cabanossi joined #perl6
20:23 xinming joined #perl6
20:34 RabidGravy meanwhile in another window I am trying to calm the enthusiasm of someone who doesn't even know what ssh is to be doing their own system administration
20:34 psch sounds fun!
20:37 RabidGravy every once in a while the radio station does something weird and the best course of action is to be restarting some pieces, and nearly all of those times I am on a train or something
20:37 Cabanossi joined #perl6
20:39 RabidGravy you guys are going to have to help me move the whole thing over to a Perl 6 version of Emitria by writing more modules
20:40 Coleoid_ns joined #perl6
20:40 RabidGravy as I have completely reset my plans for an ORM type thingy in the last few days
20:40 sufrostico joined #perl6
20:41 RabidGravy but in other news a well known online luxury fashion retailer paid me for another day of doing Perl 6 stuff
20:42 El_Che uk based?
20:42 dudz Are you using perl for website?
20:42 dudz *hello
20:43 viki hey
20:44 [Coke] dudz: Hi, can we help you?
20:44 viki dudz: it's kind'f bare bones so far. We haven't yet had a champion to develop a solid web framework. There are some in various stages of development at https://modules.perl6.org
20:44 RabidGravy yes, uk based,
20:44 perlpilot RabidGravy: What's "the whole thing"?  And what modules do you need written?  :-)
20:44 RabidGravy I have done web stuff in Perl 6
20:45 dudz hi [Coke]
20:46 RabidGravy perlpilot, the "whole thing" is the management and scheduling of radio playout, making sure that the right things get played out the stream at the right time
20:47 dudz I was thinking of something to do to contribute towards a perl modules database, and at the same time use that as samples to show my experience, i was told that the perl6 community hasn't got that much modules adding functionality for the language yet and so I was thinking to use existing cpan modules for perl5 as ideas on what things to make for perl6
20:47 nicq20 FROGGS: Adding '--debug=3' when setting up moar seems to error out trying to find 'Perl6/Grammar.moarvm'
20:48 RabidGravy I want to place the mostly working well but horrible PHP and Python hybrid of https://www.sourcefabric.org/en/airtime/ with something that is a sane design under the hood
20:48 nicq20 FROGGS: Seems to compile everything fine though.
20:48 FROGGS that's strange
20:49 [Coke] dudz: there's a "most wanted" page showing modules that have been specifically asked for.
20:49 [Coke] https://github.com/perl6/perl6-most-wanted/blob/master/most-wanted/modules.md
20:49 FROGGS nicq20: dunno what to suggest though
20:49 RabidGravy dudz, the trick at this point is not so much "port all the things" but make new and exciting designs that reflect Perl 6 idiom to cover common needs
20:49 * nicq20 shrugs
20:50 [Coke] ... it is generous to call a git repo with a single readme file and nothing else a WIP (picking one at random off that list.)
20:50 * perlpilot notes in passing that DBIx::Class is missing from the most wanted ;)
20:51 viki dudz: http://metacpan.org/pod/Mojolicious would be nice :) But not a code port, API port :) A lot of that code we have in core Perl 6 already
20:51 RabidGravy perlpilot, having thought about it quite a lot, a straight up port of DBIx::Class is not going to work at all well - a whole new design is required
20:52 RabidGravy not because there's anything much wrong with DBIx::Class per-se but just some of the ways it works don't play too well with the way Perl 6 is
20:53 mst amusingly, I think a whole new design is required because there *is* plenty wrong with the DBIC design
20:53 El_Che mst: shut up :)
20:53 El_Che mst: no dbix here :)
20:53 nicq20 FROGGS: Oh, well. I'll try to look into it more. There has to be something small I'm missing or forgetting because Net::HTTP works fine, and it seems to open a connection for each request as well.
20:53 RabidGravy mst, in detail perhaps but the very high level API is basically sound
20:54 RabidGravy some of the actual code is the satan
20:54 dudz ok thanks [Coke] RabidGravy and viki
20:54 mst I wish resultsets had been envisioned as proper collections from the start
20:54 mst also waaay too much of the persistence logic lives in the row objects
20:54 mst I would like basically LINQ + orthogonal persistance
20:54 RabidGravy and prefetch should just be killed with fire
20:55 mst how so? prefetch is probably the single most effective optimisation tool
20:55 cognominal joined #perl6
20:55 mst it was adding that to Class::DBI::Sweet that started me down this entire path into madness
20:57 RabidGravy it *is* an effective optimisation thing but it hurts badly when you start getting complicated with your queries
20:57 RabidGravy so adding one small condition somewhere on a result way down the line can break the whole thing
20:58 mst in that you can produce completely cfazy complex queries with resultset chaining but making them work -and- prefetch at the same time results in a massive fight?
20:58 mst right
20:58 labster joined #perl6
20:58 mst ok, so, that is not a problem with prefetch, it's a problem with how I first implemented it and the things people now rely on that weren't actually the right approach
20:59 RabidGravy I took a lot of it out at DB, but some of those queries were getting exceptionally hairy
20:59 RabidGravy three or four pages of generated SQL type hairy
21:00 RabidGravy but hey it was oracle, it's good a half way decent query optimiser right ;-)
21:00 mst my mistake, basically, was never figuring out a good way to be able to tell whether the user was trying to achieve "add a WHERE to the query" or "restrict a prefetch to a subset of its results" - for the latter, you should be pushing those clauses into the ON clause so's not to destroy LEFT JOINs
21:00 mst so 'add some WHERE to the query' gets (ab)used for both, and that makes it very easy to get the wrong one
21:03 RabidGravy mind you I learned something new about Postgres today which wasn't something I expected, no ORM involved whatsoever
21:09 RabidGravy I think we should have committed to proper object relational data storage in the nineties and sacked off all the straight relational databases, then we wouldn't be in this mess:)
21:10 perlpilot That doesn't sound very perlish  ;)
21:12 TEttinger joined #perl6
21:17 cdg joined #perl6
21:18 nicq20 left #perl6
21:20 RabidGravy y'see I think "Document" or "Graph" data stores are probably more perlish in ethos, but they're totally shit to make complex transactional applications in
21:21 bazzaar joined #perl6
21:22 bazzaar o/ perl6
21:22 RabidGravy I'll probably be well retired before they come up with something that works for everything we want to do with it
21:22 bazzaar m: grammar { token TOP { <command> }; proto token command {*}; token command:sym<create> { <mid> 'est' <sym>* }; token mid { 'create_t' } }.parse: 'create_testcreate', :actions(class {method TOP ($/) { say $<command>.WHAT}});
21:23 camelia rakudo-moar 4f581a: OUTPUT«(Match)␤»
21:23 bazzaar m: grammar { token TOP { <command> }; proto token command {*}; token command:sym<create> { <mid> 'est' <sym>* }; token mid { 'create_t' } }.parse: 'create_testcreate', :actions(class {method TOP ($/) { say $<command><mid>.WHAT}});
21:23 camelia rakudo-moar 4f581a: OUTPUT«(Match)␤»
21:23 [Coke] I have happily given up on ORM having lost many more hours trying to make it work than I ever saved from being exposed to SQL.
21:23 bazzaar m: grammar { token TOP { <command> }; proto token command {*}; token command:sym<create> { <mid> 'est' <sym>* }; token mid { 'create_t' } }.parse: 'create_testcreate', :actions(class {method TOP ($/) { say $<command><sym>.WHAT}});
21:23 camelia rakudo-moar 4f581a: OUTPUT«(Array)␤»
21:24 firstdayonthejob joined #perl6
21:24 bazzaar anyone know why <sym> is an array, and not a match object like <mid>
21:25 RabidGravy [Coke], I love them and I have probably written more straight up SQL in my life than most people have written perl
21:25 jnthn bazzaar: Because you wrote <sym>*
21:25 RabidGravy it's just I get irked at the extreme edge
21:26 jnthn bazzaar: Meaning "match many of them"
21:26 jnthn So you get an array of match objects
21:26 jnthn (Same with + and **)
21:26 RabidGravy I think I may have to make an I4GL slang for Perl 6
21:26 bazzaar jnthn: aaah, very good :)
21:27 bazzaar m: grammar { token TOP { <command> }; proto token command {*}; token command:sym<create> { <mid> 'est' <sym>? }; token mid { 'create_t' } }.parse: 'create_testcreate', :actions(class {method TOP ($/) { say $<command><sym>.WHAT}});
21:27 camelia rakudo-moar 4f581a: OUTPUT«(Match)␤»
21:27 mst [Coke]: my main issue with SQL is that you can't factor out chunks of queries in a reusable way; when I'm writing DBIx::Class code, I'm imagining the SQL it'll generate
21:28 mst but most ORMs try and hide the database and augh
21:29 RabidGravy well you can't factor out chunks of queries in a sane away across DBMs anyway
21:29 richi235 joined #perl6
21:32 mst RabidGravy: sure. but being able to do things like 'this other query, except with an extra bit of WHERE clause' should have nicer ways to do it than string concatenation, basically
21:33 RabidGravy yeah, if only we had killed MySQL when we had a chance we might be closer to that
21:35 perlpilot mst: maybe you could prototype an improved DBIx::Class in Perl 6 and get some people to run with it like you did with DBIx::Class (only with lessons learned now)  :)
21:35 seatek joined #perl6
21:36 RabidGravy perlpilot, I don't want mst to do it
21:36 RabidGravy ;-)
21:36 perlpilot :-PPP
21:37 RabidGravy I love the hippy freak dearly but I want someone from outside to come along and do something completely new
21:37 viki :)
21:38 perlpilot The real trick is finding someone knowledgeable enough about the problem space *and* Perl 6 to do it well.
21:39 mst RabidGravy: I've been waiting for somebody to come and do something completely new for a long time, and yet nobody's even come close to a DBIC replacement
21:39 mst RabidGravy: so, like, I don't want me to do it either but eventually I may end up having to anyway ;)
21:40 RabidGravy I've been dicking around with the SQL generation part for a while now and I'm just about to throw most of it away and start again
21:40 viki dudz: out of curiousity, where did you hear that Perl 6 doesn't have many modules?
21:42 RabidGravy I think 745 is quite good, that's half as many again since January, I think we should have a stretch target of 1000 by this coming January
21:42 dudz viki: irc
21:42 viki I thinks that's way optimistic :)
21:42 viki dudz, which chanmel? This one?
21:43 dudz irc.perl.org/#australia (perlmongers, sydney)
21:43 viki Ah :)
21:43 dudz :)
21:43 RabidGravy people only write modules that they want to use, it's not the modules it's the software written in Perl 6 we need
21:44 viki I haven't written any Perl 6 code for months
21:44 RabidGravy slacker
21:44 viki dunno what to writw
21:44 viki Other than a web framework, for which I don't have the stamina
21:45 perlpilot viki: you sound like me.   We need less people like us and more people who just make stuff
21:45 RabidGravy you could fix the Net::ZMQ module if you're bored, I go back to it every once in a while and give up
21:45 RabidGravy I have "special reasons" for wanting it to work
21:46 dudz viki's a nice name, my wife has that same name only spelt differently, and she's very beautiful and smart and pretty and very great.
21:46 * jnthn found ZemoMQ kinda interesting... :)
21:46 jnthn *Zero
21:47 jnthn RabidGravy: Does the module make nice use of the Perl 6 async stuff?
21:47 RabidGravy not particularly, it's just a binding to the libzmq but for some reason it stopped working a few months ago
21:49 RabidGravy I've decided that a strong niche for P6 would be in the messaging middleware space, given the strength of the async design, but for this to come in to play we need many bindings to many messaging platforms
21:50 japhb And async SSL sockets ...
21:51 jnthn japhb: Yeah, I suspect I'll need to be wanting a painful kind of fun to hack further on that... :)
21:51 RabidGravy japhb, that probably needs a teensy change to expose the underlying socket and jobs a good un
21:51 jnthn I really want it though, so... :)
21:51 Tonik joined #perl6
21:52 RabidGravy jnthn, while I'm thinking about this subject, would you be averse to splitting the client and server parts of Stomp and releasing the former?
21:53 dudz Going to head out to the skatepark and practice some exercise, I got a bit of a stomich that I want to get rid of for asthetics.
21:53 RabidGravy aesthetics
21:53 dudz *aesthetics
21:54 RabidGravy 2016 is great
21:54 japhb jnthn: I don't doubt at all that there will be pain.  But man would it open things up in the networking space ....
21:54 jnthn .oO( If you work off the butt too, you'll have good assthetics... )
21:54 RabidGravy yeah, it wou;d
21:54 dudz been watching 'paper planes' (australian movie)
21:54 RabidGravy would
21:54 dudz *bbl
21:54 jnthn RabidGravy: No aversion to that really, no
21:54 jnthn RabidGravy: Though iirc there's a lot of possible re-use between them
21:55 jnthn So may want to split off the parser too...maybe :)
22:01 Coleoid_ns Hi, #Perl6!
22:01 perlpilot Coleoid_ns: greetings
22:02 Coleoid_ns When I'm running tests, sometimes it stops interpreting newlines, and starts echoing them as literal '\n' strings.
22:02 RabidGravy jnthn, maybe I'll revisit the server part and get that somewhat working, it would certainly play to my medium term evil
22:03 Coleoid_ns (when its giving me "expected x but got y" feedback on a failure)
22:03 ufobat joined #perl6
22:03 perlpilot Coleoid_ns: got a transcript of this behavior you can put on gist or something?
22:03 Coleoid_ns but sometimes i actually get the newline
22:03 Coleoid_ns I'll paste one up in a few.
22:04 bazzaar m: grammar { token TOP { <command> }; proto token command {*}; token command:sym<create> { <mid> 'est' <sym>* }; token mid { 'create_t' } }.parse: 'create_test', :actions(class {method TOP ($/) { say $<command><sym> }});
22:04 camelia rakudo-moar 4f581a: OUTPUT«[]␤»
22:04 bazzaar m: grammar { token TOP { <command> }; proto token command {*}; token command:sym<create> { <mid> 'est' <sym>* }; token mid { 'create_t' } }.parse: 'create_test', :actions(class {method TOP ($/) { say $/}});
22:04 camelia rakudo-moar 4f581a: OUTPUT«「create_test」␤ command => 「create_test」␤  mid => 「create_t」␤»
22:05 viki Coleoid_ns: got code we can reproduce this with?
22:06 bazzaar another <sym> question, if in this case <sym> is an empty array, why doesn't it appear as such in the match object?
22:07 Coleoid_ns https://nopaste.me/view/56a45603
22:08 Coleoid_ns I have code, but it's far, far from golfy, and I don't know what triggers the change.
22:08 Coleoid_ns This is $dayjob code, so it's pretty hairy.
22:08 RabidGravy what are you using to run these tests?
22:08 viki Coleoid_ns: and it's the exact same test that flips back and forth between those behaviours?
22:09 viki Coleoid_ns: what's the test BTW, is() ?
22:09 Coleoid_ns Well, largely the same, but I'm TDDing, so neither code nor tests remain the same.
22:09 jnthn bazzaar: Try say $/.perl instead for more verbose output
22:09 Coleoid_ns Yep, is().
22:10 jnthn bazzaar: I think the .gist output used by say just includes things that matched something
22:10 viki Coleoid_ns: oh, I think I know what it is
22:10 viki Coleoid_ns: it'll print literal whitespace like that when *only* whitespace differs between the values
22:11 viki m: use Test; plan 1; is "foo\tbar", "foo\tbaz"
22:11 camelia rakudo-moar 4f581a: OUTPUT«1..1␤not ok 1 - ␤␤# Failed test at <tmp> line 1␤# expected: 'foo     baz'␤#      got: 'foo   bar'␤# Looks like you failed 1 test of 1␤»
22:11 viki m: use Test; plan 1; is "foo\tbar", "foo    bar"
22:11 camelia rakudo-moar 4f581a: OUTPUT«1..1␤not ok 1 - ␤␤# Failed test at <tmp> line 1␤# expected: "foo    bar"␤#      got: "foo\tbar"␤# Looks like you failed 1 test of 1␤»
22:11 viki See ^
22:11 Coleoid_ns :O
22:11 viki Basically so you don't stare at it going "wtf! where's the difference" :)
22:11 Coleoid_ns vikiL  Thanks!
22:11 viki No problem.
22:12 perlpilot Maybe someone will write an enhancement one day that highlights exactly which characters are different.
22:13 viki And it will be named Test::More and live in userspace ;)
22:13 bazzaar jnthn: that's a great help, thankyou
22:14 Coleoid_ns viki: I will go read up on Test::More...
22:14 perlpilot heh
22:16 dalek doc: 87c254f | (Zoffix Znet)++ | doc/Language/testing.pod6:
22:16 dalek doc: Document is()'s special treatment of values...
22:16 dalek doc:
22:16 dalek doc: that differ only on whitespace
22:16 dalek doc: review: https://github.com/perl6/doc/commit/87c254f100
22:16 synopsebot6 Link: http://doc.perl6.org/language/testing
22:16 viki Coleoid_ns: I was kidding. I don't think that module exists :)Pop
22:16 perlpilot yet!
22:16 perlpilot Coleoid_ns: you could write it even  :)
22:18 Coleoid_ns If nothing like that exists in Test::*, I may have to, to retain my eyesight while I work through this project.
22:23 RabidGravy I've been doing some stuff with Test::Class::Moose (thanks Ovid) this week and I may try and improve that space in P6 soon
22:23 travis-ci joined #perl6
22:23 travis-ci Doc build errored. Zoffix Znet 'Document is()'s special treatment of values...
22:23 travis-ci https://travis-ci.org/perl6/doc/builds/177156770 https://github.com/perl6/doc/compare/2f2b0f30d4a6...87c254f10054
22:23 travis-ci left #perl6
22:24 viki bah
22:24 viki Ahhh
22:24 RabidGravy travis has been flaky this week, stopped randomly a couple of builds
22:24 viki moritz made perl6.org forse SSL and apparently Pod::To::PigPage relies on it being http :)
22:25 viki Or maybe LWP::Simple instead of Pod::To::PigPage
22:25 RabidGravy I thought I'd fixed LWP::Simple and https
22:25 viki Yeah, it's Pod::To::Bigpage
22:27 viki .tell gfldex FYI: https://github.com/gfldex/perl6-pod-to-bigpage/issues/5
22:27 yoleaux viki: I'll pass your message to gfldex.
22:31 RabidGravy why does https://travis-ci.org/retupmoca/P6-Compress-Zlib show "error"
22:41 kyclark joined #perl6
22:41 geekosaur the branches tab says #9 errored
22:42 geekosaur "panda: command not found"
22:42 kyclark Is there a recommended GUI toolkit like Qt or GTK?
22:43 geekosaur so for some reasn build history does not show the successful build #10 yet
22:43 geekosaur stops at #9 which errored
22:43 sufrostico joined #perl6
22:47 RabidGravy kyclark, afaik there is only a GTK binding for P6 right now
22:48 RabidGravy works fairly well, could use some help, need another widget a day boost up probably
22:48 kyclark Are there docs on that I can read?  I tried a simple GTK C program and got errors on OSX about something being deprecated.
22:49 kyclark Ah, found it on modules.perl7
22:49 kyclark *6
22:49 viki http://modules.perl6.org/#q=gtk
22:50 bazzaar m: grammar { token TOP { <command> }; proto token command {*}; token command:sym<create> { <mid> 'est' <sym>* }; token mid { 'create_t' } }.parse: 'create_testcreate', :actions(class {method TOP ($/) { say $/.perl}});
22:50 camelia rakudo-moar 4f581a: OUTPUT«Match.new(ast => Any, list => (), hash => Map.new((:command(Match.new(ast => Any, list => (), hash => Map.new((:mid(Match.new(ast => Any, list => (), hash => Map.new(()), orig => "create_testcreate", to => 8, from => 0)),:sym([Match.new(ast => Any, list =>…»
22:50 RabidGravy https://github.com/perl6/gtk-simple
22:50 bazzaar m: grammar { token TOP { <command> }; proto token command {*}; token command:sym<create> { <mid> 'est' <sym>* }; token mid { 'create_t' } }.parse: 'create_testcreate', :actions(class {method TOP ($/) { say $/<command><sym> }});
22:50 camelia rakudo-moar 4f581a: OUTPUT«[「create」]␤»
22:51 RabidGravy kyclark, the caveat is, if it's missing a widget you want, you get to implement it
22:51 kyclark Right-o
22:52 RabidGravy we've had a couple of big pushes on it, but it's massive
22:53 bazzaar heck, irc clips +camelia's output
22:53 RabidGravy I did like two weeks of a widget a day and it's still half there
22:55 bazzaar anyway $/.perl shows :sym to contain an array, but no values are shown (why?), but $/<command><sym> is the array with 'create' as the first element
22:56 nadim joined #perl6
22:57 RabidGravy I'm not a grammar expert but isn't that what you asked for?
22:58 bazzaar m: my @array = <one two three>; say @array.perl
22:58 camelia rakudo-moar 4f581a: OUTPUT«["one", "two", "three"]␤»
23:03 bazzaar RabidGravy: I quess I am just querying the .perl output of the match object, perhaps it doesn't report more than a couple of levels deep ...
23:05 * viki recalls a bug involving Match and .perl
23:05 setty1 joined #perl6
23:05 viki "$/.perl doesn't round-trip when captures are present
23:06 viki ": https://rt.perl.org/Ticket/Display.html?id=129307#ticket-history
23:11 bazzaar viki: that's just the thing, good spot :)
23:32 kyclark joined #perl6
23:36 Herby_ joined #perl6
23:36 Herby_ o/
23:46 RabidGravy erp
23:50 skids joined #perl6
23:51 BenGoldberg joined #perl6

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

Perl 6 | Reference Documentation | Rakudo