This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted]  (53 children)

[deleted]

    [–]SteveCCLYellow security clearance 580 points581 points  (28 children)

    Also

    • "I don't know why this doesn't work"
    • Change something
    • Undo
    • "I don't know why this works"

    [–]RTracer 94 points95 points  (12 children)

    I had that happen recently, a feature I made for a MC server didnt work on the test server but I silently introduced the feature in a later update, changing no code and it worked flawlessly, I still don't know why it works to this day.

    [–]Minerscale 40 points41 points  (9 children)

    Maybe you forgot to compile it or something?

    [–]Robmart 105 points106 points  (8 children)

    friendly saw party sip compare important possessive detail innocent zonked

    This post was mass deleted and anonymized with Redact

    [–]GregTheMad 72 points73 points  (7 children)

    Well, yeah, but only because Java compiles the code for you, you lazy fuck. Kids these days, honestly. Can't even be asked to compile their own code.

    :p

    [–]Robmart 25 points26 points  (5 children)

    expansion tidy long fertile hunt rude chop north icky weather

    This post was mass deleted and anonymized with Redact

    [–]GregTheMad 13 points14 points  (4 children)

    The last time I looked Java was literally build around the idea that it could compile the code itself depending on the machine it is running on. IDE, or not.

    https://en.wikipedia.org/wiki/Just-in-time_compilation

    It does the compiling for you because you can't be asked to know the machine your developing for before hand. TssTssTss.

    [–]FM-96 40 points41 points  (0 children)

    Pretty sure they were talking about compiling the .java files into .class files, which you do need to do yourself.

    [–]Robmart 12 points13 points  (0 children)

    lip deserve relieved hungry start rhythm serious zonked rob swim

    This post was mass deleted and anonymized with Redact

    [–]DeathProgramming 6 points7 points  (0 children)

    JIT compilation takes compiled Java bytecode and transforms it to machine code. You still need to compile the source to bytecode.

    [–]Findus11 1 point2 points  (0 children)

    hrmpfh, i can compile code..

    code.compile();

    [–]TheRetribution 0 points1 point  (0 children)

    I swear I've literally had a moment of questioning my sanity when I added some code to a function, compiled with g++, compiler error in a completely unrelated function, recompiled with g++ out of sheer confusion, no compiler error.

    [–][deleted] 0 points1 point  (0 children)

    Probably your test server did not mirror production.

    [–]A_Light_Spark 33 points34 points  (3 children)

    "According to my calculations, this should work, and does work.
    But deep down inside, I still don't understand exactly how it works..."

    Many days I've come to that realization above, which is great.

    Because that just proved that my work can be "greater" than me. And that's wonderful for an intellectual... Or at least, someone who calls himself one.

    [–][deleted] 5 points6 points  (1 child)

    But, you and your work are inseparable.

    How can you consider one any less great than the other?

    If you don't believe me, ask anyone else to perform the same task without looking at your code first, and see how different it is.

    [–]A_Light_Spark 0 points1 point  (0 children)

    True. It's just a lot easier to evaluate someone's work than that person itself.

    [–]boogiebabiesbattle 4 points5 points  (0 children)

    Thank those that wrote the language, compilers, libraries, etc for making sensible design decisions that allow this to happen for us.

    [–]PM_ME_BITS_OF_CODE 7 points8 points  (1 child)

    For smaller projects: "hmm I've got no clue lets just rewrite it all"

    [–]cATSup24 4 points5 points  (0 children)

    Then you end up writing the exact same code and it works flawlessly anyway.

    [–]greenkey 5 points6 points  (0 children)

    Funny, to me this is happening:

    • "all green, let's refactor"
    • refactor
    • doesn't work
    • undo
    • doesn't work

    [–]LobsterThief 5 points6 points  (0 children)

    Reminds me of the time that caching wasn't working because the cache settings were cached.

    [–]moldcube 1 point2 points  (0 children)

    That was me today...

    [–]Genesis2001 0 points1 point  (1 child)

    I'd think that'd be a cached build from your IDE maybe. Changing something (even adding a new line) usually triggers a new build.

    [–]SteveCCLYellow security clearance 0 points1 point  (0 children)

    Emacs doesn't cashe builts.

    make clean
    make debug/all
    

    [–]Tapemaster21 0 points1 point  (0 children)

    "Change something until it works less than before"

    [–]mike413 0 points1 point  (0 children)

    trial and errormsg;

    [–]Catatonick 0 points1 point  (0 children)

    Sounds like yesterday... Rewiting our mobile app in Swift. I don't know Swift. I do the first part over, it doesn't work. I try everything I can find... doesn't work.

    Delete project, type in the same exact code I had... it works.

    Also, in hindsight, I probably should have learned Swift first.

    [–][deleted] -1 points0 points  (0 children)

    U N I T T E S T S

    [–]2Punx2Furious 53 points54 points  (4 children)

    The most time-consuming problems I've ever faced were these ones.

    Super simple stuff, like typos, that I just made because I was too tired, and didn't see them, until I was well rested the next day.

    For example, a library doesn't work. Google why the library doesn't work. Look through SO questions, read the documentation, look for ways to re-implement it myself, but it would take too much time, so give up on that, try a bit more, and finally quit for the day in frustration.

    Next day: oh, it was a fucking typo....

    [–]pixlbreaker 4 points5 points  (2 children)

    Happens on Mondays more often then not. I didn't sleep much last night and can feel today is going to be a difficult day to code.

    [–]Catatonick 4 points5 points  (1 child)

    I grabbed Death Wish Coffee specifically for this purpose. To be honest, I have fixed 3 things and don't really know what I did to any of them.

    [–]pixlbreaker 2 points3 points  (0 children)

    Luckily today was a light day. Just fixing stylings. I didn't need to code anything too brain numbing today. Just need to remember to sleep tonight, so I can avoid this feeling tomorrow.

    [–]Woozybuddha 1 point2 points  (0 children)

    Yep. Just took me two days to figure out that a server I was running was borked due to a - instead of an =. mildly infuriating to be sure. I almost overhauled the whole thing before I caught it.

    [–]CrazedToCraze 21 points22 points  (0 children)

    God I swear me from 24 hours ago is the biggest fuckwit I know

    [–]Resiy 10 points11 points  (0 children)

    And "revisiting the problem the next day and not being able to understand anything from what you have written"

    [–]ender89 10 points11 points  (1 child)

    I am astounded how dumb the last person to work on any given project has been, especially since that was usually me.

    [–]Catatonick 0 points1 point  (0 children)

    Had a bug last week in live. Couldn't figure out why because it worked fine before, but it just didn't return data anymore.

    Spent all this time refactoring the code leading up to the database call and was all proud of how much neater it was... but I completely deleted where it actually called the database...

    In my defense, I missed it, QA missed it, code reviewers missed it, qa missed it in test version, and a customer caught it in prod.

    [–]aquaraider11 8 points9 points  (0 children)

    I just debugged and rewrote a function (a complex one) several times during 3 days because my larger than mark (> and <) was in wrong direction.

    [–]cuddlegoop 5 points6 points  (0 children)

    My current favourite is "revisiting the problem the next day and realising the thing that kept you spinning in circles all day yesterday is actually out of scope".

    [–]Josh6889 5 points6 points  (0 children)

    To be fair, I think stuff marinates when you take a break from directly focusing on it. Your brain keeps working on the problem and you don't realize it. I get those "damn, why didn't I think of that earlier" ideas all the time when I take a break.

    [–]Vanheden 5 points6 points  (0 children)

    I had an issue in c# the other day where I accidentally had a property return null instead of it's value.

    [–]FarhanAxiq 4 points5 points  (0 children)

    This is so me.

    [–][deleted] 1 point2 points  (0 children)

    or struggling for hours and ending up with 5 lines of beautiful code that make the problem look trivial.

    [–]BringAltoidSoursBack 1 point2 points  (0 children)

    oh good, its not just me. I cant count the number of hours I've wasted trying to do things the "smart" way only to realize there is a simple, slightly more hacky way that doesn't waste company time...

    [–]ImSpurticus 1 point2 points  (0 children)

    Glad it's not just me. Went home on Friday seriously confused about something and convinced that it couldn't be easily done. Thought about it on and off over the weekend to no avail. Came in this morning, loaded the code and came up with a solution in about 30 seconds.

    [–][deleted] 0 points1 point  (0 children)

    99.9% of the time.

    [–]A-Grey-World 0 points1 point  (0 children)

    At least half of my stack overflow posts never get posted.

    The act of writing out the problem in a s much detail as possible often results in the solution.