3

I use Plugin 'klen/python-mode' in my vim, and work fine

but when I want add a break point and run code with python mode, occurs unexpected error, the vim says [Pymode] code running ... and vim is stops, then I must kill the process of vim

My config:

let g:pymode_breakpoint = 1
let g:pymode_rope = 1
let g:pymode_doc_bind = "<C-S-d>"
let ropevim_enable_shortcuts = 1
let g:pymode_breakpoint_bind = '<leader>k'

I use python 2.7.9

I want use breakpoints and run code with vim but this is damaged

Thank you very much! :D

Halis
  • 367
  • 1
  • 9
Milor123
  • 537
  • 4
  • 20
  • did you figure this out? I am also not able to run it – alpha_989 Nov 18 '17 at 22:18
  • I think that it is a bug or is not possible (You should report in the git repo ... I do not it xD), for it now I run the script out of vim... with the console, `python script.py` , please report it in https://github.com/python-mode/python-mode/issues and then you could tell me the solution hahaha.. greetings!! – Milor123 Nov 18 '17 at 22:32
  • it works using !pythone %, but not with r. If you use !python3 %, maybe map it to a key, the debugger works as expected. Yeah, I do agree this is a bug. Will report it. – alpha_989 Nov 18 '17 at 23:36

1 Answers1

0

Use :!python3 % instead of using the default keybinding <leader>r.

I am now able to put in breakpoints, and pdb works as expected. Also you can break out of an infinite loop or kill the process using Cntrl+C.

alpha_989
  • 4,882
  • 2
  • 37
  • 48