personalrobotics / prpy

Python utilities used by the Personal Robotics Laboratory.
BSD 3-Clause "New" or "Revised" License
62 stars 19 forks source link

Correct handling of resources relative to the OPENRAVE_DATA path #310

Open cdellin opened 8 years ago

cdellin commented 8 years ago

It has come to my attention that some of our JSON infrastructure does not correctly name resources relative to the OPENRAVE_DATA path (these files exist in the pr_ordata package, so this is the correct way to reference them). Nobody should be passing around OPENRAVE_DATA paths explicitly -- it is up to packages to advertise their ordata/data directories correctly (which pr_ordata does, with the help of openrave_catkin).

According to @mkoval, there are two types of problems:

  1. JSON files are not loaded relative to the OPENRAVE_DATA path. When a JSON file is to be loaded, its actual filesystem path should be resolved using openravepy.RaveFindLocalFile() (like all other such resources are loaded).
  2. The JSON files themselves reference other files with hardcoded paths, instead of paths relative to OPENRAVE_DATA.

I'm also tagging @Shushman and @jeking04 because they were discussing this briefly today.