01:34 ab5tract left 01:41 kylese left, kylese joined 02:15 kylese left, kylese joined 03:05 Aedil joined 03:35 guifa left 03:56 Aedil left 04:14 Aedil joined 05:30 Sgeo left 05:35 Aedil left 06:08 Chanakan left 06:22 Aedil joined 06:27 floyza left 06:54 ab5tract joined 07:18 holyghost left 08:11 dakkar joined 09:03 ab5tract left 09:54 blendux joined
Geth ¦ problem-solving: tbrowder assigned to rba Issue Raku's Github list of popular repositories is outdated and needs a new listk github.com/Raku/problem-solving/issues/448 10:10
¦ problem-solving: lizmat unassigned from rba Issue Raku's Github list of popular repositories is outdated and needs a new list github.com/Raku/problem-solving/issues/448 10:29
tbrowder i need help with hypering a zef command. all the hypering examples i've seen confuse me to no end as to how to assemble the pieces. my single zef cmd is "zef info SomeModule". when i iterate over a list of 47 locally installed modules and use "run $cmd" on them i usually get okay results, but sometimes i get one or two undefined or Any results which i think is caused by zef's hypering. 11:28
lizmat zef doesn't hyper afaik ?
tbrowder hm, then i don't understand why i sometime i get differing output on the same inputs. probably my error--will check again. 11:33
but i would still like to hyper it. i looked at yr hyperize and it's too much golfing to me--not sure how the above would look. 11:34
lizmat fwiw, if you could create a golf that shows breakage, that would be appreciated :-) 11:36
OTOH, zef is a frontend to functionality in the core... perhaps you don't need to call zef ?
tbrowder ref zef, i have an ongoing convo now w/ugexe about auth use of zef. and i'll try use hyperize, too. 11:47
i'm proposing a new function for zef: cmd 'lint' to check in a module sourve repo any mismatch between /resources and META6.json.resources. 11:49
*source
12:00 Aedil left
tbrowder hyperizing zef would be helpful because a zef info call can take a while. i don't think i have enough chutzpah and time to access the module databases like zef does 12:01
12:02 kaholaz left
tbrowder lizmat: i think i got hyperize to work! yahoo!\if i get the zef thing working, would you take a PR with a simple sample? 12:55
i used racify which should really be speedy for my needs 12:56
hm, one big question: is pushing to the @results array thread safe? or do i need to get the array index via the map or grep? 13:08
or? 13:09
lizmat arrays are **not** thread safe 13:40
the easiest way is something like
my @results = @source.&hyperize.map( { do your thing } ) 13:41
that will make sure the results *are* stored in the main thread, and thus threadsafe 13:42
ugexe Note I’ve closed issue about linting in zef before due to my stance that zef isn’t the place for such a linter. Further, even the request to ensure resources listed in meta6 and the actual files in the directory are exactly the same is a manner of style - it is perfectly fine to have files anywhere in a repository that are not listed in META6.json somewhere (e.g. folder specific readmes, dot 13:46
files like the cache tag, etc)
Why not just write a linter program to distribute and/or use? 13:51
tbrowder ugexe: i still disagree, but (1) why on earth do we even need /resources if zef doesn’t care and (2) where do you think the proper place for a linter is? 13:53
note i have filed an issue with App::Mi6 to provide such a check. 13:54
ugexe do you believe that every file the filesystem sees under resources/ should be listed in META6.json? if so then we just fundamentally disagree 14:06
if you believe that every file listed in META6.json should exist period, then you can just try to install a distribution and rakudo itself will die due to the missing file
the proper place for a linter is a linting program 14:07
not a package manager
that is how (i believe) every other language works 14:09
golang generally uses the golangci-lint executable, perl generally uses the e.g. perlcritic executable, etc
14:12 Aedil joined 14:13 tea3po left
tbrowder ok, i’ll be quiet on the subject. thanks. 14:17
ugexe if zef were to theoretically ever run linting, it'd ultimately want to do it by running an external command anyways. the other benefit of an external command is external dependencies can be used to implement it (which can't be done in zef, which aims to be dependency free so to speak) 14:20
similar to how zef tests things by using an external command, or extracts things with an external command, etc 14:21
tbrowder oops, one more comment: just because every other language does it that way is no justification imho. raku is different in lots of ways, why not have a better package manager too?
ugexe just because we don't have something doesn't mean we are lacking. i had hoped i had made it clear that these decisions have been made mindfully based on tradeoffs that have been considered. 14:22
the fact other languages do it does go to show that other very smart people have come to the same conclusion 14:23
fwiw I probably run a linter nearly a hundred times per week at work, so I'm familiar with their usefulness and using them in my general workflow 14:31
In software engineering it's a best practice for tools to have a single, well-defined purpose. A package manager is designed to handle dependencies, package installation, and version management. A linter, on the other hand analyzes code for errors, style issues, and potential bugs. Combining them violates the single responsibility principle, making the tool more complex and harder to maintain. 14:38
It's generally better to have specialized tools that excel in their specific domains. This allows for easier maintenance, better performance, and more flexibility in choosing the best tools for a given project's needs 14:39
So I'd argue that while integrating a package manager and a linter into a single tool might offer some convenience, it introduces more problems than it solves 14:40
Although again, I'm not saying having a linter is bad. Just that I don't thinking having the package manager be the linter is not ideal 14:41
14:43 ab5tract joined 15:02 orangebot joined 15:09 El_Che left 15:11 El_Che joined 15:56 DarthGandalf left 15:57 DarthGandalf joined 16:08 blendux left
tbrowder 👍🏻 16:34
lizmat: ref hyperize: inside the {} is it safe to call a sub with no other nested subs? 16:36
16:38 rir joined
tbrowder so far i’m getting expected results, but able to use a sub there would certainly declutter the code 16:39
it was not obvious to me how the elements of @results were being added but i see anything created is added so i should be able to create a class object it and access it later, true? 16:43
back to the sandbox… 16:44
16:47 rir left, rir joined
lizmat m: sub a($a) { 2 * $a }; dd (^10).map: &a 16:48
camelia (0, 2, 4, 6, 8, 10, 12, 14, 16, 18).Seq
lizmat tbrowder: ^^ is that an answer ?
m: sub a($a,$b) { $a * $b }; dd (^10).map: &a
camelia (0, 6, 20, 42, 72).Seq
16:49 dakkar left
lizmat it can even haz multiple args 16:49
tbrowder cool 17:02
17:42 rir left 18:09 ab5tract left 19:20 clarkema1234 joined 19:24 Aedil left 19:25 stanrifkin joined, clarkema1234 left, clarkema1234 joined 20:28 guifa joined 20:51 guifa left 20:55 floyza joined 21:02 orangebot left 22:01 clarkema1234 left 22:02 clarkema1234 joined 22:03 itaipu left 22:14 Sgeo joined 22:16 stanrifkin left 22:17 itaipu joined 22:51 floyza left 23:26 ab5tract joined