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. The Lounge
  3. Worst Exception!!

Worst Exception!!

Scheduled Pinned Locked Moved The Lounge
performancequestion
92 Posts 49 Posters 2 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.
  • P patbob

    YvesDaoust wrote:

    This one gives me nightmares because so far I have been unable to troubleshoot it. The application refuses to start, that's it. No clue on what DLL was missing/of invalid type or whatsoever

    Check into sxstrace. It generates a log of all side-by-side library loads, reporting what library versions were checked and which were loaded (or not found). Totally useless for C# though, but useful for native code.

    We can program with only 1's, but if all you've got are zeros, you've got nothing.

    A Offline
    A Offline
    AlphaDeltaTheta
    wrote on last edited by
    #78

    patbob wrote:

    Check into sxstrace. It generates a log of all side-by-side library loads, reporting what library versions were checked and which were loaded (or not found). Totally useless for C# though, but useful for native code.

    Hey, It will be very helpful to me if you please instruct me how to use that tool ??

    P 1 Reply Last reply
    0
    • G gjpt

      Keyboard error Press F1

      A Offline
      A Offline
      AlphaDeltaTheta
      wrote on last edited by
      #79

      How in the world I'll press F1 after keyboard error??

      1 Reply Last reply
      0
      • K KLSmith

        Seems to me that worst is being interpreted as either: nonsensical, useless (programmer too lazy to write a meaningful message), or a dreaded message, where something bad really did happen. Here is a nonsensical one: One recent message in my Windows-7 system event log was The service failed to start. Reason: The service finished successfully.

        A Offline
        A Offline
        AlphaDeltaTheta
        wrote on last edited by
        #80

        KLSmith wrote:

        The service failed to start. Reason: The service finished successfully.

        This is a good one... Also in my event log!

        1 Reply Last reply
        0
        • P Peter Webb

          Up until yesterday "Out of Memory" was my worst exception. By coincidence, today I found out was not actually an exception, but an error condition in Java, which explains why I wasn't catching it. So now its been promoted to worst throwable. And I hate pretty much everything you can throw.

          A Offline
          A Offline
          AlphaDeltaTheta
          wrote on last edited by
          #81

          I have a top-level exception (well, throwable) catcher that catches all these and creates another, Unexpected Error :laugh:

          P 1 Reply Last reply
          0
          • T Tomz_KV

            Jacquers wrote:

            object reference not set to an instance of an object

            This exception message is not useful at all. It would be nice if it gives the object name.

            TOMZ_KV

            K Offline
            K Offline
            KP Lee
            wrote on last edited by
            #82

            Tomz_KV wrote:

            This exception message is not useful at all. It would be nice if it gives the object name.

            It would be nice if the computer served up tea and crumpets while it explained the vagaries of the code that put it in this situation, but the fact of the matter is that this is a normal unhandled exception message. It is your responsibility as a developer to throw explanatory errors to the system before general purpose messages crumple it up into a general purpose error message. It should at least give you the stack trace, which tells you where the error occurred and if you read that line, it tells you the object it thought it was when the error occurred and you might even find out what the object really was when it was created if you follow the trace far enough. All general purpose error messages are an indication that the developer lacked the caring needed to create meaningful error messages in the special situation it was brought to, completely by (the lack of caring by) the developer's hand.

            T K 2 Replies Last reply
            0
            • A AlphaDeltaTheta

              I have a top-level exception (well, throwable) catcher that catches all these and creates another, Unexpected Error :laugh:

              P Offline
              P Offline
              Peter Webb
              wrote on last edited by
              #83

              The temptation is to wrap my entire runnable in something like: Try {// running my program} Catch (Throwable anything) { // act like nothing bad happened and restart somewhere nice } But my head tells me that handling every possible throwable in my code is probably not a great idea.

              1 Reply Last reply
              0
              • A AlphaDeltaTheta

                What's in your mind is the worst exception in programming?? My favourite is Out of Memory!

                D Offline
                D Offline
                dpminusa
                wrote on last edited by
                #84

                What about the ones with no description and just an error code. You can get some general information from MSDN that leads to a category but ...

                "Courtesy is the product of a mature, disciplined mind ... ridicule is lack of the same - DPM"

                1 Reply Last reply
                0
                • P Peter Webb

                  Up until yesterday "Out of Memory" was my worst exception. By coincidence, today I found out was not actually an exception, but an error condition in Java, which explains why I wasn't catching it. So now its been promoted to worst throwable. And I hate pretty much everything you can throw.

                  B Offline
                  B Offline
                  BobJanova
                  wrote on last edited by
                  #85

                  There's actually a really good reason for that, too. If it were an Exception, you'd catch it and try to run some more code, which would almost certainly not have the memory to run, throwing it again. Unexpected exceptions in catch/finally blocks can really screw your code up, so OOME is not supposed to be caught except in the explicit case that you really want to handle it. In Java there's very little you can do about it because you don't directly control your memory.

                  1 Reply Last reply
                  0
                  • R Reelix

                    Uncaught Error - 'undefined' The error message that gets thrown when an HTML5 WebSocket crashes due to an unknown cause...

                    -= Reelix =-

                    B Offline
                    B Offline
                    BobJanova
                    wrote on last edited by
                    #86

                    Socket error handling is a nightmare even in a real language/environment ... SocketDisposedException is the .Net equivalent of this, when a socket is closed but it hasn't got around to telling you until you try to write to it.

                    1 Reply Last reply
                    0
                    • K KP Lee

                      Tomz_KV wrote:

                      This exception message is not useful at all. It would be nice if it gives the object name.

                      It would be nice if the computer served up tea and crumpets while it explained the vagaries of the code that put it in this situation, but the fact of the matter is that this is a normal unhandled exception message. It is your responsibility as a developer to throw explanatory errors to the system before general purpose messages crumple it up into a general purpose error message. It should at least give you the stack trace, which tells you where the error occurred and if you read that line, it tells you the object it thought it was when the error occurred and you might even find out what the object really was when it was created if you follow the trace far enough. All general purpose error messages are an indication that the developer lacked the caring needed to create meaningful error messages in the special situation it was brought to, completely by (the lack of caring by) the developer's hand.

                      T Offline
                      T Offline
                      Tomz_KV
                      wrote on last edited by
                      #87

                      When try..catch is used, no details will be given.

                      TOMZ_KV

                      1 Reply Last reply
                      0
                      • A AlphaDeltaTheta

                        What's in your mind is the worst exception in programming?? My favourite is Out of Memory!

                        M Offline
                        M Offline
                        Member 4333322
                        wrote on last edited by
                        #88

                        For me, the worst is the Prism Framework's composition exception. There is often not enough detail to be able to tell exactly what the issue is - so you end up having to retrace through the composition of the object and its imports only to think its OK and the framework is screwing with you. Then after staring blankly at the code for an hour you finally see a missing export or an unhandled exception in a constructor somewhere and you curse Prism for not telling you that in the first place! Then you feel like an idiot for missing it for the last hour.

                        1 Reply Last reply
                        0
                        • A AlphaDeltaTheta

                          patbob wrote:

                          Check into sxstrace. It generates a log of all side-by-side library loads, reporting what library versions were checked and which were loaded (or not found). Totally useless for C# though, but useful for native code.

                          Hey, It will be very helpful to me if you please instruct me how to use that tool ??

                          P Offline
                          P Offline
                          patbob
                          wrote on last edited by
                          #89

                          I don't have time to do a full how-to, but briefly, you launch it from an admin window with the options to start logging. Launch your app and bring it to the error. Then run sxstrace again to stop logging. Then run sxstrace a final time to translate the binary log to a txt file. You'll have to google for details. In theory, every SxS access/DLL-search gets logged, which versions of which libraries it was looking for, which it found, their suitability, etc. In practice, it seems not everything. Hope that helps.

                          We can program with only 1's, but if all you've got are zeros, you've got nothing.

                          A 1 Reply Last reply
                          0
                          • P patbob

                            I don't have time to do a full how-to, but briefly, you launch it from an admin window with the options to start logging. Launch your app and bring it to the error. Then run sxstrace again to stop logging. Then run sxstrace a final time to translate the binary log to a txt file. You'll have to google for details. In theory, every SxS access/DLL-search gets logged, which versions of which libraries it was looking for, which it found, their suitability, etc. In practice, it seems not everything. Hope that helps.

                            We can program with only 1's, but if all you've got are zeros, you've got nothing.

                            A Offline
                            A Offline
                            AlphaDeltaTheta
                            wrote on last edited by
                            #90

                            Thanks, this is enough to get started! If I require more... I'll google it!

                            1 Reply Last reply
                            0
                            • J jibalt

                              Do you work in the Department of Redundancy department? ABEND means "Abnormal End" ... there was no "Abnormal ABEND".

                              pkfoxP Offline
                              pkfoxP Offline
                              pkfox
                              wrote on last edited by
                              #91

                              Hi there, I know what abend means I'm merely stating the error message I received on many occasions.

                              When the going gets weird the weird turn pro - Hunter S Thompson RIP

                              1 Reply Last reply
                              0
                              • K KP Lee

                                Tomz_KV wrote:

                                This exception message is not useful at all. It would be nice if it gives the object name.

                                It would be nice if the computer served up tea and crumpets while it explained the vagaries of the code that put it in this situation, but the fact of the matter is that this is a normal unhandled exception message. It is your responsibility as a developer to throw explanatory errors to the system before general purpose messages crumple it up into a general purpose error message. It should at least give you the stack trace, which tells you where the error occurred and if you read that line, it tells you the object it thought it was when the error occurred and you might even find out what the object really was when it was created if you follow the trace far enough. All general purpose error messages are an indication that the developer lacked the caring needed to create meaningful error messages in the special situation it was brought to, completely by (the lack of caring by) the developer's hand.

                                K Offline
                                K Offline
                                kerem ispirli
                                wrote on last edited by
                                #92

                                tea, yes!

                                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