Author Topic: Multiple stacks when trying to debug python  (Read 207 times)

rowbearto

  • Senior Community Member
  • Posts: 1868
  • Hero Points: 121
Multiple stacks when trying to debug python
« on: February 10, 2021, 11:10:32 pm »
When I tried to debug my python program, which runs under 'execute', I got multiple stacks.

You can find it on support at stack_pydebug.log

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1470
  • Hero Points: 131
Re: Multiple stacks when trying to debug python
« Reply #1 on: February 11, 2021, 02:46:41 pm »
The top part of the first exception is cut off, but I suspect it's a problem we've been working on with the debug view getting garbled after back to back debug sessions. Once that happens, your next debug session will usually fail to start.

You may need to remove your vrestore.slk to work around this.  Before you do that, could you upload it to the same directory as the stack? 

rowbearto

  • Senior Community Member
  • Posts: 1868
  • Hero Points: 121
Re: Multiple stacks when trying to debug python
« Reply #2 on: February 11, 2021, 02:59:32 pm »
Look for pydebugstack.tgz on support.

I put the vrestore.slk there as well as an updated stack log that shouldn't have the beginning cut off.

I will try later debugging with a deleted vrestore.slk.

rowbearto

  • Senior Community Member
  • Posts: 1868
  • Hero Points: 121
Re: Multiple stacks when trying to debug python
« Reply #3 on: February 11, 2021, 03:01:42 pm »
If it helps I do notice that when it switches to debug mode that all my tool windows are gone and I have just 1 giant editor window.

I will try later to debug again after removing vrestore.slk.

rowbearto

  • Senior Community Member
  • Posts: 1868
  • Hero Points: 121
Re: Multiple stacks when trying to debug python
« Reply #4 on: February 11, 2021, 03:12:38 pm »
I deleted (actually renamed) the vrestore.slk. When I try to debug again I get more stacks.

I have uploaded a new tarball to support:

pydebugstack2.tgz

This new tarball has the new stack.log after removing vrestore.slk as well as the new vrestore.slk file after closing SE.

rowbearto

  • Senior Community Member
  • Posts: 1868
  • Hero Points: 121
Re: Multiple stacks when trying to debug python
« Reply #5 on: February 11, 2021, 03:13:46 pm »
I'm not using any hotfix on 25.0.1. Should I be?

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1470
  • Hero Points: 131
Re: Multiple stacks when trying to debug python
« Reply #6 on: February 11, 2021, 03:21:32 pm »
Oh.  Yes there is a fix in hotfix 1 for stacks starting up the debugger in mainwindow.e


patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1470
  • Hero Points: 131
Re: Multiple stacks when trying to debug python
« Reply #7 on: February 11, 2021, 03:26:30 pm »
Actually, hold up, that's not in hotfix 1, it's staged for hotfix 2.  If you apply hotfix 1, I believe I can send you a file to load with the fix in a few minutes.

rowbearto

  • Senior Community Member
  • Posts: 1868
  • Hero Points: 121
Re: Multiple stacks when trying to debug python
« Reply #8 on: February 11, 2021, 03:33:28 pm »
OK, while you wrote that last post I tried again with hotfix1 and still got stack.

I uploaded stack.log, vrestore.slk (after deleting before the debug session), user.cfg.xml and about .txt into a tarball on support:

pydebugstack3.tgz

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1470
  • Hero Points: 131
Re: Multiple stacks when trying to debug python
« Reply #9 on: February 11, 2021, 03:46:45 pm »
Here's the file that is fixed for the next hotfix.  "load" that from the SlickEdit command line, restart the editor, and then start the debugger.

The changes match up with your stacks, so I think this is all it is. 

rowbearto

  • Senior Community Member
  • Posts: 1868
  • Hero Points: 121
Re: Multiple stacks when trying to debug python
« Reply #10 on: February 11, 2021, 03:53:36 pm »
OK, no stacks now after your fix. But now I have just 1 big editor window. When I debug I usually also have many tool windows like the call stack, breakpoints, Open, Files, Search, etc. If I add them manually will they be there again next time I debug?

If I restore my old vrestore.slk is there a chance that it wouldn't crash and I get all those tool windows back?

rowbearto

  • Senior Community Member
  • Posts: 1868
  • Hero Points: 121
Re: Multiple stacks when trying to debug python
« Reply #11 on: February 11, 2021, 04:00:13 pm »
Looks like if I add tool windows in my debug session that they will return in my next debug session.

rowbearto

  • Senior Community Member
  • Posts: 1868
  • Hero Points: 121
Re: Multiple stacks when trying to debug python
« Reply #12 on: February 11, 2021, 04:02:35 pm »
I added the "Output" tool window to my debug session but then the debug session shut down. Now everytime I try to start a debug session it shuts down. I see a "Warning" tab in the bottom right: 'Debugger stopped, socket shut down".

rowbearto

  • Senior Community Member
  • Posts: 1868
  • Hero Points: 121
Re: Multiple stacks when trying to debug python
« Reply #13 on: February 11, 2021, 04:04:43 pm »
Nevermind, it is because I removed my breakpoint that it is shutting down. It actually runs to completion.

patrick

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1470
  • Hero Points: 131
Re: Multiple stacks when trying to debug python
« Reply #14 on: February 11, 2021, 04:13:42 pm »
Ok.  Your original vrestore.slk may not be better, if it was overwritten after the stack that interrupted the initial restore.