03:03 < bridge> is it common practice to have a backend always return HTTP 200 plus a status code to indicate errors rather than using other HTTP codes. 03:03 < bridge> our java backend devs seems to prefer 200 always 03:17 < bridge> <0xdeen> I haven't seen that. Errors should return an error code. Just because your library makes handling those annoying is not an excuse to not use error codes. 03:40 < bridge> :owo: cool 03:43 < bridge> i'm guessing they want the confidence to say it is not their fault for anything non-200 and pass the problem as faults of load balancers and such to SAs (server administrators) 03:44 < bridge> still weird tho 08:27 < bridge> `This class of status codes indicates the action requested by the client was received, understood, and accepted` 08:28 < bridge> Which means 200 is on the http level, the body response can contain an error about the processed data for some reason 09:38 < bridge> web dev is a free warzone 09:38 < bridge> everybody does what they want 09:57 < bridge> Yup 10:13 < bridge> You can't even shoot yourself properly ;( 11:11 < bridge> imagine web 12:36 < bridge> @learath2 https://www.cambridge.org/core/journals/journal-of-functional-programming/article/knuthmorrispratt-illustrated/8EFA77D663D585B68630E372BCE1EBA4 12:37 < bridge> remember aho corasick? 12:38 < bridge> Is it from this journal volume? 12:38 < bridge> idk 12:39 < bridge> but this is a algo related to search 12:39 < bridge> > String search is a classic problem. Given a string, the pattern, determine if it occurs in a longer string, the text. String search can be solved in O(n+m) time and O(m) space, where n is the size of the text and m is the size of the pattern. Unfortunately, the algorithm that does so, Knuth–Morris–Pratt (KMP) (Knuth et al., Reference Knuth, Morris and Pratt1977), is hard to understand. Its pseudocode is short, but most explanations of it are 14:18 < bridge> https://cdn.discordapp.com/attachments/293493549758939136/1230130286487142440/2024-04-17-141754_1920x1080_scrot.png?ex=6632331b&is=661fbe1b&hm=f0ed83e7532f6bff6a4b818020271fd140821d819f7e8e399b0e20429e7514ea& 14:19 < bridge> ^ mipmap debugging going on, found the image oddly appealing 14:35 < bridge> Looks funny 14:43 < bridge> Have any of you heard of "Durable Execution"? It's quite an interesting concept 14:57 < bridge> It's like a distributed job queue that is very tolerant to failure by way of having the ability to just resume any job at any point 16:08 < bridge> Dones anyoye give deep fly code? 16:08 < bridge> pls 16:44 < bridge> https://wiki.ddnet.org/wiki/Binds#Deepfly 18:04 < bridge> is it possible to save logs to `$CURRENTDIR/filename` not `$USERDIR/filename` 18:13 < bridge> that gives the phrase MIP a completely new interpretation 😄 18:13 < bridge> 18:13 < bridge> "The letters MIP in the name are an acronym of the Latin phrase multum in parvo, meaning "much in little"." 18:16 < bridge> why the fucking hell does gitlab require a phone number to register 18:17 < bridge> instant cancel 18:17 < bridge> 🤣 18:18 < bridge> biggest bullshit i've ever seen 18:18 < bridge> and they advertise with privacy 18:19 < bridge> btw is there a good irc chat nvim plugin? 18:24 < bridge> so when you normally register to gitlab u dont need phone number 18:24 < bridge> but if you register over github they want it 18:24 < bridge> now jupeyy is taken by an account that will never exist :lol: 😭 18:31 < bridge> oof 18:33 < bridge> <0xdeen> Put `add_path $CURRENTDIR` at the top of storage.cfg I think 19:19 < bridge> You could specify the logfile with an absolute path. If you change the first storage location then everything will be saved there 19:20 < bridge> https://www.cs.yale.edu/homes/perlis-alan/quotes.html 19:20 < bridge> ``` 19:20 < bridge> 1. One man's constant is another man's variable. 19:20 < bridge> 2. Functions delay binding; data structures induce binding. Moral: Structure data late in the programming process. 19:20 < bridge> 3. Syntactic sugar causes cancer of the semicolon. 19:20 < bridge> 4. Every program is a part of some other program and rarely fits. 19:20 < bridge> 5. If a program manipulates a large amount of data, it does so in a small number of ways. 19:20 < bridge> 6. Symmetry is a complexity-reducing concept (co-routines include subroutines); seek it everywhere. 19:20 < bridge> 7. It is easier to write an incorrect program than understand a correct one. 19:20 < bridge> 8. A programming language is low level when its programs require attention to the irrelevant. 19:20 < bridge> 9. It is better to have 100 functions operate on one data structure than 10 functions on 10 data structures. 19:20 < bridge> 10. Get into a rut early: Do the same process the same way. Accumulate idioms. Standardize. The only difference(!) between Shakespeare and you was the size of his idiom list - not the size of his vocabulary. 19:20 < bridge> 11. If you have a procedure with ten parameters, you probably missed some. 19:20 < bridge> 12. Recursion is the root of computation since it trades description for time. 19:20 < bridge> .... 19:20 < bridge> ``` 19:20 < bridge> tl;dr? 19:21 < bridge> read them 19:21 < bridge> its quotes 19:21 < bridge> fun 19:23 < bridge> man egui shots out major updates so often :lol: 19:24 < bridge> almost as often as robster 19:24 < bridge> but just almost 19:24 < bridge> 😏 19:25 < bridge> @robyt3 how would you rate your current rust skill from 0-100? 19:26 < bridge> 0.1 maybe, I successfully installed and configured rust, and I wrote maybe 5 lines of tests for a console function once because it apparently exists in our rust code 19:27 < bridge> perfect. anything >0 is scalable 19:27 < bridge> end of year you must be rust expert 19:27 < bridge> 19:27 < bridge> i believe in you 19:31 < bridge> Rewriting ddnet ui in rust :justatest: 19:31 < bridge> xdd 19:33 < bridge> Ill probably work with Rust on my job 😏 19:43 < bridge> cheater 19:44 < bridge> i'd love to have a job that has nothing to do with databases. 19:44 < bridge> 19:44 < bridge> i envy ryo so much 😂 19:47 < bridge> My first project will be just to play around with wasm and tell em if it's a good shit 19:47 < bridge> :greenthing: 19:47 < bridge> spoiler: it's good 19:47 < bridge> 19:47 < bridge> if you need plugin system 19:48 < bridge> I saw someone was making a game with wasm 19:48 < bridge> And it had a lot less fps 😬 19:48 < bridge> 😏 19:48 < bridge> And it had much less fps 😬 19:49 < bridge> it runs at pretty good speed indeed 19:49 < bridge> 19:49 < bridge> only problem is sharing memory, that's not very cheap 19:49 < bridge> between host & guest i mean 19:53 < bridge> Ayyo, I have a problem that i keep timing out and idk the reason why. I timeout quicker / more on populated servers 19:53 < bridge> I need help 19:53 < bridge> restart router 19:53 < bridge> funny 19:53 < bridge> set cl_port in f1 19:53 < bridge> was serious 19:54 < bridge> i have the issue since 2 months 19:54 < bridge> and have u restarted router in 2months?= 19:54 < bridge> yes 19:54 < bridge> it was even turned off for 2 weeks 19:54 < bridge> call ISP 19:54 < bridge> i dud 19:54 < bridge> if it's on all servers especially 19:55 < bridge> they dont block anything they told me 19:55 < bridge> i mean yes 19:55 < bridge> not blocking but apparently selling you shit :lol: 19:55 < bridge> what cl_port shall i set? 19:55 < bridge> u can try 13000 19:55 < bridge> 19:55 < bridge> then restart 19:55 < bridge> 42069 19:56 < bridge> that does not tell me a lot 19:56 < bridge> https://cdn.discordapp.com/attachments/293493549758939136/1230215228244099132/image.png?ex=66328236&is=66200d36&hm=dd6f24a265edf1a0cc160b7b63dc668390b59ab665ada3551631752a9e3b44e2& 19:56 < bridge> but if u have it since 2 months.. i assume it wont help 19:56 < bridge> it forces the client on a specific port 19:56 < bridge> which SOMETIMES helps 19:56 < bridge> esp for ppl that use dummy too 19:56 < bridge> ill chill a bit on an another server to confirm i time out there aswell 19:56 < bridge> alright 19:57 < bridge> but ger10 multeasy i timeout quick 19:57 < bridge> mh on ger10 it _might_ also be the filter 19:57 < bridge> but better confirm on other servers first 19:59 < bridge> nope i still timed out 19:59 < bridge> i tried RUS 20:21 < bridge> i didnt time out for 20 mins, it looks good 20:23 < bridge> and i timed out 😦 20:52 < bridge> https://cdn.discordapp.com/attachments/293493549758939136/1230229310535635046/GLYmSrfXMAAv4Vk.jpg?ex=66328f54&is=66201a54&hm=5696d68030836bd41529449c091edaaf3de40496584949a8e9152ea5502dd8a4& 20:52 < bridge> true programmer 20:52 < bridge> wizard 21:06 < bridge> @jupeyy_keks and other suggestions? 21:07 < bridge> do you use latest client? 21:08 < bridge> i have steam 21:08 < bridge> these dudes explain shit the best fr 21:08 < bridge> have u tried a different lan cable? 21:08 < bridge> maybe other port in router 21:08 < bridge> maybe a shorter cable 21:09 < bridge> i have powerline 21:09 < bridge> if you have multiple computers in your house, try if u also time out there 21:09 < bridge> but tw only game with problems 21:10 < bridge> mh ok. well dunno if anything helps here tbh 21:10 < bridge> 21:10 < bridge> i'd say it's the routing between you and the servers 21:10 < bridge> 21:10 < bridge> but why it results in timeout is unclear to me 21:10 < bridge> that kinda sounds like the port gets closed after a while for an unknown reason 21:12 < bridge> testing on a different computer would eliminate all problems that are caused by potential malfunctional software 21:12 < bridge> then you could concentrate on hardware 21:27 < bridge> yikes ☹️ 21:27 < bridge> his problem is probably the powerline adapter 21:28 < bridge> they have a substantially higher baseline latency than most wifi 21:28 < bridge> and it’ll fluctuate a lot 21:29 < bridge> especially if the gateway end adapter is not on the same circuit as the computer end adapter 21:30 < bridge> mh yeah 21:30 < bridge> better try lan cable directly in router 21:30 < bridge> i dont trust any other tech xd 21:30 < bridge> yea 21:30 < bridge> i exposed pre-drilled holes from tenants past to run my Ethernet 22:09 < bridge> ```rust 22:09 < bridge> foo!( 22:09 < bridge> "foo", 22:09 < bridge> "{x}", 22:09 < bridge> "bar", 22:09 < bridge> "{y}" 22:09 < bridge> "baz", 22:09 < bridge> x = 69 22:09 < bridge> y = 72 22:09 < bridge> ); 22:09 < bridge> ``` 22:09 < bridge> is it possible in theory to write such a macro in rust? :justatest: 22:10 < bridge> and it will return a formatted & concatenated string 22:16 < bridge> is he programming in a parking lot? xDD 22:27 < bridge> i would be surprised if it isn’t 22:43 < bridge> ```rust 22:43 < bridge> macro_rules! foo { 22:43 < bridge> ($x:expr, $y:expr) => { 22:43 < bridge> println!("x: {}, y: {}", $x, $y); 22:43 < bridge> }; 22:43 < bridge> } 22:43 < bridge> 22:43 < bridge> fn main() { 22:43 < bridge> foo!(69, 72); 22:43 < bridge> } 22:43 < bridge> ``` 22:43 < bridge> 22:43 < bridge> output: 22:43 < bridge> 22:43 < bridge> x: 69, y: 72 22:44 < bridge> 22:44 < bridge> 22:44 < bridge> is that what you wanna do? 22:47 < bridge> ```rust 22:47 < bridge> macro_rules! foo { 22:47 < bridge> ($x:expr, $y:expr) => { 22:47 < bridge> println!("x: {}, y: {}", $x, $y); 22:47 < bridge> }; 22:47 < bridge> } 22:47 < bridge> 22:47 < bridge> fn main() { 22:47 < bridge> foo!(69, 72); 22:47 < bridge> } 22:47 < bridge> ``` 22:47 < bridge> 22:47 < bridge> output: 22:47 < bridge> x: 69, y: 72 22:47 < bridge> 22:47 < bridge> or do you want smth like: 22:47 < bridge> 22:47 < bridge> ```rust 22:47 < bridge> 22:47 < bridge> fn main() { 22:47 < bridge> 22:47 < bridge> let result = format!( 22:47 < bridge> "{foo} {x} {bar} {y} {baz}", 22:47 < bridge> foo = "foo", 22:47 < bridge> x = 69, 22:48 < bridge> bar = "bar", 22:48 < bridge> y = 72, 22:48 < bridge> baz = "baz" 22:48 < bridge> ); 22:48 < bridge> 22:48 < bridge> 22:48 < bridge> hey you never talk bad about a man's crib! 22:50 < bridge> ```rust 22:50 < bridge> macro_rules! foo { 22:50 < bridge> ($x:expr, $y:expr) => { 22:50 < bridge> println!("foo: {}, bar: {}", $x, $y); 22:50 < bridge> }; 22:50 < bridge> } 22:51 < bridge> 22:51 < bridge> fn main() { 22:51 < bridge> foo!(69, 72); 22:51 < bridge> } 22:51 < bridge> ``` 22:51 < bridge> 22:51 < bridge> output: 22:51 < bridge> foo: 69, bar: 72 22:51 < bridge> 22:51 < bridge> or do you want smth like: 22:51 < bridge> 22:51 < bridge> ```rust 22:51 < bridge> 22:51 < bridge> fn main() { 22:51 < bridge> 22:51 < bridge> let result = format!( 22:51 < bridge> "{foo} {x} {bar} {y} {baz}", 22:51 < bridge> foo = "foo", 22:51 < bridge> x = 69, 22:51 < bridge> bar = "bar", 22:51 < bridge> y = 72, 22:51 < bridge> baz = "baz" 22:51 < bridge> ); 22:51 < bridge> 22:51 < bridge> 23:48 < bridge> i think he is looking for a variadic approach 23:48 < bridge> btw i think this would be very easy with a proc macro 23:48 < bridge> because you can just build the format string directly 23:52 < bridge> ah, just have it iterate over to build the string? 23:55 < bridge> https://github.com/WINSDK/bite 23:55 < bridge> no LLDB frontend - booooooh