How to Debug Custom Module Errors More Efficiently in Tryton?

Hello

I’ve been working on a custom module in Tryton and sometimes run into errors that are not very descriptive.:innocent: For example, I’ll get a traceback pointing deep into the framework, but it’s not immediately clear which part of my module is causing the issue. :upside_down_face:

This makes debugging a slow process, especially when dealing with complex models or workflows.

Has anyone found effective ways to speed up debugging in Tryton?:thinking: Do you rely mainly on logging, test-driven development, or specific tools to trace errors back to the custom code? :thinking:

I’d be interested in hearing practical strategies that make the debugging process smoother without adding too much overhead to development.:slightly_smiling_face:

I have read through the Tryton Developer Documentation, but it doesn’t go very deep into debugging workflows. Real-world tips from developers who regularly extend Tryton would be a big help. :thinking: While exploring new tools and learning resources; I also looked into what is ChatGPT and how it can support developers during troubleshooting.:thinking:

Thank you !! :slightly_smiling_face:

Personally I mainly debug with print statement (and sometimes raising Exception when debugging scenario because standard output are hidden).
And in most of the case, the traceback only is often enough for me to fix the code.

And when dealing with external services, I rely on logging to debug code in production.

My strategy is to use simple design, test each component/unit individually as soon as possible.