os.rename() in _call_easy_install fails intermittently on Windows
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Buildout |
New
|
Undecided
|
Unassigned |
Bug Description
Very frequently buildout blows up during the call to os.rename() in _call_easy_install with an 'OSError: Permission Denied' on Windows.
The problematic code is:
for d in dists:
if os.path.
Apparently, an anti-virus or Google Desktop Search could cause this kind of failure (the third-party application might have an open handle to one of the files). Not sure what to do other than retrying the call a couple times until it works, or using shutil.move() which is a little bit smarter about it.
Here's a full traceback showing the issue:
While:
Installing instance.
Getting distribution for 'kss.core==1.4.7'.
An internal error occured due to a bug in either zc.buildout or in a plone\3. 3\buildout- cache\eggs\ zc.buildout- 1.4.2-py2. 4.egg\zc\ buil buildout, command)(args) plone\3. 3\buildout- cache\eggs\ zc.buildout- 1.4.2-py2. 4.egg\zc\ buil ._call( recipe. install) plone\3. 3\buildout- cache\eggs\ zc.buildout- 1.4.2-py2. 4.egg\zc\ buil plone\3. 3\buildout- cache\eggs\ plone.recipe. zope2instance- 3.4-py2. recipe\ zope2instance\ __init_ _.py", line 39, in install working_ set() plone\3. 3\buildout- cache\eggs\ zc.recipe. egg-1.2. 2-py2.4. egg\zc\ re hosts=self. allow_hosts, plone\3. 3\buildout- cache\eggs\ zc.buildout- 1.4.2-py2. 4.egg\zc\ buil install. py", line 800, in install install( specs, working_set) plone\3. 3\buildout- cache\eggs\ zc.buildout- 1.4.2-py2. 4.egg\zc\ buil install. py", line 670, in install dist(requiremen t, ws, self._always_unzip plone\3. 3\buildout- cache\eggs\ zc.buildout- 1.4.2-py2. 4.egg\zc\ buil install. py", line 542, in _get_dist easy_install( plone\3. 3\buildout- cache\eggs\ zc.buildout- 1.4.2-py2. 4.egg\zc\ buil install. py", line 381, in _call_easy_install rename( d.location, newloc)
recipe being used:
Traceback (most recent call last):
File "c:\src\
dout\buildout.py", line 1660, in main
getattr(
File "c:\src\
dout\buildout.py", line 532, in install
installed_files = self[part]
File "c:\src\
dout\buildout.py", line 1204, in _call
return f()
File "c:\src\
4.egg\plone\
requirements, ws = self.egg.
File "c:\src\
cipe\egg\egg.py", line 89, in working_set
allow_
File "c:\src\
dout\easy_
return installer.
File "c:\src\
dout\easy_
for dist in self._get_
File "c:\src\
dout\easy_
dists = self._call_
File "c:\src\
dout\easy_
os.
OSError: [Errno 13] Permission denied