1837
def versions_section_ignored_for_dependency_in_favor_of_site_packages():
1839
This is a test for a bugfix.
1841
The error showed itself when at least two dependencies were in a shared
1842
location like site-packages, and the first one met the "versions" setting. The
1843
first dependency would be added, but subsequent dependencies from the same
1844
location (e.g., site-packages) would use the version of the package found in
1845
the shared location, ignoring the version setting.
1847
We begin with a Python that has demoneeded version 1.1 installed and a
1848
demo version 0.3, all in a site-packages-like shared directory. We need
1849
to create this. ``eggrecipedemo.main()`` shows the number after the dot
1850
(that is, ``X`` in ``1.X``), for the demo package and the demoneeded
1851
package, so this demonstrates that our Python does in fact have demo
1852
version 0.3 and demoneeded version 1.1.
1854
>>> py_path = make_py_with_system_install(make_py, sample_eggs)
1857
... "import tellmy.version; print tellmy.version.__version__"),
1860
Now here's a setup that would expose the bug, using the
1861
zc.buildout.easy_install API.
1863
>>> example_dest = tmpdir('example_dest')
1864
>>> workingset = zc.buildout.easy_install.install(
1865
... ['tellmy.version'], example_dest, links=[sample_eggs],
1866
... executable=py_path,
1868
... versions={'tellmy.version': '1.0'})
1869
>>> for dist in workingset:
1871
... if res.startswith('tellmy.version'):
1876
Before the bugfix, the desired tellmy.version distribution would have
1877
been blocked the one in site-packages.
1880
def handle_namespace_package_in_both_site_packages_and_buildout_eggs():
1882
If you have the same namespace package in both site-packages and in
1883
buildout, we need to be very careful that faux-Python-executables and
1884
scripts generated by easy_install.sitepackage_safe_scripts correctly
1885
combine the two. We show this with the local recipe that uses the
1886
function, z3c.recipe.scripts.
1888
To demonstrate this, we will create three packages: tellmy.version 1.0,
1889
tellmy.version 1.1, and tellmy.fortune 1.0. tellmy.version 1.1 is installed.
1891
>>> py_path = make_py_with_system_install(make_py, sample_eggs)
1894
... "import tellmy.version; print tellmy.version.__version__")
1898
Now we will create a buildout that creates a script and a faux-Python script.
1899
We want to see that both can successfully import the specified versions of
1900
tellmy.version and tellmy.fortune.
1902
>>> write('buildout.cfg',
1906
... find-links = %(link_server)s
1909
... executable = %(py_path)s
1912
... recipe = z3c.recipe.scripts
1913
... python = primed_python
1914
... interpreter = py
1915
... include-site-packages = true
1916
... eggs = tellmy.version == 1.0
1917
... tellmy.fortune == 1.0
1919
... script-initialization =
1920
... import tellmy.version
1921
... print tellmy.version.__version__
1922
... import tellmy.fortune
1923
... print tellmy.fortune.__version__
1924
... ''' % globals())
1926
>>> print system(buildout)
1928
Getting distribution for 'tellmy.version==1.0'.
1929
Got tellmy.version 1.0.
1930
Getting distribution for 'tellmy.fortune==1.0'.
1931
Got tellmy.fortune 1.0.
1932
Getting distribution for 'demo'.
1934
Getting distribution for 'demoneeded'.
1935
Got demoneeded 1.2c1.
1936
Generated script '/sample-buildout/bin/demo'.
1937
Generated interpreter '/sample-buildout/bin/py'.
1940
Finally, we are ready to see if it worked. Prior to the bug fix that
1941
this tests, the results of both calls below was the following::
1944
Traceback (most recent call last):
1946
ImportError: No module named fortune
1949
In other words, we got the site-packages version of tellmy.version, and
1950
we could not import tellmy.fortune at all. The following are the correct
1951
results for the interpreter and for the script.
1954
... join('bin', 'py'),
1955
... "import tellmy.version; " +
1956
... "print tellmy.version.__version__; " +
1957
... "import tellmy.fortune; " +
1958
... "print tellmy.fortune.__version__") # doctest: +ELLIPSIS
1962
>>> print system(join('bin', 'demo'))
1969
def handle_sys_path_version_hack():
1971
This is a test for a bugfix.
1973
If you use a Python that has a different version of one of your
1974
dependencies, and the new package tries to do sys.path tricks in the
1975
setup.py to get a __version__, and it uses namespace packages, the older
1976
package will be loaded first, making the setup version the wrong number.
1977
While very arguably packages simply shouldn't do this, some do, and we
1978
don't want buildout to fall over when they do.
1980
To demonstrate this, we will need to create a distribution that has one of
1981
these unpleasant tricks, and a Python that has an older version installed.
1983
>>> py_path, site_packages_path = make_py()
1984
>>> for version in ('1.0', '1.1'):
1985
... tmp = tempfile.mkdtemp()
1987
... write(tmp, 'README.txt', '')
1988
... mkdir(tmp, 'src')
1989
... mkdir(tmp, 'src', 'tellmy')
1990
... write(tmp, 'src', 'tellmy', '__init__.py',
1992
... "'pkg_resources').declare_namespace(__name__)\n")
1993
... mkdir(tmp, 'src', 'tellmy', 'version')
1994
... write(tmp, 'src', 'tellmy', 'version',
1995
... '__init__.py', '__version__=%r\n' % version)
1997
... tmp, 'setup.py',
1998
... "from setuptools import setup\n"
2000
... "sys.path.insert(0, 'src')\n"
2001
... "from tellmy.version import __version__\n"
2003
... " name='tellmy.version',\n"
2004
... " package_dir = {'': 'src'},\n"
2005
... " packages = ['tellmy', 'tellmy.version'],\n"
2006
... " install_requires = ['setuptools'],\n"
2007
... " namespace_packages=['tellmy'],\n"
2008
... " zip_safe=True, version=__version__,\n"
2009
... " author='bob', url='bob', author_email='bob')\n"
2011
... zc.buildout.testing.sdist(tmp, sample_eggs)
2012
... if version == '1.0':
2013
... # We install the 1.0 version in site packages the way a
2014
... # system packaging system (debs, rpms) would do it.
2015
... zc.buildout.testing.sys_install(tmp, site_packages_path)
2017
... shutil.rmtree(tmp)
2020
... "import tellmy.version; print tellmy.version.__version__")
2023
>>> write('buildout.cfg',
2027
... find-links = %(sample_eggs)s
2030
... executable = %(py_path)s
2033
... recipe = zc.recipe.egg:eggs
2034
... python = primed_python
2035
... eggs = tellmy.version == 1.1
2036
... ''' % globals())
2038
Before the bugfix, running this buildout would generate this error:
2041
Getting distribution for 'tellmy.version==1.1'.
2042
Installing tellmy.version 1.1
2043
Caused installation of a distribution:
2045
with a different version.
2049
Error: There is a version conflict.
2050
We already have: tellmy.version 1.0
2053
You can see the copiously commented fix for this in easy_install.py (see
2054
zc.buildout.easy_install.Installer._call_easy_install and particularly
2055
the comment leading up to zc.buildout.easy_install._easy_install_cmd).
2056
Now the install works correctly, as seen here.
2058
>>> print system(buildout)
2060
Getting distribution for 'tellmy.version==1.1'.
2061
Got tellmy.version 1.1.
2066
def isolated_include_site_packages():
2069
This is an isolated test of the include_site_packages functionality, passing
2070
the argument directly to install, overriding a default.
2072
Our "py_path" has the "demoneeded" and "demo" packages available. We'll
2073
simply be asking for "demoneeded" here.
2075
>>> py_path, site_packages_path = make_py()
2076
>>> create_sample_sys_install(site_packages_path)
2077
>>> zc.buildout.easy_install.include_site_packages(False)
2080
>>> example_dest = tmpdir('site-packages-example-install')
2081
>>> workingset = zc.buildout.easy_install.install(
2082
... ['demoneeded'], example_dest, links=[], executable=py_path,
2083
... index=None, include_site_packages=True)
2084
>>> [dist.project_name for dist in workingset]
2087
That worked fine. Let's try again with site packages not allowed (and
2088
reversing the default).
2090
>>> zc.buildout.easy_install.include_site_packages(True)
2093
>>> zc.buildout.easy_install.clear_index_cache()
2094
>>> rmdir(example_dest)
2095
>>> example_dest = tmpdir('site-packages-example-install')
2096
>>> workingset = zc.buildout.easy_install.install(
2097
... ['demoneeded'], example_dest, links=[], executable=py_path,
2098
... index=None, include_site_packages=False)
2099
Traceback (most recent call last):
2101
MissingDistribution: Couldn't find a distribution for 'demoneeded'.
2103
That's a failure, as expected.
2105
Now we explore an important edge case.
2107
Some system Pythons include setuptools (and other Python packages) in their
2108
site-packages (or equivalent) using a .egg-info directory. The pkg_resources
2109
module (from setuptools) considers a package installed using .egg-info to be a
2112
zc.buildout.buildout.Buildout.bootstrap will make setuptools and zc.buildout
2113
available to the buildout via the eggs directory, for normal eggs; or the
2114
develop-eggs directory, for develop-eggs.
2116
If setuptools or zc.buildout is found in site-packages and considered by
2117
pkg_resources to be a develop egg, then the bootstrap code will use a .egg-link
2118
in the local develop-eggs, pointing to site-packages, in its entirety. Because
2119
develop-eggs must always be available for searching for distributions, this
2120
indirectly brings site-packages back into the search path for distributions.
2122
Because of this, we have to take special care that we still exclude
2123
site-packages even in this case. See the comments about site packages in the
2124
Installer._satisfied and Installer._obtain methods for the implementation
2125
(as of this writing).
2127
In this demonstration, we insert a link to the "demoneeded" distribution
2128
in our develop-eggs, which would bring the package back in, except for
2129
the special care we have taken to exclude it.
2131
>>> zc.buildout.easy_install.clear_index_cache()
2132
>>> rmdir(example_dest)
2133
>>> example_dest = tmpdir('site-packages-example-install')
2134
>>> mkdir(example_dest, 'develop-eggs')
2135
>>> write(example_dest, 'develop-eggs', 'demoneeded.egg-link',
2136
... site_packages_path)
2137
>>> workingset = zc.buildout.easy_install.install(
2138
... ['demoneeded'], example_dest, links=[],
2139
... path=[join(example_dest, 'develop-eggs')],
2140
... executable=py_path,
2141
... index=None, include_site_packages=False)
2142
Traceback (most recent call last):
2144
MissingDistribution: Couldn't find a distribution for 'demoneeded'.
2146
The MissingDistribution error shows that buildout correctly excluded the
2147
"site-packages" source even though it was indirectly included in the path
2148
via a .egg-link file.
2152
def allowed_eggs_from_site_packages():
2154
Sometimes you need or want to control what eggs from site-packages are used.
2155
The allowed-eggs-from-site-packages option allows you to specify a whitelist of
2156
project names that may be included from site-packages. You can use globs to
2157
specify the value. It defaults to a single value of '*', indicating that any
2158
package may come from site-packages.
2160
This option interacts with include-site-packages in the following ways.
2162
If include-site-packages is true, then allowed-eggs-from-site-packages filters
2163
what eggs from site-packages may be chosen. If allowed-eggs-from-site-packages
2164
is an empty list, then no eggs from site-packages are chosen, but site-packages
2165
will still be included at the end of path lists.
2167
If include-site-packages is false, allowed-eggs-from-site-packages is
2170
This test shows the interaction with the zc.buildout.easy_install API. Another
2171
test below (allow_site_package_eggs_option) shows using it with a buildout.cfg.
2173
Our "py_path" has the "demoneeded" and "demo" packages available. We'll
2174
simply be asking for "demoneeded" here.
2176
>>> py_path, site_packages_path = make_py()
2177
>>> create_sample_sys_install(site_packages_path)
2179
>>> example_dest = tmpdir('site-packages-example-install')
2180
>>> workingset = zc.buildout.easy_install.install(
2181
... ['demoneeded'], example_dest, links=[], executable=py_path,
2183
... allowed_eggs_from_site_packages=['demoneeded', 'other'])
2184
>>> [dist.project_name for dist in workingset]
2187
That worked fine. It would work fine for a glob too.
2189
>>> zc.buildout.easy_install.clear_index_cache()
2190
>>> rmdir(example_dest)
2191
>>> example_dest = tmpdir('site-packages-example-install')
2192
>>> workingset = zc.buildout.easy_install.install(
2193
... ['demoneeded'], example_dest, links=[], executable=py_path,
2195
... allowed_eggs_from_site_packages=['?emon*', 'other'])
2196
>>> [dist.project_name for dist in workingset]
2199
But now let's try again with 'demoneeded' not allowed.
2201
>>> zc.buildout.easy_install.clear_index_cache()
2202
>>> rmdir(example_dest)
2203
>>> example_dest = tmpdir('site-packages-example-install')
2204
>>> workingset = zc.buildout.easy_install.install(
2205
... ['demoneeded'], example_dest, links=[], executable=py_path,
2207
... allowed_eggs_from_site_packages=['demo'])
2208
Traceback (most recent call last):
2210
MissingDistribution: Couldn't find a distribution for 'demoneeded'.
2212
Here's the same, but with an empty list.
2214
>>> zc.buildout.easy_install.clear_index_cache()
2215
>>> rmdir(example_dest)
2216
>>> example_dest = tmpdir('site-packages-example-install')
2217
>>> workingset = zc.buildout.easy_install.install(
2218
... ['demoneeded'], example_dest, links=[], executable=py_path,
2220
... allowed_eggs_from_site_packages=[])
2221
Traceback (most recent call last):
2223
MissingDistribution: Couldn't find a distribution for 'demoneeded'.
2225
Of course, this doesn't stop us from getting a package from elsewhere. Here,
2226
we add a link server.
2228
>>> zc.buildout.easy_install.clear_index_cache()
2229
>>> rmdir(example_dest)
2230
>>> example_dest = tmpdir('site-packages-example-install')
2231
>>> workingset = zc.buildout.easy_install.install(
2232
... ['demoneeded'], example_dest, executable=py_path,
2233
... links=[link_server], index=link_server+'index/',
2234
... allowed_eggs_from_site_packages=['other'])
2235
>>> [dist.project_name for dist in workingset]
2237
>>> [dist.location for dist in workingset]
2238
['/site-packages-example-install/demoneeded-1.1-py2.6.egg']
2240
Finally, here's an example of an interaction: we say that it is OK to
2241
allow the "demoneeded" egg to come from site-packages, but we don't
2242
include-site-packages.
2244
>>> zc.buildout.easy_install.clear_index_cache()
2245
>>> rmdir(example_dest)
2246
>>> example_dest = tmpdir('site-packages-example-install')
2247
>>> workingset = zc.buildout.easy_install.install(
2248
... ['demoneeded'], example_dest, links=[], executable=py_path,
2249
... index=None, include_site_packages=False,
2250
... allowed_eggs_from_site_packages=['demoneeded'])
2251
Traceback (most recent call last):
2253
MissingDistribution: Couldn't find a distribution for 'demoneeded'.
2257
def subprocesses_have_same_environment_by_default():
2259
The scripts generated by sitepackage_safe_scripts set the PYTHONPATH so that,
2260
if the environment is maintained (the default behavior), subprocesses get
2261
the same Python packages.
2263
First, we set up a script and an interpreter.
2265
>>> interpreter_dir = tmpdir('interpreter')
2266
>>> interpreter_parts_dir = os.path.join(
2267
... interpreter_dir, 'parts', 'interpreter')
2268
>>> interpreter_bin_dir = os.path.join(interpreter_dir, 'bin')
2269
>>> mkdir(interpreter_bin_dir)
2270
>>> mkdir(interpreter_dir, 'eggs')
2271
>>> mkdir(interpreter_dir, 'parts')
2272
>>> mkdir(interpreter_parts_dir)
2273
>>> ws = zc.buildout.easy_install.install(
2274
... ['demo'], join(interpreter_dir, 'eggs'), links=[link_server],
2275
... index=link_server+'index/')
2277
... "import subprocess, sys; subprocess.call("
2278
... "[sys.executable, '-c', "
2279
... "'import eggrecipedemo; print eggrecipedemo.x'])")
2280
>>> generated = zc.buildout.easy_install.sitepackage_safe_scripts(
2281
... interpreter_bin_dir, ws, sys.executable, interpreter_parts_dir,
2282
... reqs=['demo'], interpreter='py',
2283
... script_initialization=test + '; sys.exit(0)')
2285
This works for the script.
2287
>>> print system(join(interpreter_bin_dir, 'demo'))
2291
This also works for the generated interpreter.
2293
>>> print call_py(join(interpreter_bin_dir, 'py'), test)
2299
def bootstrap_makes_buildout_that_works_with_system_python():
2301
In order to work smoothly with a system Python, bootstrapping creates
2302
the buildout script with
2303
zc.buildout.easy_install.sitepackage_safe_scripts. If it did not, a
2304
variety of problems might happen. For instance, if another version of
2305
buildout or setuptools is installed in the site-packages than is
2306
desired, it may cause a problem.
2308
A problem actually experienced in the field is when
2309
a recipe wants a different version of a dependency that is installed in
2310
site-packages. We will create a similar situation, and show that it is now
2313
First let's write a dummy recipe.
2315
>>> mkdir(sample_buildout, 'recipes')
2316
>>> write(sample_buildout, 'recipes', 'dummy.py',
2318
... import logging, os, zc.buildout
2320
... def __init__(self, buildout, name, options):
2322
... def install(self):
2324
... def update(self):
2327
>>> write(sample_buildout, 'recipes', 'setup.py',
2329
... from setuptools import setup
2332
... name = "recipes",
2333
... entry_points = {'zc.buildout': ['dummy = dummy:Dummy']},
2334
... install_requires = 'demoneeded==1.2c1',
2337
>>> write(sample_buildout, 'recipes', 'README.txt', " ")
2339
Now we'll try to use it with a Python that has a different version of
2340
demoneeded installed.
2342
>>> py_path, site_packages_path = make_py()
2343
>>> create_sample_sys_install(site_packages_path)
2344
>>> rmdir('develop-eggs')
2345
>>> from zc.buildout.testing import make_buildout
2346
>>> make_buildout(executable=py_path)
2347
>>> write(sample_buildout, 'buildout.cfg',
2350
... develop = recipes
2352
... find-links = %(link_server)s
2353
... executable = %(py_path)s
2356
... recipe = recipes:dummy
2357
... ''' % globals())
2359
Now we actually run the buildout. Before the change, we got the following
2362
Develop: '/sample-buildout/recipes'
2365
Getting section dummy.
2366
Initializing section dummy.
2367
Installing recipe recipes.
2368
Error: There is a version conflict.
2369
We already have: demoneeded 1.1
2370
but recipes 0.0.0 requires 'demoneeded==1.2c1'.
2372
Now, it is handled smoothly.
2374
>>> print system(buildout)
2375
Develop: '/sample-buildout/recipes'
2376
Getting distribution for 'demoneeded==1.2c1'.
2377
Got demoneeded 1.2c1.
2381
Here's the same story with a namespace package, which has some additional
2382
complications behind the scenes. First, a recipe, in the "tellmy" namespace.
2384
>>> mkdir(sample_buildout, 'ns')
2385
>>> mkdir(sample_buildout, 'ns', 'tellmy')
2386
>>> write(sample_buildout, 'ns', 'tellmy', '__init__.py',
2387
... "__import__('pkg_resources').declare_namespace(__name__)\n")
2388
>>> mkdir(sample_buildout, 'ns', 'tellmy', 'recipes')
2389
>>> write(sample_buildout, 'ns', 'tellmy', 'recipes', '__init__.py', ' ')
2390
>>> write(sample_buildout, 'ns', 'tellmy', 'recipes', 'dummy.py',
2392
... import logging, os, zc.buildout
2394
... def __init__(self, buildout, name, options):
2396
... def install(self):
2398
... def update(self):
2401
>>> write(sample_buildout, 'ns', 'setup.py',
2403
... from setuptools import setup
2405
... name="tellmy.recipes",
2406
... packages=['tellmy', 'tellmy.recipes'],
2407
... install_requires=['setuptools'],
2408
... namespace_packages=['tellmy'],
2409
... entry_points = {'zc.buildout':
2410
... ['dummy = tellmy.recipes.dummy:Dummy']},
2414
Now, a buildout that uses it.
2416
>>> create_sample_namespace_eggs(sample_eggs, site_packages_path)
2417
>>> rmdir('develop-eggs')
2418
>>> from zc.buildout.testing import make_buildout
2419
>>> make_buildout(executable=py_path)
2420
>>> write(sample_buildout, 'buildout.cfg',
2426
... find-links = %(link_server)s
2427
... executable = %(py_path)s
2430
... recipe = tellmy.recipes:dummy
2431
... ''' % globals())
2433
Now we actually run the buildout.
2435
>>> print system(buildout)
2436
Develop: '/sample-buildout/ns'
2437
Develop: '/sample-buildout/recipes'
1772
2444
if sys.version_info > (2, 4):
1773
2445
def test_exit_codes():
2655
3328
######################################################################
3330
def make_py_with_system_install(make_py, sample_eggs):
3331
py_path, site_packages_path = make_py()
3332
create_sample_namespace_eggs(sample_eggs, site_packages_path)
3335
def create_sample_namespace_eggs(dest, site_packages_path=None):
3336
from zc.buildout.testing import write, mkdir
3337
for pkg, version in (('version', '1.0'), ('version', '1.1'),
3338
('fortune', '1.0')):
3339
tmp = tempfile.mkdtemp()
3341
write(tmp, 'README.txt', '')
3343
mkdir(tmp, 'src', 'tellmy')
3344
write(tmp, 'src', 'tellmy', '__init__.py',
3346
"'pkg_resources').declare_namespace(__name__)\n")
3347
mkdir(tmp, 'src', 'tellmy', pkg)
3348
write(tmp, 'src', 'tellmy', pkg,
3349
'__init__.py', '__version__=%r\n' % version)
3352
"from setuptools import setup\n"
3354
" name='tellmy.%(pkg)s',\n"
3355
" package_dir = {'': 'src'},\n"
3356
" packages = ['tellmy', 'tellmy.%(pkg)s'],\n"
3357
" install_requires = ['setuptools'],\n"
3358
" namespace_packages=['tellmy'],\n"
3359
" zip_safe=True, version=%(version)r,\n"
3360
" author='bob', url='bob', author_email='bob')\n"
3363
zc.buildout.testing.sdist(tmp, dest)
3364
if (site_packages_path and pkg == 'version' and version == '1.1'):
3365
# We install the 1.1 version in site packages the way a
3366
# system packaging system (debs, rpms) would do it.
3367
zc.buildout.testing.sys_install(tmp, site_packages_path)
3371
def _write_eggrecipedemoneeded(tmp, minor_version, suffix=''):
3372
from zc.buildout.testing import write
3373
write(tmp, 'README.txt', '')
3374
write(tmp, 'eggrecipedemoneeded.py',
3375
'y=%s\ndef f():\n pass' % minor_version)
3378
"from setuptools import setup\n"
3379
"setup(name='demoneeded', py_modules=['eggrecipedemoneeded'],"
3380
" zip_safe=True, version='1.%s%s', author='bob', url='bob', "
3381
"author_email='bob')\n"
3382
% (minor_version, suffix)
3385
def _write_eggrecipedemo(tmp, minor_version, suffix=''):
3386
from zc.buildout.testing import write
3387
write(tmp, 'README.txt', '')
3389
tmp, 'eggrecipedemo.py',
3390
'import eggrecipedemoneeded\n'
3392
'def main(): print x, eggrecipedemoneeded.y\n'
3396
"from setuptools import setup\n"
3397
"setup(name='demo', py_modules=['eggrecipedemo'],"
3398
" install_requires = 'demoneeded',"
3399
" entry_points={'console_scripts': "
3400
"['demo = eggrecipedemo:main']},"
3401
" zip_safe=True, version='0.%s%s')\n" % (minor_version, suffix)
3404
def create_sample_sys_install(site_packages_path):
3405
for creator, minor_version in (
3406
(_write_eggrecipedemoneeded, 1),
3407
(_write_eggrecipedemo, 3)):
3408
# Write the files and install in site_packages_path.
3409
tmp = tempfile.mkdtemp()
3411
creator(tmp, minor_version)
3412
zc.buildout.testing.sys_install(tmp, site_packages_path)
2657
3416
def create_sample_eggs(test, executable=sys.executable):
2658
write = test.globs['write']
3417
from zc.buildout.testing import write
2659
3418
dest = test.globs['sample_eggs']
2660
3419
tmp = tempfile.mkdtemp()
2662
write(tmp, 'README.txt', '')
2664
3421
for i in (0, 1, 2):
2665
write(tmp, 'eggrecipedemoneeded.py', 'y=%s\ndef f():\n pass' % i)
2666
c1 = i==2 and 'c1' or ''
2669
"from setuptools import setup\n"
2670
"setup(name='demoneeded', py_modules=['eggrecipedemoneeded'],"
2671
" zip_safe=True, version='1.%s%s', author='bob', url='bob', "
2672
"author_email='bob')\n"
3422
suffix = i==2 and 'c1' or ''
3423
_write_eggrecipedemoneeded(tmp, i, suffix)
2675
3424
zc.buildout.testing.sdist(tmp, dest)