Stretch_web_interface error when logging in as operator

I have been using the web interface for a while now, and I have been getting a very tricky error when the operator logs in: they can select the robot from the options connected, but when they select the robot the camera image does not appear; however, the cursor icon does change shapes when you move it on the screen.

I am pasting here the output from the roslaunch terminal. It gave a warning about an error in inbound connection.

The thing with this issue is that I haven’t found a reproducible way to restart the web interface. Sometimes it works in mobile devices while it still continues to fail in linux, windows, etc. I have tried multiple browsers (chrome, mozilla, chromium). The time I was able to quickly recover I made sure I visited the website to logout before killing the bash script start_dev_env.sh

At the moment, I am interested in finding a reproducible way to recover from this error.

=== OUTPUT ===

2020-09-21 17:48:01-0700 [-] [INFO] [1600735681.933218]: Client disconnected. 0 clients total. [WARN] [1600735682.944206]: Inbound TCP/IP connection failed: connection from sender terminated before handshake header received. 0 bytes were received. Please check sender for additional details. 2020-09-21 17:48:11-0700 [-] [WARN] [1600735691.936003]: Could not process inbound connection: Internal error processing topic [/stretch_controller/follow_joint_trajectory/goal]{'message_definition': '# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======\n\nHeader header\nactionlib_msgs/GoalID goal_id\nFollowJointTrajectoryGoal goal\n\n================================================================================\nMSG: std_msgs/Header\n# Standard metadata for higher-level stamped data types.\n# This is generally used to communicate timestamped data \n# in a particular coordinate frame.\n# \n# sequence ID: consecutively increasing ID \nuint32 seq\n#Two-integer timestamp that is expressed as:\n# * stamp.sec: seconds (stamp_secs) since epoch (in Python the variable is called \'secs\')\n# * stamp.nsec: nanoseconds since stamp_secs (in Python the variable is called \'nsecs\')\n# time-handling sugar is provided by the client library\ntime stamp\n#Frame this data is associated with\nstring frame_id\n\n================================================================================\nMSG: actionlib_msgs/GoalID\n# The stamp should store the time at which this goal was requested.\n# It is used by an action server when it tries to preempt all\n# goals that were requested before a certain time\ntime stamp\n\n# The id provides a way to associate feedback and\n# result message with specific goal requests. The id\n# specified must be unique.\nstring id\n\n\n================================================================================\nMSG: control_msgs/FollowJointTrajectoryGoal\n# ====== DO NOT MODIFY! AUTOGENERATED FROM AN ACTION DEFINITION ======\n# The joint trajectory to follow\ntrajectory_msgs/JointTrajectory trajectory\n\n# Tolerances for the trajectory. If the measured joint values fall\n# outside the tolerances the trajectory goal is aborted. Any\n# tolerances that are not specified (by being omitted or set to 0) are\n# set to the defaults for the action server (often taken from the\n# parameter server).\n\n# Tolerances applied to the joints as the trajectory is executed. If\n# violated, the goal aborts with error_code set to\n# PATH_TOLERANCE_VIOLATED.\nJointTolerance[] path_tolerance\n\n# To report success, the joints must be within goal_tolerance of the\n# final trajectory value. The goal must be achieved by time the\n# trajectory ends plus goal_time_tolerance. (goal_time_tolerance\n# allows some leeway in time, so that the trajectory goal can still\n# succeed even if the joints reach the goal some time after the\n# precise end time of the trajectory).\n#\n# If the joints are not within goal_tolerance after "trajectory finish\n# time" + goal_time_tolerance, the goal aborts with error_code set to\n# GOAL_TOLERANCE_VIOLATED\nJointTolerance[] goal_tolerance\nduration goal_time_tolerance\n\n\n================================================================================\nMSG: trajectory_msgs/JointTrajectory\nHeader header\nstring[] joint_names\nJointTrajectoryPoint[] points\n================================================================================\nMSG: trajectory_msgs/JointTrajectoryPoint\n# Each trajectory point specifies either positions[, velocities[, accelerations]]\n# or positions[, effort] for the trajectory to be executed.\n# All specified values are in the same order as the joint names in JointTrajectory.msg\n\nfloat64[] positions\nfloat64[] velocities\nfloat64[] accelerations\nfloat64[] effort\nduration time_from_start\n\n================================================================================\nMSG: control_msgs/JointTolerance\n# The tolerances specify the amount the position, velocity, and\n# accelerations can vary from the setpoints. For example, in the case\n# of trajectory control, when the actual position varies beyond\n# (desired position + position tolerance), the trajectory goal may\n# abort.\n# \n# There are two special values for tolerances:\n# * 0 - The tolerance is unspecified and will remain at whatever the default is\n# * -1 - The tolerance is "erased". If there was a default, the joint will be\n# allowed to move without restriction.\n\nstring name\nfloat64 position # in radians or meters (for a revolute or prismatic joint, respectively)\nfloat64 velocity # in rad/sec or m/sec\nfloat64 acceleration # in rad/sec^2 or m/sec^2\n', 'callerid': '/stretch_driver', 'tcp_nodelay': '0', 'md5sum': 'cff5c1d533bf2f82dd0138d57f4304bb', 'topic': '/stretch_controller/follow_joint_trajectory/goal', 'type': 'control_msgs/FollowJointTrajectoryActionGoal'} 2020-09-21 17:48:12-0700 [-] [WARN] [1600735692.067486]: Could not process inbound connection: [/rosbridge_websocket] is not a publisher of [/stretch_controller/follow_joint_trajectory/cancel]. Topics are [['/client_count', 'std_msgs/Int32'], ['/rosout', 'rosgraph_msgs/Log'], ['/connected_clients', 'rosbridge_msgs/ConnectedClients']]{'message_definition': '# The stamp should store the time at which this goal was requested.\n# It is used by an action server when it tries to preempt all\n# goals that were requested before a certain time\ntime stamp\n\n# The id provides a way to associate feedback and\n# result message with specific goal requests. The id\n# specified must be unique.\nstring id\n\n', 'callerid': '/stretch_driver', 'tcp_nodelay': '0', 'md5sum': '302881f31927c1df708a2dbab0e80ee8', 'topic': '/stretch_controller/follow_joint_trajectory/cancel', 'type': 'actionlib_msgs/GoalID'} ^C
The ^C is when I forced kill the roslaunch

Hi @csemecu, thanks for bringing this up. I’ve seen the first symptom, but exiting everything and restarting usually resolves the issue. The web_interface repo is definitely in an alpha state at the moment. I can help you debug the networking issue if you could post the complete logs from the roslaunch stretch_web_interface web_interface.launch and ./start_desktop_dev_env.sh commands.

Also note, if you have ROS_MASTER_URI, ROS_IP, or ROS_HOSTNAME in your .bashrc, removing them might resolve the issue. I had ROS_MASTER_URI defined in my environment variables from working with Remote ROS Master, and this conflicted with the web_interface.