• Bogolese (unregistered)

    Been there, done that.

    "Normal" work schedule "back then:"

    Arrive at 10AM

    Fix stupid stuff done the night before from 10AM - Noon

    Do more stupid stuff from Noon - 2AM

    Repeat

  • Heinebold (unregistered)

    That's what you get when you have bosses completely impervious to reason. "If you can ship it tomorrow, then ship it tomorrow, the users won't see if your code is pretty anyway. You can fix it later when there's time" - "So, will I get time to fix old things now?" - "No, I need you to ship this other huge feature until turshday! Do whatever you can to make thursday, you can fix the code later..."

  • (nodebb)

    TRWTF is that feeling when the comment should say:

    // Don't blame me for this WTF // Best I could do with what other people did before me

    Addendum 2022-04-13 09:33: I curse you, mark down - Curse you, I say!

  • MaxiTB (unregistered)

    I can't even count the times where one developer decided to give up because ((reasons)) and left rubbish code behind which resulted in their coworkers doing extra shifts to fix all the mess later. And all because they can't bring it to themselves to just go home, sleep over it and announce the next day during the standup "I couldn't fix it, can someone help me out". Boy it's infuriating to clean up sloppy mess after someone else, especially when this person says something and suddenly you have a big pile of technical debt with the offender on vacation or no longer part of the project. "I don't care" people should always be instantly removed from a project and promoted to line management, where they belong.

  • Sole Purpose Of Visit (unregistered)

    I can see monkey-patching for just about anything (as long as the this is not "object," or the moral equivalent thereof.

    But I'm distinctly concerned about the whole idea of monkey-patching one of the few basic methods of "object," such as ToString. That is a little too close to taking a machine gun to your .NET feet for me.

  • (nodebb) in reply to Sole Purpose Of Visit

    Hopefully, that is the overridden toString() method of a custom class. At the same time, I don't want to see something like:

    myInstance = new myClass(dataObject.ToString())
    

    instead of:

    myInstance = new myClass(dataObject)
    
  • (nodebb) in reply to Sole Purpose Of Visit

    It could be monkey patching ToString() so that it has side effects. That'd be… horrifying.

  • Jeremy (unregistered)

    What's left out is the are the comments of the developer who has to fix this 5 years later, when a lot more code was put in place that actually relies on this monkey patch

  • The Shadow Knows (unregistered)

    Perfectly understandable to put in sloppy and uncommented code in an emergency - I've literally had to write something that was life saving as a piece of medical equipment wasn't communicating and the patient was in the middle of surgery. Quick and dirty code that needed to run without error (though if it did error it would have been the same result as if we'd done nothing, so it was worth trying). Then the next day let someone who wasn't shaking go in and write a better version with a description of why it was needed.

    But it's also understandable that there's some managers who would have told everyone to leave the code as is and go onto the next task - it's working so don't bother and fix something that isn't.

  • (nodebb)

    Back in the nineties working in an HP environment we needed a simplified program launcher toolbar for our suite of applications. The original was developed with obsolete libraries and was difficult to update. I built it's replacement in a couple of days using dtksh, which married HP's Desktop Environment (motif based) with a very early version of ksh93. It took a couple of days because it kept on crashing. I'd put in echo statements to try to isolate the problem, but then it wouldn't crash. I tried re-arranging the code, but it still crashed. I removed the echo statements one by one until it crashed, and determined the echo statement between two commands was the one keeping it from crashing. Then I substituted the null command, ":", and protected it with copious comments along the lines of "If you remove this, you will break our toolbar and you will be inundated with angry phone calls".

  • ichbinkeinroboter (unregistered) in reply to Bogolese

    for me, "back then" 10am = 8am Stupid stuff (aka "the negative work zone") after 4pm.

    I try to do harmless admin or research things later in the afternoon now.

  • (nodebb)

    I don't care. Stop time, spend several hours or days to fix the error, then start time again.

  • (nodebb) in reply to Nutster

    Your "preferred" introduces a coupling between the two classes which may be totally inappropriate.

  • ttlanhil (unregistered) in reply to dkf

    We already have per-socket licenses and pay to enable features - why not license a daily quota of strings?

    You need to monkeypatch Object's toString (or per language equivalent) so that any attempt to get a string will check if you've used your quota (and keep track of use for the day).

    Now that's horrifying!

  • see sharp (unregistered)

    Seems like an issue too urgent to wait for the developer to first get needed sleep and then approach the problem the correct way. Not the 2am developer being either lazy or careless (that's whoever created the problem requiiring the 2am monkey patch in the first place). Throwing in a patch in the middle of the night is just a developer recognizing his/her limits under the circumstances of the moment.

  • Argle (unregistered)
    Comment held for moderation.

Leave a comment on “A Careless Comment”

Log In or post as a guest

Replying to comment #:

« Return to Article