OpenERP 6, Aptana - debugger doesn't stop at breakpoint in QR Bar Code Label code
Question: I am trying to debug code for QR Bar Code Labels in OpenERP 6 using Aptana
Studio 3. I put a breakpoint in "pyqr" module, file "myfile.py", function
"generate_image()", as per attached picture:

![enter image description here](http://i.stack.imgur.com/SA7wM.jpg)

Now, when I run OpenERP server from Aptana IDE ("openerp-server.py" -> Debug
As -> Python Run) and navigate to Manufacturing Orders where I can click on
one of the right hand buttons "Large Label" or "Medium Label" or "Small
Label", the debugger doesn't stop at the breakpoint and yet the label is
printed in opened PDF file.

I have performed the following tests to check if the code in "myfile.py"
executes. I have put "print" statement in "generate_image()" function, and it
did not print anything in console. I put "import pdb" and "pdb.set_trace()"
and the execution did not stop there. I added a message box in
"generate_image()" function and message box did not display, yet the QR bar
code label was created. It looks like that "myfile.py" code is not executed at
all adding to mystery which code is executed that creates QR Bar Code labels.

How I can make debugger stop at this breakpoint? What am I missing?


Answer: To be able to debug in your IDE, I assume that you are running the Odoo server
from source and start it from inside the IDE.

I'm not sure what is your actual setup, but maybe these pointers can help.

  * Try putting the breakpoint on a line of the method, instead of on it's definition.
  * Are you sure that the code is being executed? Try placing a `print` statement in it to confirm. Or try adding a `import pdb; pdb.set_trace()` line as a way to force a breakpoint.

