Skip to content

from virtualenv, pyros-setup gets wrong location for config file #54

Description

@asmodehn

Failing Example :

(pyros-ros) alexv@AlexV-Linux:~/Projects/ros_pyros_ws/src/pyros_rosinterface$ python
Python 2.7.6 (default, Oct 26 2016, 20:30:19) 
[GCC 4.8.4] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import rospy
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: No module named rospy
>>> import pyros_setup
>>> pyros_setup.configurable_import().configure().activate()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python2.7/dist-packages/pyros_setup/__init__.py", line 92, in configure
    """)
  File "/usr/local/lib/python2.7/dist-packages/pyros_config/confighandler.py", line 74, in configure_file
    os.makedirs(os.path.dirname(cfg_filename))
  File "/home/alexv/.virtualenvs/pyros-ros/lib/python2.7/os.py", line 157, in makedirs
    mkdir(name, mode)
OSError: [Errno 13] Permission denied: '/usr/local/lib/python2.7/dist-packages/instance'

In that case :

  • we run from a virtualenv
  • we use pyros from an installed location
  • BUT the config file is attempted to be created along the package, instead of going to /usr/var.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions