pytries / datrie

Fast, efficiently stored Trie for Python. Uses libdatrie.
http://pypi.python.org/pypi/datrie/
GNU Lesser General Public License v2.1
530 stars 88 forks source link

installation fails due to sandbox violation #59

Closed mschilli87 closed 4 years ago

mschilli87 commented 5 years ago

When attempting

python2.7 setup.py build

I get

Traceback (most recent call last):
  File "setup.py", line 58, in <module>
    tests_require=["pytest", "hypothesis"])
  File "/usr/lib64/python2.7/site-packages/setuptools/__init__.py", line 128, in setup
    _install_setup_requires(attrs)
  File "/usr/lib64/python2.7/site-packages/setuptools/__init__.py", line 123, in _install_setup_requires
    dist.fetch_build_eggs(dist.setup_requires)
  File "/usr/lib64/python2.7/site-packages/setuptools/dist.py", line 453, in fetch_build_eggs
    replace_conflicting=True,
  File "/usr/lib64/python2.7/site-packages/pkg_resources/__init__.py", line 866, in resolve
    replace_conflicting=replace_conflicting
  File "/usr/lib64/python2.7/site-packages/pkg_resources/__init__.py", line 1146, in best_match
    return self.obtain(req, installer)
  File "/usr/lib64/python2.7/site-packages/pkg_resources/__init__.py", line 1158, in obtain
    return installer(requirement)
  File "/usr/lib64/python2.7/site-packages/setuptools/dist.py", line 520, in fetch_build_egg
    return cmd.easy_install(req)
  File "/usr/lib64/python2.7/site-packages/setuptools/command/easy_install.py", line 672, in easy_install
    return self.install_item(spec, dist.location, tmpdir, deps)
  File "/usr/lib64/python2.7/site-packages/setuptools/command/easy_install.py", line 698, in install_item
    dists = self.install_eggs(spec, download, tmpdir)
  File "/usr/lib64/python2.7/site-packages/setuptools/command/easy_install.py", line 879, in install_eggs
    return self.build_and_install(setup_script, setup_base)
  File "/usr/lib64/python2.7/site-packages/setuptools/command/easy_install.py", line 1118, in build_and_install
    self.run_setup(setup_script, setup_base, args)
  File "/usr/lib64/python2.7/site-packages/setuptools/command/easy_install.py", line 1106, in run_setup
    raise DistutilsError("Setup script exited with %s" % (v.args[0],))
distutils.errors.DistutilsError: Setup script exited with error: SandboxViolation: open('/var/tmp/portage/dev-python/datrie-0.7.1/work/datrie-0.7.1-python2_7/lib/ptr.py', 'wb') {}

The package setup script has attempted to modify files on your system
that are not within the EasyInstall build area, and has been aborted.

This package cannot be safely installed by EasyInstall, and may not
support alternate installation locations even if you run its setup
script by hand.  Please inform the package's author and the EasyInstall
maintainers to find out if a fix or workaround is available.

Note that /var/tmp/portage/dev-python/datrie-0.7.1/work/ is the working directory from which I run setup.py (I'm trying to package datrie for Gentoo), so it seems to be an attempt to write to ../datrie/datrie-0.7.1-python2_7/lib/ptr.py that causes this error.

Any pointers on how to fix / work around this?

tacaswell commented 4 years ago

Given that this is a year old and against an old version of datrie, I am going to close this. If you still have this problem against 0.8.2 please open a new issue.