🦋 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
reportable6 joined
00:49
lichtkind left
01:42
Xliff left
02:03
Sankalp left
02:05
Sankalp joined
02:06
Sankalp left
02:07
Sankalp joined
02:08
Sankalp left
02:10
Sankalp joined
02:11
Sankalp left
02:26
Sankalp joined
02:27
Sankalp left
02:28
Sankalp joined
02:30
Sankalp left
02:35
Sankalp joined
02:37
Kaiepi left
|
|||
Geth | doc: 0rir++ created pull request #4081: Simple typos, misphrasings, and punc |
02:46 | |
03:37
linkable6 left,
evalable6 left
03:38
linkable6 joined
03:39
evalable6 joined
04:39
sourceable6 left,
quotable6 left,
bloatable6 left,
statisfiable6 left,
coverable6 left,
reportable6 left,
committable6 left,
releasable6 left,
unicodable6 left,
nativecallable6 left,
evalable6 left,
linkable6 left,
benchable6 left,
tellable6 left,
shareable6 left,
greppable6 left,
notable6 left,
bisectable6 left
04:40
notable6 joined,
coverable6 joined,
greppable6 joined,
sourceable6 joined,
benchable6 joined,
committable6 joined
04:41
tellable6 joined,
bloatable6 joined,
reportable6 joined,
evalable6 joined,
nativecallable6 joined,
releasable6 joined
04:42
shareable6 joined,
bisectable6 joined,
unicodable6 joined,
statisfiable6 joined
04:43
linkable6 joined,
quotable6 joined
05:16
sienet_ja_LSD[m] joined
|
|||
sienet_ja_LSD[m] | hi, has someone experienced died with exception when trying to access webpages? I can put this www.nasdaqomxnordic.com/webproxy/Da...2018-12-14 into my firefox and I get an XML response back instantly, but with Cro the HTTP::Client get timeouts | 05:21 | |
fetching other websites seems to work though | 05:26 | ||
with LWP::Simple it works similarly, just freezes and does nothing | 05:41 | ||
06:08
reportable6 left
06:10
reportable6 joined
07:10
quotable6 left,
reportable6 left,
bloatable6 left,
sourceable6 left,
statisfiable6 left,
coverable6 left,
benchable6 left,
committable6 left,
notable6 left,
linkable6 left,
shareable6 left,
unicodable6 left,
nativecallable6 left,
greppable6 left,
bisectable6 left,
releasable6 left,
evalable6 left,
tellable6 left,
sourceable6 joined
07:11
evalable6 joined,
bisectable6 joined,
shareable6 joined,
bloatable6 joined,
tellable6 joined,
benchable6 joined,
notable6 joined
07:12
linkable6 joined,
reportable6 joined,
quotable6 joined,
statisfiable6 joined
07:13
greppable6 joined,
unicodable6 joined,
nativecallable6 joined,
coverable6 joined,
committable6 joined,
releasable6 joined
07:20
mexen joined
07:35
Sgeo left
07:37
jjido joined
08:15
p6steve left
08:36
jjido left
|
|||
Voldenet | sienet_ja_LSD[m]: this address doesn't respond if you don't use proper browser headers - it needs User-Agent, Accept-Language and Connection headers to work | 08:52 | |
I bet it's some anti bot protection | 08:53 | ||
sienet_ja_LSD[m] | hmm ok, I have useragent but probly need those others too | ||
09:10
Kaiepi joined
09:25
Sankalp left
09:29
kawaii_ is now known as kawaii
09:31
Sankalp joined
|
|||
sienet_ja_LSD[m] | ok now with headers it fails: Malformed UTF-8 near byte 8b at line 1 col 2 | 09:58 | |
Voldenet | >my $resp = await Cro::HTTP::Client.get("…", user-agent => "Mozilla/5.0", headers => [Accept-Language => "en", Connection => "keep-alive", Accept => "*/*"]); | 10:05 | |
try this | |||
I think using instance of the client will set `Connection: keep-alive` by default | 10:07 | ||
Nope, they don't | 10:08 | ||
sienet_ja_LSD[m] | hmm now it's complaining about ampersands in the url | 10:10 | |
parameters aren't passed as they ought to | 10:11 | ||
Voldenet | cro.services/docs/reference/cro-ht...parameters | 10:13 | |
sienet_ja_LSD[m] | nope, still malformed utf-8 | 10:23 | |
Voldenet | consider CRO_TRACE=1, then | 10:25 | |
tho this service sounds like a pain to work with | |||
sienet_ja_LSD[m] | perl5 works, but trying to use v5 errors No compiler available for Raku v5 | ||
I got it working with full headers | 10:26 | ||
Voldenet | don't be too surprised when they add js challenge to it :/ | ||
sienet_ja_LSD[m] | maybe the output is actually non-utf8 although all fronts say that it is supposedly utf8 | 10:35 | |
this says the same: use LWP::Simple; my %headers = ('User-Agent' => 'Mozilla/4.76 [en] (Win98; U)', 'Accept-Language' => 'en-US', 'Accept-Charset' => 'iso-8859-1,*,utf-8', 'Accept-Encoding' => 'gzip', 'Accept' => "image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, image/png, */*"); my $content = | |||
LWP::Simple.get('www.nasdaqomxnordic.com/webproxy/Da...18-12-14', %headers) | |||
those same headers get an XML response with p5 | 10:37 | ||
so I guess use v5; doesn't work? or? | 10:47 | ||
nine | raku.land/cpan:NINE/Inline::Perl5 | 10:50 | |
sienet_ja_LSD[m] | ah thanks | 10:52 | |
Nemokosch | hello | 11:23 | |
I have a process and I'm reading it's stdout | |||
how can I make it not assume UTF-8 for text? | 11:25 | ||
I'd need Latin-1 in particular | |||
this seems to work actually: | 11:29 | ||
$diff-proc.stdout(:bin).decode('iso-8859-1') | |||
11:33
linkable6 left,
evalable6 left
11:34
linkable6 joined
11:35
evalable6 joined
12:07
reportable6 left
12:08
reportable6 joined
12:10
jjido joined
|
|||
another one | 12:12 | ||
I'm sure I've come across this but I don't remember the preferred solution | |||
I want to get rid of _adjacent_ duplicates in a Positional | 12:13 | ||
gfldex | <@297037173541175296> you are looking for `.squish` | 12:21 | |
Nemokosch | So this even has a name? Wow 😄 | 12:23 | |
Thank you | |||
12:39
lichtkind joined
12:41
lizmat joined
|
|||
lizmat | and yet another Rakudo Weekly News hits the Net: rakudoweekly.blog/2022/06/06/2022-...y-release/ | 12:42 | |
12:42
lizmat left
|
|||
Nemokosch | I noticed a mistake | 12:46 | |
> But you can also use a zen slice and the :v adverb: | |||
The example does not contain zen slicing, according to the docs | |||
12:47
jgaz joined
|
|||
"Zen slicing is different from passing a Whatever-star (which, like a normal slice, always returns a List of elements no matter the type of the original object) or an empty list (which returns an empty slice):" | 12:48 | ||
Voldenet | zen slice would still work though, right? | 12:50 | |
m: my @a; @a[3] = 42; @a[5] = 666; say @a[]:v; | |||
camelia | (42 666) | ||
Nemokosch | seems like that | 12:53 | |
Voldenet | btw, in the example whatever-star also returns list | 12:58 | |
gfldex | m: multi sub infix:<M>(\l, \r) { l.tail eqv r ?? l !! slip(l,r) }; multi sub infix:<M>(\l, Mu:U \r) { l }; my @a = <a a b c c d e e e>; my \foo = lazy gather for @a -> $l, $r? { take $l M $r }; dd [M] <a a b c c d e e e>; | 13:02 | |
camelia | slip("a", "b", "c", "d", "e") | ||
gfldex | <@297037173541175296> if you use operators (or inline a block), you can even get lazy. | ||
Nemokosch | oh right, I tried to do something like this but apparently messed it up | 13:04 | |
13:47
evalable6 left,
linkable6 left
13:49
linkable6 joined,
evalable6 joined
13:55
lichtkind_ joined,
lichtkind left
14:00
jjido left
14:19
jgaz left
14:23
jgaz joined
14:25
razetime joined
14:27
Sgeo joined
|
|||
is not defined @var also not a thing? | 14:45 | ||
😩 | 14:46 | ||
14:55
japhb joined
15:03
marcel_ joined
15:05
marcel_ left
15:06
marcel_ joined
|
|||
marcel_ | m: say 3; | 15:07 | |
camelia | 3 | ||
15:11
marcel__ joined,
marcel_ left
15:14
marcel__ is now known as MARTIMM
15:18
jgaz left
15:19
marcel_ joined
15:21
MARTIMM left
15:22
marcel_ left,
marcel_ joined
15:23
[Coke] left
15:26
marcel_ left
15:28
[Coke] joined
15:49
[Coke] left
15:50
[Coke] joined
15:53
archenoth joined
16:14
systems joined
|
|||
systems | hi | 16:14 | |
which two folders in should add to my path on windows | |||
C:\rakudo\bin is one | |||
which is the other | |||
while installing i unchecked this step, thinking i was upgrading, so no need to clutter the path, but it seem i still need to add them | 16:15 | ||
found it i think C:\rakudo\share\perl6\site\bin | 16:18 | ||
ugexe | m: say CompUnit::RepositoryRegistry.repository-for-name(q|site|).prefix.add(q|bin|).absolute | 16:21 | |
camelia | /home/camelia/rakudo-m-inst-1/share/perl6/site/bin | ||
ugexe | you can run that to get the PATH where module bin scripts are typically installed | 16:22 | |
systems | thanks | 16:24 | |
16:52
razetime left
|
|||
sienet_ja_LSD[m] | how would I create a 2dimensional matrix row by row? append flattens it | 17:26 | |
m: my @a = [[rand xx 2] xx 3]; say @a; | 17:27 | ||
camelia | [[0.13418002515610716 0.6678566564232125] [0.19015445598582792 0.7429061642968087] [0.325871474624009 0.09065142650269675]] | ||
sienet_ja_LSD[m] | like that | ||
but I'm extracting it from xml | |||
xinming | SmokeMachine: Seems Red doesn't work well with 2022.06 version of raku | 17:30 | |
Voldenet | m: my @a; @a.push([rand xx 2]) for ^3; say @a; | 17:32 | |
camelia | [[0.7651678791845333 0.12262858201485227] [0.5144848317870481 0.46827779697223415] [0.6788642244410071 0.4080803165619924]] | ||
Voldenet | sienet_ja_LSD[m]: ^ this should work | ||
sienet_ja_LSD[m] | ah push, got it. thanks | 17:33 | |
17:52
linkable6 left,
evalable6 left
17:53
evalable6 joined
17:54
linkable6 joined
18:08
reportable6 left
18:10
reportable6 joined
|
|||
drakonis | github.com/sirherrbatka/vellum v. inspiring. | 18:29 | |
18:33
systems left
18:42
systems joined
|
|||
systems | m: 9/99999999999999999999 | 18:43 | |
camelia | Unhandled exception: Cannot unbox 67 bit wide bigint into native integer at gen/moar/Optimizer.nqp:3248 (/home/camelia/rakudo-m-inst-1/share/perl6/lib/Perl6/Optimizer.moarvm:) from gen/moar/Optimizer.nqp:3223 (/home/camelia/rakudo-m-inst-1/s… |
||
Unhandled exception: Cannot unbox 67 bit wide bigint into native integer at gen/moar/Optimizer.nqp:3248 (/home/camelia/rakudo-m-inst-1/share/perl6/lib/Perl6/Optimizer.moarvm:) from gen/moar/Optimizer.nqp:3223 (/home/camelia/rakudo-m-inst-1/s… |
18:44 | ||
systems | hmmm | ||
m: 9/99999999999999999999e0 | |||
camelia | ===SORRY!=== Cannot unbox 67 bit wide bigint into native integer |
||
systems | m: say 9/99999999999999999999e0 | 18:45 | |
camelia | 9e-20 | ||
systems | m: say 9/99999999999999999999 | ||
camelia | 0.00000000000000000009 | ||
systems | m: say 9/999999999999999999999 | ||
camelia | 9e-21 | ||
systems | so what is the threshold for switching to scientific notation, and how can i enforce bignum | ||
i can enforce scientific notation by prefixing with e0 | 18:46 | ||
sorry postfix | |||
drakonis | works fine here | ||
each one of them works as expected | 18:47 | ||
is camelia up to date? | |||
systems | what do you mean work fine | ||
drakonis | no errors nor unhandled exceptions here | 18:48 | |
systems | yes, i think camelia, needs the say operator | ||
it works fine on my pc as well | 18:49 | ||
i am asking thought when does numbers switch to scientific notation using e0 | |||
and how can i enforce bignumbers | |||
drakonis | m: $*VM | ||
camelia | ( no output ) | ||
drakonis | hm | 18:50 | |
m: $*RAKU | |||
camelia | ( no output ) | ||
drakonis | m: say $*VM | ||
camelia | moar (2022.06) | ||
systems | m: say $*VM | ||
camelia | moar (2022.06) | ||
drakonis | oh its up to date huh | ||
systems | m: say $*RAKU | ||
camelia | Raku (6.d) | ||
drakonis | weird | ||
18:50
discord-raku-bot left
|
|||
systems | whats weird, maybe this is how camelia is programmed | 18:51 | |
not a repl | |||
18:51
discord-raku-bot joined
|
|||
systems | m: my $x = 9/999999999999999999999 ; say $x | 18:52 | |
camelia | 9e-21 | ||
systems | m: my $x = $*RAKU ; say $x | ||
camelia | Raku (6.d) | ||
SmokeMachine | xinming: is it giving any error? | ||
systems | m: my $x = 9/999999999999999999999 | ||
camelia | ( no output ) | ||
systems | m: 9/999999999999999999999 | ||
camelia | Unhandled exception: Cannot unbox 70 bit wide bigint into native integer at gen/moar/Optimizer.nqp:3248 (/home/camelia/rakudo-m-inst-1/share/perl6/lib/Perl6/Optimizer.moarvm:) from gen/moar/Optimizer.nqp:3223 (/home/camelia/rakudo-m-inst-1/s… |
||
systems | m: 9/99 | 18:53 | |
camelia | WARNINGS for <tmp>: Useless use of "/" in expression "9/99" in sink context (line 1) |
||
systems | m: 9 / 99 | ||
camelia | WARNINGS for <tmp>: Useless use of "/" in expression "9 / 99" in sink context (line 1) |
||
systems | m: 9 * 99 | ||
camelia | WARNINGS for <tmp>: Useless use of "*" in expression "9 * 99" in sink context (line 1) |
||
systems | m: 9 * 99 | ||
camelia | WARNINGS for <tmp>: Useless use of "*" in expression "9 * 99" in sink context (line 1) |
||
systems | i guess, ppl expect more a repl like behavior, when camelia, seem to offer a script behavior | 18:54 | |
does raku have a slack or a discord | 18:55 | ||
MasterDuke | yes to discord at least | 18:56 | |
systems | which channel to use on discord, its very confusing , too many channels | 18:57 | |
systems | test | 18:58 | |
MasterDuke | looks like you found it | ||
systems | yes | ||
it too big | |||
so many channels | |||
systems | test test | 18:59 | |
19:27
jgaz joined
|
|||
jdv | vrurg: thanks. works. | 19:28 | |
19:44
jgaz left
|
|||
drakonis | thems some neat talks on tprc | 19:56 | |
20:09
jgaz joined
20:42
jjido joined
20:43
morte_ joined
21:01
Maylay left
21:03
Maylay joined,
systems left
21:19
jgaz left
21:45
lichtkind_ left
21:53
morte_ left
21:57
jjido left
22:02
vasko joined
22:03
jjido joined
22:19
jjido left
22:32
abraxxa-home joined
22:36
abraxxa-home left
22:37
abraxxa-home joined
22:52
discord-raku-bot left,
discord-raku-bot joined
23:52
unicodable6 left,
linkable6 left,
evalable6 left,
reportable6 left,
sourceable6 left,
statisfiable6 left,
releasable6 left,
quotable6 left,
shareable6 left,
bisectable6 left,
greppable6 left,
committable6 left,
nativecallable6 left,
notable6 left,
bloatable6 left,
tellable6 left,
benchable6 left,
coverable6 left,
releasable6 joined,
bloatable6 joined,
abraxxa-home1 joined
23:53
sourceable6 joined,
coverable6 joined,
unicodable6 joined,
statisfiable6 joined,
quotable6 joined,
bisectable6 joined,
greppable6 joined,
committable6 joined
23:54
shareable6 joined,
tellable6 joined,
reportable6 joined,
notable6 joined,
nativecallable6 joined
23:55
benchable6 joined,
linkable6 joined,
evalable6 joined
23:56
abraxxa-home left
23:58
abraxxa-home1 left,
abraxxa-home joined
|