Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Other Discussions
  3. The Weird and The Wonderful
  4. Whew

Whew

Scheduled Pinned Locked Moved The Weird and The Wonderful
debugging
9 Posts 7 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    Richard A Dalton
    wrote on last edited by
    #1

    When a debug message conveys Relief, you're probably on thin ice.

    dbg('Function returning true...');
    dbg('Whew.... Its your baby now - messaging');

    -Rd

    C B 2 Replies Last reply
    0
    • R Richard A Dalton

      When a debug message conveys Relief, you're probably on thin ice.

      dbg('Function returning true...');
      dbg('Whew.... Its your baby now - messaging');

      -Rd

      C Offline
      C Offline
      Chris Meech
      wrote on last edited by
      #2

      Similar to this one

      TRACE("Shouldn't be able to reach this code! But good luck, though.");

      :cool:

      Chris Meech I am Canadian. [heard in a local bar] In theory there is no difference between theory and practice. In practice there is. [Yogi Berra]

      F J R 3 Replies Last reply
      0
      • C Chris Meech

        Similar to this one

        TRACE("Shouldn't be able to reach this code! But good luck, though.");

        :cool:

        Chris Meech I am Canadian. [heard in a local bar] In theory there is no difference between theory and practice. In practice there is. [Yogi Berra]

        F Offline
        F Offline
        fjdiewornncalwe
        wrote on last edited by
        #3

        MsgBox( "Oops." ) I found this one in something I wrote in my first job out of school.

        1 Reply Last reply
        0
        • R Richard A Dalton

          When a debug message conveys Relief, you're probably on thin ice.

          dbg('Function returning true...');
          dbg('Whew.... Its your baby now - messaging');

          -Rd

          B Offline
          B Offline
          BillW33
          wrote on last edited by
          #4

          Yes, that kind of thing is always a bad sign. Not that I ever did such a thing when I started out! ;) I do make sure to avoid doing such things now.

          Just because the code works, it doesn't mean that it is good code.

          R 1 Reply Last reply
          0
          • B BillW33

            Yes, that kind of thing is always a bad sign. Not that I ever did such a thing when I started out! ;) I do make sure to avoid doing such things now.

            Just because the code works, it doesn't mean that it is good code.

            R Offline
            R Offline
            Richard A Dalton
            wrote on last edited by
            #5

            In my first job I was working alongside some guys from an external vendor. Integrating their system into ours and trying to get the whole thing validated by System Test. One day an error popped up that originated in the Vendors Code: "The System Has Gone Pear Shaped" System test weren't impressed. The guy from the external vendor was summoned, and asked what a more accurate error message would be. I can't remember what it was, but he gave a very detailed, accurate and completely unintelligible response. To which the head of system test replied... "And what does that mean? In English?" To which he replied... "The system has gone pear shaped." -Rd

            G 1 Reply Last reply
            0
            • C Chris Meech

              Similar to this one

              TRACE("Shouldn't be able to reach this code! But good luck, though.");

              :cool:

              Chris Meech I am Canadian. [heard in a local bar] In theory there is no difference between theory and practice. In practice there is. [Yogi Berra]

              J Offline
              J Offline
              JHizzle
              wrote on last edited by
              #6

              I used to do that alot in crazy if else statements that shouldn't have been needed:

              Response.Write("Something has gone seriously wrong here, please reboot universe")

              1 Reply Last reply
              0
              • C Chris Meech

                Similar to this one

                TRACE("Shouldn't be able to reach this code! But good luck, though.");

                :cool:

                Chris Meech I am Canadian. [heard in a local bar] In theory there is no difference between theory and practice. In practice there is. [Yogi Berra]

                R Offline
                R Offline
                RugbyLeague
                wrote on last edited by
                #7

                I use a throw with a similar message - mostly on the default of a switch

                1 Reply Last reply
                0
                • R Richard A Dalton

                  In my first job I was working alongside some guys from an external vendor. Integrating their system into ours and trying to get the whole thing validated by System Test. One day an error popped up that originated in the Vendors Code: "The System Has Gone Pear Shaped" System test weren't impressed. The guy from the external vendor was summoned, and asked what a more accurate error message would be. I can't remember what it was, but he gave a very detailed, accurate and completely unintelligible response. To which the head of system test replied... "And what does that mean? In English?" To which he replied... "The system has gone pear shaped." -Rd

                  G Offline
                  G Offline
                  Gary Wheeler
                  wrote on last edited by
                  #8

                  At which point, you take the vendor outside the building, put two bullets in his head, and leave his body mounted on a pike outside the castle walls as a warning to others.

                  Software Zen: delete this;

                  R 1 Reply Last reply
                  0
                  • G Gary Wheeler

                    At which point, you take the vendor outside the building, put two bullets in his head, and leave his body mounted on a pike outside the castle walls as a warning to others.

                    Software Zen: delete this;

                    R Offline
                    R Offline
                    Richard A Dalton
                    wrote on last edited by
                    #9

                    Gary Wheeler wrote:

                    At which point, you take the vendor outside the building, put two bullets in his head, and leave his body mounted on a pike outside the castle walls as a warning to others.

                    Actually that particular project I had no problem with the Vendor. I was young Naive, what did I know? I'll say this. Compared to experiences I've had and am still having with vendors, that project was a cakewalk. When you've debugged a vendor's Javascript files you start to understand that a dodgy error message is no biggie. There's nothing quite like javascript files which seem to have had all whitespace sucked out of them, presumably to stop people stealing some of the most horrible code ever written (why would anyone want to). -Rd

                    1 Reply Last reply
                    0
                    Reply
                    • Reply as topic
                    Log in to reply
                    • Oldest to Newest
                    • Newest to Oldest
                    • Most Votes


                    • Login

                    • Don't have an account? Register

                    • Login or register to search.
                    • First post
                      Last post
                    0
                    • Categories
                    • Recent
                    • Tags
                    • Popular
                    • World
                    • Users
                    • Groups