🦋 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. |
|||
00:11
thaewrapt left
00:12
thaewrapt joined
00:16
jpn joined
00:20
jpn left
|
|||
[Coke] | .seen Util | 00:24 | |
tellable6 | [Coke], I saw Util 2024-04-16T20:36:58Z in #raku: <Util> Summary: (1) we want more Raku talks. (2) Rakudo internals qualifies for the Science track (paper or poster). Thanks! | ||
[Coke] | ^^ there was an attempt to get more talks. | 00:25 | |
00:37
tirnanog left
00:39
tirnanog joined
|
|||
antononcube | @Coke Right, I remember the call for papers. I strongly considered going, then I decided it is too far and not worth it. | 00:43 | |
01:33
hulk joined
01:34
kylese left
02:15
hulk left,
kylese joined
03:30
jpn joined
03:35
jpn left
04:54
tirnanog left
05:06
tirnanog joined
05:11
tirnanog left
05:23
tirnanog joined
05:30
Sgeo left
05:33
tirnanog left
05:45
tirnanog joined
05:51
tirnanog left
06:02
tirnanog joined
06:08
tirnanog left
06:41
sena_kun joined
06:45
kylese left
06:49
kylese joined
07:08
CIAvash joined
08:18
beastieboo left
08:19
beastieboo joined
08:26
dakkar joined
08:58
beanbrain left
09:33
jpn joined
10:04
jpn_ joined
10:06
jpn left
10:11
jpn joined
10:14
jpn_ left
10:19
CIAvash left
11:01
jpn left
11:04
jpn joined
11:26
Xliff joined
|
|||
Xliff | m: role U[$class] { method-get-class ($a) { ::($ = $a) }; class A does U[B] { }; class B { has $.c }; A.get-class.^attributes.gist.say; | 11:28 | |
camelia | ===SORRY!=== Error while compiling <tmp> Variable '$a' is not declared. Perhaps you forgot a 'sub' if this was intended to be part of a signature? at <tmp>:1 ------> role U[$class] { method-get-class (⏏$a) { ::($ = $a) }; class … |
||
Xliff | m: role U[$class] { method-get-class { ::($ = $class) }; }; class A does U[B] { }; class B { has $.c }; A.get-class.^attributes.gist.say; | ||
camelia | ===SORRY!=== Error while compiling <tmp> Undeclared name: B used at line 1 |
||
Xliff | m: role U[$class] { method-get-class { ::($ = $class) }; }; class A does U['B'] { }; class B { has $.c }; A.get-class.^attributes.gist.say; | ||
camelia | ===SORRY!=== Error while compiling <tmp> Could not instantiate role 'U'; exception details: lang-call cannot invoke object of type 'VMNull' belonging to no language in sub at <tmp> line 1 in any package_declarator:sym… |
||
Xliff | m: role U[$class] { method get-class { ::($ = $class) }; }; class A does U['B'] { }; class B { has $.c }; A.get-class.^attributes.gist.say; | 11:29 | |
camelia | (Mu $!c) | ||
11:38
jpn left
12:04
jpn joined
|
|||
tbrowder | ugexe: using the Build module, what is the correct way to have an installation script get the *contents* of file X in the /resources directory? | 12:12 | |
12:15
jpn left
|
|||
tbrowder | the docs say: $?DISTRIBUTION.content(“resources/X”); | 12:22 | |
12:23
jpn joined
|
|||
antononcube | @tbrowder Can't you just you slurp over %*RESOURCES<X> ? | 12:52 | |
lizmat clickbaits rakudoweekly.blog/2024/07/01/2024-...learnings/ | 13:08 | ||
13:38
jpn left
13:39
jpn joined
14:11
Xliff left
14:47
soverysour joined
14:54
soverysour left
14:55
sjn left,
sjn joined
|
|||
tbrowder | antononcube: it’s a subtle issue in my brain. during a Build and install action i just want to make sure the docs are correct. i’m assuming they are but i like to have ugexe to verify that. | 15:24 | |
antononcube | @tbrowder Good luck! | 15:25 | |
ugexe | you don't get access to $?DISTRIBUTION in Build. Build implies that it must occur before the distribution truly exists | 15:31 | |
if the distribution hasn't been built, how could $?DISTRIBUTION exist in other words | 15:32 | ||
at build time i | 15:34 | ||
that being said, you could just do: | |||
class Buikd { method build($dist-path) { my $dist = Distribution::Path.new($dist.IO); say $dist.content("resources/foo.txt") } } | |||
rather: class Build { method build($dist-path) { my $dist = Distribution::Path.new($dist-path.IO); say $dist.content("resources/foo.txt") } } | |||
at build time though I'd probably just access the paths directory without using a distribution object | 15:35 | ||
i.e. class Build { method build($dist-path) { say $dist-path.IO.slurp } } | |||
either one should work for you | 15:36 | ||
i don't know why you'd have a Build.rakumod file to verify docs are correct though. that means it would be occuring on every users computer that installs that distribution, when in reality it should only ever need to be verified once by the author | 15:37 | ||
so maybe that verification would be better in a xt/foo.rakutest file that you as the author manually run | 15:38 | ||
15:49
soverysour joined
16:01
jpn left
16:07
tejr left
16:08
tejr joined
|
|||
[Coke] | +1 | 16:13 | |
16:34
beanbrain joined,
beanbrain left,
beanbrain joined
16:36
dakkar left
|
|||
tbrowder | maybe not. the resources include a font file that may or may not already exist the first time the module is installed. it also installs a user font config file if it doesn’t exist. if it does exist, the user may have misconfigured it. | 16:36 | |
and it will be repaired. | 16:37 | ||
ugexe | distributions should be immutable | 16:47 | |
adding things to resources/ at build time is mutating it | 16:48 | ||
if you have some file to instal that may or may not exist, it should be installed outside the scope of raku. i.e. install to $HOME/.some-known-directory, and have your code reference that | 16:49 | ||
tbrowder | that’s what i’m doing | 16:50 | |
ugexe | ah i parsed your sentence wrong then | 16:51 | |
tbrowder | not adding to resources, using them | ||
ugexe | i think you have to be careful around assuming if it exists that it might be misconfigured | 16:52 | |
for example, someone installs your module which runs that Build.rakumod and installs that file. Then they uninstall that distribution which does nothing to remove the file you installed with Build.rakumod. Then they later go to install it again | |||
tbrowder | yes. i just check it for proper contents and structure and inform user | 16:53 | |
and fix it | |||
the config file is a hash for quick lookups of local but required font files | 16:57 | ||
17:01
abraxxa-home joined
17:05
soverysour left
17:08
abraxxa-home left
17:09
abraxxa-home joined
17:18
soverysour joined,
soverysour left,
soverysour joined
17:50
derpydoo joined
|
|||
librasteve | o/ | 18:02 | |
just coming on the chat - @ingy has made some counterpoints to mine - so, maybe I am out of line - what is the "show of hands" on this channel about the recent tprc (+) means good for raku, (-) means bad for raku, (++) / (--) weight for folks that attended... | 18:04 | ||
antononcube | @librasteve You are not "out of line." I, on the other hand, consider writing a blog post "Reasons not to use Raku." I have a few versions of it, BTW. | 18:05 | |
I have written similar for other languages -- WL, Python, R, Swift. | 18:06 | ||
(Reasons not to use those, that is...) | |||
librasteve | on the basis of Murphys law, that would probably boost interest in raku | ||
antononcube | Yeah, "Streisand law", I think. | 18:07 | |
librasteve | we need to collect all the counter fashionistas | 18:08 | |
antononcube | Yeah, that would be good. | 18:09 | |
I need to finish my R rant / blog. I was just explaining the main reason "why not R" to a computer scientist. | 18:13 | ||
18:13
beanbrain left
|
|||
The thing is for R there is well know effort doing that kind criticism -- that cannot be criticized -- called "The R Inferno." | 18:14 | ||
That is high bar to reach... | |||
@librasteve I think your ±raku / ±perl study has to be done via Google forms or similar. | 18:16 | ||
librasteve | well - I see that you have not confined yourself to my +/- format | ||
antononcube | Of course, we can/should write a "Cro" app for that. (Or "HummingBird" one.) | ||
@librasteve 🙂 I am using your "around / interval" arithmetic post as guide. | 18:17 | ||
librasteve | as a guide to "why not raku"? | 18:18 | |
antononcube | no, to use "±raku" and "±perl" -- I misunderstood. | 18:19 | |
...And I was referring to this post : rakujourney.wordpress.com/2023/11/...rithmetic/ | 18:20 | ||
librasteve | thank you and you're welcome! | 18:21 | |
antononcube | Sure. The keyword Around is from WL, by the way. I strongly susptect it was introduced because of units-related workflows. | 18:22 | |
Interval and co., on the other hand, have "always" been in Mathematica. (Most like post version 2.0.) | 18:26 | ||
librasteve | my recent reading suggests that Interval arithmetic is a useful tool in rather an abstract way, but that its inability to represent Gaussian means that it is not a useful tool for physicists | 18:27 | |
ie to represent physical measurements | 18:28 | ||
18:28
soverysour left
|
|||
antononcube | Hmm... I wonder is Around of Mathematica / WL trying to address that. See here: reference.wolfram.com/language/ref/Around.html | 18:29 | |
librasteve | ah! thanks for the references | ||
19:05
silug left
19:07
silug joined
19:46
silug left
20:20
dmvrtx joined,
thaewrapt left
20:22
thaewrapt joined
20:27
thaewrapt left
20:30
thaewrapt joined
20:31
derpydoo left
20:38
xinming left
20:40
xinming joined
21:17
rypervenche left
21:39
rypervenche joined
21:53
beastieboo left
22:20
abraxxa-home left
22:35
Sgeo joined
22:41
sena_kun left
23:53
silug joined
|