Re: CPU running at 100%, GUI locks up
Marc Tompkins <[email protected]> Mon, 8 Mar 2021 15:07:04 -0800
| Newsgroups | gmane.comp.python.wxpython |
|---|---|
| Message-ID | <CAKK8jXZNjKNZ+ArLKkOuMcanG_jwbf-N6ZXey8rnvWJhQ7+uWw@mail.gmail.com> |
On Mon, Mar 8, 2021 at 2:14 PM Tim Roberts <[email protected]> wrote: > Matthias Brennwald wrote: > > > Performance really cannot be the issue, as I have another Python program > which does pretty much the same "work", using command-line user interface > instead of the wxPython GUI. This CLI program consumes about 3-5% of CPU on > the E3930. > > I have never really worked with debuggers. Any hints or suggestions on > how/where to start? > > Well, you can do "gdb python xxx.py", then type "run" to start it. When > it hangs, you press Ctrl-C to break into the debugger. "bt" gets a stack > trace of the current thread. You may need a stack trace of all threads, > which is likely to be verbose: "thread apply all bt". Email me a copy if > you want some interpretation. > > -- > > Before jumping into gdb (which, until you learn it, will confuse the heck out of you), I recommend the "poor man's debugger" - i.e. insert lots of print() or console.log() statements throughout your code. It's free, it's easy, you can make your statements as terse or as informative as you want, and it's the fastest way I know to narrow down your search for the culprit. -- You received this message because you are subscribed to the Google Groups "wxPython-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/wxpython-users/CAKK8jXZNjKNZ%2BArLKkOuMcanG_jwbf-N6ZXey8rnvWJhQ7%2BuWw%40mail.gmail.com.