Apollo: How to view Apollo modules errors and print lines?

Created on 15 Jun 2018  ·  6Comments  ·  Source: ApolloAuto/apollo

Hello,

I am just getting started with Apollo. And I launch the modules from dreamviewer or with the scripts.. that say module launched successfully. But I never see any error messages or print to console messages, how can I turn on debug mode so I can see standard out and error messages, so that I can do my own editing and debugging.

Thank you

Others Question

All 6 comments

The short answer is you can not see debug message in the DreamView console, without a lot of work.
To view Debug message, go to data/log folder you will see text files with debug message from different modules.
To enable debug mode, for example in planning module: add --v=4 at the end of modules/planning/conf/planning.conf

Okay thank you.

Does that work for all modules?

Will it show all kinds of print lines?

You can modify how each module is launched in modules/tools/supervisord/dev.conf (or release.conf). To change the verbosity level, just add --minloglevel option, e.g. --minloglevel=2 ( you can set it to be 1, 2, or 3).

@jilinzhou

Thank you.

Is this going to put the log messages in the ubuntu terminal? or in Dreamview console?

@snuffysasa

As an example, here is how canbus is started in dev.conf:

[program:canbus]
command=/apollo/bazel-bin/modules/canbus/canbus --flagfile=/apollo/modules/canbus/conf/canbus.conf --log_dir=/apollo/data/log
autostart=false
numprocs=1
exitcodes=0
stopsignal=SIGINT
startretries=10
autorestart=unexpected
redirect_stderr=true
stdout_logfile=/apollo/data/log/canbus.out

Just play with redirect_stderr and stdout_logfile. You can figure it out then.

Closing this issue as it appears to be resolved. @snuffysasa if you have any additional questions, feel free to reopen the issue.

Was this page helpful?
0 / 5 - 0 ratings