Wisdom From Linus | Prime Reacts

2024 ж. 1 Ақп.
367 041 Рет қаралды

Recorded live on twitch, GET IN
/ theprimeagen
Become a backend engineer. Its my favorite site
boot.dev/?promo=PRIMEYT
This is also the best way to support me is to support yourself becoming a better backend engineer.
Reviewed excerpt: lkml.iu.edu/hypermail/linux/k...
By: Linus Torvalds
MY MAIN YT CHANNEL: Has well edited engineering videos
/ theprimeagen
Discord
/ discord
Have something for me to read or react to?: / theprimeagenreact
Kinesis Advantage 360: bit.ly/Prime-Kinesis
Hey I am sponsored by Turso, an edge database. I think they are pretty neet. Give them a try for free and if you want you can get a decent amount off (the free tier is the best (better than planetscale or any other))
turso.tech/deeznuts

Пікірлер
  • For all of those asking "Why is hair blue?" I LOST A BET AND I AM A MAN OF MY WORD NO MATTER HOW STUPID I FEEL

    @ThePrimeTimeagen@ThePrimeTimeagen3 ай бұрын
    • way worse if it were green

      @user-lz2oh9zz4y@user-lz2oh9zz4y3 ай бұрын
    • thats a man of integrity

      @MrAvocadoMan@MrAvocadoMan3 ай бұрын
    • But what would you have gotten if you won?

      @onred_@onred_3 ай бұрын
    • It works, keep it :D

      @666ILIKECAKE@666ILIKECAKE3 ай бұрын
    • Respect

      @engineeranonymous@engineeranonymous3 ай бұрын
  • biblically accurate rust dev

    @gala_vs@gala_vs3 ай бұрын
    • underrated comment bhahaha

      @lonelywanderer2467@lonelywanderer24673 ай бұрын
    • 🤣

      @akhilbisht798@akhilbisht7983 ай бұрын
    • What would Linus do? WWLD?

      @nholms@nholms3 ай бұрын
    • hahaha, gottem good

      @ninocraft1@ninocraft13 ай бұрын
    • Programmers are also humans, has a video on Sr. rust dev. the dev also has blue hair.🤣🤣 kzhead.info/sun/h6ufgdlomYOKfps/bejne.html

      @coolhologramkid@coolhologramkid3 ай бұрын
  • Nice senior rust dev hair

    @DCCXXV@DCCXXV3 ай бұрын
    • 🤣🤣🤣

      @RiwenX@RiwenX3 ай бұрын
    • can't be one. He's not in a fur suit

      @TheHighborn@TheHighborn3 ай бұрын
    • It's part of the new Netflix uniform requirements

      @_Lumiere_@_Lumiere_3 ай бұрын
    • @@_Lumiere_Either that or he has to personally go to Skid Row and greenlight a series pitched by a homeless drug addict.

      @jerichaux9219@jerichaux92193 ай бұрын
    • 😂😂😂😂😂

      @riigel@riigel3 ай бұрын
  • That hair, telltale sign of entering the next phase of his furry arc

    @tacklemcclean@tacklemcclean3 ай бұрын
    • Arc

      @CallMeMSL@CallMeMSL3 ай бұрын
    • Trying so hard to pretend that he is not DrDisrespect

      @christophwinkler1655@christophwinkler16553 ай бұрын
    • @@CallMeMSL Arc

      @hasan_haja@hasan_haja3 ай бұрын
    • I find it really jarring for some reason. I can't look at it too long, or I find it disturbing.

      @yeetdeets@yeetdeets3 ай бұрын
    • ​@@yeetdeetsit is, maybe its just the autism speaking xD

      @ninocraft1@ninocraft13 ай бұрын
  • My biggest takeaway as a junior developer who is getting into real stuff. You dont have to solve every problem by creating a new abstraction, because not every problem is worth solving. - ThePrimeagen I love this. Thanks

    @ycombinator765@ycombinator7653 ай бұрын
    • Also for all level of engineers. If you are not clear about the domain of a specific functions. Copy & Paste that function for your own usage with modification and clear out all the unrelated stuff is totally fine, it doesn't violate the DRY principle. Don't try to reuse everything, please. I have a hard hard hard time to watch people are arguing about DRY and Copy&Paste

      @doc8527@doc85273 ай бұрын
    • Yeah, i have stopped myself a many times.... but a reminder is always helpful

      @XDarkGreyX@XDarkGreyX3 ай бұрын
    • YAGNI! You ain't gonna need it :-)

      @user-yf5wt2so2d@user-yf5wt2so2d3 ай бұрын
    • Software developers like to be clever. Once your cleverness gets you in trouble a few times you'll learn to prioritize simplicity and maintainability.

      @Spoonbringer@Spoonbringer3 ай бұрын
    • It's easier to write 5 lines of code 3 times than to write 50 lines of code to abstract those 5 lines and then share those 50 as a dependency in 3 projects that has to be maintained and documented for 20 years

      @bike4aday@bike4aday3 ай бұрын
  • An experienced co-worker used to say: "you write it, you own it" and "Who's going to own it?". He would say this whenever someone would suggest a new tool or wrapper.

    @michaelslattery3050@michaelslattery30503 ай бұрын
    • Yes! Someone built a cheat sheet thing for... mostly another team. I haven't used it. I'm not sure who has used it and I'm not sure who has kept the info in there updated, if they ever did. He's no longer with the company, so now it's with another team who is just maintaining it.

      @ferinzz@ferinzz2 ай бұрын
    • Then the communist co-worker says "i don't believe in private property" 😂

      @SXZ-dev@SXZ-dev18 күн бұрын
    • And then the person who wrote/owns it leaves the company

      @Blaisem@Blaisem15 күн бұрын
  • The opposite of DRY (don't repeat yourself) is WET (we enjoy typing) :D

    @nicholaswillhite5888@nicholaswillhite58883 ай бұрын
    • This is why it's bad to have too nice a keyboard

      @dfcx1@dfcx13 ай бұрын
    • That's why the best programmers are lazy by default. We spend the extra effort to make a routine atomic, so we can make it into a module. That way we can just pull it in instead of having to write the whole darn thing again.

      @HansBezemer@HansBezemer3 ай бұрын
    • I have learned that WET = Write Everything Twice; The heuristic being that you need at least three instances in order for an abstraction to be merited. It's not a perfect heuristic, but it's worth to keep in mind.

      @mr-boo@mr-boo3 ай бұрын
    • Well said.

      @pcwalter7567@pcwalter756710 күн бұрын
  • therapist: Blue hair primeagen doesn't exist blue hair primeagen:

    @batatanna@batatanna3 ай бұрын
    • Rust may make iron red but it makes programmers blue.

      @DaliPose@DaliPose3 ай бұрын
    • He was like "hold my beer"

      @Tony-mw-533@Tony-mw-5333 ай бұрын
    • primeagen isn't being treated by a therapist. the therapist is being treated by primaeagean

      @private_account407@private_account4073 ай бұрын
    • @@private_account407 thats not how this meme works but ok

      @batatanna@batatanna3 ай бұрын
    • @Alan-ru5cg@Alan-ru5cg3 ай бұрын
  • prime is about to start wearing thigh highs, and run arch

    @dromedda6810@dromedda68103 ай бұрын
    • on his way to buy programming socks, software development is an equipment sport

      @ninocraft1@ninocraft13 ай бұрын
  • I can assure you my 20+ files of extensive boilerplate designed to track div toggle events are not garbage.

    @zacharythomasrobertson8471@zacharythomasrobertson84713 ай бұрын
    • i just wouldn't understand engineering (real engineering)

      @ThePrimeTimeagen@ThePrimeTimeagen3 ай бұрын
  • Linus' two areas of proficiency are kernel development, and delivery of what TVTropes defines as the "The Reason You Suck speech."

    @petrus4@petrus43 ай бұрын
    • The two requirements for a BDFL.

      @georgerogers1166@georgerogers11663 ай бұрын
    • God bless Linus.

      @thule1823@thule18233 ай бұрын
    • Also made git

      @Blaisem@Blaisem15 күн бұрын
    • @@Blaisem Git is hmm... kinda... messed up though, we use git because everyone else does. Where mercurial and whatever really worse?

      @aoeu256@aoeu2567 күн бұрын
    • @@aoeu256 At different points they may have been, but I know some of their advantages have since been integrated into git. I don't know how they compare today.

      @Blaisem@Blaisem7 күн бұрын
  • The even more funny thing: The guy who committed the change is a software engineer at Google and later admitted he actually did not understand what the function does or why it is important in detail.

    @Finkelfunk@Finkelfunk3 ай бұрын
    • All in all, he f**ked up in the best way possible

      @electrolyteorb@electrolyteorb3 ай бұрын
    • Thats not some random engineer at Google, he is one of the oldest kernel developers, a very known guy (speaks at conferences, part of Linux advisories boards, etc), and did most of the work for ftrace framework (IIRC). Which makes this thing kind of funny and awkward.

      @BeniaminSandu@BeniaminSandu3 ай бұрын
    • Steven is not some random Google engineer. By Steven's own words; "tl;dr; Google had very little to do with the email thread. I didn't copy a function that I didn't understand but it was overkill for my use case which is why Linus said I didn't understand it. Linus was having a bad week when a bug report came in on my code." There's a longer comment on TheRegister explaining everything from his start as a kernel developer, building file systems, to the issue at hand and a more in-depth explanation of what happened.

      @dealloc@dealloc3 ай бұрын
    • Why lie?

      @31redorange08@31redorange083 ай бұрын
    • ​@@deallocWeird to take Steven's words at face value while not taking Linus's

      @Evan-dh5oq@Evan-dh5oq3 ай бұрын
  • I like how polite and thoughtful Linus is there when he writes "*' in place of the "u". Anyway, I'd start using copilot if they upload a Linus agent, I need that.

    @youkenez@youkenez3 ай бұрын
    • Don't let your memes be dreams. Train your own language model on aggro Linus emails.

      @3lH4ck3rC0mf0r7@3lH4ck3rC0mf0r72 ай бұрын
    • @@3lH4ck3rC0mf0r7 fuck. we need to do this.. lets make this a project.

      @rgergigergeergergegergeg@rgergigergeergergegergeg8 күн бұрын
  • This is something that happens all of the time at work for me too, where I continuously question "why did we make this so complicated" and the XY problem constantly comes up and haunts us! Definitely going to check your other videos on that. Ugh, with all rules in webdev - the rules like "DRY" are always "as needed" because you will inevitably end up over abstracting (or abstracting too early). Thanks for talking about the damage and impact this has had overall on a higher level!

    @flyguy8791@flyguy87913 ай бұрын
  • "I have a video where I read an article about it"....peak reactor

    @thekwoka4707@thekwoka47073 ай бұрын
    • A prime reactor, even

      @joestevenson5568@joestevenson55683 ай бұрын
    • ​@@joestevenson5568prime reactor can not be even unless it's a 2

      @papsanlysenko5232@papsanlysenko52323 ай бұрын
    • @@papsanlysenko5232A prime reactor, odd

      @supernova5434@supernova54343 ай бұрын
    • @@joestevenson5568 nuclear reactor

      @timetraveler0002@timetraveler00023 ай бұрын
    • speaking of wrappers huh

      @titos2k@titos2k3 ай бұрын
  • I agree, so much. Fighting this every day. I especially love it when teams create wrappers around APIs from other teams (not external, just another department), because, you know, maybe we want to change it at some point in the future. The more extreme version is the wrapper service, whose only purpose to map objects from a naming convention someone else invented to hour own naming convention. Add the microservices paradigms into the mix and you end up with a codebase that is 50% just wrapping and mapping.

    @mx2000@mx20003 ай бұрын
    • A significant portion of all computing is just generating and parsing json

      @oblivion_2852@oblivion_28523 ай бұрын
    • @@oblivion_2852 That is trully horrifying. Probably in the same order of magnitude of power usage compared to crypto mining

      @darekmistrz4364@darekmistrz43643 ай бұрын
  • Hii prime, just wanna say after i started watching you, i started to learn my environment. No im proud to say, im a neovim user, with all config i wrote from scratch after learning your video. Thanks so much man, you are like one of my idols ik programming world. Kinda crazy, but also crazy genius and passionate about programming. Btw, im from malaysia, small country in south east asia. Soo, ❤ from malaysia primeagen !!

    @muhammadhafizuddin2965@muhammadhafizuddin29653 ай бұрын
  • Such good continued exposure for the X/Y Problem. Well done!

    @mkvalor@mkvalor3 ай бұрын
  • >wrap an already well known tool with their own tool because it helps shorcut some basic common usages i do that all the time, it's called a Makefile

    @danielgulyas2575@danielgulyas25753 ай бұрын
    • Cmake 🤣

      @freasses@freasses3 ай бұрын
    • @@freasses ffs no. literally the definition of overcomplicating things

      @samuelwaller4924@samuelwaller49243 ай бұрын
    • @@samuelwaller4924 it depends what kind of tool.

      @rgergigergeergergegergeg@rgergigergeergergegergeg8 күн бұрын
  • It was an interesting thread to read, I appreciate the direct confrontation. There's a lot of maturity in this project.

    @kevinkkirimii@kevinkkirimii3 ай бұрын
    • That was anything but mature from Linus lol. He ranted in his face for several paragraphs. He could have shut him down in 10 sentences tops and still done it via direct confrontation. Basically Linus went beyond shutting him down and bullied/intimidated him, as you can see from the other person's meek reply that Prime skipped over. Classic Linus, still toxic.

      @Blaisem@Blaisem15 күн бұрын
    • @@Blaisem Read the whole thread, not what prime is just reacting to, understand the genesis of that conversation and you'll see why I came to that conclusion. Open source projects are hectic and repeated pull requests can be annoying, especially if they have the same issues re-occurring .

      @kevinkkirimii@kevinkkirimii15 күн бұрын
  • Most calm Finnish person…

    @sez5435@sez54353 ай бұрын
    • *Perkele*

      @Takyodor2@Takyodor23 ай бұрын
    • Finland mentioned, torilla tavataan!

      @lifelover69@lifelover693 ай бұрын
    • The Swedes knew what they were talking about when they coined the term "Management by Perkele" to describe Finnish managers 😄 I suppose Linus managed to find just about the only niche where that style KINDA works. Anywhere else it's only harmful to everyone involved 😅

      @topiuusi-seppa5277@topiuusi-seppa52772 ай бұрын
    • @@topiuusi-seppa5277 thats completely untrue. this works everywhere, you people are just soft and trained to speak 90% lies and obfuscation. linus is pure honesty. and honesty is the only thing that works long term.

      @rgergigergeergergegergeg@rgergigergeergergegergeg8 күн бұрын
  • he's delving deeper into rust...

    @hackermanreal@hackermanreal3 ай бұрын
  • Yay 5 minutes after post! Can't wait to actually get into it!

    @acetributon@acetributon3 ай бұрын
  • I'm worried what's gonna happen to the Kernel once Linus (fully)retires...

    @daniel85mg@daniel85mg3 ай бұрын
    • I hope he finds someone just like him

      @maximofernandez196@maximofernandez1963 ай бұрын
    • greg is there lol

      @vilian9185@vilian91853 ай бұрын
    • Looking at the Linux community today, once Linus retires, the whole thing is doomed ...

      @RicardoSilvaTripcall@RicardoSilvaTripcall3 ай бұрын
    • Random fact: I bought a car at an estate sale from Linus’s neighbor once. The only reason I knew it was his house is because he used to drive this obnoxious yellow Mercedes with ‘LINUX’ on the license plate, and I saw it nearby. Also, we were friends in Google+, and I feel like that should count for something.

      @AdamPippert@AdamPippert3 ай бұрын
    • A LOT of things in civilization only work because of the people who built them, or at least people who continued to have the same or similar standards of behavior, competence etc as those that did. Once that all goes away, everything falls apart. Tbh, as critical as Linux is, it looks like just the tip of the iceberg, or but one example case, atm.

      @TheJeremyKentBGross@TheJeremyKentBGross3 ай бұрын
  • I am newish to software development but I have been in Tech for just shy of a decade. The issue I see a lot when people copy something they don't understand or they repeat certain patterns that are not optimal is time. A lot of people are afraid to take that extra step to learn the "Why's" of something because they may not "Feel" like they have the time to do so on a project, in a corporate setting. You should never have this issue on your own projects at home, take the time to learn! I am certainly guilty of this and I trying to get better with each new problem/project because I have found this to only hurt me in the long run.

    @MarstonConner@MarstonConner3 ай бұрын
    • I literally went from trying to program games in java for a month or two to programming in C++ and trying to program game engines to then finding a game about making a turing complete computer and doing so to programming in Rust some other higher level things than that to finally what I am working on more actively right now which is learning about how operating systems work and trying to make one written completely in Rust without having to use assembly, I already know how annoying assembly is to program with because of the game previously mentioned and for the life of me I can't remember the conventions people have come up with for their version of assembly at best I know the most basic types of assembly work being just a find and replace with binary data that directly controls the hardware. What I mean to say with this is I found some very interesting things out by just trying to understand what code I was writing and how things worked.

      @christopheriman4921@christopheriman49213 ай бұрын
  • This is really key argument, thanks for sharing.

    @n3r0z3r0@n3r0z3r02 ай бұрын
  • OMG! This speaks to me so viscerally! I mean, sometimes you want a "wrapper" (usually scripts) to help people not make mistakes. Especially if it saves time from a daily set of tasks. But I agree 200%... sometimes companies build in-house things to do things in the way THEY do things and then they don't train the newbies or even have good up-to-date documentation. Preach, brother!

    @MikeSwanberg@MikeSwanberg3 ай бұрын
  • I think DRY is good if you apply KISS before. So primarily make things simple and as a way to do that, try and don't repeat yourself. In my current job, I made a task to abstract a "age of data checking" to a specific new class. It is so people don''t repeat themselfs, but much more about making it so if this fails, there is only one single point of failure. In the same project, we also have many linked lists (imposed by third party tool) and even if I could very well do something to make it less repetitive to handle, I didn't because it has no big added value, devs can just write a for loop for themselfs.

    @maxoumimaro@maxoumimaro3 ай бұрын
    • Part of keeping it simple, for me, is repeating myself until I know more definitively if it was actually repetitive. All too often you assume something is the same as something else, and then you get further into the problem and you were either wrong or the circumstances have changed. It's often easy to combine things that turn out to overlap in the future if they truly do, but it's a pain starting and continuing to retrofit DRY early on regardless of the situation.

      @nashiora@nashiora3 ай бұрын
    • Also, something I've seen happen too much is making something a function because it's used two or three times. This is fine as long as the same intent is behind the code. Sometimes the same code is used for different things and as such will change for different reasons. That is the biggest caveat I apply to DRY

      @SanderDecleer@SanderDecleer3 ай бұрын
    • @SanderDecleer of course different code will use slightly different functions. That’s why function arguments accept VARIABLES. Lol. They VARY. Doesn’t mean there needs to be a separate goddamn function for every single variation.

      @drygordspellweaver8761@drygordspellweaver87613 ай бұрын
    • @@SanderDecleer as long as you write same code twice, its really bad, cose as soon as he need to be updated (and he will needs in general), you have to check every f**** spot where that code was duplicated to update those part too ... but feel free to copy paste same code if you want, as long as i dont work on it i dont really care x')

      @grimpowsify@grimpowsify3 ай бұрын
    • @@grimpowsify In most cases I agree. But there are cases where two different concepts use the exact same code. When these concepts use the same method you might accidentally change more than you want while reworking that bit of code. That is why, for me in specific cases, I don't care two methods have the same nody. Copy pasting entire chunks of logic to do the exact same thing over and over again is an entirely different thing.

      @SanderDecleer@SanderDecleer3 ай бұрын
  • Great things, every dev should read the XY problem every day until engrave this in mind! Linus say it a lot of true things that many times people don't want to hear these days!

    @daltonyon@daltonyon3 ай бұрын
  • I needed this video. I have a couple of projects now, where a customer wanted to 1) upload an Excel file 2) see the list the program makes of it and 3) runs whatever needs to be run. I basically copied my class from the first of such projects for all of them, making minor improvements. For this project of that sort, I wanted to abstract it somehow. This would undoubtably have taken a lot of time I don't have (because other big project going live soon). It would be a fake problem I guess, because copying a class takes almost no time and I can start working on what needs to be done for that particular use case. The level of abstraction needed would have been a nightmare, and the worst part is: I was seriously contemplating it for a while now. So ... thanks.

    @acebasher1st360@acebasher1st360Ай бұрын
  • That video was way more to the point than I thought it would be. Very nice.

    @georgeparaskevas8091@georgeparaskevas8091Ай бұрын
  • I totally agree. Instead of fixing problem find and fix the root-cause.

    @mainendra@mainendra3 ай бұрын
  • You cannot make a problem simpler than it actually is. I feel like that people often try to abstract to make the problem simpler, but actually it almost always makes the problem more complicated. And even if that's just because now there is more code/tools/etc. to understand. Also: People should just stop inventing problems they don't actually have.

    @MultiProGGer@MultiProGGer3 ай бұрын
  • 6:00 thank you for this segment. I will view forum posts in a more distanced way from now on.

    @75hilmar@75hilmar3 ай бұрын
  • The abstraction away from the actual tech (while the underlying tech stays the same) is something that cloud providers are notorious for. For example "hey you should come use our custom web gui routing system (nginx)" or "hey you should use our container apps with 90% of the features stripped and basic scale to 0 serverless orchestration (kube)"

    @oblivion_2852@oblivion_28523 ай бұрын
  • As math grad, I think we have something similar to SWE’s obsession with abstraction, which is obsession with rigor, as described by Terry Tao’s article “There’s more to mathematics than rigour and proofs”.

    @davidli8936@davidli89363 ай бұрын
  • I don't even code and I love your content dude, keep up posting. Also respect for opening about your struggles in previous videos, big respect.

    @aiuniverse@aiuniverse3 ай бұрын
  • Why is his mustache dyed brown?

    @Griffin12536@Griffin125363 ай бұрын
  • I want to hear more on this "don't take DRY too far" rant. The perfect abstraction can be amazing when it works, but so elusive sometimes.

    @FireStormOOO_@FireStormOOO_3 ай бұрын
  • Totally agree with this. In fact replace the word “tool” with “abstraction”. There are way too many abstractions that try to hide complexity but just add to the pile of stuff to learn.

    @russellf@russellf3 ай бұрын
  • Making things more complicated than they need to be is essential for job security.

    @markusmachel397@markusmachel3973 ай бұрын
    • For business too😁

      @74Bagas@74Bagas3 ай бұрын
  • lmao i just saw this yesterday and spent a good ten minutes reading the email chain between linus and steven

    @harleyspeedthrust4013@harleyspeedthrust40133 ай бұрын
  • Super True, Thank you Lord Prime.

    @quasi_verum@quasi_verum3 ай бұрын
  • Man, you are just amazing.

    @spaceinvader8892@spaceinvader88923 ай бұрын
  • I really needed to hear this. I keep doing stupid stuff, trying to force OOP into everything and make everything a perfect abstraction. The project I'm working on isn't even complicated. I'm just trying to make Chess in the terminal and I keep failing. I'm just going to do it in a simple, straightforward way, and I promise myself that I won't abstract until absolutely necessary.

    @NibbleMeTwice@NibbleMeTwice3 ай бұрын
    • Yeah like, sometimes you need to make yourself use a simple 2d 8x8 byte array, and stop asking questions like "but what if the board needs to be customizable?" or "what if i'll need to add more unique pieces in runtime?" - first of all, the answer is "most definitely not", and second of all, unless it is the whole premise of what you're doing, just don't give a shit and do it the simple way. If you eventually find out that you didn't even need it - good! If it turns out that you have to rewrite the whole codebase to implement it - good, that's invaluable experience! I really need to understand it myself as well... Good luck with your chess project, hope it'll turn out great!

      @kittenlord3572@kittenlord35723 ай бұрын
    • i guess the problem on working with abstraction is that you also have to set your mind to the abstraction also, i learned dev on procedural, and the difficult part of switching to OOP isnt to learn and understand what object is, its more, now i have to ignore or dont really care on what will call my object, or getting the whole process in the code in mind, its more, i have an object, he need that and that, he can do this and this and i'm working at this level on this object so for example with chess, i need to create a chessman object, it have a position X;Y you could ask yourself does those positions values could be negative, does they have a maximum or a minimum ? then you can also say, i dont know so two option -> you dont set rule on min/max pos, or you also can add public properties that set thoses limits ... a chessman can move, so he should have a method to deplace it, you can ask yourself, how i will implement it ? then that could be by a translation (like a vector on X/Y), or simply passing the new position ... mebbe an enum to know wich type of Chessman it is (or just simple string to say pawn etc ..), but dont specify the rule of the chess inside the chessman object. in fact i think the "good way" to do it is that you end with a chessman object where we can know it actual position, its type (or name) and we can move it. its ALL. after that you can make a "engine" that will use those chessman object to applie moving rules, winning conditions etc (whatever you want in fact) ... and i guess with those chessman object you will also be able to reuse them for a checkers game .. (i didnt coded neither a checkers game or a chess game, but that gived me the motivation to make one for fun sooner or latrer :p) in conclusion : try keep object as simple as possible, more you make your object simple to use and manipulate, more the entire code will be easy to use for yourself and for other. taking the time to "correctly" name your methods, properties and thinking for the view point of the object itself is a good start i guess.

      @grimpowsify@grimpowsify3 ай бұрын
  • I suffered the consequences of striving to keep my code too DRY, to the point where it no longer made sense. The result was a need to refactor the code and learn that some repetition isn't inherently as bad as I initially thought.

    @tuffgniuz@tuffgniuz3 ай бұрын
  • it has been a LONG TIME since I've heard something so useful on my lunchbreak quick videos. I'll share with my team the XY problem.

    @tanvski5984@tanvski5984Ай бұрын
  • When you have abstractions for your abstractions for your abstractions. At some point you end up with problems because of the abstractions. For example I've recently found bugs with type coercion from an endpoint that produces json. Basically the mapper to the record didn't have a error case (if a field didn't exist) and rather just has a default value (which doesn't tell you if the endpoint call actually worked because of the implicit type coercion)

    @oblivion_2852@oblivion_28523 ай бұрын
  • The lore friendly next step for him are the stripey programmer socks

    @AaroRissanen-pi4td@AaroRissanen-pi4td3 ай бұрын
  • If I don’t solve tomorrow’s problems today, in a sense I’m the root cause of all problems that might not have needed to be problems if I’d problem-solved ahead of time…

    @Kane0123@Kane01233 ай бұрын
    • Sure, but in a way it's like branch prediction. If you are bad at guessing what tomorrow's problems are, you are just making it worse.

      @VojtaJavora@VojtaJavora3 ай бұрын
    • The way you deal with that is documenting the known limitations and possible future problems ahead of time so fixing them can make it onto the roadmap before they become problems. It doesn't work for everything (e.g. software running off your premises or when software and hardware are tightly coupled), but often it does.

      @3ventic@3ventic3 ай бұрын
    • The problem is, you don't know, actually know, what tomorrow's problems are going to be. And there's rarely a shortage of "today's problems" to deal with first.

      @martenkahr3365@martenkahr33653 ай бұрын
    • ​@@VojtaJavoraso what you're saying is we should get CPU prediction architects to use their powers as a team leader instead of a CPU architect... Interesting.

      @Gennys@Gennys3 ай бұрын
    • How come problems exist tomorrow?

      @pianissimo7121@pianissimo71213 ай бұрын
  • thanks, Linus/x for having a look deeply at core changes, I really appreciate that you are the last bastion

    @Meketrefe84@Meketrefe843 ай бұрын
  • Yeah, mutually exclusive solutions. That's one of my favorites. How does it get additions and concatenations correct in any reliable fashion without strong typing or different operators? It doesn't! Or all implicit conversions ever: It's not a matter of if, only when. That's why I like helping people with c++. They either listen or their screams are very delightful. Same with very "smart" assembler code. Always entertaining when it's not your responsibility.

    @fgregerfeaxcwfeffece@fgregerfeaxcwfeffece3 ай бұрын
  • MBA's are obsessed with the fantasy of JS-only companies, thinking that it will solve their recruiting problems while ignoring the complexity that writing JS exclusively brings. A company I worked for was acquired by a PE firm and they pushed us really hard to rewrite our 10yr old app in Node so that it would be easier to hire devs.

    @UntitledProjectDemo@UntitledProjectDemo3 ай бұрын
    • This is so retarded. Just because the language is the same doesn't mean the libraries and API' are, let alone the design patterns. I thought we learned this lesson with Classic ASP and VBScript / JScript

      @JP-hr3xq@JP-hr3xq3 ай бұрын
  • I like the way LT writes. Sharp, concise, clear. No superfluous words.

    @tatanyave@tatanyave3 ай бұрын
    • "No superfluous words." What? He's verbose af. Like 20% of his words are dedicated to denigrating colleagues.

      @BeefIngot@BeefIngot3 ай бұрын
    • Oh yeah, because you are not the subject.

      @bumblebee9426@bumblebee94263 ай бұрын
  • I would really appreciate it if Prime actually dove into the problem, not just sided with Linus, but formed his own opinion based on the problem space.

    @1414tyty@1414tyty3 ай бұрын
  • I wrote that docker tool, but in my defense we use a container registry that is not friendly with plain ole docker. We also have multiple environments and each environment has its own registry. I also had devs building containers from development git branches without realizing it. So the tool ensures you're building from the main branch, it tags everything for you, uploads to all of the different registries asynchronously to reduce wait times, it runs all tests prior to build and fails when tests fail, and it cleans up the registries now and then. Running the tool is a single command. I get what you're saying Prime but sometimes a wrapper is okay.

    @The-Funk35@The-Funk353 ай бұрын
  • 8:00 Frankly, I don't get the obsession with DRY. If the code is readable and performant, then who cares if there's a bit of repetition? For smaller projects especially I think it can be taken too far to the point where future humans will be unable to quickly understand what past humans had built due to all the abstraction layers...

    @lashlarue7924@lashlarue79243 ай бұрын
    • Because it's a fundamental principle. 11 times out of 10. breaking dry is just being g lazy. Why write twice when you can do it once?

      @halcyonramirez6469@halcyonramirez64693 ай бұрын
    • @@halcyonramirez6469 Yabut they can take it too far though. JS hyper-abstractions are a great example. Personally sometimes I find what you gain in elegance you often lose in future humans being unable to understand what the code is trying to do...

      @lashlarue7924@lashlarue79243 ай бұрын
    • If you don't get it, I'd consider a different career path.

      @HansBezemer@HansBezemer3 ай бұрын
    • @@HansBezemer I'm in operations. My world is not the same as yours. I'm not developing the Linux kernel where everything needs to be cleaned with chlorine pentafluoride before the PR gets approved.

      @lashlarue7924@lashlarue79243 ай бұрын
    • @@lashlarue7924 Read my lips. Develop good programming practices. Because you can fall back on them when you need them. If you develop bad practices, you won't be able to shrug them off when you don't need them.

      @HansBezemer@HansBezemer3 ай бұрын
  • Blue hair. Next step is the thigh high rainbow socks.

    @wlockuz4467@wlockuz44673 ай бұрын
    • Then he will cut off his penis. 🤣

      @rehoboth_farm@rehoboth_farm3 ай бұрын
  • 1000% agree with this. At my company, I sometimes get shit for rewriting, and rewriting the same AWS function (such as fetching file from S3 or another service) over and over again when my company has a wrapper for aws sdk. My fiew is DRY only matters when the underlying resource/code you are using has a high enough probability to change. Fun fact, all lambda function that used the company's wrapper for aws sdk failed after someone messed with the library

    @jamesmills6379@jamesmills63792 ай бұрын
  • PREACH!! I had a boss who literally told me that he would never approve duplicated code in reviews because DRY was the only way to write code

    @seanmcconnell1874@seanmcconnell18742 ай бұрын
  • I genuinely fucking hate the "XY problem" because, no, sometimes you just need to do that thing, and now every single post anywhere online about doing that niche thing is just "do this entirely different thing that doesn't actually do what you asked" "Thanks, that solved it" and no-one who actually needs to do that niche thing can find out how. I'd rather the guy who can't be bothered to research a good solution deal with a suboptimal one then everyone who *_does_* know what they're doing be unable to actually do it because we tried to protect that one stupid person from themselves. If push comes to shove, just say "well, I think you're trying to do this, in which case go link>>> here

    @robonator2945@robonator29453 ай бұрын
  • I'm afraid of what Linux will become in the aftermath of the inevitable day when we lose Linus. :(

    @CappytanMusic@CappytanMusic3 ай бұрын
  • Real talk, I've been denying pull requests lately because devs were writing crazy complicated code for doing the simplest things. Often the abstractions required a lot more code (sometimes 3 times the amount) as compared with writing the code straight up. No... You do not need to make an array of objects and loop over them for everything, especially to save repeating 2 lines of almost identical code right next to each other. No... You don't need to create 3 layers of abstractions spread all over the file and code base to write that test, just write the dang test assertion in 1 line! Seriously I've deleted thousands of lines of code like this recently because of the craziness. I'd rather update a handful of lines of code by hand than learn whatever crazy abstraction you wanna invent on the fly.

    @baka_baca@baka_baca3 ай бұрын
  • yea i needed this

    @demarcorr@demarcorr3 ай бұрын
  • Heyy... Nice blue hair 😄

    @srujangurram@srujangurram3 ай бұрын
    • It's green

      @RiwenX@RiwenX3 ай бұрын
    • wait did he get his hair done or is this some video effect @@RiwenX

      @ea_naseer@ea_naseer3 ай бұрын
    • @@RiwenX more like a teal

      @VieiraBBX@VieiraBBX3 ай бұрын
    • @@VieiraBBX that’s one of those made up colors only girls recognize, like beige.

      @RiwenX@RiwenX3 ай бұрын
    • @@ea_naseer He got his hair done

      @lovredev@lovredev3 ай бұрын
  • 8:20 - JavaScript does not have operator overloading... imagine JavaScript getting a global operator overload feature where any library you use can change the meaning of the +-operator at any time. :D:D:D:D

    @MrRecorder1@MrRecorder13 ай бұрын
    • Now we want this, someone should do it

      @clevrf0x916@clevrf0x9163 ай бұрын
  • I could not agree more, I talk about 7 minute of the video. I just realized that, I am able to create web app, and I can work with it as Java Dev but I suck as developer in general. And that start makes me going crazy.

    @4bclover@4bclover3 ай бұрын
  • deciding how much abstraction is enough and how much is too much is one of the hard parts of being a dev.

    @Oktokolo@Oktokolo3 ай бұрын
  • At the bank where I did two freelance projects the last 5 years me and another freelance colleague always yelled: "STOP! What problem are we solving?" We are running BAU, so we know what the problems are that plague us, those we solve... Others that don't create business value, we flush! And the irony is that those devs who found the edge of the edge of the edge case, didn't even bother to check if a file open actually returned a valid FD. When the create an object that it actually isn't null when they ingest data from a source didn't bother to run the conformation and consistency checks -- two classes that actually bring value for data consitency.

    @CallousCoder@CallousCoder3 ай бұрын
  • This is my first time seeing anything from Linus firsthand. I'm no expert by any means but I'm not going to lie; Sure he could have said that in a nicer way, but I agree with him on principle. I've often gotten flak for taking time to analyze the code that I'm supposed to just blindly import only to later fix a "crisis" with ease because I knew a bit about how the damn thing worked.

    @garthenar@garthenar3 ай бұрын
    • Nothing wrong with inspecting code, as long as you aren't flaming people! As brilliant as LT is as a programmer, his social IQ is pretty low.

      @Jefferson-ly5qe@Jefferson-ly5qe3 ай бұрын
    • Yeah, I don’t know if Prime has read old mailing list stuff but it has changed. He used to have more personal attacks on the dev rather than the code is garbage. He infamously said that someone should be retroactively aborted and were probably too stupid to find a teet to suck on.

      @U1TR4F0RCE@U1TR4F0RCE3 ай бұрын
  • The "you copied the function without knowing why t works" is almost never true for me, although I still have to wrap my head around how _exactly_ the async function delay(ms) on my website (copied from SO) waits for the specified amount of milliseconds. Okay, I now (more than two years after adding it) finally understand how it works, it creates a promise that waits for a timeout to run out. Pretty clever!

    @Lampe2020@Lampe20203 ай бұрын
  • I appreciate what JS's abstraction capability has done for our awareness. With it we've begun seeing the upper limit of what is a useful abstraction. And it's not something like lisp where some 0.01% of coders ever actually make anything real with it. You can't learn without making mistakes. JS has allowed many to make mistakes and begin learning from them. You cannot apply discipline to yourself if you do not have freedom. It is painful, but it allows us to learn what good programming is.

    @SemiMono@SemiMono3 ай бұрын
  • I think he meant "do not solve problems that doesn't exists" other than "do not solve small problems"

    @MACAYCZ@MACAYCZ3 ай бұрын
  • 3:19 will probably be the most played segment of this video

    @tanmaydas@tanmaydas3 ай бұрын
  • that first argument though, I can use it for Next and server components as well: "Just learn the damn thing!"

    @geni15o@geni15o3 ай бұрын
  • This is recent. YEEEES! Linus is back, the Kernel is saved!

    @arturwelp1877@arturwelp18773 ай бұрын
  • Linus may not be the nicest person in the world, but he certainly is one of the most important people in the world. He not only is a great developer, he also has basically the whole internet in his hands. Many network equipment parts (from fiber-to-wire-converters to the very servers that run the internet) run Linux or something based on Linux. Almost 100% of the web runs on Linux. And even 3.x% of desktop computers run Linux.

    @Lampe2020@Lampe20203 ай бұрын
    • Meh. It's not as important as you think it is. If it wasn't him it would have been someone else. It's just an offensive job that few--if any--sane people would actually want to do, so they let this little goblin do it.

      @youtubesuresuckscock@youtubesuresuckscock3 ай бұрын
    • @@youtubesuresuckscock But because _he_ took that role _he_ is basically the most important person in the world. It's not because it's him, it's because he created and maintains Linux.

      @Lampe2020@Lampe20203 ай бұрын
    • @@Lampe2020 That's not my definition of most important. If he had never been born, things would have more or less played out the same way. The most important people had a significant impact. At the end of the day, no operating system really matters much.

      @youtubesuresuckscock@youtubesuresuckscock3 ай бұрын
    • Had he not done what he did, other people would've come up with comparable solutions a few years later.

      @deleted01@deleted013 ай бұрын
    • @@deleted01 Expand the answer section of this comment to see my answer to another user who said basically the same thing.

      @Lampe2020@Lampe20203 ай бұрын
  • bro dyed the hair blue, looking like Ninja(fortnite)

    @xi9d@xi9d3 ай бұрын
  • I appreciate the hair color change. It really makes it obvious roughly when the video was made

    @uoweme5grand@uoweme5grand3 ай бұрын
  • Shiny object syndrome is something I am going to have to remember and use. That's amazing

    @CFEF44AB1399978B0011@CFEF44AB1399978B00112 ай бұрын
  • He seemed to be a reasonable-sounding guy knowing his way, but then...... hi dyed his hair in a strange liberal color))

    @DNAMIX1@DNAMIX13 ай бұрын
    • He said he lost a bet haha

      @nakedsquirtle@nakedsquirtle3 ай бұрын
    • He lost a bet

      @Jabberwockybird@Jabberwockybird3 ай бұрын
    • I believe that strange "liberal color" is called "blue" these days.

      @senatrius1968@senatrius19682 ай бұрын
  • I'm not really in the computer coding community. When I build my own code, if i include a function, i do learn/understand it's structure. I guess that's why I'm slow/not good at it.

    @codyaimes4354@codyaimes43543 ай бұрын
  • The thing that needs to take precedence over DRY is single responsibility / too much complexity. If you introduce more complexity to cover more use cases maybe repeating yourself is not such a bad idea? There are so many tools and so many design patterns. I just want to simplify things as much as possible so that I can go from point A to point B as quickly as possible (in terms of state management).

    @csy897@csy8973 ай бұрын
  • This happens with non homegrown wrappers too. For example I need to learn terraform for work… but I have to learn it…. Plus the stupid wrapper (looking at you terragrunt). I also have to learn k8s…. This time abstracted behind an internal home grown wrapper… Learning a tool via a wrapper is the worst. I wish the vendors would just integrate the wrapped feature natively into the thing to the extent to which it actually makes things easier…

    @relaxingsounds5469@relaxingsounds54693 ай бұрын
  • Does anybody have a link to Prime's video about the XY problem? I'd like to watch it, but I couldn't find it on either channel.

    @Zolodar@ZolodarАй бұрын
  • I agree 100% and felt alone in this. If I have two similar but not identical functionalities, for example displaying data in a list and displaying an entry in detail, I am simply going to repeat the code, yes it will trigger people's OCD, but because it's not the same thing and subject to change, I will not reuse one line of code. Yes I need to fix the same bug in multiple places but unless the thing is literally the same functionality I will not reuse the code, it's illogical, it's similar, not the same.

    @forestmanification@forestmanification2 ай бұрын
  • The docker-wrapper rant ❤

    @marcusrehn6915@marcusrehn69153 ай бұрын
  • Just so I understand the video, a bad PR on the Linux kernel that's written in C is the result of junior javascript developers?

    @DeanRTaylor@DeanRTaylor3 ай бұрын
  • This hits home hard. I've felt this for quite some time too and I also feel like it has creeped into documentation, where the actual quality of the written content has decreased, even though the quantity is vast and there's a million essential dependencies linked which you are supposed to use to make a simple program work which in return you have to read their awful docs and learn their syntax anew. Sometimes even the english language is an issue it seems. In the end you have a web frontend for some cli tool that has existed for decades. This is an upsetting trend which only makes things harder for everyone involved. As for the typical Linus rage: It's funny for us, but it's actually rough to get rectified like this, even when everything said is accurate. You just gotta take it and move on, seems the guy was a good sport about it, which is nice.

    @marianarlt@marianarlt9 күн бұрын
  • We called that Tools for Tools back in my desktop support days

    @laysdong@laysdong3 ай бұрын
  • lmofa the thumbnail has me crying

    @throwaway-lo4zw@throwaway-lo4zw3 ай бұрын
  • - Love, Linus! That was great!!

    @rodelias9378@rodelias93783 ай бұрын
  • In the mechanic world, we refer to XY problem as the can of worms paradox.- Don't be surprised when you find worms when opening a can of worms.

    @kylehorn09@kylehorn0915 күн бұрын
  • Man this article/video was a kick in the noggin. I’ve been building a document generator to avoid having to maintain like 20 document templates (and to procrastinate Salesforce dev work I need to do💀). I’m dropping the doc gen problem now

    @funkdefied1@funkdefied13 ай бұрын
    • The entire Salesforce Development field is just an abstraction built over product development. 👎🏻

      @funkdefied1@funkdefied13 ай бұрын
  • Haha, just remembered something from late early 00's. Someone made template library for PHP. Argh, PHP is great for making templates without some crazy "helper" library.

    @airjuri@airjuri3 ай бұрын
  • this whole vibe needs a shirt, had and a mug!

    @joshmccall@joshmccall3 ай бұрын
  • DRY is good when the new abstraction is flexible enough to cover majority of use-cases, e.g. C over Assembly. Otherwise, the whole thing explodes.

    @ivanjermakov@ivanjermakov3 ай бұрын
  • A discord server I'm in that has a programming help channel has it as strict advice (or even a rule? I don't quite remember) that you always state the initial problem you're trying to solve. They get a lot of questions that originate in the X Y problem and insisting that people explain why they need help often clears that up.

    @Kenionatus@Kenionatus3 ай бұрын
  • I understand exactly how he feels. I have written similar emails (or memos) in the last 50 years..

    @Oodle-ox2vf@Oodle-ox2vf3 ай бұрын
  • I understand the disdain for wrappers, but man, when they're just short hand, they're great

    @mattymattffs@mattymattffsАй бұрын
KZhead