Check this video for debugging ODOO using pdb on localhost
- At line intended to debug add import pdb pdb.set_trace()
- From terminal start odoo python /usr/bin/odoo -c /etc/odoo.conf
- Take appropriate action on ODOO.
- On reaching the break point, browser will stop and terminal will show line number with pdb prompt
- Use pdb commands to step, continue etc. Check pdb commands
Of course, other more interactive debuggers like pycharm can also be tried.