warn if ROS_IP contains whitespace#1379
Conversation
This breaks ROS connections and it does not show with `echo $ROS_IP`. Also "local IP address" often refers to 192.168. et al, so I resolved this ambiguity too.
|
Is this added check catching a case not already caught by the |
|
Is this added check catching case not caught by the `in addrs` check which immediately follows?
No, not if you put the question like this.
But it gives the user an explicit hint for this special case which can be very frustrating to debug.
After all this is what `roswtf` is for.
Personally, I debugged this case twice in the last three years and it cost me at least an hour each time to figure it out...
|
|
Can you please give an example of a value which you ran into? Are we talking about leading / trailing spaces or spaces in the middle of the IP address? |
|
LGTM then. |
This was my problem this time: There is probably a better way to extract the intended IP address, but a bug in the sed script accidentally added 4 spaces before the IP. In theory this is shown in the warning, but in practice it could also be random padding in the output. Now this will say Additionally I disambiguate the previous warning when the IP does not match a local adapter. |
|
Thank you for the patch and the explanation. |
This breaks ROS connections and it does not show with
echo $ROS_IP.Also "local IP address" often refers to 192.168. et al,
so I resolved this ambiguity too.