Commit 521d49b6 authored by jim's avatar jim

Bugs Fixed

----------

Non-zip-safe eggs were not unzipped when they were installed.


git-svn-id: http://svn.zope.org/repos/main/zc.buildout/trunk@70497 62d5b8a3-27da-0310-9561-8e5933582275
parent 004b65b3
......@@ -22,6 +22,14 @@ priorities include:
Change History
**************
1.0.0b9 (2006-10-02)
====================
Bugs Fixed
----------
Non-zip-safe eggs were not unzipped when they were installed.
1.0.0b8 (2006-10-01)
====================
......
......@@ -7,7 +7,7 @@ def read(*rnames):
name = "zc.buildout"
setup(
name = name,
version = "1.0.0b8",
version = "1.0.0b9",
author = "Jim Fulton",
author_email = "jim@zope.com",
description = "System for managing development buildouts",
......
......@@ -229,16 +229,17 @@ def _get_dist(requirement, env, ws,
"Couln't download a distribution for %s."
% requirement)
should_unzip = False
if always_unzip:
should_unzip = True
else:
metadata = pkg_resources.EggMetadata(
zipimport.zipimporter(dist.location)
)
should_unzip = not (
should_unzip = (
metadata.has_metadata('not-zip-safe')
or
not metadata.has_metadata('zip-safe')
or not metadata.has_metadata('zip-safe')
)
if should_unzip:
setuptools.archive_util.unpack_archive(
dist.location,
......
......@@ -134,7 +134,7 @@ dependencies. We might do this to specify a sprcific version.
- demo-0.3-py2.4.egg
- demoneeded-1.0-py2.4.egg
- demoneeded-1.1-py2.4.egg
- other-1.0-py2.4.egg
d other-1.0-py2.4.egg
We can request that eggs be unzipped even if they are zip safe. This
can be useful when debugging.
......
......@@ -403,7 +403,7 @@ def create_sample_eggs(test, executable=sys.executable):
write(
tmp, 'setup.py',
"from setuptools import setup\n"
"setup(name='other', zip_safe=True, version='1.0', "
"setup(name='other', zip_safe=False, version='1.0', "
"py_modules=['eggrecipedemobeeded'])\n"
)
zc.buildout.testing.bdist_egg(tmp, executable, dest)
......
......@@ -30,7 +30,7 @@ We can specify an specific Python executable.
>>> ls(dest)
d demo-0.3-py2.3.egg
d demoneeded-1.1-py2.3.egg
- setuptools-0.6-py2.3.egg
d setuptools-0.6-py2.3.egg
"""
......
......@@ -61,8 +61,8 @@ we'll get the Python 2.3 eggs for demo and demoneeded:
>>> ls(sample_buildout, 'eggs')
- demo-0.2-py2.3.egg
- demoneeded-1.1-py2.3.egg
- setuptools-0.6-py2.3.egg
- setuptools-0.6-py2.4.egg
d setuptools-0.6-py2.3.egg
d setuptools-0.6-py2.4.egg
- zc.buildout-1.0-py2.4.egg
And the generated scripts invoke Python 2.3:
......
......@@ -104,7 +104,7 @@ def test_suite():
zc.buildout.testing.normalize_path,
zc.buildout.testing.normalize_script,
(re.compile('Got setuptools \S+'), 'Got setuptools V'),
(re.compile('setuptools-\S+-py'), 'setuptools-V-py'),
(re.compile('([d-] )?setuptools-\S+-py'), 'setuptools-V-py'),
(re.compile('-py2[.][0-24-9][.]'), 'py2.4.'),
(re.compile('zc.buildout-\S+[.]egg'),
'zc.buildout.egg'),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment