Closed tettoffensive closed 2 years ago
Thank you for the pull request. I tested and it seems to work fine* except for the freezing while waiting for attach.
* There are some minor unrelated issues I found testing with 3.0 that I'll need to fix before creating a release.
Yea. Maybe there's another way to get it to wait with a timeout. I just noticed in debugpy's example they use that method to wait indefinitely but it blocks use of blender. Not ideal.
There's no need to wait in our situation, unless you have some specific use case for it, otherwise that line can just be removed. It's not like we can't first enable this addon then enable the addon we'll be debugging. I believe wait_for_client
exists for when running things from a script where you don't want immediate execution but have no control over when the execution happens.
Also the addon already uses a timeout to give some feedback of when a client attaches because neither ptvsd or debugpy offer some way to get notified when a client has attached. ptvsd/debugpy keep working regardless of if the timer checks anything is connected, if that makes sense. Once the server is running it can't be stopped, clients can connect at any time.
Makes sense. I'll remove that line
Ok, I've manually merged it.
ptvsd has been deprecated in favor of debugpy