can't debug bzr on windows with pdb
Bug #587868 reported by
Jason Spashett
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Bazaar |
Fix Released
|
Medium
|
Unassigned |
Bug Description
Bzr 'does' something with arguments on windows, which means it cannot be debugged with pdb as far as I can tell. The same command works on ubuntu.
C:\bzr\
> c:\bzr\
-> """Bazaar -- a free distributed version-control tool"""
(Pdb) c
bzr: ERROR: unknown command "bzr.py"
bzr: warning: some compiled extensions could not be loaded; see <https:/
C:\bzr\
Related branches
lp:~jspashett/bzr/587868_args_handling_cant_debug
- Martin Packman (community): Approve
- Alexander Belchenko: Pending requested
- John A Meinel: Pending requested
-
Diff: 154 lines (+45/-24)5 files modifiedNEWS (+5/-0)
bzr (+0/-1)
bzrlib/commands.py (+2/-0)
bzrlib/tests/test_win32utils.py (+19/-5)
bzrlib/win32utils.py (+19/-18)
To post a comment you must log in.
Looking into it I find in get_unicode_argv
# Skip the first argument, since we only care about parameters line_to_ argv(command_ line)[1: ]
argv = _command_
but the command line retunred from GetCommandLineW on windows, is:
unicode: C:\\Python26\ \python. exe -u C:\\eclipse\ \plugins\ \org.python. pydev.debug_ 1.5.7.201005062 1\\pysrc\ \pydevd. py --vm_type python --client localhost --port 2134 --file C:\\bzr\ \bazaar\ \578005_ no_revision_ none\\bzr. py
under the debugger.
I'll check later how it works on other platforms. Perhaps pdb "fixes up the argv", but GetCommandLineW sidesteps the fix.
It makes no difference if I use eclipse or pdb straight.