Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Exception handling
QtWS25 Last Chance

Exception handling

Scheduled Pinned Locked Moved General and Desktop
3 Posts 2 Posters 2.0k Views
  • 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.
  • F Offline
    F Offline
    farcat
    wrote on last edited by
    #1

    I have been working with pyside for a while now and am very happy with the result ... however there is one thing that takes a lot of time: finding bugs when Qt (C++) throws an exception. This basically leads to a program crash with no indication of what went wrong. Sometimes i just go back to an earlier version and restart.

    Does anyone know of an initiative to translate C++ exceptions in Qt to Python exceptions? This would be a huge help and remove one of the weakest points in Pyside (in my humble opinion).

    1 Reply Last reply
    0
    • D Offline
      D Offline
      DerManu
      wrote on last edited by
      #2

      Qt doesn't throw exceptions. Qt usually asserts when something can go really wrong. Can't catch termination caused by failing asserts, as far as I know. The program is probably in an invalid state, so it's a good thing it's being brought down.

      What's the specific code situation where this happens?

      1 Reply Last reply
      0
      • F Offline
        F Offline
        farcat
        wrote on last edited by
        #3

        No problem with it being brought down, just want to be able to hunt down the errors somewhat quickly, e.g. via an exception call-stack and message, not by stepping through/into code untill something goes wrong.

        Currently i have an occasional crash on start-up; when i find the code where it happens, i am as far as i would have been with a call_stack and could probably solve the error quickly enough.

        1 Reply Last reply
        0

        • Login

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • Users
        • Groups
        • Search
        • Get Qt Extensions
        • Unsolved