I blame management



  • I was asked to review some web code. I'm not in the slightest a web developer, so how the hell am I supposed to know if it's any good or not, but that's another rant.

    I found this, apparently from a kindred spirit, and I blame mangement:

     

    // To whomever inherits this code
    //
    // I am not a web developer, and have no experience as such.
    // They needed this in a crunch and all the web guys were on
    // vacation so they forced me to hobble this together. It
    // sort of works, although there are plenty of iffy sections
    // (noted in code).
    //
    // Don't try to save it. If you value your sanity, rewrite it.
    //
    // I'm *sorry*


  • At least he was honest, but I feel for you man.



  •  He is a good man.



  • Oh the agony.  You should add an addendum letter to the next guy saying pretty much the same thing, but in your own words.


  • 🚽 Regular

    Every so often when I find the cause of a critical bug that absolutely has to get deployed in the next 5 minutes and I have to take shortcuts around some major refactoring to get it done, I leave comments like that.

    I almost always go back and fix it the right way soon after, removing the comment, but I do recall a time or two where I never went back. I hope the bad karma doesn't come onto me too hard in the future.



  • @snoofle said:

    // To whomever inherits this code
    //
    // I am not a web developer, and have no experience as such.
    // They needed this in a crunch and all the web guys were on
    // vacation so they forced me to hobble this together. It
    // sort of works, although there are plenty of iffy sections
    // (noted in code).
    //
    // Don't try to save it. If you value your sanity, rewrite it.
    //
    // I'm sorry

    So much pain! Now I'll be sad for the rest of the day.

    Snoofle, you post some dandies.



  • Was his description just?

    I know that if I came across such a warning, I woud expect the code that follows to be better than run-of-the-mill code. Dunning-Kruger effect would be in it's favor: the writer is competent enough to believe himself incompetant, which, if you don't mind my saying, indicates that he may well be ahead of your average cow-orker.

    So, was the code anywhere near as bad as it's author believed it.



  • @robbak said:

    So, was the code anywhere near as bad as it's author believed it.
    Given that I'm not really qualified to judge how things should be done in "web-ese", the code contained some quirky date-logic (he admitted he had no idea how to do dates in that particular language, but his brute force approach was clean, and he listed the shortcomings and gotcha points), some brute force page format stuff (he commented that it probably should be done in css, but he had no knowledge of css and didn't want to make it worse, so he repeated formatting blocks as needed), and like that.

    He obviously knew how to do things right; just not in the world of web, and he admitted as such.

     



  • That's like the thing you see written in chalk on the side of a dilapidated building at the beginning of a horror movie.



  • @blakeyrat said:

    That's like the thing you see written in chalk on the side of a dilapidated building at the beginning of a horror movie.
    With another mindset, it's like the note you find on the windshield of your bashed-up car: "The people watching me think I am writing my contact and insurance information.  I'm not.  Have a nice day."



  • @snoofle said:

    He obviously knew how to do things right; just not in the world of web, and he admitted as such.


    Are you sure you didn't do it yourself, and made yourself forget the horrible experience?



  • @swayde said:

    Are you sure you didn't do it yourself, and made yourself forget the horrible experience?
    I don't do web programming. Period.

    I have nothing against it. It's just that I find most of the business related stuff goes on in the server, and that's what's of interest to me. I've built enough forms that if I never have to write another check box/radio button/combo box/text box/grid again, I will be living a happy life.



  • @RHuckster said:

    Every so often when I find the cause of a critical bug that absolutely has to get deployed in the next 5 minutes and I have to take shortcuts around some major refactoring to get it done, I leave comments like that.

    I almost always go back and fix it the right way soon after, removing the comment, but I do recall a time or two where I never went back. I hope the bad karma doesn't come onto me too hard in the future.

    You will be reborn in India and forced to write crappy PHP code from a young age.

     



  • @Severity One said:

    You will be reborn in India and forced to write crappy PHP code from a young age.

    They are not forced to write crappy code. It's a cultural thing. Like freedom of speech in the USA or assisted suicide in Belgium.


Log in to reply