> The code was sparsely documented with what was happening and I'm still 
> somewhat learning python.  Communities don't function well without 
> documentation, but OSS can still survive.  If Tiny wants help with code from 
> the community it would help to document what functions are supposed to do at 
> least what the file is for.
> 


I would love to see more comments on the code. I think that 'quality certified' 
addons should all have at least docstrings for each module, each class and each 
method (PyLint [http://www.logilab.org/pylint] could be used to enforce using 
docstrings in the code).


> I could not find documentation for debugging the server to find the error in 
> the report template.  I ended up just throwing in prints.  These are just 
> developer problems.  


Try with this code:
import pdb; pdb.set_trace()

It will 'stop' the server and open a command-line debugger 
(http://docs.python.org/library/pdb.html) when the code reaches the set_trace() 
sentence. You can use "p variable-name" to examine variables, "n" to run next 
sencence, "c" to continue running, "l" to list the code... It will not replace 
an IDE debugger, but it's a fast and simple way to set a break-point. :)

------------------------
Borja López Soilán
Pexego - www.pexego.es




-------------------- m2f --------------------

--
http://www.openobject.com/forum/viewtopic.php?p=42856#42856

-------------------- m2f --------------------


_______________________________________________
Tinyerp-users mailing list
http://tiny.be/mailman2/listinfo/tinyerp-users

Reply via email to