🦋 Welcome to the MAIN() IRC channel of the Raku Programming Language (raku.org). This channel is logged for the purpose of keeping a history about its development | evalbot usage: 'm: say 3;' or /msg camelia m: ... | Log inspection is getting closer to beta. If you're a beginner, you can also check out the #raku-beginner channel!
Set by lizmat on 25 August 2021.
00:07 reportable6 left 00:08 clarjon1 left 00:09 reportable6 joined 00:14 rbt left, rbt joined 00:27 Guest35 left 00:32 lichtkind left 00:41 londoed_ left, londoed left 00:42 londoed_ joined, londoed joined 00:53 rir left 00:59 rbt left, rbt joined 01:04 rbt left 01:06 guifa joined
SmokeMachine u: element of 01:27
unicodable6 SmokeMachine, U+2208 ELEMENT OF [Sm] (∈)
SmokeMachine, U+2209 NOT AN ELEMENT OF [Sm] (∉)
SmokeMachine, 13 characters in total (∈∉∊⋲⋳⋴⋵⋶⋷⋸⋹⟒⫙): gist.github.com/1c28a0131096aa0b8e...0dd3c5bcc7
01:28 melezhik joined
melezhik . 01:29
tellable6 2022-04-16T23:06:08Z #raku <SmokeMachine> melezhik it seems it's not being able to connect to PG...
2022-04-16T23:10:17Z #raku <SmokeMachine> melezhik sorry, it seems I misunderstood the message: `stderr: initdb: warning: enabling "trust" authentication for local connections`
2022-04-16T23:11:26Z #raku <SmokeMachine> melezhik I'm not finding what the error is on this log: sparrowhub.io:2222/report/132\
2022-04-16T23:12:35Z #raku <SmokeMachine> melezhik the truth is I can't see it running the tests...
01:30 melezhik left, melezhik joined
melezhik .tell @SmokeMachine to see test report you need to open "report" tab 01:32
tellable6 melezhik, I cannot recognize this command. See wiki for some examples: github.com/Raku/whateverable/wiki/Tellable
01:32 leedo left 01:33 melezhik left, melezhik joined
melezhik .tel SmokeMachine  to see test report you need to open "report" tab 01:34
Uploaded file: uploads.kiwiirc.com/files/8e9ec06e...2%20PM.png 01:38
^^ SmokeMachine
also init section creates all required red db user with password as well as test database 01:40
stderr: ++ sudo -u postgres psql -c 'create user testuser with password '\''testpass'\'''
 sudo -u postgres sh -l -c 'createdb redtest'
sudo -u postgres psql -c 'grant all privileges on database redtest to testuser;'
RED_DATABASE=Pg host=localhost port=5432 user=testuser password=testpass dbname=redtest
I also increase timeout to 1000 sec per build hopefully it will solve the problem of timeout for long running builds ... 01:46
01:57 melezhik left 02:04 frost joined 02:16 hhcryfqnut joined
hhcryfqnut this was tripping me up``` 02:18
[0,1] == [1,1]
```
before i realized it was comparing the lengths (i see that i need to use `eqv`)
also, as someone who has never done perl, i find the `@` sigil very tricky. (i think i'm getting the hang of it tho) 02:19
moon-child fwiw @ works differently than in perl 02:24
hhcryfqnut ah. i'm less alone then. lol 02:26
are these the same `(1,1).Array eqv [1,1].Array`   `(1,1) ~~ [1,1]`
02:44 melezhik joined 02:48 leedo joined, melezhik left 03:24 melezhik joined
melezhik . 03:24
03:30 melezhik left 03:35 rbt joined
guifa (1,1).Array becomes [1,1] 03:40
tellable6 2020-08-04T08:17:00Z #raku-dev <JJMerelo> .tell guifa can you upload your artlcle to the WP site as a draft? Let me schedule it when it's more convenient.
2020-08-06T08:20:00Z #raku-dev <JJMerelo> .tell guifa2 OK, great, thanks. That date is probably OK, I'll check.
guifa ummmmm
tellable6 you are drunk
AlexDaniel A little bit! 03:45
It was down for some time, I had some restoring to do 03:46
For some messages it doesn't know if it delivered them or not, sorry
guifa haha it's fine, that was just a bit hilarious
AlexDaniel :) I just made double sure that it delivers what it promised to deliver, in this case I guess I was too pessimistic 03:47
guifa I mean, I don't know. It might not have delivered that ever 03:51
I don't hop on raku-dev often, so if it used to go per channel, it might not have had the chance 03:52
04:22 hhcryfqnut left 04:35 zacts joined 04:47 xinming left 04:49 xinming joined 05:06 zacts left 05:40 rbt left, rbt joined 05:46 frost left 06:07 reportable6 left 06:08 reportable6 joined 06:56 rbt left, rbt joined 07:06 clarjon1 joined 07:18 guifa left 07:32 jjido joined 07:46 rbt left, rbt joined 07:51 rbt left, rbt joined 08:15 lichtkind joined 08:26 grondilu joined
grondilu m: class { has $.foo; multi method new($foo) { LEAVE say $.foo; self.bless: :$foo } }.new: "bar" 08:29
camelia Cannot look up attributes in a <anon|1> type object. Did you forget a '.new'?
in method foo at <tmp> line 1
in method new at <tmp> line 1
in block <unit> at <tmp> line 1
grondilu 🤔
should't the blessed instance be accessible in the LEAVE phaser? 08:30
nevermind I think I should use a BUILD submethod 08:33
lizmat grondilu: nowadays I would almost always recommend using TWEAK 08:37
problem with your code is that "self" inside "new" is still a type object, and $.foo is just short for "self.foo" 08:38
grondilu looked at the doc for TWEAK 08:47
yeah it looks more like what I need
09:22 rbt left, rbt joined 09:52 rbt left, rbt joined 10:23 zacts joined 10:30 Sgeo left 10:58 zacts left 11:00 djerius left 11:25 discord-raku-bot left, discord-raku-bot joined 11:31 xinming left 11:32 xinming joined 11:33 ProperN[out] joined 11:34 ProperNoun left 11:36 jjido left 11:51 sena_kun left 11:53 sena_kun joined 11:59 euandreh joined 12:02 euandreh_ left 12:04 euandreh left 12:07 rbt left, rbt joined, reportable6 left 12:10 reportable6 joined 12:34 frost joined 12:53 rbt left, rbt joined 13:08 razetime joined 13:55 razetime left 14:08 rjbs left 14:09 zacts joined 14:10 rjbs joined 14:23 rbt left, rbt joined 14:34 zacts left 14:42 melezhik joined 14:46 melezhik left 14:53 rbt left, rbt joined 15:06 [Coke] left 15:10 [Coke] joined 15:21 zacts joined 15:44 [Coke] left, frost left, [Coke] joined 15:52 zacts left 16:52 evalable6 left, linkable6 left 16:53 linkable6 joined 16:54 evalable6 joined
Tirifto m: /<( [ Q[\] . || <-["]> ] * )>/ 17:07
camelia ===SORRY!=== Error while compiling <tmp>
Unable to parse expression in metachar:sym<[ ]>; couldn't find final ']' (corresponding starter was at line 1)
at <tmp>:1
------> /<( [ Q[\] . || <-["]> ] * )>⏏/
expecting any of:
Tirifto m: raku -e '/<( [ Q[\\] . || <-["]> ] * )>/' 17:08
camelia ===SORRY!=== Error while compiling <tmp>
Two terms in a row
at <tmp>:1
------> raku -e⏏ '/<( [ Q[\\] . || <-["]> ] * )>/'
expecting any of:
infix
infix stopper
postfix
statement end
Tirifto m: /<( [ Q[\\] . || <-["]> ] * )>/
camelia ( no output )
Tirifto ^ Is this a bug in Raku, or did I miss something? According to the documentation, Q quoting notation does not allow for backslash escapes, but it seems like backslash escapes are used anyway, since the first expression above throws an error, but the third one (where the backslash is escaped in ‘Q[\\]’) compiles just fine. (The second expression was a bad copy.) 17:10
17:14 rbt left, rbt joined
Geth doc: 30206e44bb | (JJ Merelo)++ | xt/check-signatures.t
Minor doc changes #3871
17:17
17:18 linkable6 left 17:20 linkable6 joined
Geth doc: 15ec823039 | (JJ Merelo)++ | xt/check-signatures.t
Prints the error to make it a bit more informative #3871
17:31
17:31 linkable6 left 17:32 linkable6 joined 17:36 grondilu left 17:44 [Coke]_ joined, [Coke] left 18:00 jjido joined 18:07 reportable6 left 18:09 sena_kun left, reportable6 joined 18:10 sena_kun joined 18:44 rbt left, rbt joined 18:54 rbt left, rbt joined
gfldex Tirifto: You are just matching for Q followed by a backslash. 19:00
Tirifto gfldex, Q doesn’t work as a quoting construct inside regexes? :o 19:02
gfldex indeed
Tirifto Ahh, I see. 19:03
Thank you!
19:37 sena_kun left 19:39 sena_kun joined 19:54 Sgeo joined 20:10 Oshawott joined 20:14 archenoth left 20:20 p6steve joined
Tirifto If I’m writing a parser for a document language, are there best practices to naming the module? 20:21
I see that there is a namespace for some languages that some modules/parsers use as their parent (XML::Parser::Tiny, XML::Actions, JSON::Fast, JSON::Tiny, JSON::Pretty), while others use it directly (XML, TOML), while others don’t use it at all (LibXML, YAMLish). This leaves me wondering what pattern should I follow if I would like to write and publish some modules and make them convenient for everyone. 20:26
gfldex It's clear that XML and JSON need parsing. So if the default action is parsing, there is no need to point out your module is a parser. 20:34
p6steve I would say that there are several (competing) conventions: (i) wrapping a perl5 cpan module or native C lib ?? LibXML is a wrapper of libxml, (ii) closely related modules may share a lib file tree conceptually (I am not sure that this is how they are installed anymore - but orginally in perl5 then you knew that XML::Actions would be in folder something like site/lib/XML, (iii) if you set out to write or 20:43
tellable6 2020-08-07T08:37:00Z #raku-dev <JJMerelo> .tell p6steve you ready to upload your article, or you want me to upload it for you?
hey p6steve, you have a message: gist.github.com/382ec639cdfd2d866d...7c6d881186
p6steve somehow define a "world" of interacting modules (like Cro) then it may not be obvious the best way to define and reuse code in a class structure - but as you work out the design this will become clear (for you) and you can then name the higher levels accordingly
Tirifto Thank you. I guess I may as well just use the language name then, and see if that works alright in practice. :-) 20:49
20:53 monkey_ joined 21:26 lichtkind_ joined 21:28 lichtkind left 21:35 rbt left, rbt joined 21:40 rbt left, rbt joined 22:01 juanfra__ joined 22:10 mexen left 22:17 lichtkind_ left 22:18 londoed left, londoed_ left
japhb Tirifto: If you're writing a parser *only*, and not a serializer, then having Parser in the name is reasonable. If you're doing both directions, then the main name shouldn't include it, but it's reasonable to have submodules that do (e.g. DocLang containing DocLang::Parser and DocLang::Writer). 22:28
I tend to use ::Tiny if the *implementation* is minimalist, ::Simple if the *API* is minimalist 22:29
I personally feel that data codecs should be well optimized anyway, so I generally prefer ::Simple over ::Fast if I think both names might apply; as far as the caller is concerned, ::Simple is an API design decision, but ::Fast is baseline. ::Tiny usually means that either the implementation is the smallest thing that could reasonably work at all, or that it's designed to favor small, easy-to-read code over 22:31
any other factor.
JSON::Tiny, for instance, is a showcase for how much of a difference Grammars can make in terms of implementation clarity. 22:32
23:18 linkable6 left, evalable6 left 23:19 evalable6 joined 23:21 linkable6 joined 23:25 rbt left, rbt joined 23:30 jjido left 23:36 rbt left 23:49 monkey_ left 23:56 rbt joined