🦋 Welcome to the MAIN() IRC channel of the Raku Programming Language (raku.org). Log available at irclogs.raku.org/raku/live.html . If you're a beginner, you can also check out the #raku-beginner channel!
Set by lizmat on 6 September 2022.
guifa_ hmm, weird 00:00
I have a subclass B of a subclass A of Hash. The A subclass overrides AT-KEY / SET-KEY, and the B subclass doesn't define anything for it. But Raku hangs on calling AT-KEY for B and based on say statements, never calls the A method. 00:02
Nemokosch are they not submethods by any chance?
guifa_ they're just plain methods, which should mask the Hash implementation (confirmed by .^mro) 00:07
I'll try submethod
something feels fishy but I haven't figured out how to figure out the MRO for a method (just for the type)
Nemokosch yeah I mean who am I trying to fool, you probably wouldn't fall into that trap 00:13
guifa_ well that's just the thing, I feel like I *must* be falling into some trap 00:14
Anton Antonov The trap falling into will continue until raccoons improve. 00:23
guifa_ What's stranger about this one is I swear it worked just fine at some point a while ago 00:28
BUt this is in my CLDR module so golfing it down will take me a while 00:29
it's an easy enough work around for now (just explicitly giving B an AT-KEY / SET-KEY method, which just call self.Hash::AT-KEY or bomb for SET-KEY) but still, it's weird 00:30
Nemokosch is there any sort of Raku integration for the `file` program? 01:21
Anton Antonov <@297037173541175296> What is th `file` program? 01:56
<@297037173541175296> What is the `file` program?
tbrowder tonyo: no disrespect, but csv module from tux has an API that doesn't work with my coding style. 02:28
tonyo none taken ! I usually ask so when I design other things I can consider how others prefer things to be 02:39
japhb Anton Antonov: `file` is a Unix/Linux standard command for guessing file type based on the file's *contents*, rather than on extension (as is common on Windows, for instance). 02:55
The Mac folk have (or had, at least) yet another different method for this, based on marking binary files with 4-character type identifiers. 02:56
Anton Antonov @japhb Thank you for your clarifications! 09:50
tbrowder tonyo: also, that module needs to be updated to fit better into current practice like github workflow testing, more info in README, etc., i.e., it also needs an Apo::Mi6 makeover 10:17
Nemokosch Hey, that doesn't sound like a problem to me, I like to renovate stuff 10:19
I prefer fixing modules over creating yet another module 10:21
lizmat clickbaits rakudoweekly.blog/2022/10/31/2022-44-prename/ 11:13
guifa_ japhb: yeah, resource forks are mostly gone in the Mac world. Since most other OSes / file systems (I think it was more embedded in the FS iirc) don't really have an equivalent, it meant the potential for lossy data transfers between systems unless you were being very careful. But they were really useful used well 11:23
Geth ¦ problem-solving: 2colours assigned to codesections Issue Raku / Perl 6 books - CCR measures and beyond github.com/Raku/problem-solving/issues/349 11:36
Anton Antonov @lizmat Thanks for finding out (and placing) the conference and video links for my presentation in the last Rakudoweekly post! 13:30
Nemokosch Can somebody confirm that `zef --help` writes onto stderr? 14:12
Another one: what do you think of ().min producing Inf and ().max producing -Inf? 14:55
Seems random to me and I couldn't find it in the docs, or any related issues 14:56
dutchie logical enough 15:07
the idea is that `@a.min min @b.min == (@a, @b).flat.min` is always true even either of @a or @b is empty 15:10
so .min of an empty list should return an "identity"
Nemokosch I would say not enough, actually
This could be achieved with Nil as well 15:11
dutchie what about ().sum? 15:12
it's the same idea
Nemokosch and I think any argument that applies in numeric context, actually fails when the empty list is not an empty *numeric* list
including your very example
dutchie i guess it also falls apart a bit with a &by argument 15:14
Nemokosch The problem is that .min makes sense in non-numeric contexts and it does work in general
that's unlike .sum 15:15
So I think Nil (or even Any) would be a better default, or at least this behavior should be documented, pointing out the special behavior of Inf (~~ Numeric) with regards to non-numeric situations 15:19
Usually when I ask these questions, the background motive is "should I open an issue for it or not" 15:23
dutchie imo it's worth opening it to discussion with people who aren't paying attention to this chatroom right now 15:33
tonyo fez v38 is out in the world now, major change is using `pax` as the bundler rather than `git`/`tar`..people that were using git will see the files on disk (rather than committed to the branch) bundled rather than what was committed 16:08
[Coke]_ TIL about pax 17:15
thundergnat <Nemokosch> is there any sort of Raku integration for the `file` program? - Not exactly, but raku.land/github:thundergnat/Filetype::Magic uses libmagic, which id what File uses to determine file types. 17:29
tonyo tbrowder: just pushed some fixes/enhancements for CSV
tonyo please checkout 0.1.3 and lmk how it goes 17:31
Nemokosch thundergnat: this is really nice, I will check it for sure 17:41
Xliff \o 19:15
Raku bindings for GDK4 are now a thing...
github.com/Xliff/raku-GDK4 19:21
Nemokosch what is GDK? 19:23
Superstart033 I want to know too 19:27
Xliff Nemokosch: Part of the Gnome Took Kit (GTK)
tellable6 Xliff, I'll pass your message to Nemokosch
Xliff And GTK is this thing: docs.gtk.org/gtk4/getting_started.html 19:28
Superstart033 LOL, game dev in Raku is real! 19:29
Xliff Not quite yet. 19:30
But getting there.... maybe...
And TUI games in Raku are already possible.
Superstart033 So that means a roguelike is possible? 19:31
Xliff Oh, definitely.
Please note, work on GDK4 has just started. 19:32
I don't plan on starting work on GTK4 until late Q2 2023.
Superstart033 I see 19:43
Then what would you recommend right now for TUI apps?
tbrowder tonyo: thnx, i’ll check it out 20:06
tonyo also, tbrowder feel free to PM me whenever if you're having something with a module. i get 1k + github notifications a day from work and they get lost in the sauce 20:23
Nemokosch japhb has a solid portfolio of Terminal-related modules 20:29
tbrowder tonyo: wilco 20:35
tbrowder tonyo: i'm swamped with non-raku business rest of day, hopefully will check out CSV tomorrow 20:47
japhb Superstart033: Talk discussing Terminal-related modules: conf.raku.org/talk/178 21:26
Superstart033 Thanks 21:35
japhb Of course! 21:52
Nemokosch I'm starting to realize that the "smartmatch with S///" problem boils down to the fact that smartmatch drifted away from its principle 21:56
it is treated as something that only makes sense in boolean context / always produces boolean values 21:58
however, this is not true, and it is not true exactly around regexes
I wanted to use this long weekend for an issue dump but eventually I only managed like one or two 22:25