🦋 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:00
reportable6 left,
reportable6 joined
00:11
smarton left
01:09
_elcaro_ joined
01:12
razetime joined
01:17
_elcaro_ left
01:20
linkable6 left
01:22
linkable6 joined
01:35
deoac joined
01:59
ProperNoun left
02:01
ProperNoun joined
02:16
razetime left
02:17
razetime joined
02:21
guifa joined
02:25
guifa left
02:54
Xliff left
03:05
razetime left
03:18
japhb left
03:41
deoac left
03:45
japhb joined
04:29
guifa joined
04:32
guifa_ left
05:19
siavash joined
05:59
jpn joined
06:00
reportable6 left
06:02
reportable6 joined
06:44
ProperNoun left
|
|||
El_Che | tbrowder__: sudo is not root (environment wise). You need sudo -s for that (or su) | 06:55 | |
tbrowder__: depending on the configuration some setings/envs from the user are kept | |||
06:56
fanta1 joined
07:41
ProperNoun joined
07:46
Sgeo left
08:00
sena_kun joined
08:08
jpn left
08:10
abraxxa joined,
dakkar joined
08:17
tea3po left,
tea3po joined
08:20
MasterDuke left,
hythm left,
tea3po left,
tea3po joined
08:42
razetime joined
08:44
wafflus joined
08:58
abraxxa1 joined
09:00
abraxxa left
09:17
fanta1 left
09:18
sena_kun left,
sena_kun joined
09:40
wafflus left,
pierrot left
09:41
pierrot joined
09:46
pierrot left,
pierrot joined
10:00
siavash left
10:20
cm_ joined
10:21
cm left,
cm_ is now known as cm
|
|||
librasteve | ugexe - i now have a couple of quiet hours to work on this ... please can you elaborate on the "print the output of the resource of the META6.json it guesses"? is this just to handle the dan => libdan.so mapping maybe? | 10:46 | |
write something to populate it for you say CompUnit::Repository::FileSystem.new(prefix => $*CWD.add("lib")) .distribution.meta<resources> for instance (point it at the lib directory specifically so it doesn't use the existing META6.json and has to generate one) then we print the output of the resources section of the META6.json data it guesses for the lib dir you might have to modify the things prefixed with | |||
libraries/ though, i dunno if it can properly guess those | |||
^^^ this is the relevant info from up above | |||
10:47
thebb joined
11:10
hythm joined
11:17
abraxxa1 is now known as abraxxa
|
|||
ok ... getter deeper in...I think that you mean use the output of the inspection to dynamically modify the META6.json prior to the INSTALL stage. This will give me something in "repo" space that looks like this: L resources L libraries L libdan.so L dan L target L ... L deps L ahash-b969b0faba930866.d L aho_corasick-5793093b55abbd53.d L ... 267 more of these | 11:19 | ||
And something in META6.json that looks like this for the INSTALL stage: "resources": [ "libraries/dan", <= that's the libdan.so "dan/target/.../deps/ahash-b969b0faba930866.d", "dan/target/.../deps/aho_corasick-5793093b55abbd53.d", ... 267 more of these ], And so, finally I will have a bunch of mappings eg. %?RESOURCES<libraries/dan> => | |||
/root/rakudo/share/perl6/site/resources/499157652A301782B3B09AAE3147D98600012DDF.so %?RESOURCES<dan/target/.../deps/ahash-b969b0faba930866.d> => /root/rakudo/share/perl6/site/resources/499157652A301782B3B09AAE3147D986000xxxxx.d %?RESOURCES<dan/target/.../deps/aho_corasick-5793093b55abbd53.d> => /root/rakudo/share/perl6/site/resources/499157652A301782B3B09AAE3147D986000xxxxx.d BUT, the thing is that I need to run an | |||
incremental build for a rust lib on the fly as part of my module so that I can mix in some generated code: run <rustc -L ../target/.../deps --crate-type cdylib apply.rs>; AND, this needs ../target/.../deps to be a coherent directory (not sure if the names matter?) for the rustc to pick up all the deps already built during the install. SO, I suspect you will tell me that there is no method to pass a whole dir over short of | |||
making one manually with symlinks on first run of the code ...?? | |||
tbrowder__ | El_Che: yes, sudo -s and sudo -i are part of what i am relearning. i also just read more closely yr instructions in the rakudo-pkg info on the website. i will play around with that today and see if can get some very old habits retrained. i'm | 11:21 | |
sure that will be a chore, but here goes anyway. thank you so much for your kind patience with my fumbling. | 11:22 | ||
12:00
reportable6 left
12:01
reportable6 joined
12:11
amano joined
|
|||
amano | Does anyone know how to use listen-path and connect-path from IO::Socket::Async? | 12:12 | |
12:15
jgaz joined
|
|||
dakkar | relating to some fedi notes… | 12:41 | |
m: say 𒐀 | |||
camelia | 2 | ||
dakkar | m: say 𒐀𒐁 | ||
camelia | ===SORRY!=== Error while compiling <tmp> Bogus postfix at <tmp>:1 ------> say 𒐀⏏𒐁 expecting any of: infix infix stopper postfix statement end statement modifier … |
||
dakkar | m: say "𒐀".num | ||
camelia | No such method 'num' for string '𒐀'. Did you mean any of these: 'Num', 'sum'? in block <unit> at <tmp> line 1 |
||
dakkar | m: say "𒐀".Num | ||
camelia | Cannot convert string to number: base-10 number must begin with valid digits or '.' in '⏏𒐀' (indicated by ⏏) in block <unit> at <tmp> line 1 |
||
dakkar | is all of that expected & intended behaviour? | 12:42 | |
nemokosch | this is probably some funny number system, right? | 12:46 | |
dakkar | cuneiform, but any non-ASCII digits almost certainly behave the same way | 12:47 | |
oooh, no, I'm wrong! | 12:48 | ||
m: say 𖭑𖭒 | |||
camelia | 12 | ||
nemokosch | Num only works with Arabic numerals | ||
say <two empty squares> | |||
rip | |||
dakkar | m: say "𖭑𖭒".Num | ||
camelia | 12 | ||
dakkar | turns out there's a big difference between "digit" and "numeric sign" | 12:49 | |
nemokosch | what is this character? | ||
dakkar | I suspect it's got something to do with non-base-10 representation | ||
so, the first characters I tried were U+12400 CUNEIFORM NUMERIC SIGN TWO ASH and U+12401 CUNEIFORM NUMERIC SIGN THREE ASH | 12:50 | ||
nemokosch | the arrows did show up | ||
dakkar | the other two (those that worked more) were U+16B51 PAHAWH HMONG DIGIT ONE and U+16B52 PAHAWH HMONG DIGIT TWO | 12:51 | |
nemokosch | I wonder if it's supposed to work | 12:52 | |
or like is it even a good idea | |||
dakkar | with digits, yes | ||
same as /\d/ will match non-ASCII digits | |||
nemokosch | Now that's what I'm not that sure of. Whether they should be the same. | 12:53 | |
dakkar | if you don't want it, filter/validate/sanitise your inputs 😜 | ||
nemokosch | After all, .Num is a coercion method, not a parsing method | 12:54 | |
it would be better if it didn't make funny round-trips | |||
dakkar | nobody shoul expects .Num↔.Str to round-trip | ||
m: "010.010".Num.Str | 12:55 | ||
camelia | ( no output ) | ||
dakkar | m: say "010.010".Num.Str | ||
camelia | 10.01 | ||
nemokosch | Why not? | ||
dakkar | because of that example I just ran, at the very least | ||
nemokosch | that example might be another sign that .Num is a bit ill-defined | 12:56 | |
it does parsing and my point is exactly that I rather don't think it should | |||
dakkar | it does what's most useful in pratice | 12:57 | |
nemokosch | for parsing | ||
dakkar | adding filters/restrictions is easy, removing them is harder | ||
nemokosch | in which case a parsing function might be even more useful | ||
dakkar | so if your application requires strict validation, you add it | ||
if not, you don't have to rewrite the parser/converter | |||
nemokosch | no no, my point is that if you want parsing, probably you shouldn't use a coercion method | 12:58 | |
the coercion method is a dedicated thing, that should do its one narrow task | |||
dakkar | you probably don't want to work with perl-family languages, then 😁 | ||
nemokosch | most people don't, it seems | 12:59 | |
but Perl was the language to be fixed, mind you | |||
and the current behavior is partial for parsing as well: tamil numerals don't work | 13:00 | ||
or maybe my terminal doesn't work? 🤔 | 13:02 | ||
oh, even better: sometimes it works, sometimes it doesn't | 13:04 | ||
௰ means 10 and Rakudo knows this - however, it won't parse it for you from a string | |||
lizmat | m: say say ௰ + 32 | 13:06 | |
camelia | 42 True |
||
lizmat | m: say "௰".unival | ||
camelia | 10 | ||
lizmat | nemokosch ?? | ||
13:10
cm_ joined
13:11
cm left,
cm_ is now known as cm
|
|||
nemokosch | yes, unival | 13:17 | |
m: say "௰".Numeric | |||
Raku eval | Exit code: 1 Cannot convert string to number: base-10 number must begin with valid digits or '.' in '⏏௰' (indicated by ⏏) in block <unit> at main.raku line 1 | ||
nemokosch | meanwhile | ||
m: "௨".Numeric.say; ௰.say | 13:18 | ||
Raku eval | 2 10 | ||
lizmat | m: dd "௨".uniprop | ||
camelia | "Nd" | ||
lizmat | m: dd "௰".uniprop | 13:19 | |
camelia | "No" | ||
lizmat | Nd is ok in strings, No is assumed to be a string | ||
nemokosch | it's anything but fun that I can just take numbers from a wikipedia table and already one of them works while the other one doesn't | ||
lizmat | blame unicode | ||
m: say ௨௨ | |||
camelia | 22 | ||
nemokosch | I blame the guessing game built into a coercion method | 13:20 | |
lizmat | m: say ௰௰ | ||
camelia | ===SORRY!=== Error while compiling <tmp> Bogus postfix at <tmp>:1 ------> say ௰⏏௰ expecting any of: infix infix stopper postfix statement end statement modifier … |
||
nemokosch | this could be reasoned and even fixed in a parsing method | ||
lizmat | No is not considered to be a digit, but a singleton numeric value | ||
nemokosch | that's an arbitrary distinction. It is a valid number according to Rakudo itself | ||
an implementation detail, if you will | 13:21 | ||
lizmat | yes, but *not* a digit | ||
no, a conscious decision in my memory | |||
nemokosch | I didn't ask for a digit, I asked for the numeric value of a number | ||
lizmat | no, you asked for the numeric value of a string | ||
nemokosch | a string containing a valid number in Raku | 13:22 | |
like do you not see the irony | |||
lizmat | there's no iroy | ||
*irony | |||
m: say "pi".Numeric | |||
camelia | Cannot convert string to number: base-10 number must begin with valid digits or '.' in '⏏pi' (indicated by ⏏) in block <unit> at <tmp> line 1 |
||
nemokosch | it's perfectly reasonable to assume that once these coercion methods go into parsing territory, they will parse the numbers Rakudo parses, at least | 13:23 | |
lizmat | would you also like that to work ? | ||
nemokosch | that's such a bad parallel, please | ||
pi is not parsed as a number | |||
lizmat | m: dd pi | ||
camelia | 3.141592653589793e0 | ||
lizmat | ?? | ||
nemokosch | lizmat discovering symbol resolution | ||
how can you be this fake... | 13:24 | ||
lizmat | and how can you be so personally attacking? | ||
nemokosch | you are being dishonest | ||
lizmat | and how am I being dishonest? | ||
that's quite an accusation | 13:25 | ||
nemokosch | you pretend to not understand the problem, you pretend to not understand the difference between something being parsed as a number and a random symbol being resolved by a lookup table | ||
amano | It seems nemokosch is attacking lizmat. | 13:26 | |
Don't make things up. | |||
Go away. | |||
nemokosch | ௰ is not a magical constant | ||
amano | Does anyone know how to use listen-path and connect-path from IO::Socket::Async? | 13:27 | |
elcaro | amano: No docs added yet for the linux socket stuff. I assume it's meant to confirm to the existing API for network sockets. | ||
lizmat | leont would be the one to ask, as they made it | ||
elcaro | Not that I know much about those either... but I tried to see if I could figure it, but only managed the "listen" part | ||
lizmat | leont should maybe write some docs *nudge *nudge* | ||
leont | Yeah, I should | 13:28 | |
amano | I don't know whether listen-path creates a stream socket or a datagram socket. | ||
leont | Stream. libuv doesn't support datagram sockets. | ||
amano | I don't yet know how to deal with streams. | ||
Can you create a datagram socket with listen-path? | 13:29 | ||
Or, will there be a separate function for creating a datagram unix socket? | |||
leont | No, and I don't think we can support it currently. | ||
libuv handles all of this in a really weird way IMO | |||
amano | How can I send and receive a message through a stream? | 13:30 | |
leont | The methods generally work the same as their TCP counterparts, except they take a path instead of a host an port | 13:31 | |
amano | If I tap IO::Socket::Async::ListenSocket, do I get a line? Or? | 13:34 | |
Let's assume that I sent "hello\n" to a unix stream socket. Would I get "hello\n" from IO::Socket::Async::ListenSocket? | 13:35 | ||
nemokosch | is this for IPC? | 13:36 | |
amano | Yes. | 13:37 | |
I want to send messages. | |||
nemokosch | makes sense | 13:39 | |
this is quite a recent thing, Leon nailed it after a considerable amount of time missing it | 13:41 | ||
but it seems that people do want this, after all | |||
tbrowder__ | .tell El_Che it looks like your basic install script does not create the /opt/rakudo-pkg directory if it doesn't exist. that is disconcerting because all else indicates everything is installed, but it's nowhere on the host fille system. | 13:42 | |
tellable6 | tbrowder__, I'll pass your message to El_Che | ||
amano | I wish io::socket::async could create a datagram unix socket, but a stream unix socket will do the job because I read how the stream works in raku. | 13:45 | |
13:46
bigdata joined
|
|||
El_Che | tbrowder__: /opt/rakudo-pkg is created by the package, not the script | 13:47 | |
13:50
bigdata left
|
|||
tbrowder__ | for me, the /opt/rakudo-pkg dir did not exist prior to the script being run. i did try "sudo aptitude install rakudo-pkg" and the response said it was installed but it wasn't there. i will try one more time. | 13:51 | |
El_Che | did you remove the directory manually, eg while testing | 13:52 | |
it's the root of the pkg | |||
tbrowder__ | originally i did, trying to follow the uninstall directions | 13:55 | |
ok, i think i missed the step "sudo aptitude remove rakudo-pkg" (not explicitly said as such) | 13:57 | ||
have you updated the instuctions recently? | 13:58 | ||
nemokosch | what is your goal, by the way? | ||
tbrowder__ | no, i see. i followed the removal instuctions in the same menu for setup. it does not use the "apt remove step" | 14:00 | |
El_Che | tbrowder__: the rm is for removing leftover you added yourself, eg root compiled modules etc | ||
the package only cleans itself | |||
tbrowder__ | that may be the problem then. it wasn't clear when i was just trying to clean and reinstall | 14:01 | |
14:02
amano left
|
|||
tbrowder__ | to me the two different install methods need to be separated a bit more. just my funny brain. | 14:02 | |
antononcube | “*<amano> Go away.” — Hmm… I am inclined to judge the maturity of the people in this forum by the way they treat Nemokosch. 🙂 | 14:03 | |
leont | amano: the first example in the IO::Socket::Async documentation shows how to do it, except you replace .listen($host, $port) with .listen-path($path) | 14:06 | |
tellable6 | leont, I'll pass your message to amano | ||
leont | Oh he's gone | ||
librasteve | 👉 when you point a finger, four fingers point back at you | 14:37 | |
antononcube | Well, it seems it is at most three fingers (judging by the emoji) and in the way I do it no fingers point at me. 🙂 | 14:43 | |
nemokosch | sometimes you might think that people are pointing fingers when they are really just counting | 14:47 | |
14:54
abraxxa left
15:03
fanta1 joined
15:41
discord-raku-bot left
15:42
discord-raku-bot joined
16:04
Xliff joined
|
|||
Xliff | \o | 16:05 | |
tbrowder__ | o/ | 16:06 | |
Xliff | How goes? Anything interesting happening? | 16:07 | |
tbrowder__ | El_Che: i’m getting the rakudo-pkg install results i want by using the manual install steps in a sudo-run script and adding at its end “apt-get install rakudo-pkg” | 16:09 | |
it avoids my shaky copy/paste problems in a terminal window | 16:11 | ||
there’s a lot going on in the first “easy” method that’s hard to grok | 16:16 | ||
personally, i would like to see a similar script on your rakudo-pkg instructions | 16:23 | ||
it would help those of us who need step-by-step recipes encapsulated in good scripts | 16:24 | ||
your rakudo-pkg (after successful setup) is wonderful and i highly recommend if for multii-user systems as well as debian users of all stripes. easy-peasy maintenance! | 16:27 | ||
16:35
dakkar left
16:36
abraxxa joined
|
|||
nemokosch | what is your particular environment that poses you these challenges? | 16:38 | |
tbrowder__ | old age, bad eyesight, poor muscular control, shaky fingers | 17:02 | |
scripts work great | |||
as long as i can see the inside of them | 17:04 | ||
El_Che | tbrowder__: I will ping you for when I have a little more time. If you have something to propose (or the adapted scripts), I'll be happy to hear it | 17:10 | |
The matter stays that the way rakudo handles modules takes some time to get used to, or maybe needs more standardization | 17:11 | ||
17:35
abraxxa left
17:41
razetime left
|
|||
tbrowder__ | El_Che: thanks | 17:43 | |
18:00
reportable6 left
18:03
reportable6 joined
18:26
ProperNoun left
18:27
ProperNoun joined
|
|||
nemokosch | 😅 | 18:30 | |
19:04
ProperNoun left
19:05
ProperNoun joined
19:27
heartburn left
20:01
silug left
20:17
teatwo joined
20:20
teatwo left,
teatwo joined
20:21
tea3po left
20:24
japhb left
20:26
japhb joined
20:54
fanta1 left
21:11
silug joined
|
|||
a friend of mine keeps complaining about wanting syntax and I keep saying that it exists in Raku | 21:29 | ||
it's kinda sad that there is a way to write early exit from a block in Raku but it's basically the side effect of a statement (when) | 21:36 | ||
succeed would just be perfect, if it weren't forbidden outside when | 21:37 | ||
21:37
trumpybumpy81 joined
|
|||
trumpybumpy81 | ted zielinski was right | 21:38 | |
22:10
jmcantrell joined
22:19
trumpybumpy81 left
22:26
Sgeo joined
22:39
sena_kun left
|
|||
tonyo | about society? | 22:58 | |
23:19
japhb left
23:23
japhb joined
23:27
daxim left
23:33
amano joined
|
|||
amano | Does Channel not have peek? | 23:34 | |
tellable6 | 2023-08-22T14:06:06Z #raku <leont> amano: the first example in the IO::Socket::Async documentation shows how to do it, except you replace .listen($host, $port) with .listen-path($path) | ||
23:40
daxim joined
|
|||
amano | okay | 23:56 | |
23:57
amano left
|