Hi, I need to print to console during testing my custom module.
I already create logging configuration, which logging level = DEBUG and execute it when starting the app like below:
If you’re not seeing output from print() or logger.info() in your console, it’s likely due to the logging level configuration in Tryton. By default, Tryton only displays messages of level ERROR in the console. To see INFO or DEBUG messages, you need to adjust the verbosity level when starting the server.​
Here’s how you can do it:
For INFO level messages:
trytond -c trytond.conf -v
For DEBUG level messages:
trytond -c trytond.conf -v --dev
The -v or --verbose flag increases the verbosity level, allowing INFO messages to be displayed. Adding the --dev flag further increases verbosity to include DEBUG messages.