• Balthazar@lemmy.world
    link
    fedilink
    arrow-up
    37
    arrow-down
    1
    ·
    6 hours ago

    It’s always scary when it compiles without errors the first time. Then you just know there’s a logic bug or corner case in there somewhere.

  • Solemarc@lemmy.world
    link
    fedilink
    arrow-up
    57
    ·
    8 hours ago

    My favourite is always;

    Lemme quickly write this test, it passes great, if I make this little change it’ll fail. It’s still passing, damn.

    • dan@upvote.au
      link
      fedilink
      arrow-up
      35
      ·
      6 hours ago

      The worst is when you expect an existing test to fail, but it passes, and it turns out the test wasn’t actually properly testing the code. Fixing the test finds a bunch of broken edge cases.

      • TunaLobster@lemmy.world
        link
        fedilink
        arrow-up
        27
        ·
        6 hours ago

        Then you ask questions about what the past person could possibly have been thinking. You wonder what logic path brought them to create the code this way. You check git blame. It was you.

        • sbv
          link
          fedilink
          English
          arrow-up
          9
          ·
          5 hours ago

          Debugging. It’s a whodunnit where the victim, murderer, and investigator are all you.^(apologies to Filipe Fortes)

    • marlowe221@lemmy.world
      link
      fedilink
      English
      arrow-up
      12
      ·
      6 hours ago

      Nothing is temporary. Every script, patch, application, and duct tape MacGyver/Scotty inspired fix I’ve ever written will run for eternity….

      • dan@upvote.au
        link
        fedilink
        arrow-up
        12
        ·
        edit-2
        6 hours ago

        The first “temporary hack” I ever wrote for my current job (~January 2014) is still in the codebase.

    • AwkwardLookMonkeyPuppet@lemmy.world
      link
      fedilink
      English
      arrow-up
      2
      ·
      4 hours ago

      One time I stayed up late trying to fix a really complicated problem that I couldn’t figure out. I was drinking. I got really drunk and fixed the problem. In the morning I couldn’t figure out my own code. I had no idea what I wrote, or how it worked, but it did work. I just left it since it was apparently above my ability to fix.

  • AwesomeLowlander
    link
    fedilink
    arrow-up
    3
    ·
    5 hours ago

    MFW I hook up a Factorio spaghetti section to inputs and it works the first time.

  • RedSeries@lemmy.world
    link
    fedilink
    English
    arrow-up
    3
    ·
    6 hours ago

    Remember, every temporary solution is a permanent one! It’s always spooky when it works the first time.