-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remote Attach Times out #90
Comments
Just want to say that the same exact issue, for the same exact reason, happen for Maya. From Visual Studio Code the debugger attaches itself without problem, of course, we have first to use "the hacky work around of temporarily overwriting sys.executable before launching debugpy" that is described in those debugpy issues that @munkybuttballs have already posted. |
I'm pretty swamped but I'll try to take a look this weekend. I imagine there is some additional stuff they add to the configuration before they send it to the debug adapter or they are using some custom dap events to get this working. Otherwise I would expect it to work |
So the problem seems to have a bit more to it. |
@munkybutt How to run the debugpy.listen from Max? I do this from Maya: I find first the right path to the python interpreter that Maya uses then use the debugpy.configuration to tell debugpy to use that interpreter and then I start to listen. With this, I can connect from Visual Studio Code, but not from Debugger in Sublime. import sys, os
import debugpy
execu = os.path.join(os.path.dirname(sys.executable), 'mayapy.exe')
debugpy.configure(python=execu)
print debugpy.listen(address=('localhost', 5678)) @daveleroy I didn't look inside your code, so I'm only guessing here, but could it be you are not allowing |
Are you using the st3 version of Debugger? If so it probably doesn't support attach because as far as I remember debugpy attach is supposed to connect to the adapter through a socket which is only supported in st4. Note the special handling of attach here https://github.com/daveleroy/sublime_debugger/blob/master/modules/debugger/adapters/python.py that is not supported in the st3 version If you are using st4 I do not know what the issue is but if they use any custom debug adapter extensions they are not supported. If you grab a log from the |
Hey @daniele-niero - yeah I am setting the correct interpreter via the python arg in the configure method, this is what allows it to work from VSCode. The issue must be related to me using ST3 as @daveleroy suggests - I guess this will be unusable until ST4 is officially released. Thanks for the info @daveleroy |
Hey!
I use the debugger to remote debug 3DsMax, which runs an embedded python interpreter.
Since updating to debugpy I have been unable to run the debugger due to debugpy wanting to spawn a sub-process which doesn't really work in an embedded environment.
The main issue was described here:
microsoft/debugpy#387
microsoft/debugpy#262
And I have used the hacky work around of temporarily overwriting sys.executable before launching debugpy.
I now have an issue whereby the connection just times out and I am unable to figure out why.
This is my config in Sublime:
and this is the code being run from within 3DsMax:
The 3DsMax Python version is 2.7 and the python version I am pointing to is also 2.7.
Both have debugpy installed.
The text was updated successfully, but these errors were encountered: