[Grok-dev] problem with zope.app.testing during installation Grok on Windows XP

Michael Haubenwallner michael at d2m.at
Sat Nov 15 08:13:03 EST 2008


Roger Erens wrote:
> on 14-11-2008 17:13 Michael Haubenwallner wrote:
>> The real problem was that zope.app.testing could not be extracted from
>> the tarball. See your last posting...
>>
>>      ...
>>      self._read(readsize)
>>    File "c:\python25\Lib\gzip.py", line 279, in _read
>>      uncompress = self.decompress.decompress(buf)
>> zlib.error: Error -3 while decompressing: invalid literal/lengths set
>> An error occured when trying to install zope.app.testing 3.4.3.
> 
> So, that makes it a bug? An error when the tarball was created; two MS 
> Windows processes accessing the temporary tarbal at the same time?
> 
> I just want to help making installation on MS Windows more smoothly, so 
> if you know who I should bugger with this issue... :-)
> 

Had some time to track that down today. Problem is twofold:

- decompression issue

in z3c.recipe.eggbasket.downloader the tarball is pulled and saved to a
temporary file:

  tarball = open(temp_tarball_name, 'w')

Problem is it should be

  tarball = open(temp_tarball_name, 'wb')

at least windows makes a difference here when decompressing the (binary)
file.

You can simply patch the z3c.recipe.eggbasket egg (in your eggs folder)
and change the line in downloader.py. Then run grokproject again and
create a new project. All eggs get extracted and installed into the eggs
folder. Should work fine until you hit the second problem:

- temp file cannot be removed, used by another process

that is, after extracting/creating the eggs, removal of the temp file
fails and the setup is stopped - and buildout is not run. Just change to
the created grokproject folder and run "bin\buildout", which installs
the commands into the bin directory. And that's it, i tested it on
native XP.


Solving the  first problem is easy, we should just change the line in
z3c.recipe.eggbasket. Not sure how to solve the second issue though. I'm
CCing to mauritsvanrees for suggestions.

> Thanks for your time. BTW, is your nick name d2m at #grok?

YW and - yes.

Regards
Michael

-- 
http://blog.d2m.at
http://planetzope.org



More information about the Grok-dev mailing list