Debugging in OpenERP 7.0

后端 未结 8 1011
小鲜肉
小鲜肉 2021-01-18 06:05

How to do debug in OpenERP v7?

In previous versions of OpenERP, it was easy to debug. But in the latest version it\'s tough to debug.

相关标签:
8条回答
  • 2021-01-18 06:26

    Their is more complexity and less control by adding more fancy tools try and go low level and use python pdb and if you are debug geek then use winpdb with pdb which gives extreme contorl over your code navigation.

    And for simple value abd flow use print or pprint module from python.

    Bests.

    0 讨论(0)
  • 2021-01-18 06:31

    Navigate through
    administrator(top Right)>>about OpenERP
    Dialog Open Click on Activate Developer mode

    0 讨论(0)
  • 2021-01-18 06:37

    Activate the Debug mode and use some print statements to debug the variable values

    0 讨论(0)
  • 2021-01-18 06:41

    To debug openERP 7 from eclipse just Stop openERP server and rename the main file named openerp-server.py.From "Run/Debug Configurations" make a new configuration selecting Project and main module such as ${workspace_loc:openerp7/src/openerp-server.py} then press Apply.After that /openerp7/src/openerp-server.py 'Debug As --> Python Run' using new configuration.Server is running where pydev debugger is also started.Now run 'gtk' or 'web-client'.Then select the python file of that module where want to debug and give breakpoints.That's all.

    0 讨论(0)
  • 2021-01-18 06:46

    To debug your OpenERP+python code in eclipse, start eclipse (helios/indigo only) in debug perspective and follow the given steps:

    1: Stop your openERP running server by pressing "ctr+c".

    2: In eclipse go to Menu "Run/Debug Configurations". In configuration window under "Python Run", create new debug configuration(Double click on 'Python Run').

    3: After creating new debug configuration follow the given steps:

    3.1: In "Main" tab under "Project", select the "server" project or folder (in which Openerp Server resides) from your workspace.

    3.2: Write location of 'openerp-server' under "Main Module".

    Ex: ${workspace_loc:server/openerp-server}.
    

    3.3: In "Arguments" tab under "Program Arguments", click on button "Variables" and new window will appear.

    3.4: Then create new "Variable" by clicking on "Edit Variables" button and new window will appear.

    3.5: Press on "New" button and give your addons path as value.

    Ex: --addons ../addons,../your_module_path
    

    3.6: Press Ok in all the opened windows and then "Apply".

    4: Now into "PyDev Package Explorer" view go to 6.1/server and right click on "openerp-server" file, Select 'Debug As --> Python Run'.

    5: Now in "Console" you can see your server has been started.

    6: Now open your .py file which you want to debug and set a break-point.

    7: Now start your module's form from 'gtk' or 'web-client' and execution will stop when execution will reach to break-point.

    8: Now enjoy by debugging your code by pressing "F5, F6, F7" and you can see value of your variables.

    You can refer following link: Debug OpenERP Code from Eclipse

    0 讨论(0)
  • 2021-01-18 06:47

    Debugging is quite simple in interface.

    For Programmers

    By Default when you login to openerp, your url will look something like this

    http://localhost:7373/?db=Test_July_25#menu_id=107&action=97
    

    Edit the url and add debug=&

    localhost:7373/?debug=&db=Test_July_25#menu_id=107&action=97

    For Functional Users

    • Navigate mouse to top right corner and select About OpenERP

    enter image description here

    • Now Activate Debug Mode

    enter image description here

    You Should be done now with interface debugging.

    For Code Debugging (along with arya's method these images may help you)

    • You can use browse button to select the project and the openerp server file

    enter image description here

    enter image description here

    Finally place breakpoints in your code where ever necessary

    0 讨论(0)
提交回复
热议问题