-
-
Notifications
You must be signed in to change notification settings - Fork 38
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
PR: Fix debug filename path for remote debugging #389
Conversation
# Tell IPython to hide this frame (>7.16) | ||
__tracebackhide__ = True | ||
ipython_shell = get_ipython() | ||
if filename is None: | ||
filename = get_current_file_name() | ||
if filename is None: | ||
return | ||
else: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not needed because remote filename and canonic filename are separated
@@ -655,7 +657,7 @@ def debugfile(filename=None, args=None, wdir=None, post_mortem=False, | |||
if shell.is_debugging(): | |||
# Recursive | |||
code = ( | |||
"runfile({}".format(repr(normalise_filename(filename))) + |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
removed normalise_filename because filename is now the remote one, unchanged
I think the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your help with this @impact27! Just two tiny suggestions for you.
@impact27, how confident do you feel about these changes for a bug fix release? The thing is I wouldn't like to break our debugger just to fix a bug for remote environments. That's important, of course, but maintaining our debugger's reliability is more important at this point in the Spyder 5 development cycle. |
Co-authored-by: Carlos Cordoba <ccordoba12@gmail.com>
I mean it touches file paths, so there might be some hard-to-understand problem. I am relatively confident but because it touches file paths I am not completely comfortable. |
I missed this comment, sorry. It's up to you if you want to remove it as part of this PR. |
I searched for if run_as_module:
pdb._runmodule(mainpyfile)
else:
pdb._runscript(mainpyfile)
if pdb._user_requested_quit:
break
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @impact27!
On linux when processing window paths:
This PR changes the filename handling to fix spyder-ide/spyder#18330