Opened 6 years ago

Closed 6 years ago

#4193 defect closed duplicate (duplicate)

NameError: global name 'FilePath' is not defined

Reported by: thijs Owned by: jml
Priority: normal Milestone:
Component: trial Keywords:
Cc: thijs Branch:
Author: Launchpad Bug:


Was getting this error:

$ python test
running test
running egg_info
writing requirements to PyAMF.egg-info/requires.txt
writing PyAMF.egg-info/PKG-INFO
writing top-level names to PyAMF.egg-info/top_level.txt
writing dependency_links to PyAMF.egg-info/dependency_links.txt
writing manifest file 'PyAMF.egg-info/SOURCES.txt'
running build_ext
copying build/lib.linux-x86_64-2.6/cpyamf/ -> cpyamf
copying build/lib.linux-x86_64-2.6/cpyamf/ -> cpyamf
could not remove FilePath('/home/thijs/pyamf/_trial_temp'), caught OSError [Errno 13]: Permission denied
Traceback (most recent call last):
  File "", line 186, in <module>
    "Topic :: Software Development :: Libraries :: Python Modules",
  File "/usr/local/lib/python2.6/distutils/", line 152, in setup
  File "/usr/local/lib/python2.6/distutils/", line 975, in run_commands
  File "/usr/local/lib/python2.6/distutils/", line 995, in run_command
  File "/usr/local/lib/python2.6/site-packages/setuptools-0.6c11-py2.6.egg/setuptools/command/", line 121, in run
  File "/usr/local/lib/python2.6/site-packages/setuptools-0.6c11-py2.6.egg/setuptools/command/", line 101, in with_project_on_sys_path
  File "", line 36, in run_tests
    return self.run_twisted()
  File "", line 26, in run_twisted
  File "/usr/local/lib/python2.6/site-packages/Twisted-9.0.0-py2.6-linux-x86_64.egg/twisted/trial/", line 833, in run
    return self._runWithoutDecoration(test)
  File "/usr/local/lib/python2.6/site-packages/Twisted-9.0.0-py2.6-linux-x86_64.egg/twisted/trial/", line 859, in _runWithoutDecoration
    oldDir = self._setUpTestdir()
  File "/usr/local/lib/python2.6/site-packages/Twisted-9.0.0-py2.6-linux-x86_64.egg/twisted/trial/", line 753, in _setUpTestdir
  File "/usr/local/lib/python2.6/site-packages/Twisted-9.0.0-py2.6-linux-x86_64.egg/twisted/trial/", line 728, in _removeSafely
    newPath = FilePath('_trial_temp_old%s'
NameError: global name 'FilePath' is not defined

Which starts out as a permission problem, which is ok, but turns into a NameError. FilePath should be file.FilePath in trunk/twisted/trial/

Change History (1)

comment:1 Changed 6 years ago by exarkun

  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #4020

Note: See TracTickets for help on using tickets.