10
$\begingroup$

In ROS, I cannot get [ERROR] logs to print in red when I use python. How can I make them appear in red instead of black?


For example, the following Python:

rospy.logerr("No analog input received.")

produces this output in black:

[ERROR] [WallTime: 135601422.876123] No analog input received.


whereas the following C++:

ROS_ERROR("No analog input received.");

produces the following output in red.

[ERROR] [135601551.192412]: No analog input received.

$\endgroup$

2 Answers 2

4
$\begingroup$

This has been merged as of six weeks ago:

https://github.com/ros/ros_comm/commit/8a1f92fc0c888099fe47005f609883601b7d8d72#diff-1

$\endgroup$
7
$\begingroup$

Please see this bug ticket: https://code.ros.org/trac/ros/ticket/3691

I filed this bug report (with patch to fix) 13 months ago and am pretty disappointed in the ROS team that they have not put this in trunk.

$\endgroup$
1
  • 1
    $\begingroup$ It seems that a lot of ROS development is moving towards Github's issues and pull requests, because the Trac site has become abysmal. Not to create more work for you, but if you file an issue and pull request on github.com/ros/ros_comm, it will be more likely to be handled. $\endgroup$
    – mjcarroll
    Oct 31, 2012 at 12:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.