05:38 < bridge_> why do i have the urge to buy 64GB of ram 05:38 < bridge_> those 2 slots are looking at me with hungry eyes 05:38 < bridge_> 64 more* 08:33 < bridge_> pascal? 08:33 < bridge_> RUST 08:33 < bridge_> It's rust. But rust is indeed similar in few things 08:34 < bridge_> I had pascal in school xdd 08:34 < bridge_> Fortran 08:34 < bridge_> Lisp 08:34 < bridge_> COBOL 08:34 < bridge_> Cobol 08:34 < bridge_> Xd 08:34 < bridge_> 😬 08:34 < bridge_> Scheme 08:34 < bridge_> FFR 08:35 < bridge_> Perl 08:35 < bridge_> :brownbear: 08:35 < bridge_> True ffr 08:35 < bridge_> But I'm at gym rn 08:35 < bridge_> Wait till 11 08:35 < bridge_> I always forget my questions xd 08:35 < bridge_> Xd 08:35 < bridge_> Yesterday i had one 08:35 < bridge_> No. It was too unexpected and random. Did you write that by hand? :D 08:36 < bridge_> Yes 08:36 < bridge_> Wow 08:36 < bridge_> prolog? 08:36 < bridge_> Such effort 08:36 < bridge_> I hoped you start a new programming language 08:36 < bridge_> I got the rust part 08:36 < bridge_> yes 08:37 < bridge_> Do u don't have time for other stuff 08:37 < bridge_> If you know what i mean 😏 08:39 < bridge_> I'm trying 08:39 < bridge_> edlang 08:39 < bridge_> @jupeyy_keks do u use variable shadowing a lot in rust 08:40 < bridge_> I do and I think it's even idiomatic 08:40 < bridge_> It falls in place clean 08:40 < bridge_> Can’t stop me now! 08:41 < bridge_> Im basically finished 08:41 < bridge_> Just polish is left 08:42 < bridge_> Isn’t shadowing encouraged in the rust book? I thought it’s is idiomatic. 08:42 < bridge_> Ah red wrong 08:43 < bridge_> Yes it’s idiomatic :D 08:43 < bridge_> Shawoing is poor man’s mutable variables :P 08:45 < bridge_> Nah it's mutating a variable type 08:46 < bridge_> :D 08:50 < bridge_> It's definitely different to other languages. I often do it when unwrapping or pattern matching 10:37 < ChillerDragon> pheww fakin fonts robsti 10:38 < ChillerDragon> i wanted to do 0.7ing today -.- 10:38 < ChillerDragon> didnt know the streamer pr would be such a hazzle 10:38 < bridge_> good job robsti 10:38 < ChillerDragon> -.- 10:38 < bridge_> what streamer pr? 10:38 < ChillerDragon> #7087 10:38 < chillerbot1> https://github.com/ddnet/ddnet/issues/7087 10:43 < ChillerDragon> royowo u like the pr? 10:43 < bridge_> chiller 10:43 < ChillerDragon> da 10:44 < bridge_> do u know if u can do a freeze jump in a 5 tile freeze 10:44 < bridge_> freeze jump is only in 1 tile right 10:44 < ChillerDragon> maybe 10:44 < ChillerDragon> i think i saw 2tile 10:44 < ChillerDragon> physics 10:44 < bridge_> https://wiki.ddnet.org/index.php?title=Freeze&curid=305&diff=26480&oldid=19777&diffmode=source 10:44 < bridge_> i reverted this cuz 10:44 < ChillerDragon> you just gotta be really fast 10:44 < bridge_> i dont think u can freeze jump 5 deep freeze tiles 10:45 < ChillerDragon> who added 5 tiles? 10:45 < bridge_> I think the rule is that you need to have enough speed to touch the ground before the freeze tile gets processed 10:45 < ChillerDragon> yea question is can you be that fast? 10:45 < bridge_> So maybe it is possible? Idk 10:45 < ChillerDragon> but its weird 1 tile freeze jump you can do while being slow ass 10:45 < ChillerDragon> and 2 tile doesnt work even if you super fast 10:46 < bridge_> There might be some other thing at play too. I'm only thinking of the simplest way it could work 10:46 < ChillerDragon> rng 10:47 < bridge_> Unlikely 😄 10:47 < ChillerDragon> im curious who added the 5 tiles maybe that person has some epic demo 10:47 < ChillerDragon> it also depends on your coordinates 10:47 < ChillerDragon> i remember im corneum had to move a part around the map to make a freeze jump 10/10 consistent xd 10:47 < ChillerDragon> and im not talking about far lands 10:48 < ChillerDragon> just a few hounderd tiles away from spawn 10:48 < ChillerDragon> where if you hit the ceiling to get the exact same speed you can freeze jump 10/10 in one place but if that part is moved a bit it does not work anymore 10:49 < ChillerDragon> i can already see heinrich drafting his next physics change where freezejumps will work 10/10 everywhere haha 10:53 < ChillerDragon> @ryozuki wait i got another angle! What if that person meant the freeze is 1 tile high but the jump from the floor is 5 jumps high? 10:53 < ChillerDragon> nah it should be 7 right? 10:53 < ChillerDragon> its a full jump 10:53 < ChillerDragon> nah the sentence is pretty unambigious 10:53 < ChillerDragon> im telling you this dood found the magic coordinates for the 5 tile bungee jump 10:58 < bridge_> that person is a web3 entuthiast 10:58 < bridge_> sorry i couldnt help but read his discord bio xd 10:59 < bridge_> https://cdn.discordapp.com/attachments/293493549758939136/1147093248976891974/IMG_6435.png 10:59 < bridge_> nice meme snail 10:59 < bridge_> ur a dev now 10:59 < bridge_> siu 11:01 < ChillerDragon> xd 11:01 < ChillerDragon> whos bio? 11:01 < ChillerDragon> wot web3 11:01 < bridge_> nothing xd 11:02 < ChillerDragon> omagawd 11:02 < bridge_> the discord user description 11:02 < bridge_> it said web3 moderator 11:02 < bridge_> i just found it funny 11:02 < ChillerDragon> 2nd coffe and havent even open vscode yet xd 11:02 < ChillerDragon> which user? 11:06 < bridge_> jurai 11:06 < bridge_> btw i also had 2nd coffee 11:06 < bridge_> one before gym and one after 11:06 < bridge_> becoming a ddnet chad 11:07 < bridge_> Gym??? What's next, will you tell me you touch grass????? 11:07 < bridge_> Blasphemy 11:07 < bridge_> u already knew i go to gym 11:07 < bridge_> but i havent touched grass yet 11:08 < bridge_> 草 11:09 < bridge_> @jupeyy_keks where is ur rust question 11:09 < bridge_> Can coke be used to clean rust? 11:09 < bridge_> never tried 11:10 < bridge_> https://this-week-in-rust.org/blog/2023/08/30/this-week-in-rust-510/ 11:11 < ChillerDragon> xd 11:11 < bridge_> https://cdn.discordapp.com/attachments/293493549758939136/1147096430373240832/image.png 11:11 < bridge_> daily gentoo emerge 11:11 < bridge_> with coffee in hand 11:11 < bridge_> admiring the beauty of computing 11:12 < bridge_> :BASED: 11:13 < bridge_> @jupeyy_keks https://andreabergia.com/blog/2023/08/a-jvm-in-rust-part-5-executing-instructions/ 11:13 < ChillerDragon> java pog 11:14 < ChillerDragon> the jvm is so old and heavily optimized i doubt any new implementation will stand a chance 11:15 < bridge_> not everything is made for the sake of competing 11:15 < bridge_> its fun to do it for the sake of doing it 11:20 < bridge_> Mhh, dunno. 11:20 < bridge_> What is the most exotic, yet useful feature you can think of 11:20 < bridge_> Isn't there already 2 that perform well? HotSpot and OpenJ9 11:21 < bridge_> I'm always impressed when i remember chiller is a Java developer 11:21 < bridge_> oh 11:21 < bridge_> Imagine I'm secretly a python dev xd 11:21 < bridge_> i find this rly interesting https://doc.rust-lang.org/std/ptr/index.html#strict-provenance 11:22 < bridge_> pointer provenance 11:22 < bridge_> its still a nightly feature 11:22 < bridge_> https://cdn.discordapp.com/attachments/293493549758939136/1147099130854912010/image.png 11:22 < bridge_> https://cdn.discordapp.com/attachments/293493549758939136/1147099138505314314/image.png 11:23 < bridge_> Interesting. Have to read xd 11:23 < bridge_> ye go read it 11:23 < bridge_> its the future 11:23 < bridge_> https://github.com/rust-lang/rust/issues/95228 11:23 < bridge_> > This is an unofficial experiment to see How Bad it would be if Rust had extremely strict pointer provenance rules that require you to always dynamically preserve provenance information. Which is to say if you ever want to treat something as a Real Pointer that can be Offset and Dereferenced, there must be an unbroken chain of custody from that pointer to the original allocation you are trying to access using only pointer->pointer operations. If 11:25 < bridge_> > A secondary goal of this project is to try to disambiguate the many meanings of ptr as usize, in the hopes that it might make it plausible/tolerable to allow usize to be redefined to be an address-sized integer instead of a pointer-sized integer. This would allow for Rust to more natively support platforms where sizeof(size_t) < sizeof(intptr_t), and effectively redefine usize from intptr_t to size_t/ptrdiff_t/ptraddr_t (it would still generally 11:25 < bridge_> > 11:25 < bridge_> > A tertiary goal of this project is to more clearly answer the question "hey what's the deal with Rust on architectures that are pretty harvard-y like AVR and WASM (platforms which treat function pointers and data pointers non-uniformly)". There is... weirdness in the language because it's difficult to talk about "some" function pointer generically/opaquely and that encourages you to turn them into data pointers and then maybe that does Wrong Thi 11:25 < bridge_> > 11:25 < bridge_> > The mission statement of this experiment is: assume it will and must work, try to make code conform to it, smash face-first into really nasty problems that need special consideration, and try to actually figure out how to handle those situations. We want the evil shit you do with pointers to work but the current situation leads to incredibly broken results, so something has to give. 11:26 < ChillerDragon> im not a java developer -.- 11:28 < bridge_> https://www.ralfj.de/blog/2020/12/14/provenance.html 11:28 < bridge_> Yes you are 11:28 < bridge_> chiller is the declared ddnet java dev 11:28 < bridge_> True 11:29 < bridge_> Chiller java 11:29 < bridge_> Heinrich Python 11:29 < bridge_> Ryo rust 11:29 < bridge_> Me shading language 11:29 < bridge_> Learath c 11:29 < bridge_> heinrich python xd 11:30 < bridge_> he also knows lot of rust 11:30 < bridge_> maybe more 11:30 < bridge_> probs more 11:30 < bridge_> im a nobo 11:30 < bridge_> Yes, but he ain't showing his hype so much xd 11:31 < bridge_> And he protects Python xddd 11:38 < bridge_> Hello math heads, what's the best way to calculate a percentage between 0-100% from a few numbers? I want to show how much those numbers agree with each other, for example [2,2,2,2] = 100%, [0, 100] = 50% or 0%? 11:39 < bridge_> The standard deviation doesnt seem to be it 11:39 < bridge_> https://en.wikipedia.org/wiki/Levenshtein_distance 11:40 < bridge_> Heard of that before... I'll look into it 11:40 < bridge_> Ryo had that tab open xdd 11:41 < bridge_> xd 11:42 < ChillerDragon> xd 11:42 < bridge_> xd 11:42 < bridge_> quick google 11:42 < bridge_> https://www.geeksforgeeks.org/python-percentage-similarity-of-lists/ 11:42 < bridge_> but apparently 11:42 < bridge_> its pretty subjective 11:42 < bridge_> to what u consider similar 11:43 < bridge_> https://en.wikipedia.org/wiki/String_metric 11:46 < bridge_> @ryozuki would you rather use sha3 keccak 11:46 < bridge_> Or blake2 11:46 < bridge_> But that's for strings, not for lists of numbers 11:46 < bridge_> strings are numbers 11:47 < bridge_> fair 11:47 < bridge_> blake2 is faster i think 11:47 < bridge_> NIST created a competition for SHA-3, and it was Keccak that was crowned the champion. Since then, SHA-3 has received good adoption levels, but you'll also see BLAKE2 — one of the finalists — being used in many applications. Keccak won because it was fast, and where BLAKE2 was submitted too late to compete against it. 11:47 < bridge_> Yep, but sha3 is told to be more secure. Even tho even sha2 is still secure xd 11:48 < bridge_> this is not for passwords right xd 11:48 < bridge_> It's for file hashes 11:48 < bridge_> ah 11:48 < bridge_> gentoo uses blake2 11:48 < bridge_> so blake2 11:48 < bridge_> Xd ok 11:50 < bridge_> @ryozuki i dont understand how i would adapt this to use a list of integers 11:50 < bridge_> me neither 11:50 < bridge_> xd 11:51 < bridge_> i think u need to explain what u want 11:51 < bridge_> in reality 11:51 < bridge_> . 11:51 < bridge_> https://xyproblem.info/ 11:51 < bridge_> i mean the reason why u want to do that 11:51 < bridge_> Sha3 might get acceleration support tho. Bcs its standard 11:52 < bridge_> isnt sha2 accelerated 11:52 < bridge_> its secure enough and its files 11:52 < bridge_> thats basically what i said, i have a list of numbers, so for example it could be a vote, and everyone votes a number, and then i just want to calculate an agreement @ryozuki 11:53 < bridge_> oh 11:53 < bridge_> explain more the vote thing 11:53 < bridge_> thats what i mean 11:53 < bridge_> between 0 and 100% 11:53 < bridge_> u simply count the votes on each number? 11:54 < bridge_> if people vote a number between 0 and 100 simply do the median or smth 11:54 < bridge_> the numbers are between 0 and 15 11:55 < bridge_> and if the numbers are [2,2,3,1] the average is 2, but the agreement should look like 90% or whatever 11:56 < bridge_> hmm 11:59 < bridge_> im not a data scientist so 11:59 < bridge_> but maybe this helps https://en.wikipedia.org/wiki/Median_absolute_deviation 11:59 < bridge_> xd 12:02 < ChillerDragon> foko wat u doin 12:06 < bridge_> hax 12:13 < ChillerDragon> sus 12:17 < bridge_> sadly no 12:28 < bridge_> I would first normalize the numbers. So if the the max is 3 I would divide everything by 3 so max would be one (haven't thought any further yet) 12:37 < bridge_> btw do you want the agreement to be based on 15 or to be relative? 12:38 < bridge_> Like if it's `2, 2, 2, 2` it's 100% agreement but that's without taking into acount that it could be `15, 15, 15, 15` which would aslo be 100% agreement 12:42 < bridge_> ye 12:42 < bridge_> same numbers always 100% 12:43 < bridge_> ok 13:02 < bridge_> just use sha256, it's supported everywhere 13:09 < bridge_> Nah, i want the future 13:17 < ChillerDragon> I was too lazy too open my bloated gui video editor so i spend 20 minutes on stackoverflow to manage my task with ffmpeg xd 13:19 < ChillerDragon> jopsti can you pls build a easy to use blazingly fast curses video editor that does all the simple tasks and has a nice search and cool defaults 13:19 < ChillerDragon> which can crop and cut videos remove sound add a sound track etc 13:22 < bridge_> Is kdenlive bloated? 13:28 < bridge_> I'm on to smt dunno how correct it is though 😜 13:32 < bridge_> ```py 13:32 < bridge_> >>> def deviation(x): 13:32 < bridge_> ... return np.exp(np.sum(-np.abs(np.log(x / np.median(x)))) / len(x)) 13:32 < bridge_> ... 13:32 < bridge_> >>> deviation([2,2,2,2]) 13:32 < bridge_> 1.0 13:32 < bridge_> >>> deviation([2,2,3,1]) 13:32 < bridge_> 0.7598356856515925 13:32 < bridge_> >>> deviation([2,2,3,2]) 13:32 < bridge_> 0.9036020036098449 13:32 < bridge_> ``` 13:47 < ChillerDragon> @Jupstar ✪ unless im hired by fucking netflix to cut an entire movie it feels overkill to launch this kdenbloat 13:48 < bridge_> how long does it take to start? 13:48 < ChillerDragon> its a nice editor but not fun for super little tasks when operating on one clip 13:48 < ChillerDragon> it takes about 1 second to start on my lapotp 13:48 < ChillerDragon> it takes as long to start as ffmpeg takes to render the whole thing 13:49 < ChillerDragon> and its full of gui where i have to use the mouse and click through menus to render a fakin video 13:50 < bridge_> did you factor in the amount of time to find the correct invocationn? 😉 13:50 < ChillerDragon> no 13:50 < ChillerDragon> that was the joke 13:50 < ChillerDragon> i waste so much time on ffmpeg and i never remember the shit no matter how often i do it 13:50 < ChillerDragon> thats why i need a ffmpeg wrapper where i can search human friendly terms such as "crop" "compress" "cut" and then use some sliders and input fields to adjust 13:52 < bridge_> it sounds like chatgpt might perform well on this task 13:54 < bridge_> Time to write a paper about it 13:55 < bridge_> Well chiller, dunno what exactly you do. But if Video editors are bloat to edit a video. Then at least also say videos itself are bloat 13:56 < bridge_> Video is latin for i see xdd 13:56 < bridge_> For programming related questions it's basically a coin-toss right now whether ChatGPT is correct or not: https://arxiv.org/abs/2308.02312 13:57 < bridge_> I would expect it to have a good performance on "how to cut in ffmpeg"-type questions 13:58 < bridge_> Yeah, I think it works pretty good for making small command line scripts or writing individual commands 13:58 < bridge_> which is what chillerdragon wants to do 13:58 < bridge_> It's good in predicting the next word. So yeah. The more often these types of questions are asked or the task is mentioned in text form. The better it is 13:58 < bridge_> That's also why it's much better in js and python than rust 14:02 < ChillerDragon> @heinrich5991 i rather spin up kdenlive than use fakin ai 14:03 < bridge_> Maybe kdenlive internally uses ChatGPT to generate its ffmpeg invocations? 😏 14:03 < bridge_> rust is more complex too 14:04 < bridge_> ChillerDragon: why not spin up AI to learn something? 14:05 < bridge_> chiller where were ur docs about packets 14:05 < bridge_> ? 14:05 < ChillerDragon> @fokkonaut check matrix 14:06 < ChillerDragon> ryo version? 14:06 < ChillerDragon> https://chillerdragon.github.io/teeworlds-protocol/06/packet_layout.html 14:06 < ChillerDragon> 0.6 i assume xd 14:07 < bridge_> But also if u don't know anything about logic? Xd 14:07 < ChillerDragon> @heinrich5991 i am waiting for libre ai that doesnt need phone num or has quotas and is pay2win. Also i somehow prefer stackoverlfow and docs over hallucinating AI. 14:07 < ChillerDragon> i just dislike it smh a lot 14:07 < bridge_> buy 100 gpus 14:08 < ChillerDragon> ryo wat u doin with packets? 14:08 < bridge_> i wanna do a packet library in rust 14:08 < ChillerDragon> og 14:08 < ChillerDragon> pog 14:08 < bridge_> also ill try to fix huffman 14:08 < bridge_> i have teeint 14:08 < ChillerDragon> btw if you duckduckgo "teeworlds packet" its the first hit for me 14:08 < bridge_> ill change rustyman to teehuff 14:08 < bridge_> then teenet 14:09 < bridge_> I can recommend https://github.com/heinrich5991/libtw2/blob/044597a89faa5afaaa01e6cb2fa100d94c806738/gamenet/generate/spec/ddnet-16.7.2.json as a spec for the protocol 14:09 < bridge_> ChillerDragon: could you link my packet spec jsons btw? 14:09 < ChillerDragon> yea they are good 14:09 < bridge_> oh epic 14:10 < ChillerDragon> idk where to link them 14:10 < ChillerDragon> maybe on the main page 14:10 < bridge_> https://www.desmos.com/calculator/kqv6ez4cwu I am too nobo to code it :( 14:10 < bridge_> @heinrich5991 is it autogenerated? 14:10 < bridge_> can u generate latest 14:10 < bridge_> @ryozuki yes 14:11 < bridge_> I can generate latest if you want 14:11 < bridge_> do you? 14:11 < bridge_> ye 14:11 < bridge_> i like shiny new stuff 14:11 < bridge_> sec 14:11 < bridge_> this automatically updates the wireshark dissector and the gamenet crate as well 14:14 < bridge_> do u have a rust code generator already? 14:16 < bridge_> yes 14:16 < bridge_> I have a rust crate 14:16 < bridge_> gamenet 14:16 < bridge_> it supports ddnet, teeworlds 0.6 and teeworlds 0.7 IIRC 14:17 < bridge_> ok well if it exists 14:17 < bridge_> i lost motivation now xd 14:17 < bridge_> off 14:17 < bridge_> oof 14:17 < ChillerDragon> yea ryo dont reinvent the weel 14:17 < ChillerDragon> just pr some to libtw2 14:17 < ChillerDragon> for example docs -.- 14:18 < bridge_> libtw2 is awesome 14:18 < bridge_> but the code style just doesnt match with me xd 14:19 < ChillerDragon> bruv 14:19 < bridge_> well i looked at it years ago 14:19 < bridge_> also there is fun in making ur own stuff 14:19 < bridge_> im gonna try to fix my rustyman tho 14:20 < bridge_> @heinrich5991 why u never published to crates.io? 14:20 < bridge_> because I didn't want to make stability guarantees 14:20 < bridge_> https://gitlab.com/ddnet-rs/twgame 14:20 < bridge_> I'll probably publish to crates.io at some point 14:22 < bridge_> there's an issue for it, too 14:22 < bridge_> https://github.com/heinrich5991/libtw2/issues/53 14:22 < bridge_> https://wiki.ddnet.org/wiki/Resources#Tool_and_libraries 14:22 < bridge_> anything u see here missing 14:23 < bridge_> maybe just publish the libraries u think help most others 14:23 < bridge_> the problem with git deps is u cant publish to crates with git deps 14:25 < bridge_> what's the reason you want to publish to crates.io? ^^ 14:25 < bridge_> I guess forever free hosting is nice 14:26 < bridge_> cargo add ddnet-map-gen 14:26 < bridge_> and ye 14:26 < bridge_> more places 14:26 < bridge_> more visibility 14:26 < bridge_> cargo install ddnet-map-gen 14:26 < bridge_> cargo install works with git urls as well 14:27 < bridge_> i knew u would say that xd 14:27 < bridge_> afaik 14:27 < bridge_> I don't like the flat namespace of crates.io ^^ 14:27 < bridge_> --git 14:27 < bridge_> u mean u would like it like github 14:27 < bridge_> yes, e.g. 14:27 < bridge_> ye i also think it would be nice 14:28 < bridge_> it makes name squatting more meaningless too 14:29 < bridge_> e.g. this protocol update 14:29 < bridge_> is unfortunately a breaking change for the rust crate 14:30 < bridge_> https://github.com/heinrich5991/libtw2/commit/602156e4cb787f3d2c4afeb267706233741aea9c 14:33 < bridge_> hm true 14:33 < bridge_> maybe make a version per ddnet version 14:33 < bridge_> altho probs ddnet is not the whole scope 14:33 < bridge_> the ddnet protocol crate is separate 14:33 < bridge_> so that's probably fine 14:34 < bridge_> i looked at gamenet 14:34 < bridge_> its awesome 14:34 < bridge_> just idk what to build with it xd 14:35 < bridge_> the PoC teeworlds server and the map downloader are built with it 14:35 < bridge_> apropos downloader 14:36 < bridge_> someone told me it broke 14:38 < bridge_> oh damn some code is 9y old 14:43 < bridge_> are we talking about ddnet 2.0? 14:45 < ChillerDragon> no libtw2 14:45 < bridge_> works on my machine™ 14:45 < bridge_> no 14:45 < ChillerDragon> not to be confused with ddnet2 14:45 < ChillerDragon> both rust 14:45 < ChillerDragon> both 2 14:45 < ChillerDragon> but different 14:49 < bridge_> ```rust 14:49 < bridge_> pub fn lookup_host(domain: &str, port: u16) -> io::Result> { 14:49 < bridge_> for socket_addr in (domain, port).to_socket_addrs()? { 14:49 < bridge_> return Ok(Some(Addr::from_socket_addr(socket_addr))); 14:49 < bridge_> } 14:49 < bridge_> Ok(None) 14:49 < bridge_> } 14:49 < bridge_> ``` 14:49 < bridge_> clippy says this never loops 14:52 < bridge_> yea, looks like it 14:52 < bridge_> could be an `if let` with `.next()` 14:52 < bridge_> https://github.com/heinrich5991/libtw2/blob/602156e4cb787f3d2c4afeb267706233741aea9c/net/src/protocol.rs#L607-L615 14:52 < bridge_> is write() intended? 14:53 < bridge_> write doesnt ensure a full write like write_all 14:53 < bridge_> it may do a partial write 14:53 < bridge_> arrayvec's write always does complete writes 14:54 < bridge_> > This function will attempt to write the entire contents of buf, but the entire write might not succeed, or the write may also generate an error. Typically, a call to write represents one attempt to write to any wrapped object. 14:54 < bridge_> i see 14:54 < bridge_> > the entire write might not succeed 14:54 < bridge_> whathever this means 14:54 < bridge_> > It is not considered an error if the entire buffer could not be written to this writer. 14:54 < bridge_> > 14:54 < bridge_> > An error of the ErrorKind::Interrupted kind is non-fatal and the write operation should be retried if there is nothing else to do. 14:54 < bridge_> on a tcp connection, the buffer might be full 14:54 < bridge_> docs on the method 14:54 < bridge_> wow, that looks promising. Thanks a lot!! 14:55 < bridge_> note: this only works with positive numbers. it treats [2,2,3] as having more deviation than [2,2,2,3] 14:56 < bridge_> does it work with 0's? 14:56 < bridge_> a `0` will always cause a 0% match 14:56 < bridge_> did MaybeUninit exist 9 years ago? 14:56 < bridge_> lol no 😄 14:56 < bridge_> Hmm. 14:57 < bridge_> ```rust 14:57 < bridge_> error: calling `set_len()` immediately after reserving a buffer creates uninitialized values 14:57 < bridge_> --> zlib_minimal/src/lib.rs💯5 14:57 < bridge_> | 14:57 < bridge_> 100 | let mut dest = Vec::with_capacity(upper_bound); 14:57 < bridge_> | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 14:57 < bridge_> ... 14:57 < bridge_> 104 | dest.set_len(upper_bound); 14:57 < bridge_> ``` 14:57 < bridge_> Is there a way to add a special case for `0`? 14:58 < bridge_> https://doc.rust-lang.org/std/mem/union.MaybeUninit.html 1.36.0 was released in july 2019, according to https://www.wikidata.org/wiki/Q575650 14:58 < bridge_> maybe if i shift everything + 1 and later back -1 ? 14:58 < bridge_> I can make it depend on absolute difference instead of ratio 14:58 < bridge_> does 8-9 have a different distance from 1-2? 14:58 < bridge_> that would be perfect, as `0` is a valid number to enter 14:59 < bridge_> i.e. does [1,2] have a different mismatch than [8,9]? 14:59 < bridge_> > Vec clearly states that you must initialize the first len elements before calling set_len. Failing to do so breaks Vec's safety guarantees and gives Vec permission to invoke UB. 14:59 < bridge_> true 15:00 < bridge_> that was a question from my side ^^ 15:00 < bridge_> so that I can accurately represent it in the function 15:00 < bridge_> oh 15:00 < bridge_> ehm 15:01 < bridge_> i think no? xd 15:01 < bridge_> idk 15:01 < bridge_> yea, there are some things that should probably be fixed up with the new models of rust UB 15:01 < bridge_> I haven't noticed any miscompilations so far though 15:02 < bridge_> i dont like thinking like that xd 15:02 < bridge_> i tried adding a test and running miri but it wont work cuz the c dep 15:02 < bridge_> you don't like thinking that it should be fixed? ^^ 15:02 < bridge_> i mean this 15:02 < bridge_> this is just an observation 15:02 < bridge_> ah ok 15:02 < bridge_> it's not an opinion 15:03 < bridge_> what should the function output for [1,2]? 15:03 < bridge_> ```rust 15:03 < bridge_> test test::test_compress ... error: unsupported operation: can't call foreign function `compressBound` on OS `linux` 15:03 < bridge_> --> zlib_minimal/src/lib.rs:95:15 15:03 < bridge_> | 15:03 < bridge_> 95 | (unsafe { raw::compressBound(source_len as c_ulong) }) as usize 15:03 < bridge_> | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ can't call foreign function `compressBound` on OS `linux` 15:03 < bridge_> ``` 15:03 < bridge_> sad miri noises 15:03 < bridge_> should [1,1,2] be less mismatch than [1,2]? 15:03 < bridge_> probably the same as for [8,9], i believe. it's just a voting agreement display 15:04 < bridge_> yes, but what approximate number? 15:04 < bridge_> 1,2 is probably 50/50, and 1,1,2 is more than that 15:04 < bridge_> ok 15:04 < bridge_> i think 15:04 < bridge_> not so sure xD 15:04 < bridge_> heinrich today job is mathematician xD 15:04 < bridge_> he pro tho 15:04 < bridge_> ye 15:04 < bridge_> my maths are bad 15:05 < bridge_> i had maths in my final exams, i mean i was always quite good at maths but the level heinrich is on is smth different 15:05 < bridge_> `[8,9]` is also 50% then? 15:05 < bridge_> ah wait 15:06 < bridge_> no, [8,9] should be around 80% or smth, approxiamtely 15:06 < bridge_> it should just be slightly under 100% 15:06 < bridge_> but [1,2] should be 50%? 15:06 < bridge_> no, sorry, i was dumb 15:06 < bridge_> that should also be 80%ish? 15:06 < bridge_> yea 15:07 < bridge_> just imagine we wanna agree on one specific number, and x people can contribute to that 15:07 < bridge_> and this % should display the level of agreement 15:08 < bridge_> so, [2,2,2,2,3] should be around 90% i believe, and [2,2,2,2,8] should be less than 90 15:09 < bridge_> `closeness = lambda x: 0.64 ** (np.sum(np.abs(x - np.median(x))) / len(x))` 15:10 < bridge_> ```py 15:10 < bridge_> >>> closeness = lambda x: 0.64 ** (np.sum(np.abs(x - np.median(x))) / len(x)) 15:10 < bridge_> >>> closeness([2,2,2,2,3]) 15:10 < bridge_> 0.9146101038546527 15:10 < bridge_> >>> closeness([2,2,2,2,8]) 15:10 < bridge_> 0.5853504664669777 15:10 < bridge_> >>> closeness([1,2]) 15:10 < bridge_> 0.8 15:10 < bridge_> >>> closeness([8,9]) 15:10 < bridge_> 0.8 15:10 < bridge_> ``` 15:10 < bridge_> magic number cooked by AI 15:10 < bridge_> jkjk 15:10 < bridge_> 0.64 magic 15:10 < bridge_> ? xd 15:10 < bridge_> 0.64 is the square root of 0.8 15:10 < bridge_> ah no, it's the square 15:10 < bridge_> mh 15:11 < bridge_> i think its too harsh 15:11 < bridge_> closeness([2,2,2,2,8]) should probably be a little more than 60% i have the feeling 15:11 < bridge_> i dunno 15:11 < bridge_> the first (without magic numbers) looked more promising 15:11 < bridge_> it has about 60% ^^ 15:11 < bridge_> the first was relative 15:11 < bridge_> it treated 8,9 different from 1,2 15:12 < bridge_> ah 15:12 < bridge_> if you want to remove the magic number, you'll have to put 0.5 where the 0.64 is 15:12 < bridge_> but this is just a scaling factor 15:12 < bridge_> what happens wth 0.5? 15:12 < bridge_> the percentages drop 15:13 < bridge_> ChillerDragon: https://codeberg.org/gothub/gothub 15:13 < bridge_> hm... which approach would you personally take, including 0's as a voting option @heinrich5991 15:14 < bridge_> what is the best representation of the chosen numbers? 15:14 < bridge_> I like the latter better 15:14 < bridge_> because of this 15:14 < bridge_> ye 15:14 < bridge_> anyone know how can i make a bot in ddnet? just saw a guys using chat commands to control it and stuff 15:15 < bridge_> and would you increase 0.64 even more, or do you think its perfect? 15:15 < bridge_> :banhammer: 15:15 < ChillerDragon> @ryozuki thats cool! 15:15 < ChillerDragon> i wanted to build literally that once 15:15 < ChillerDragon> but too lazy 15:15 < bridge_> u mean a chat bot 15:15 < bridge_> or a client bot 15:15 < bridge_> client bots are forbidden 15:15 < bridge_> idk the stance on chat bots xd 15:15 < ChillerDragon> use ruby :D 15:15 < bridge_> probs the stance is: dont be annoying 15:15 < ChillerDragon> chat bots also illegal 15:15 < ChillerDragon> i got many bans for it 15:16 < bridge_> nice 15:16 < bridge_> did i hear bot client 15:16 < bridge_> the guy wrote !bot say blabla etc 15:16 < ChillerDragon> yes 15:16 < ChillerDragon> i can send you ruby code 15:16 < bridge_> !bot leave leaves for example 15:16 < bridge_> Command not found! 15:16 < bridge_> xd 15:16 < bridge_> joins like a player 15:16 < ChillerDragon> https://github.com/ChillerDragon/teeworlds_network/tree/9230f32c6a9dbbe3bd0bfc17f89fd38a34016b48#sample 15:17 < bridge_> that's purely up to you. use one that feels right with the percentages 15:17 < ChillerDragon> or js 15:17 < bridge_> I don't know what percentages you have in mind 15:17 < ChillerDragon> https://gitlab.com/swarfey/teeworlds-client/-/blob/888716d52bcfa43c5acec235dd3e6773e6d393e2/docs/examples/chat_bot.js 15:17 < bridge_> ``` 15:17 < bridge_> # I JUST REALIZED I ALREADY USED .scan(/../) 15:17 < bridge_> # TO GET .groups_of(2) 15:17 < bridge_> # AND DUUUUH .scan() IS BASICALLY ALREADY 15:17 < bridge_> # .groups_of() 15:17 < bridge_> # TODO: get rid of it?! 15:17 < bridge_> # update: no 15:17 < bridge_> # .scan(/../) works on strings and groups_of works on arrays 15:17 < bridge_> # so it has its purpose 15:17 < bridge_> ``` 15:17 < bridge_> nice comments chiller 15:17 < bridge_> js better thank you 15:17 < ChillerDragon> ohno xd 15:17 < bridge_> i dont wanna fake my own study, so i'd go with what is mathematically the best representation 15:17 < bridge_> what r we talking about 15:17 < bridge_> just publish ur math in the study 15:18 < bridge_> this is underdefined, there is no faking. there's no mathematically "correct" interpretation of closeness 15:18 < bridge_> wait 15:18 < bridge_> is this something serious? ^^ 15:18 < bridge_> no, its not 15:18 < bridge_> or just some visual representation somewhere 15:18 < bridge_> yes 15:18 < bridge_> then just pick numbers that suit what you feel is best 15:18 < bridge_> xDDD 15:18 < bridge_> that's what I'd do 15:18 < bridge_> alright 15:19 < bridge_> now i just need to get this code into avascript 15:19 < bridge_> now i just need to get this code into javascript 15:19 < bridge_> ```var closeness; 15:19 < bridge_> 15:19 < bridge_> closeness = x => { 15:19 < bridge_> return Math.pow(0.64, np.sum(np.abs(x - np.median(x))) / x.length); 15:19 < bridge_> };``` 15:19 < bridge_> ez 15:19 < bridge_> i hope 15:19 < bridge_> sum is the sum of the array 15:20 < bridge_> abs takes the absolute value of each value in the array 15:20 < bridge_> i hope (converter_) 15:20 < bridge_> median takes the (len(array)/2)-th element of the sorted array 15:20 < bridge_> ```js 15:20 < bridge_> const sum = [1, 2, 3].reduce((partialSum, a) => partialSum + a, 0); 15:20 < bridge_> console.log(sum); // 6 15:20 < bridge_> ``` 15:21 < bridge_> thanks heinrich, i might get back to you on monday when everything explodes around me trying to make this work 15:24 < bridge_> you're welcome 🙂 15:27 < bridge_> louis was ahead of his time xd 15:27 < bridge_> https://discord.com/channels/252358080522747904/293493549758939136/822891602451628073 15:37 < bridge_> i did it thank you. is this illegal? 15:46 < ChillerDragon> automated chat bots might get you banned on some servers yes 15:47 < ChillerDragon> but its one of the lesser enforced ones 15:47 < ChillerDragon> jopsti wat msg did you reference? 15:48 < bridge_> https://cdn.discordapp.com/attachments/293493549758939136/1147166015277506650/image.png 15:48 < ChillerDragon> ty 15:48 < ChillerDragon> xd 16:05 < bridge_> @robyt3 16:05 < bridge_> https://cdn.discordapp.com/attachments/293493549758939136/1147170409452679188/image.png 16:05 < bridge_> what format did u use? 16:05 < bridge_> oh 16:05 < bridge_> Try reloading the page, sometimes it also does that for me 16:05 < bridge_> reloading fixed it 16:05 < bridge_> xd 16:06 < bridge_> I just use Handbrake for encoding 16:06 < bridge_> that pixelated style gives off retro game vibes 16:06 < bridge_> (which calls ffmpeg I assume) 16:06 < bridge_> yr 16:06 < bridge_> ye 16:07 < bridge_> It looks smooth if you use FSAA, but I assume nobody uses it because it can cause delay 16:08 < bridge_> @heinrich5991 i see crates.io fails sometimes in CI, are the deps not cached? what about vendoring for CI 16:08 < bridge_> [ 33%] Built target rust-bridge-shared 16:08 < bridge_> warning: spurious network error (2 tries remaining): [28] Timeout was reached (Operation too slow. Less than 10 bytes/sec transferred the last 30 seconds) 16:08 < bridge_> warning: spurious network error (1 tries remaining): [28] Timeout was reached (Operation too slow. Less than 10 bytes/sec transferred the last 30 seconds) 16:08 < bridge_> error: failed to get `syn` as a dependency of package `cxxbridge-macro v1.0.71` 16:08 < bridge_> https://github.com/rust-lang/cargo/issues/6513 16:09 < bridge_> firefox issues xd 16:09 < bridge_> link? 16:09 < bridge_> https://github.com/ddnet/ddnet/actions/runs/6042446365/job/16397568468?pr=7119 16:10 < bridge_> > ... Restoring cache ... 16:10 < bridge_> > No cache found. 16:10 < bridge_> xd 16:10 < bridge_> that seems to be the problem ^^ 16:11 < bridge_> probably needs to cachee the build folder instead 16:11 < bridge_> Caused by: 16:11 < bridge_> failed to query replaced source registry `crates-io` 16:11 < bridge_> ohh 16:11 < bridge_> the cache actually replaced the source registry? 16:11 < bridge_> or idk 16:11 < bridge_> weird wording 16:11 < bridge_> probably not 16:15 < bridge_> maybe github replaced it with their own mirror(?) 16:16 < bridge_> doesn't even suport viewing issues AFAICT 16:17 < bridge_> rly? 16:18 < bridge_> I think they do that for ubuntu packages 16:18 < bridge_> no, it doesn't replace it for crates.io 16:19 < bridge_> hmm hmm 16:19 < bridge_> maybe the cache isn't available for pull requests? 16:20 < bridge_> no, other jobs have a cache 16:28 < bridge_> @jupeyy_keks or @heinrich5991 do u have a link to the factorio blog where they did a rendering optimization 16:28 < bridge_> i cant recall which 16:29 < bridge_> https://factorio.com/blog/post/fff-333 ? 16:30 < bridge_> ye 16:37 < bridge_> implement for ddnet 16:37 < bridge_> so i can say. see i told ya 16:39 < bridge_> omg future humans will have 500 TB VRAM and simply render the whole map into memory 16:39 < bridge_> 16:39 < bridge_> these luckers 16:43 < ChillerDragon> or future humans cant game anymore at all due to some world crisis 16:44 < bridge_> that's not the future but present 16:52 < bridge_> I think @patiga implemented it for his renderer and it wasn't beneficial 16:53 < bridge_> yea for me it didn't work out, didn't test long though 17:11 < bridge_> maybe ddnet maps arent big/complex enough 17:11 < bridge_> also this opt is more for integrated gpus 17:24 < bridge_> we'll never know 17:26 < bridge_> would be interesting to run the whatever they had before this renderer and this renderer on rtx 4090 xdd 18:05 < bridge_> chillerdragon: are you still using 'wired'? 18:06 < bridge_> chillerdragon: are you still using 'wire'? 18:44 < bridge_> Yes 18:48 < bridge_> Does DDNet Client support 128 player scoreboard? 18:50 < bridge_> https://stackdiary.com/x-can-now-use-posts-for-ai-training-as-per-terms-of-service/ 18:51 < bridge_> i cant wait for everyone to start posting literally just random letters so the ai model gets confused as fuck 18:51 < bridge_> also bro "x/twitter" 18:52 < bridge_> objectively worse than calling it just "x" but oh well 18:52 < bridge_> its seo 18:52 < bridge_> the social network formerly known as twitter 18:53 < bridge_> https://groups.google.com/a/mozilla.org/g/dev-platform/c/uv7PNrHUagA 18:53 < bridge_> mozilla plans to enable ech, sounds very cool 🙂 18:53 < bridge_> Summary: 18:53 < bridge_> ECH enhances the privacy of TLS connections made by the browser by encrypting the initial packet sent at the start of the TLS connection which contains sensitive information. ECH requires server-side support in order to be effective. If ECH support is not available, then a GREASE extension containing random data is added to the TLS Client Hello which is ignored by the server. 18:53 < bridge_> it encrypts the remaining cleartext bits of the tls handshake in a way that is hopefully not blockable by china 18:53 < bridge_> or other middleware vendors 18:54 < bridge_> epic 18:55 < bridge_> did chatgpt write this 18:55 < bridge_> no 18:55 < bridge_> oh wait its IN the email 18:55 < bridge_> ok 18:55 < bridge_> i thought you summarized it or smth 18:55 < bridge_> i thought you had gpt summarized it or smth 18:55 < bridge_> not gonna lie i only used chatgpt 1 day 18:57 < bridge_> I tried using it a couple of times 18:57 < bridge_> I know someone who really likes to use copilot for programming 🙂 18:58 < bridge_> gpt3 mostly gives sht when asking complex things 18:58 < bridge_> can you give an example? 18:59 < bridge_> ask it if it can make a function that takes in an integer and returns a string with the trinary representation of that integer 18:59 < bridge_> that's not an actual question I had so far, I like real-life examples better 18:59 < bridge_> or was this something you needed to do? 18:59 < bridge_> yea 19:00 < bridge_> ah 19:00 < bridge_> bruteforcing some things for a game. but it was only for visuals so it wasnt much of an issue. did it later myself anyways 19:02 < bridge_> or ask it to optimize a piece of code using SIMD instructions or smth. 19:02 < bridge_> or try finding possible spots for memory corruption in your code. 19:02 < bridge_> I got 19:02 < bridge_> ```py 19:02 < bridge_> def int_to_ternary(n): 19:02 < bridge_> if n == 0: 19:02 < bridge_> return '0' 19:02 < bridge_> 19:02 < bridge_> ternary = '' 19:02 < bridge_> while n > 0: 19:02 < bridge_> remainder = n % 3 19:02 < bridge_> ternary = str(remainder) + ternary 19:02 < bridge_> n = n // 3 19:03 < bridge_> 19:03 < bridge_> return ternary 19:03 < bridge_> 19:03 < bridge_> # Example usage: 19:03 < bridge_> number = 42 19:03 < bridge_> ternary_representation = int_to_ternary(number) 19:03 < bridge_> print(f'Ternary representation of {number} is: {ternary_representation}') 19:03 < bridge_> ``` 19:03 < bridge_> looks like it works for python 19:03 < bridge_> looks good to me 19:03 < bridge_> tried in c++ and it gave me multiple wrong answers 19:03 < bridge_> what language did you want to have? 19:03 < bridge_> ah 19:03 < bridge_> python is like pseudocode nayway 19:04 < bridge_> how often u find simd optimization opportunities? 19:04 < bridge_> ```c++ 19:04 < bridge_> #include 19:04 < bridge_> #include 19:04 < bridge_> 19:04 < bridge_> std::string toTernary(int n) { 19:04 < bridge_> if (n == 0) { 19:04 < bridge_> return "0"; 19:04 < bridge_> } 19:04 < bridge_> 19:04 < bridge_> std::string result = ""; 19:04 < bridge_> while (n != 0) { 19:04 < bridge_> int remainder = n % 3; 19:04 < bridge_> result = std::to_string(remainder) + result; 19:04 < bridge_> n /= 3; 19:04 < bridge_> } 19:04 < bridge_> 19:04 < bridge_> return result; 19:04 < bridge_> } 19:04 < bridge_> 19:04 < bridge_> int main() { 19:04 < bridge_> int number; 19:04 < bridge_> std::cout << "Enter an integer: "; 19:05 < bridge_> std::cin >> number; 19:05 < bridge_> 19:05 < bridge_> std::string ternaryRepresentation = toTernary(number); 19:05 < bridge_> std::cout << "Ternary representation: " << ternaryRepresentation << std::endl; 19:05 < bridge_> 19:05 < bridge_> return 0; 19:05 < bridge_> } 19:05 < bridge_> ``` 19:05 < bridge_> looks good to me as well 19:05 < bridge_> i dont really use it that often thats why i asked gpt 19:05 < bridge_> well its not something u can "ask" 19:05 < bridge_> cuz u need to recognize a pattern in ur code 19:05 < bridge_> my question was "Make a C++ function that takes an integer and returns a string with the ternary representation of that integer." btw 19:05 < bridge_> to know if it may be good 19:05 < bridge_> i think 19:07 < bridge_> both functions fail for negative integers, that's annoying 19:16 < bridge_> thats what gpt is good for right? 19:17 < bridge_> idk 19:18 < bridge_> u need to give all code maybe xd 19:19 < bridge_> yea if i give it 500 lines of code it just says what i could do and with the next prompt somehow it thinks that the code was in python and wanted to implement a space shuttle on windows 19:19 < bridge_> yea if i give it 500 lines of code it just says what i could do to find the issue and with the next prompt somehow it thinks that the code was in python and wanted to implement a space shuttle on windows 19:26 < bridge_> if we let ai make a ddnet update how dogwater would it be 19:26 < bridge_> https://tenor.com/view/resume-shred-gif-13992096 19:26 < bridge_> - added zoom to the ingame browser 19:27 < bridge_> - added microwave 19:28 < bridge_> i once asked gpt about kog. it said it knows kog and it means King of Gold and you have to kill other tees and collect gold 19:28 < bridge_> brilliant gamemode 19:36 < bridge_> ```#include 19:36 < bridge_> #include 19:36 < bridge_> #include 19:36 < bridge_> 19:36 < bridge_> struct { 19:36 < bridge_> unsigned char e, o, f; 19:36 < bridge_> char llp[8], lla[16], llq[32]; 19:36 < bridge_> } typedef AR; 19:36 < bridge_> 19:36 < bridge_> class UI { 19:36 < bridge_> std::string m_ModuleName; 19:36 < bridge_> std::shared_ptr m_spAR[4]; 19:36 < bridge_> float gravity; 19:36 < bridge_> 19:36 < bridge_> public: 19:36 < bridge_> AR* getAR(int index) { return m_spAR[index].get(); } 19:36 < bridge_> }; 19:36 < bridge_> 19:36 < bridge_> int main() { 19:36 < bridge_> UI* pUI = new UI(); 19:36 < bridge_> for (int i = 0; i < 4; ++i) { 19:36 < bridge_> AR* pAR = pUI->getAR(i); 19:36 < bridge_> for (int j = 0; j < sizeof(pAR->llq) / sizeof(pAR->llp[0]); ++j) { 19:36 < bridge_> pAR->llp[j] = 0; 19:36 < bridge_> } 19:36 < bridge_> for (int j = 0; j < sizeof(pAR->lla) / sizeof(pAR->lla[0]); ++i) { 19:36 < bridge_> pAR->lla[j] = -127; 19:36 < bridge_> } 19:36 < bridge_> for (int j = 0; j < sizeof(pAR->llq) / sizeof(pAR->llq[0]); ++j) { 19:36 < bridge_> pAR->llq[j] = 127; 19:36 < bridge_> } 19:36 < bridge_> - increased the bug count from 500 to 700 19:37 < bridge_> if this were a bigger example then a mis-access from an array probably wouldnt even cause a segfaults but just corrupt memory and is a pain in the ass to fix 19:37 < bridge_> if this were a bigger example then a mis-access from an array probably wouldnt even cause a segfault but just corrupt memory and is a pain in the ass to fix 19:38 < bridge_> if this were a bigger example then a out of bound access on an array probably wouldnt even cause a segfault but just corrupt memory and is a pain in the ass to fix 19:39 < bridge_> https://github.com/Anuken/Mindustry/issues 19:39 < bridge_> 19:39 < bridge_> he's probs the most consequent person i know xDD 19:39 < bridge_> https://cdn.discordapp.com/attachments/293493549758939136/1147224298923237456/image.png 19:39 < bridge_> https://crates.io/crates/pretty_assertions_sorted 19:40 < bridge_> https://old.reddit.com/r/rust/comments/1677ar8/why_is_rust_println_slower_than_java_println/ 19:40 < bridge_> annoying to read this kind of thread, people keep telling the person that they're holding it wrong 19:41 < bridge_> instead of conceding that this a problem with rust and one that will probably get fixed at some point 19:41 < bridge_> yeah indeed very sad 19:42 < bridge_> hm 19:42 < bridge_> the problem is that usually the guys making this posts just want to say "ha, rust wasnt fast after all" 19:42 < bridge_> well, it isn't in this case 19:42 < bridge_> which is a problem, and should be fixed 19:43 < bridge_> https://doc.rust-lang.org/src/std/io/stdio.rs.html#535-540 19:43 < bridge_> they seem to know about it 19:43 < bridge_> u can contribute to rust 19:43 < bridge_> yes 19:43 < bridge_> I wanted to do it at some point 19:43 < bridge_> which is why the commenters that tell me that this is by design make me sad 19:43 < bridge_> "you're just incompetent at using rust" 19:43 < bridge_> no! 19:43 < bridge_> rust has a problem and it should be fixed 19:43 < bridge_> here's a workaround 19:43 < bridge_> based 19:44 < bridge_> well internet is big and ppl say what they want 19:44 < bridge_> this is /r/rust 19:44 < bridge_> and if they dont insult then yeah thats that xd 19:44 < bridge_> not "the internet" 19:44 < bridge_> its literally the internet 19:44 < bridge_> bro when it's slower than pyson, then it's serious problem 19:44 < bridge_> its slower than python on debug i think 19:44 < bridge_> if you say this, then this will become a non-statement 19:45 < bridge_> because everything is the internet 19:45 < bridge_> yet not everything on the internet is this kind of stuff 19:45 < bridge_> there are better communities than this 19:45 < bridge_> well reddit is very close to the internet 19:45 < bridge_> if u said its rust zulip 19:45 < bridge_> i would understand 19:45 < bridge_> it's being moderated by people close to the rust project 19:45 < bridge_> I think it's sad to see this in any rust community space 19:45 < bridge_> this is one of rust's community spaces 19:46 < bridge_> well the top comment has a comment on it by someone saying what u say 19:46 < bridge_> > It aint that difficult. There is something called buffering, that Rust’s println! macro doesn’t do by default. Mostly because it would be a problem on its own. But Python, JS, etc do it by default. 19:46 < bridge_> no 19:46 < bridge_> it says that rust buffering would be a problem 19:46 < bridge_> i dont mean this one 19:46 < bridge_> the comment to this one 19:47 < bridge_> I see 19:47 < bridge_> not the top comment, obviously, and still, it's not that there's a good comment 19:47 < bridge_> it's that there are 20 bad ones 19:47 < bridge_> also reading more i think its because its complex cuz race conditions and rly OS dependant stuff 19:47 < bridge_> yes, that's what the comments say 19:47 < bridge_> but that's not why it is the way it is 19:47 < bridge_> it's just handwaving the problem that rust has 19:47 < bridge_> trying to find a good reason for it 19:47 < bridge_> @heinrich5991 tbh i would assume good faith here on the others, they simply think thats the way and havent rly thought further 19:48 < bridge_> yes. if you haven't done that, you shouldn't be like "you're holding it wrong, rust is right" 19:48 < bridge_> https://cdn.discordapp.com/attachments/293493549758939136/1147226469714645144/image.png 19:48 < bridge_> that's evangelism and reflects badly on you 19:48 < bridge_> i blame global variables 19:48 < bridge_> I don't think they're actinig in bad faith 19:48 < bridge_> I still think the behaviour is bad 19:49 < bridge_> so its the basically the difference between `std::cout << "hello" << std::endl;` and `std::cout << "hello\n";`? 19:49 < bridge_> AH, i knew u'd secretly search for rust projects 19:49 < bridge_> on your linux pc 19:49 < bridge_> yes, roughly 19:49 < bridge_> jupstar i am going to dribble you like a basketball 19:49 < bridge_> well sounds like some action 19:51 < bridge_> rust has found its way into my for you page too 19:51 < bridge_> https://cdn.discordapp.com/attachments/293493549758939136/1147227287993978991/image.png 19:54 < bridge_> soon it will be ddnet 19:55 < bridge_> one of my everyday fears 19:55 < bridge_> and when its ddnet i will suffer because rust is a hard language to learn for me and i bet if i ask for help everyone will go "read the manual" 19:57 < bridge_> rust already is in ddnet 19:57 < bridge_> yeah but i mean in like 19:57 < bridge_> anything that doesnt take a big brain to make updates for 19:57 < bridge_> i dont think rust is hard to learn generally speaking 19:57 < bridge_> 19:57 < bridge_> it depends on what your goals are 19:57 < bridge_> but yeah rust has problems it would be nice if they fix the stdout buffering 19:57 < bridge_> it would also be nice if polonius got more push 19:57 < bridge_> want to learn rust but kinda dont want to bcs i have no reason 19:58 < bridge_> and strict provenance 19:58 < bridge_> i just miss the nightly features 19:58 < bridge_> the reason is u will learn more than just a language 19:58 < bridge_> collect_into 19:58 < bridge_> it may teach things u thought were safe that arent 19:58 < bridge_> get_multiple_mut 19:58 < bridge_> it can make u a better c++ dev 19:58 < bridge_> also the tooling is just awesome 19:58 < bridge_> cmake is my pains 19:58 < bridge_> 😭 19:58 < bridge_> 😭 19:58 < bridge_> look at ddnet cmake 19:58 < bridge_> its gigantic 19:59 < bridge_> static linking best xd 19:59 < bridge_> 😭 19:59 < bridge_> lto thic 19:59 < bridge_> ddnet cmake is hell xd 19:59 < bridge_> and idk why 19:59 < bridge_> true.. as of rn, i don't even have a build.rs 19:59 < bridge_> so no build script at all 19:59 < bridge_> TIL you can cargo clean -p 19:59 < bridge_> to only cargo clean a specific dep 20:00 < bridge_> i guess that makes sense 20:01 < bridge_> hey does anyone know if nerdfonts are possible in tty? 20:01 < bridge_> ofc 20:01 < bridge_> i use nerdfonts 20:01 < bridge_> jetbrains nerd 20:01 < bridge_> my terminal is alacritty 20:01 < bridge_> made in rust 20:01 < bridge_> opengl accel 20:01 < bridge_> i3wm 20:01 < bridge_> gentoo 20:01 < bridge_> i recommend u switch over fast 20:01 < bridge_> leave the closed sourceness 20:02 < bridge_> opengl 20:02 < bridge_> that's so 1991 20:02 < bridge_> yeah 20:02 < bridge_> i wonder when they add vulkan 20:02 < bridge_> https://github.com/alacritty/alacritty/issues/183 20:02 < bridge_> > Closing because this is a non-goal. If someone ever bothers to write a Vulkan renderer feel free to send a patch, but currently we already have two different OpenGL renderers and that strikes a very good balance between GPU support and performance. Writing a Vulkan renderer would neither improve performance nor support much. 20:02 < bridge_> yea i use alacritty too but i mean in your tty 20:02 < bridge_> past human 20:02 < bridge_> yeah 20:03 < bridge_> gui is non-existent there 20:04 < bridge_> ah u mean 20:04 < bridge_> tty 20:04 < bridge_> i see 20:04 < bridge_> yea 20:04 < bridge_> hmm 20:04 < bridge_> nvm it doesnt work: 20:04 < bridge_> https://unix.stackexchange.com/questions/735514/how-to-enable-true-color-support-and-nerd-fonts-in-arch-linux-console 20:04 < bridge_> yeah 20:05 < bridge_> https://packages.gentoo.org/packages/media-fonts/terminus-font 20:05 < bridge_> use this 20:05 < bridge_> https://wiki.gentoo.org/wiki/Fonts 20:05 < bridge_> wait idk if these docs are for tty even 20:06 < bridge_> or is it 20:06 < bridge_> yea the terminus fonts are preinstalled i think. 20:06 < bridge_> sadly no special cool icons for nvim in tty ig. 20:06 < bridge_> well tty is pretty limited 20:06 < bridge_> i suggest a tiling wm 20:06 < bridge_> its rly rly lightweight 20:06 < bridge_> i use bspwm 20:06 < bridge_> nice 20:07 < bridge_> do u use pulseaudio or pipewire 20:07 < bridge_> pulse 20:07 < bridge_> what distro 20:07 < bridge_> arch 20:07 < bridge_> BTW 20:07 < bridge_> smh 20:07 < bridge_> i use gentoo btw 20:07 < bridge_> :BASEDHALT: 20:07 < bridge_> i have no cpu cycles to spare. no thank you 20:07 < bridge_> (one of the reasons i switched from arch to gentoo was for this precious moments) 20:08 < bridge_> (where i met another arch user) 20:08 < bridge_> :BASEDDEPT: 20:08 < bridge_> the giga flex i see 20:08 < bridge_> also its fun 20:08 < bridge_> openrc is fun too 20:08 < bridge_> when u compile u can think about ur life 20:08 < bridge_> yea gentoo is good for reallife interactions 20:09 < bridge_> ye 20:09 < bridge_> i only rly have to wait when compiling llvm, nodejs or firefox tho 20:09 < bridge_> since you only go to your pc for using your package manager and hitting enter xdd 20:09 < bridge_> kek 20:09 < bridge_> i saw it 20:10 < bridge_> i tried to install firefox on wm once 20:10 < bridge_> and it didnt compile nodejs in 3 hours :feelsbadman: 20:11 < bridge_> and then i realized i dont need browser 20:11 < bridge_> skill issue 20:21 < bridge_> you can use `extend` instead 20:22 < bridge_> .extend(...map(||{}) ? 20:22 < bridge_> yes 20:22 < bridge_> and that does not create any heap alloc? 20:22 < bridge_> not more than `collect_into` 20:22 < bridge_> ok 20:22 < bridge_> thx 20:23 < bridge_> in fact, that's its implementation: https://github.com/rust-lang/rust/blob/361f8ba847af0288b1beb3b84f6b7b4d3850bb43/library/core/src/iter/traits/iterator.rs#L2206 20:24 < bridge_> i c 20:24 < bridge_> guess this wasn't intuitive for me 😄 20:27 < bridge_> oh yeah it takes an iterator, well that makes stuff easier^^ 20:32 < bridge_> can you elaborate where you need this? 20:33 < bridge_> can't remember, but i simply used multiple split_mut then 20:33 < bridge_> ah yea, that works but is annoying 21:39 < bridge_> ? 21:39 < bridge_> I don't know 21:39 < bridge_> in the serverbrowser, yes, I think 21:40 < bridge_> In-game 21:47 < bridge_> I mean being able to see all players in the scoreboard 21:58 < bridge_> no it's not possible 21:58 < bridge_> it's also not easy to do in a clean way 22:07 < bridge_> I am pretty sure F-Client does it actually 22:17 < bridge_> Really? I remember using that client but I didnt notice that. Maybe it didnt exist at that time 22:27 < bridge_> can u screenshot? i wonder how it looks, to me 64 is already flood of text xd 22:27 < bridge_> 22:27 < bridge_> maybe on 16:9 with 2 more panels 22:38 < bridge_> just add a slider ig? 22:38 < bridge_> so you press your scoreboard key and scroll? 22:40 < bridge_> and that's a clean solution? 22:41 < bridge_> i find it rather annoying to have to do extra stuff to find ppl in scoreboard xd 22:41 < bridge_> i dunno what a good solution could look like 22:53 < bridge_> Just make a button and make it two pages 22:54 < bridge_> Ig this is the easiest solution (if possible) 23:02 < bridge_> that would also imply adding mouse support for scoreboard 23:02 < bridge_> not impossible, but also not trivial 23:03 < bridge_> if someone wants to code it with a chance it not being merged, it could help to see if the feature is useful enough