🦋 Welcome to Raku! raku.org/ | evalbot usage: 'p6: say 3;' or /msg camelia p6: ... | irclog: colabti.org/irclogger/irclogger_log/raku
Set by ChanServ on 14 October 2019.
[Coke] moritz++ 00:49
Geth doc: 01db0bee46 | Coke++ | xt/pws/words.pws
new word
01:40
anquegi p6: say 3; 05:09
camelia 3
Geth doc: 74a3191b45 | (Stoned Elipot)++ | doc/Type/Array.pod6
Fix references to routines
06:51
linkable6 Link: docs.raku.org/type/Array
sameer Hi 07:45
Interested in learning more on waterbed 07:46
sjn the waterbed theory of complexity? 07:56
*linguistic complexity 08:01
<- doesn't know of anything else waterbed-related in Raku 08:02
moritz it's not too complicated. The idea is that if things have a certain complexity, and you push down the complexity of the usage at one point, it goes up in another place, just like a waterbed 08:17
sjn I'm not sure if I'd like learning on a waterbed. I'm worried I'd get seasick @_@ 08:20
sameer Thanks 09:08
Altreus Never heard of that, but my first thought is, yes, but waterbeds aren't modular 09:38
So it seems like a decent analogy but the upshot is that you should be making the high-up bits be somewhere else where you can't see it
tbrowder hi, raku people 10:53
i'm looking for user opinions on general handling of spreadsheet programs or apis 10:54
do you prefer ms excel style (col, row, 1-based indexing) or traditional mayr 10:56
MasterDuke i'm of the opinion that generals shouldn't handle them. shouldn't that be an NCO's job?
tbrowder matrix style row,col, 0-based?
i probably should ask, without knowing the author's product, which interface style would you expect? 11:01
tbrowder .tell codesections you should consider submitting a pr for App::Mi6 to integrate tangle/weave into its operations 11:36
tellable6 tbrowder, I'll pass your message to codesections
[Coke] just used 'var' instead of 'my' for some reason. 13:10
Geth Raku-Steering-Council/main: 86bd991040 | Coke++ | scripts/tally.raku
fix soft line breaks

shouldn't introduce whitespace.
13:13
[Coke] 35 ballots reporting (Average votes per ballot: 4.6) 13:20
sjn reminds people about that Raku discord server where it's possible to use audio chat with others. :-) invite link -> discord.gg/hweVYX 13:24
tbrowder MasterDuke: i'm just now seeing yr joke, good one... 13:30
jjatria Hi! I recently found myself wanting something like the Timer they have in Go, and couldn't figure out how to use a Promise directly to do it and couldn't find anything to do it in the ecosystem 13:34
This is more or less what I ended up using, and I was wondering if it made sense to push it to the ecosystem, since now I find myself wanting to use it in other projects:
gitlab.com/-/snippets/2010953
I could also be overcomplicating things, and maybe there is a much simpler solution to this that means the module is not needed 13:35
dakkar I'm not sure I understand what you're doing, but it feels like Supply.throttle can do at least some of it 13:45
(the documentation is still a bit obscure to me, though)
jjatria The bottom of that snippet has an example of basically what I wanted to achieve: there's a set of events that are coming in, and I wanted to batch them in groups of "these came in within X number of seconds of each other" 13:54
I'll take a look at Supply.throttle. Thanks!
Ah, yeah... it looks like that is used to specify a maximum number of messages to allow through the Supply in a certain amount of time. I don't actually care how many messages go through 13:58
So I feel the use case is a little different
Geth Raku-Steering-Council/main: c6e248b93e | Coke++ | scripts/tally.raku
don't be greedy

avoids issue where someone has a very long sig with code that contains a closing paren and a vote on the last line.
14:02
[Coke] 37 ballots reporting (Average votes per ballot: 4.6) 14:03
I swear every vote is making me commit a bug fix. :)
patrickb ping rba 14:05
guifa [Coke]: hopefully not mine! 14:13
guifa But if it makes you feel better, that was bascally me last night getting Intl::X to finally compile into something usable. So many exceptions had to get some special treatment to be compilable =/ 14:14
moritz unique snowflake exceptions :D 14:19
rba Patrickb: busy pong. 14:35
[Coke] guifa: I don't know which email is yours, so... maybe? :)
patrickb rba: Can I persuade you to upload the last few releases of rakubrew to the website? (And if time permits also update the website itself?) People keep reporting the same already fixed errors again and again... 14:36
rba patrickb: Sure. Sorry for the grande delay :-/ 14:37
patrickb v10 - v13 need to be uploaded 14:38
lizmat and another Rakudo Weekly News hits the Net: rakudoweekly.blog/2020/09/14/2020-...ally-raku/ 15:00
codesections lizmat++ 15:02
tellable6 2020-09-14T11:36:58Z #raku <tbrowder> codesections you should consider submitting a pr for App::Mi6 to integrate tangle/weave into its operations
codesections tbrowder: Interesting. What do you have in mind? As I mentioned when I announced Pod::Weave, I don't plan to use it for all my code so I'm not sure I'd want it to be part of mi6's default `build` command. Are you thinking it'd be a separate subcommand? 15:04
moritz lizmat++ 15:12
[Coke] OT, but the peach tree in my yard is doing very well this year. 15:20
timotimo cool! 15:21
[Coke] (house came with 2 apple trees - dead, 3 cherry trees - 2 left, and one peach tree) 15:22
MasterDuke we've been enjoying all the blackberry bushes between our house and the park/playground. unfortunately we completely missed when the plums were ripe 15:23
timotimo blackberries, eh? that's the ones that will spread like gossip across the entire place? 15:24
MasterDuke and only caught the tail end of the sour cherries, weren't enough to do anything with
yep
timotimo i once helped fight a blackberry infestation
didn't get to do too much before the landlord decided their family needs the apartment more than we do 15:25
tbrowder codesections: i'm not sure exactly how to integrate it except primarily for mi6 to build the readme by extracting from the main module using your tools.
moritz through harvesting? :D
guifa` timotimo: why fight it? Turn it into cobbler, jam or wine :-)
timotimo nah, it was really almost exclusively the woody parts, none of the fruits 15:26
berries*
tbrowder hm, i guess it would have to extract the code, too, so the main input should be the .pod file, no? 15:27
lizmat m: say sprintf(q/%*.*e/,20,7,pi) # /me wonders how many people know you could do that with sprintf 15:28
camelia 3.1415927e+00
guifa` 's eyes bleed 15:30
moritz certainly didn't know 15:32
timotimo moritz: do i get a free copy of the fundamentals book to check out the cro section? or did i actually already proofread it months ago? 15:35
i do believe i did in fact proofread someone writing a chapter or two about cro 15:36
prostagma :-D 15:42
lizmat afk for a few hours& 15:46
patrickb rba: Here's the link to the files, so you don't have to look it up again: rooster.uber.space/patcloud/index....EJLQDZcjbf 16:10
rba patrickb: thank you. Will update it tonight. 16:11
moritz timotimo: I think you did; I can still try to get you a review copy 17:49
timotimo i got a review copy on 07.31 18:01
timotimo oh that was 2017 18:02
Geth doc/array-splice-desc: f44459a8d9 | (Stoned Elipot)++ | doc/Type/Array.pod6
Tweak Array.splice description

  - reduce repetition
  - add a missing self mention
  - remove an extraneous 'just'
doc: stoned++ created pull request #3643:
Tweak Array.splice description
timotimo but also 06.18 of 2020 18:03
i got a copy of chapter 12
Geth ake: c5020ee560 | (Aleks-Daniel Jakimenko-Aleksejev)++ | META6.json
Bump version

It is now called `ake`!
18:53
[Coke] finds a wikipedia page about raku rules. Coke doesn't recall this existing. checks history. Coke edited the page at some point 21:09
Geth Raku-Steering-Council/main: ff7378357e | Coke++ | scripts/tally.raku
Don't try to process lines beginning with >

  ... someone might reply to a ballot with a newly filled out ballot, e.g.
21:31
[Coke] 38 ballots reporting (Average votes per ballot: 4.6) (again, ^^ had to submit a patch. :) 21:35
Xliff \o 22:06
What is the best idiom to use when declaring a dynamic variable that might already exist? 22:07
m: sub d { my $*dyn = OUTER::<$*dyn> // 2; $*dyn,say }; sub a () { my $*dyn = 1; d; }; 22:08
camelia 5===SORRY!5=== Error while compiling <tmp>
Unsupported use of bare "say". In Raku please use: .say if you meant
to call it as a method on $_, or use an explicit invocant or argument,
or use &say to refer to the function as a noun.
at <tmp…
Xliff m: sub d { my $*dyn = OUTER::<$*dyn> // 2; $*dyn.say }; sub a () { my $*dyn = 1; d; };
camelia ( no output )
Xliff m: sub d { my $*dyn = OUTER::<$*dyn> // 2; $*dyn.say }; sub a () { my $*dyn = 1; d(); };
camelia ( no output )
Xliff m: sub d { my $*dyn = OUTER::<$*dyn> // 2; $*dyn.say }; sub a () { my $*dyn = 1; d(); $*dyn.say}; 22:09
camelia ( no output )
Xliff ^^ Shouldn't that output '1 1'? 22:10
m: sub d { my $*dyn = OUTER::<$*dyn> // 2; $*dyn.say }; sub a () { d(); my $*dyn = 1; d(); $*dyn.say};
camelia ( no output )
Xliff m: sub d { my $*dyn = OUTER::<$*dyn> // 2; $*dyn.say }; sub a () { d(); my $*dyn = 1; d(); $*dyn.say}; 22:11
camelia ( no output )
Xliff Any reason for the '(no output)' when there definitely should be? 22:12
m: sub d { my $*dyn = OUTER::<$*dyn> // 2; $*dyn.say }; sub a () { d(); my $*dyn = 1; d(); $*dyn.say }; a; 22:13
camelia 2
2
1
Xliff Derp 22:15
OK, so it looks like the call to OUTER::<$*dyn> silently fails. What's the better way?
sjn just read about guifa's error message translation project 23:00
sjn nice! one question though. would it be an idea to introduce some kind of numeric error code that one would always emit, no matter the locale the message is in? I'm thinking that this might make it easier to google error messages in order to figure out any related discussions on online forums or documentation... 23:03
guifa sjn: that’s more or less how things work, rather than numeric, it’s the type of the exception 23:05
So for instance, X::Str::Numeric indicates that a string couldn’t be turned into a number 23:06
sjn hm right 23:07
guifa lizmat: sorry for it not being in ecosystem. I wanted to get the word out first — I’m very close to feeling it’s stable enough to put in the ecosystem (plus I kind of want one 100% translated language first ha)
sjn I guess that's good enough :) 23:08
btw, why not I18n::X? :) 23:09
guifa Personal preferences :-)
I hate the I18n abbreviation
lucs M1 2o 23:10
guifa So all the international work I’ve done goes into Intl ^_^
sjn I'm not a huge fan either, but it's a very well known term that people will be looking for
guifa Keywords in META6.json ;-)
sjn google doesn't know META6.json.. :-( 23:11
also, the keywords are quite optional
guifa True, but right now I control all of the Intl:: modules so ;-) 23:12
sjn but sure... it's better than nothing.
well, give it a consideration. what's most advantageous for Raku? You probably know better than me to which extent "Intl" is a recognized term out there... 23:13
maybe there are some ways to find some data about this? 23:14
guifa books.google.com/ngrams/graph?corp...8n%3B%2Cc0 :-) 23:15
FWIW, javascript also uses Intl for its namespace 23:16
sjn mm 23:20
Xliff What is the best idiom to use when declaring a dynamic variable that might already exist? 23:21
guifa Xliff: what do you intend to have happen if it already exists vs if it doesn't 23:23
Xliff I*f it already exists, use existing value...otherwise use a default. 23:24
guifa ah okay
Xliff guifa: Think recursion.
guifa my $*foo = CALLERS::<$f*foo> // default;
- typos 23:25
Xliff m: sub d { my $*dyn = CALLERS::<$*dyn> // 2; $*dyn.say }; sub a () { d(); my $*dyn = 1; d(); $*dyn.say }; a;
camelia 2
1
1
Xliff \o/
guifa++
guifa I had to do something similar a whiel back. I needed to check at the start of a sub recursive stub if it had been set, but I wasn’t ready to declare it yet. CALLERS:: came to the rescue 23:27
Xliff m: sub d { say CALLERS::<$a>; my $*dyn = CALLERS::<$*dyn> // 2; $*dyn.say }; sub a () { my $a = 42; d(); my $*dyn = 1; d(); $*dyn.say }; a; 23:29
camelia (LoweredAwayLexical)
2
(LoweredAwayLexical)
1
1
guifa That probably explains the reason I was getting LoweredAwayLexical with something I did yesterday. 23:31
They must have changed $_ from dyn to lexical at some point
Xliff So in the case of CALLERS, it's only there to refer to dynamic vars? 23:32
guifa Correct
Xliff Cool.
guifa OUTERS:: will let you catch variables if you declare an identical name for lexical scopes 23:38
m: my $a = 1; { my $a = 2; say $a; say OUTER::<$a> } say $a 23:39
camelia 5===SORRY!5=== Error while compiling <tmp>
Strange text after block (missing semicolon or comma?)
at <tmp>:1
------> 3; { my $a = 2; say $a; say OUTER::<$a> }7⏏5 say $a
expecting any of:
infix
infix stopper…
guifa err
m: my $a = 1; { my $a = 2; say $a; say OUTER::<$a> }; say $a
camelia 2
1
1
guifa Xliff: also, if you’re worried up early callers poisoning the variable name, you can use CALLER instead of CALLERS to only accept a dynamic variable defined one caller up 23:50
Xliff m: my $a = regexp { / (a) b? / }; say "ab" ~~ $a() 23:59
camelia 5===SORRY!5=== Error while compiling <tmp>
Undeclared routine:
regexp used at line 1
Xliff m: my $a = regex { / (a) b? / }; say "ab" ~~ $a()
camelia 5===SORRY!5===
Unrecognized regex metacharacter / (must be quoted to match literally)
at <tmp>:1
------> 3my $a = regex {7⏏5 / (a) b? / }; say "ab" ~~ $a()
Unrecognized regex metacharacter (must be quoted to match literally)
at <…