• 0 Posts
  • 14 Comments
Joined 1 year ago
cake
Cake day: June 13th, 2023

help-circle

  • A very long time ago I was on psychedelics at a Phish show. I had a blast at the show, but the venue also had an upcoming Guy Fieri event and I ended up confronted with massive posters that were just Guy Fieri's weird head everywhere. I had a really bad time for a while until I got out of there. Just frosted tips and flames as far as the eye could see. I had welcome to flavortown on loop in my head and in that moment I experienced true cosmic horror at the idea that Guy Fieri existed in our universe and we were powerless to stop it.

    This picture is like that.



  • The final project in my instrumentation class was to tune a PID controller for a hot/cold mixing valve. I (CS/ENG) was paired up with an engineering student and a lot of it was throwing parameters in, seeing if weird shit happened, and then turning down or up based on the result. I had a programming final and something else I was supposed to be studying for, so I just started doing a binary search with the knobs. We got the thing tuned relatively fast and my partner acted like I was a wizard.











  • I've been a dev for 20+ years and yeah, learning a new repo is hard. Here's some stuff I've learned:

    Before digging into the code:

    • get the thing running and get familiar with exercising it: test happy path, edge cases, and corner cases. We're not even looking at code yet; we're just getting a feel for how it behaves.
    • next up, see if there's existing documentation. That's not an end-all solution, but it's good to see what the people that wrote the thing say about it.

    Digging into the code:

    • grep is your very best friend. Pick a behavior or feature you want to try and search for it in the codebase. User-facing strings and log statements are a good place to start. If you're very lucky, you can trace it down to a line of code and search up and down from there. If you're unlucky, they'll take you to a localization package and you'll have to search based on that ID.
    • git blame is also your very best friend. Once you've got an idea where you're working, use the blame feature on github to tie commits to PRs. This will give you a good idea of what contributing to the PR looks like, and what changes you'll have to make for an acceptable PR.
    • unit tests are also a good method of stealth documentation. You can see what different areas of the code look like in isolation, what they require, and how they behave.
    • keep your own documentation file with your findings. The act of writing things down reinforces those things in your mind. They'll be easier to recall and work with.
    • if there's an official channel for questions / support, make use of it. Try to strike a balance here: you don't want to blow them up every five minutes, but you also don't want to churn on a thing for days if there's an easy answer. This is a good skill to develop in general: knowing when to ask for help, knowing when an answer will actually be helpful, and knowing when to dig for a few minutes first.

    There's no silver bullet. Just keep acquiring information until you're comfortable.