I had one of those moments about two days ago where you have an error so confusingly dumb you just know you've done something stupid, and when you do find it you know you'll kick yourself.

I keep two development enviroments for a chunk of web software I've been working on, one locally and one remotely on the company dev server.
I'm working on my local copy (faster SSHing) and change a very simple feature, it was something related to what a function printed back out into the HTML, and I set the monster running - and nothing. No changes.
I go and look at the code again... Confused. So I stick a 'print STDERR "Value $var\n"' in there, to make sure my var is what I expect it to be, run the CGI again via the browser... Nada. Nothing in the error log. I think about this for a bit and decide that, yes, I've done something really dumb.
I just can't see it. I don't get it... So, I walk away for 15 minutes and take a break.

Return. Think. Think. Look at the access logs - and its not even being touched?
Decide I'd better double check the URL... Sure enough. I had somehow switched over accidentally from the local copy to the dev copy I hadn't been working on.

So banal when you work it out. So damned frustrating when you're right there wondering what kind of moronic cock-up you've just made.

JP,
-- Alexander Widdlemouse undid his bellybutton and his bum dropped off --


In reply to Re: (OT) What Was Your Most Bone-headed Programming Error? by JPaul
in thread (OT) What Was Your Most Bone-headed Programming Error? by Wally Hartshorn

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.