tork-a / roswww

Tiny web server for ROS (forked from https://github.com/jihoonl/roswww)
Other
36 stars 25 forks source link

Restructured roswww webserver #18

Closed jihoonl closed 9 years ago

jihoonl commented 9 years ago

@130s

To execute

./roswww/scripts/webserver.py --port 8081 --webpath www

130s commented 9 years ago

Looks like a well-thought refactoring is going on. A few questions before moving on:

130s commented 9 years ago

Where was roscore used?https

This is what #9 talks about I believe.

130s commented 9 years ago

@jihoonl since I removed the target branch (hydro-devel), github automatically closed this PR and never lets me reopen. Can you open a new PR against develop?

jihoonl commented 9 years ago

I have created PR to develop

19

jihoonl commented 9 years ago

Looks like a well-thought refactoring is going on. A few questions before moving on:

  • Where was roscore used?

I believe roscore was required to use rosparam and ros logger. This is why I replaced that with command arguments and python default logger library as #9 explains. I think runtime ros isn't necessary to start roswww server.

  • sudo is now required right? This itself sounds like a right step.
    • However, sudo being mandatory no longer (easily) allows rosrun (maybe related).

sudo is not required to run roswwwserver. You can just execute script to start webserver just as you can run nodejs webserver without sudo permission.

Being able to run roswww server as a ROS node was quite handy from launch file.

Still we can utilise roslaunch in a bit different way. I have updated to add example launch. https://github.com/tork-a/roswww/blob/classfy/launch/roswww.launch

  • Import glitch?

What is it?

$ sudo ./roswww/script/webserver.py --port 8081 -webpath ~/cws_viz/src/tork-a/visualization_rwt/rwt_moveit/www
[sudo] password for pastabasta: 
Traceback (most recent call last):
  File "./roswww/script/webserver.py", line 39, in <module>
    import roswww
ImportError: No module named roswww

webpath is not a root of webserver. it is web page root of each package directory. For example, the default is www. So roswww webserver looks for www directory for each package and add them into webserver handler. Later I would like to implement #19