Merge lp:~gary/zc.buildout/python-support into lp:zc.buildout

Proposed by Gary Poster
Status: Needs review
Proposed branch: lp:~gary/zc.buildout/python-support
Merge into: lp:zc.buildout
Prerequisite: lp:~gary/zc.buildout/python-support-8-support-subprocess
Diff against target: 1026 lines (+349/-185) (has conflicts)
12 files modified
CHANGES.txt (+24/-2)
bootstrap/bootstrap.py (+1/-1)
dev.py (+44/-7)
src/zc/buildout/bootstrap.txt (+1/-1)
src/zc/buildout/buildout.py (+22/-2)
src/zc/buildout/buildout.txt (+181/-115)
src/zc/buildout/easy_install.py (+8/-28)
src/zc/buildout/easy_install.txt (+10/-5)
src/zc/buildout/tests.py (+42/-16)
src/zc/buildout/update.txt (+3/-2)
z3c.recipe.scripts_/src/z3c/recipe/scripts/tests.py (+3/-2)
zc.recipe.egg_/src/zc/recipe/egg/tests.py (+10/-4)
Text conflict in CHANGES.txt
Text conflict in src/zc/buildout/buildout.py
Text conflict in src/zc/buildout/buildout.txt
To merge this branch: bzr merge lp:~gary/zc.buildout/python-support
Reviewer Review Type Date Requested Status
Francis J. Lacoste (community) Approve
Review via email: mp+21733@code.launchpad.net

Description of the change

This merges recent zc.buildout changes with the python-support-* line of branches. As such, the only work from myself here is merge conflict resolutions.

To post a comment you must log in.
Revision history for this message
Francis J. Lacoste (flacoste) wrote :

My only question is on that change:

We have the best distribution that satisfies 'setuptools'.
> - Picked: setuptools = V.V
> + Picked: setuptools = 0.6
> <BLANKLINE>
> Configuration data:
> [buildout]
> @@ -2277,7 +2274,7 @@
> develop-eggs-directory = /sample-buildout/develop-eggs
> directory = /sample-buildout
> eggs-directory = /sample-buildout/eggs
> - executable = python
> + executable = /usr/local/bin/python2.3
> find-links =
> install-from-cache = false

Is this really correct?

review: Approve
lp:~gary/zc.buildout/python-support updated
545. By Gary Poster

reinstate test cleanup

Revision history for this message
Gary Poster (gary) wrote :

Interesting, and good catch! The change is from the trunk, but from a very old revision. One of my many early branches must have changed the "Picked" and "executable" lines to the better versions, but the bzr merge didn't quite guess correctly as to what to do. So, yes, I should change it back to the values in my branch, thank you. I've done so.

lp:~gary/zc.buildout/python-support updated
546. By Gary Poster

merge from python-support-8

Revision history for this message
Gary Poster (gary) wrote :

The most recent changes (r546) merely keep the branch up-to-date with python-support-8

lp:~gary/zc.buildout/python-support updated
547. By Gary Poster

merge gary-9

548. By Gary Poster

merge lp:~gary/zc.buildout/python-support-10: add significantly improved Distribute support.

Unmerged revisions

548. By Gary Poster

merge lp:~gary/zc.buildout/python-support-10: add significantly improved Distribute support.

547. By Gary Poster

merge gary-9

546. By Gary Poster

merge from python-support-8

545. By Gary Poster

reinstate test cleanup

544. By Gary Poster

merge from python-support-8

543. By Gary Poster

merge from buildout trunk

542. By Gary Poster

merge from gary-8

541. By Gary Poster

merge buildout trunk with system python support branches.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'CHANGES.txt'
--- CHANGES.txt 2010-04-29 14:34:36 +0000
+++ CHANGES.txt 2010-04-29 14:34:36 +0000
@@ -1,11 +1,21 @@
1Change History1Change History
2**************2**************
33
4<<<<<<< TREE
51.4.4 (?)
6=========
7
8=======
9
41.?.? (201?-??-??)101.?.? (201?-??-??)
5==================11==================
612
7New Features:13New Features:
814
15- Added buildout:socket-timout option so that socket timeout can be configured
16 both from command line and from config files. (gotcha)
17>>>>>>> MERGE-SOURCE
18
9- Buildout can be safely used with a system Python (or any Python with code19- Buildout can be safely used with a system Python (or any Python with code
10 in site-packages), as long as you use the new z3c.recipe.scripts20 in site-packages), as long as you use the new z3c.recipe.scripts
11 recipe to generate scripts and interpreters, rather than zc.recipe.egg.21 recipe to generate scripts and interpreters, rather than zc.recipe.egg.
@@ -39,22 +49,34 @@
39 * The buildout script generated by bootstrap honors more of the settings49 * The buildout script generated by bootstrap honors more of the settings
40 in the designated configuration file (e.g., buildout.cfg).50 in the designated configuration file (e.g., buildout.cfg).
4151
52- You can develop zc.buildout using Distribute instead of Setuptools. Use
53 the --distribute option on the dev.py script. (Releases should be tested
54 with both Distribute and Setuptools.)
55
56- The ``distribute-version`` now works in the [buildout] section, mirroring
57 the ``setuptools-version`` option (this is for consistency; using the
58 general-purpose ``versions`` option is preferred).
59
42Bugs fixed:60Bugs fixed:
4361
62- Using Distribute with the ``allow-picked-versions = false`` buildout
63 option no longer causes an error.
64
44- The handling and documenting of default buildout options was normalized.65- The handling and documenting of default buildout options was normalized.
45 This means, among other things, that ``bin/buildout -vv`` and66 This means, among other things, that ``bin/buildout -vv`` and
46 ``bin/buildout annotate`` correctly list more of the options.67 ``bin/buildout annotate`` correctly list more of the options.
4768
48- Installing a namespace package using a Python that already has a package69- Installing a namespace package using a Python that already has a package
49 in the same namespace (e.g., in the Python's site-packages) failed in70 in the same namespace (e.g., in the Python's site-packages) failed in
50 some cases.71 some cases. It is now handled correctly.
5172
52- Another variation of this error showed itself when at least two73- Another variation of this error showed itself when at least two
53 dependencies were in a shared location like site-packages, and the74 dependencies were in a shared location like site-packages, and the
54 first one met the "versions" setting. The first dependency would be75 first one met the "versions" setting. The first dependency would be
55 added, but subsequent dependencies from the same location (e.g.,76 added, but subsequent dependencies from the same location (e.g.,
56 site-packages) would use the version of the package found in the77 site-packages) would use the version of the package found in the
57 shared location, ignoring the version setting.78 shared location, ignoring the version setting. This is also now
79 handled correctly.
5880
591.4.3 (2009-12-10)811.4.3 (2009-12-10)
60==================82==================
6183
=== modified file 'bootstrap/bootstrap.py'
--- bootstrap/bootstrap.py 2010-04-29 14:34:36 +0000
+++ bootstrap/bootstrap.py 2010-04-29 14:34:36 +0000
@@ -115,7 +115,7 @@
115115
116options, args = parser.parse_args()116options, args = parser.parse_args()
117117
118# if -c was provided, we push it back into args for buildout' main function118# if -c was provided, we push it back into args for buildout's main function
119if options.config_file is not None:119if options.config_file is not None:
120 args += ['-c', options.config_file]120 args += ['-c', options.config_file]
121121
122122
=== modified file 'dev.py'
--- dev.py 2010-04-29 14:34:36 +0000
+++ dev.py 2010-04-29 14:34:36 +0000
@@ -20,6 +20,7 @@
20"""20"""
2121
22import os, shutil, sys, subprocess, urllib222import os, shutil, sys, subprocess, urllib2
23from optparse import OptionParser
2324
24if sys.platform == 'win32':25if sys.platform == 'win32':
25 def quote(c):26 def quote(c):
@@ -56,10 +57,36 @@
5657
57is_jython = sys.platform.startswith('java')58is_jython = sys.platform.startswith('java')
5859
60setuptools_source = 'http://peak.telecommunity.com/dist/ez_setup.py'
61distribute_source = 'http://python-distribute.org/distribute_setup.py'
62
63usage = '''\
64[DESIRED PYTHON FOR DEVELOPING BUILDOUT] dev.py [options]
65
66Bootstraps buildout itself for development.
67
68This is different from a normal bootstrapping process because the
69buildout egg itself is installed as a develop egg.
70'''
71
72parser = OptionParser(usage=usage)
73parser.add_option("-d", "--distribute",
74 action="store_true", dest="use_distribute", default=False,
75 help="Use Distribute rather than Setuptools.")
76
77options, args = parser.parse_args()
78
79if args:
80 parser.error('This script accepts no arguments other than its options.')
81
82if options.use_distribute:
83 setup_source = distribute_source
84else:
85 setup_source = setuptools_source
86
59for d in 'eggs', 'develop-eggs', 'bin':87for d in 'eggs', 'develop-eggs', 'bin':
60 if not os.path.exists(d):88 if not os.path.exists(d):
61 os.mkdir(d)89 os.mkdir(d)
62
63if os.path.isdir('build'):90if os.path.isdir('build'):
64 shutil.rmtree('build')91 shutil.rmtree('build')
6592
@@ -67,22 +94,32 @@
67 to_reload = False94 to_reload = False
68 import pkg_resources95 import pkg_resources
69 to_reload = True96 to_reload = True
97 if not hasattr(pkg_resources, '_distribute'):
98 raise ImportError
70 import setuptools # A flag. Sometimes pkg_resources is installed alone.99 import setuptools # A flag. Sometimes pkg_resources is installed alone.
71except ImportError:100except ImportError:
101 ez_code = urllib2.urlopen(setup_source).read().replace('\r\n', '\n')
72 ez = {}102 ez = {}
73 exec urllib2.urlopen('http://peak.telecommunity.com/dist/ez_setup.py'103 exec ez_code in ez
74 ).read() in ez104 setup_args = dict(to_dir='eggs', download_delay=0)
75 ez['use_setuptools'](to_dir='eggs', download_delay=0)105 if options.use_distribute:
76106 setup_args['no_fake'] = True
77 import pkg_resources107 ez['use_setuptools'](**setup_args)
78 if to_reload:108 if to_reload:
79 reload(pkg_resources)109 reload(pkg_resources)
110 else:
111 import pkg_resources
112 # This does not (always?) update the default working set. We will
113 # do it.
114 for path in sys.path:
115 if path not in pkg_resources.working_set.entries:
116 pkg_resources.working_set.add_entry(path)
80117
81env = os.environ.copy() # Windows needs yet-to-be-determined values from this.118env = os.environ.copy() # Windows needs yet-to-be-determined values from this.
82env['PYTHONPATH'] = os.path.dirname(pkg_resources.__file__)119env['PYTHONPATH'] = os.path.dirname(pkg_resources.__file__)
83subprocess.Popen(120subprocess.Popen(
84 [sys.executable] +121 [sys.executable] +
85 ['-S', 'setup.py', '-q', 'develop', '-m', '-x', '-d', 'develop-eggs'],122 ['setup.py', '-q', 'develop', '-m', '-x', '-d', 'develop-eggs'],
86 env=env).wait()123 env=env).wait()
87124
88pkg_resources.working_set.add_entry('src')125pkg_resources.working_set.add_entry('src')
89126
=== modified file 'src/zc/buildout/bootstrap.txt'
--- src/zc/buildout/bootstrap.txt 2010-04-29 14:34:36 +0000
+++ src/zc/buildout/bootstrap.txt 2010-04-29 14:34:36 +0000
@@ -47,7 +47,7 @@
47 X...47 X...
48 d zc.buildout-...egg48 d zc.buildout-...egg
4949
50Now trying the `--version` option, that let you define a version for50Now we will try the `--version` option, which lets you define a version for
51`zc.buildout`. If not provided, bootstrap will look for the latest one.51`zc.buildout`. If not provided, bootstrap will look for the latest one.
5252
53Let's try with an unknown version::53Let's try with an unknown version::
5454
=== modified file 'src/zc/buildout/buildout.py'
--- src/zc/buildout/buildout.py 2010-04-29 14:34:36 +0000
+++ src/zc/buildout/buildout.py 2010-04-29 14:34:36 +0000
@@ -128,8 +128,16 @@
128 'parts-directory': 'parts',128 'parts-directory': 'parts',
129 'prefer-final': 'false',129 'prefer-final': 'false',
130 'python': 'buildout',130 'python': 'buildout',
131<<<<<<< TREE
132 'executable': sys.executable,
133 'log-level': 'INFO',
134 'log-format': '',
135=======
136 'relative-paths': 'false',
137 'socket-timeout': '',
131 'unzip': 'false',138 'unzip': 'false',
132 'use-dependency-links': 'true',139 'use-dependency-links': 'true',
140>>>>>>> MERGE-SOURCE
133 }, 'DEFAULT_VALUE')141 }, 'DEFAULT_VALUE')
134142
135143
@@ -397,9 +405,16 @@
397 partsdir = os.path.join(options['parts-directory'], 'buildout')405 partsdir = os.path.join(options['parts-directory'], 'buildout')
398 if not os.path.exists(partsdir):406 if not os.path.exists(partsdir):
399 os.mkdir(partsdir)407 os.mkdir(partsdir)
408 # (Honor the relative-paths option.)
409 relative_paths = options.get('relative-paths', 'false')
410 if relative_paths == 'true':
411 relative_paths = options['directory']
412 else:
413 assert relative_paths == 'false'
414 relative_paths = ''
400 zc.buildout.easy_install.sitepackage_safe_scripts(415 zc.buildout.easy_install.sitepackage_safe_scripts(
401 options['bin-directory'], ws, options['executable'], partsdir,416 options['bin-directory'], ws, options['executable'], partsdir,
402 reqs=['zc.buildout'])417 reqs=['zc.buildout'], relative_paths=relative_paths)
403418
404 init = bootstrap419 init = bootstrap
405420
@@ -830,10 +845,15 @@
830845
831 options = self['buildout']846 options = self['buildout']
832847
848 specs = ['zc.buildout']
849 if zc.buildout.easy_install.is_distribute:
850 specs.append('distribute')
851 else:
852 specs.append('setuptools')
833 ws = zc.buildout.easy_install.install(853 ws = zc.buildout.easy_install.install(
834 [854 [
835 (spec + ' ' + options.get(spec+'-version', '')).strip()855 (spec + ' ' + options.get(spec+'-version', '')).strip()
836 for spec in ('zc.buildout', 'setuptools')856 for spec in specs
837 ],857 ],
838 options['eggs-directory'],858 options['eggs-directory'],
839 links = options.get('find-links', '').split(),859 links = options.get('find-links', '').split(),
840860
=== modified file 'src/zc/buildout/buildout.txt'
--- src/zc/buildout/buildout.txt 2010-04-29 14:34:36 +0000
+++ src/zc/buildout/buildout.txt 2010-04-29 14:34:36 +0000
@@ -767,10 +767,17 @@
767 DEFAULT_VALUE767 DEFAULT_VALUE
768 python= buildout768 python= buildout
769 DEFAULT_VALUE769 DEFAULT_VALUE
770<<<<<<< TREE
771=======
772 relative-paths= false
773 DEFAULT_VALUE
774 socket-timeout=
775 DEFAULT_VALUE
770 unzip= false776 unzip= false
771 DEFAULT_VALUE777 DEFAULT_VALUE
772 use-dependency-links= true778 use-dependency-links= true
773 DEFAULT_VALUE779 DEFAULT_VALUE
780>>>>>>> MERGE-SOURCE
774 <BLANKLINE>781 <BLANKLINE>
775 [data-dir]782 [data-dir]
776 path= foo bins783 path= foo bins
@@ -2241,8 +2248,13 @@
2241 parts-directory = /sample-buildout/parts2248 parts-directory = /sample-buildout/parts
2242 prefer-final = false2249 prefer-final = false
2243 python = buildout2250 python = buildout
2251<<<<<<< TREE
2252=======
2253 relative-paths = false
2254 socket-timeout =
2244 unzip = false2255 unzip = false
2245 use-dependency-links = true2256 use-dependency-links = true
2257>>>>>>> MERGE-SOURCE
2246 verbosity = 202258 verbosity = 20
2247 <BLANKLINE>2259 <BLANKLINE>
22482260
@@ -2250,37 +2262,6 @@
2250command-line assignments. We've discussed most of these options2262command-line assignments. We've discussed most of these options
2251already, but let's review them and touch on some we haven't discussed:2263already, but let's review them and touch on some we haven't discussed:
22522264
2253allow-hosts
2254 On some environments the links visited by `zc.buildout` can be forbidden by
2255 paranoid firewalls. These URLs might be in the chain of links visited by
2256 `zc.buildout` as defined by buildout's `find-links` option, or as defined
2257 by various eggs in their `url`, `download_url`, `dependency_links` metadata.
2258
2259 The fact that package_index works like a spider and might visit links and
2260 go to other locations makes this even harder.
2261
2262 The `allow-hosts` option provides a way to prevent this, and
2263 works exactly like the one provided in `easy_install`.
2264
2265 You can provide a list of allowed host, together with wildcards::
2266
2267 [buildout]
2268 ...
2269
2270 allow-hosts =
2271 *.python.org
2272 example.com
2273
2274 All URLs that does not match these hosts will not be visited.
2275
2276allow-picked-versions
2277 By default, the buildout will choose the best match for a given requirement
2278 if the requirement is not specified precisely (for instance, using the
2279 "versions" option. This behavior corresponds to the
2280 "allow-picked-versions" being set to its default value, "true". If
2281 "allow-picked-versions" is "false," instead of picking the best match,
2282 buildout will raise an error. This helps enforce repeatability.
2283
2284bin-directory2265bin-directory
2285 The directory path where scripts are written. This can be a2266 The directory path where scripts are written. This can be a
2286 relative path, which is interpreted relative to the directory2267 relative path, which is interpreted relative to the directory
@@ -2305,47 +2286,6 @@
2305 The Python executable used to run the buildout. See the python2286 The Python executable used to run the buildout. See the python
2306 option below.2287 option below.
23072288
2308find-links
2309 You can specify more locations to search for distributions using the
2310 `find-links` option. All locations specified will be searched for
2311 distributions along with the package index as described before.
2312
2313 Locations can be urls::
2314
2315 [buildout]
2316 ...
2317 find-links = http://download.zope.org/distribution/
2318
2319 They can also be directories on disk::
2320
2321 [buildout]
2322 ...
2323 find-links = /some/path
2324
2325 Finally, they can also be direct paths to distributions::
2326
2327 [buildout]
2328 ...
2329 find-links = /some/path/someegg-1.0.0-py2.3.egg
2330
2331 Any number of locations can be specified in the `find-links` option::
2332
2333 [buildout]
2334 ...
2335 find-links =
2336 http://download.zope.org/distribution/
2337 /some/otherpath
2338 /some/path/someegg-1.0.0-py2.3.egg
2339
2340install-from-cache
2341 A download cache can be used as the basis of application source releases.
2342 In an application source release, we want to distribute an application that
2343 can be built without making any network accesses. In this case, we
2344 distribute a buildout with download cache and tell the buildout to install
2345 from the download cache only, without making network accesses. The
2346 buildout install-from-cache option can be used to signal that packages
2347 should be installed only from the download cache.
2348
2349installed2289installed
2350 The file path where information about the results of the previous2290 The file path where information about the results of the previous
2351 buildout run is written. This can be a relative path, which is2291 buildout run is written. This can be a relative path, which is
@@ -2359,51 +2299,12 @@
2359log-level2299log-level
2360 The log level before verbosity adjustment2300 The log level before verbosity adjustment
23612301
2362newest
2363 By default buildout and recipes will try to find the newest versions of
2364 distributions needed to satisfy requirements. This can be very time
2365 consuming, especially when incrementally working on setting up a buildout
2366 or working on a recipe. The buildout "newest" option can be used to to
2367 suppress this. If the "newest" option is set to false, then new
2368 distributions won't be sought if an installed distribution meets
2369 requirements. The "newest" option can also be set to false using the -N
2370 command-line option. See also the "offline" option.
2371
2372offline
2373 The "offline" option goes a bit further than the "newest" option. If the
2374 buildout "offline" option is given a value of "true", the buildout and
2375 recipes that are aware of the option will avoid doing network access. This
2376 is handy when running the buildout when not connected to the internet. It
2377 also makes buildouts run much faster. This option is typically set using
2378 the buildout -o option.
2379
2380parts2302parts
2381 A white space separated list of parts to be installed.2303 A white space separated list of parts to be installed.
23822304
2383parts-directory2305parts-directory
2384 A working directory that parts can used to store data.2306 A working directory that parts can used to store data.
23852307
2386prefer-final
2387 Currently, when searching for new releases, the newest available
2388 release is used. This isn't usually ideal, as you may get a
2389 development release or alpha releases not ready to be widely used.
2390 You can request that final releases be preferred using the prefer
2391 final option in the buildout section::
2392
2393 [buildout]
2394 ...
2395 prefer-final = true
2396
2397 When the prefer-final option is set to true, then when searching for
2398 new releases, final releases are preferred. If there are final
2399 releases that satisfy distribution requirements, then those releases
2400 are used even if newer non-final releases are available. The buildout
2401 prefer-final option can be used to override this behavior.
2402
2403 In buildout version 2, final releases will be preferred by default.
2404 You will then need to use a false value for prefer-final to get the
2405 newest releases.
2406
2407python2308python
2408 The name of a section containing information about the default2309 The name of a section containing information about the default
2409 Python interpreter. Recipes that need a installation2310 Python interpreter. Recipes that need a installation
@@ -2414,6 +2315,13 @@
2414 Python executable. By default, the buildout section defines the2315 Python executable. By default, the buildout section defines the
2415 default Python as the Python used to run the buildout.2316 default Python as the Python used to run the buildout.
24162317
2318relative-paths
2319 The paths generated by zc.buildout are absolute by default, and this
2320 option is ``false``. However, if you set this value to be ``true``,
2321 bin/buildout will be generated with code that makes the paths relative.
2322 Some recipes, such as zc.recipe.egg and z3c.recipe.scripts, honor this
2323 value as well.
2324
2417unzip2325unzip
2418 By default, zc.buildout doesn't unzip zip-safe eggs ("unzip = false").2326 By default, zc.buildout doesn't unzip zip-safe eggs ("unzip = false").
2419 This follows the policy followed by setuptools itself. Experience shows2327 This follows the policy followed by setuptools itself. Experience shows
@@ -2480,8 +2388,56 @@
2480directory if the original buildout had develop eggs for either2388directory if the original buildout had develop eggs for either
2481buildout or setuptools.)2389buildout or setuptools.)
24822390
2483Note that the buildout script was installed but not run. To run2391If relative-paths is ``true``, the buildout script uses relative paths.
2484the buildout, we'd have to run the installed buildout script.2392
2393 >>> write(sample_bootstrapped, 'setup.cfg',
2394 ... '''
2395 ... [buildout]
2396 ... relative-paths = true
2397 ... parts =
2398 ... ''')
2399
2400 >>> print system(buildout
2401 ... +' -c'+os.path.join(sample_bootstrapped, 'setup.cfg')
2402 ... +' bootstrap'),
2403 Generated script '/sample-bootstrapped/bin/buildout'.
2404
2405 >>> buildout_script = join(sample_bootstrapped, 'bin', 'buildout')
2406 >>> import sys
2407 >>> if sys.platform.startswith('win'):
2408 ... buildout_script += '-script.py'
2409 >>> print open(buildout_script).read() # doctest: +ELLIPSIS
2410 #!... -S
2411 <BLANKLINE>
2412 import os
2413 <BLANKLINE>
2414 join = os.path.join
2415 base = os.path.dirname(os.path.abspath(os.path.realpath(__file__)))
2416 base = os.path.dirname(base)
2417 <BLANKLINE>
2418 import sys
2419 sys.path[0:0] = [
2420 join(base, 'parts/buildout'),
2421 ]
2422 <BLANKLINE>
2423 <BLANKLINE>
2424 import os
2425 path = sys.path[0]
2426 if os.environ.get('PYTHONPATH'):
2427 path = os.pathsep.join([path, os.environ['PYTHONPATH']])
2428 os.environ['PYTHONPATH'] = path
2429 import site # imports custom buildout-generated site.py
2430 <BLANKLINE>
2431 import zc.buildout.buildout
2432 <BLANKLINE>
2433 if __name__ == '__main__':
2434 zc.buildout.buildout.main()
2435 <BLANKLINE>
2436
2437
2438Note that, in the above two examples, the buildout script was installed
2439but not run. To run the buildout, we'd have to run the installed
2440buildout script.
24852441
2486If we have an existing buildout that already has a buildout.cfg, we'll2442If we have an existing buildout that already has a buildout.cfg, we'll
2487normally use the bootstrap command instead of init. It will complain2443normally use the bootstrap command instead of init. It will complain
@@ -2512,6 +2468,48 @@
2512 Generated script '/sample-bootstrapped2/bin/buildout'.2468 Generated script '/sample-bootstrapped2/bin/buildout'.
25132469
25142470
2471Newest and Offline Modes
2472------------------------
2473
2474By default buildout and recipes will try to find the newest versions
2475of distributions needed to satisfy requirements. This can be very
2476time consuming, especially when incrementally working on setting up a
2477buildout or working on a recipe. The buildout newest option can be
2478used to to suppress this. If the newest option is set to false, then
2479new distributions won't be sought if an installed distribution meets
2480requirements. The newest option can be set to false using the -N
2481command-line option.
2482
2483The offline option goes a bit further. If the buildout offline option
2484is given a value of "true", the buildout and recipes that are aware of
2485the option will avoid doing network access. This is handy when
2486running the buildout when not connected to the internet. It also
2487makes buildouts run much faster. This option is typically set using
2488the buildout -o option.
2489
2490Preferring Final Releases
2491-------------------------
2492
2493Currently, when searching for new releases, the newest available
2494release is used. This isn't usually ideal, as you may get a
2495development release or alpha releases not ready to be widely used.
2496You can request that final releases be preferred using the prefer
2497final option in the buildout section::
2498
2499 [buildout]
2500 ...
2501 prefer-final = true
2502
2503When the prefer-final option is set to true, then when searching for
2504new releases, final releases are preferred. If there are final
2505releases that satisfy distribution requirements, then those releases
2506are used even if newer non-final releases are available. The buildout
2507prefer-final option can be used to override this behavior.
2508
2509In buildout version 2, final releases will be preferred by default.
2510You will then need to use a false value for prefer-final to get the
2511newest releases.
2512
2515Finding distributions2513Finding distributions
2516---------------------2514---------------------
25172515
@@ -2530,7 +2528,49 @@
2530requirements of the buildout will always be used.2528requirements of the buildout will always be used.
25312529
2532You can also specify more locations to search for distributions using2530You can also specify more locations to search for distributions using
2533the `find-links` option. See its description above.2531the `find-links` option. All locations specified will be searched for
2532distributions along with the package index as described before.
2533
2534Locations can be urls::
2535
2536 [buildout]
2537 ...
2538 find-links = http://download.zope.org/distribution/
2539
2540They can also be directories on disk::
2541
2542 [buildout]
2543 ...
2544 find-links = /some/path
2545
2546Finally, they can also be direct paths to distributions::
2547
2548 [buildout]
2549 ...
2550 find-links = /some/path/someegg-1.0.0-py2.3.egg
2551
2552Any number of locations can be specified in the `find-links` option::
2553
2554 [buildout]
2555 ...
2556 find-links =
2557 http://download.zope.org/distribution/
2558 /some/otherpath
2559 /some/path/someegg-1.0.0-py2.3.egg
2560
2561Dependency links
2562----------------
2563
2564By default buildout will obey the setuptools dependency_links metadata
2565when it looks for dependencies. This behavior can be controlled with
2566the use-dependency-links buildout option::
2567
2568 [buildout]
2569 ...
2570 use-dependency-links = false
2571
2572The option defaults to true. If you set it to false, then dependency
2573links are only looked for in the locations specified by find-links.
25342574
2535Controlling the installation database2575Controlling the installation database
2536-------------------------------------2576-------------------------------------
@@ -2692,11 +2732,37 @@
2692 Develop: '/sample-bootstrapped/demo'2732 Develop: '/sample-bootstrapped/demo'
2693 unload ['buildout']2733 unload ['buildout']
26942734
2735Allow hosts
2736-----------
2737
2738On some environments the links visited by `zc.buildout` can be forbidden
2739by paranoiac firewalls. These URL might be on the chain of links
2740visited by `zc.buildout` wheter they are defined in the `find-links` option,
2741wheter they are defined by various eggs in their `url`, `download_url`,
2742`dependency_links` metadata.
2743
2744It is even harder to track that package_index works like a spider and
2745might visit links and go to other location.
2746
2747The `allow-hosts` option provides a way to prevent this, and
2748works exactly like the one provided in `easy_install`.
2749
2750You can provide a list of allowed host, together with wildcards::
2751
2752 [buildout]
2753 ...
2754
2755 allow-hosts =
2756 *.python.org
2757 example.com
2758
2759All urls that does not match these hosts will not be visited.
2760
2695.. [#future_recipe_methods] In the future, additional methods may be2761.. [#future_recipe_methods] In the future, additional methods may be
2696 added. Older recipes with fewer methods will still be2762 added. Older recipes with fewer methods will still be
2697 supported.2763 supported.
26982764
2699.. [#packaging_info] If we wanted to create a distribution from this2765.. [#packaging_info] If we wanted to create a distribution from this
2700 package, we would need to specify much more information. See the2766 package, we would need specify much more information. See the
2701 `setuptools documentation2767 `setuptools documentation
2702 <http://peak.telecommunity.com/DevCenter/setuptools>`_.2768 <http://peak.telecommunity.com/DevCenter/setuptools>`_.
27032769
=== modified file 'src/zc/buildout/easy_install.py'
--- src/zc/buildout/easy_install.py 2010-04-29 14:34:36 +0000
+++ src/zc/buildout/easy_install.py 2010-04-29 14:34:36 +0000
@@ -51,6 +51,8 @@
5151
52is_win32 = sys.platform == 'win32'52is_win32 = sys.platform == 'win32'
53is_jython = sys.platform.startswith('java')53is_jython = sys.platform.startswith('java')
54is_distribute = (
55 pkg_resources.Requirement.parse('setuptools').key=='distribute')
5456
55if is_jython:57if is_jython:
56 import java.lang.System58 import java.lang.System
@@ -802,6 +804,8 @@
802804
803805
804 def _constrain(self, requirement):806 def _constrain(self, requirement):
807 if is_distribute and requirement.key == 'setuptools':
808 requirement = pkg_resources.Requirement.parse('distribute')
805 version = self._versions.get(requirement.project_name)809 version = self._versions.get(requirement.project_name)
806 if version:810 if version:
807 if version not in requirement:811 if version not in requirement:
@@ -853,30 +857,6 @@
853 # Note that we don't use the existing environment, because we want857 # Note that we don't use the existing environment, because we want
854 # to look for new eggs unless what we have is the best that858 # to look for new eggs unless what we have is the best that
855 # matches the requirement.859 # matches the requirement.
856<<<<<<< TREE
857 while 1:
858 try:
859 ws.resolve(requirements)
860 except pkg_resources.DistributionNotFound, err:
861 [requirement] = err
862 requirement = self._constrain(requirement)
863 if destination:
864 logger.debug('Getting required %r', str(requirement))
865 else:
866 logger.debug('Adding required %r', str(requirement))
867 _log_requirement(ws, requirement)
868
869 for dist in self._get_dist(requirement, ws, self._always_unzip
870 ):
871
872 ws.add(dist)
873 self._maybe_add_setuptools(ws, dist)
874 except pkg_resources.VersionConflict, err:
875 raise VersionConflict(err, ws)
876 else:
877 break
878
879=======
880 env = pkg_resources.Environment(ws.entries)860 env = pkg_resources.Environment(ws.entries)
881 while requirements:861 while requirements:
882 # Process dependencies breadth-first.862 # Process dependencies breadth-first.
@@ -911,7 +891,6 @@
911 processed[req] = True891 processed[req] = True
912 if dist.location in self._site_packages:892 if dist.location in self._site_packages:
913 logger.debug('Egg from site-packages: %s', dist)893 logger.debug('Egg from site-packages: %s', dist)
914>>>>>>> MERGE-SOURCE
915 return ws894 return ws
916895
917 def build(self, spec, build_ext):896 def build(self, spec, build_ext):
@@ -1224,12 +1203,12 @@
1224 return generated1203 return generated
12251204
1226_script_initialization_template = '''1205_script_initialization_template = '''
1227import site # imports custom buildout-generated site.py
1228import os1206import os
1229path = %(site_py_dest)r1207path = sys.path[0]
1230if os.environ.get('PYTHONPATH'):1208if os.environ.get('PYTHONPATH'):
1231 path = os.pathsep.join([path, os.environ['PYTHONPATH']])1209 path = os.pathsep.join([path, os.environ['PYTHONPATH']])
1232os.environ['PYTHONPATH'] = path1210os.environ['PYTHONPATH'] = path
1211import site # imports custom buildout-generated site.py
1233%(script_initialization)s'''1212%(script_initialization)s'''
12341213
1235# Utilities for the script generation functions.1214# Utilities for the script generation functions.
@@ -1509,7 +1488,7 @@
1509 - executable is a path to the desired Python executable.1488 - executable is a path to the desired Python executable.
1510 - name is the name of the (pure, not C) Python module.1489 - name is the name of the (pure, not C) Python module.
1511 """1490 """
1512 cmd = [executable, "-c",1491 cmd = [executable, "-Sc",
1513 "import imp; "1492 "import imp; "
1514 "fp, path, desc = imp.find_module(%r); "1493 "fp, path, desc = imp.find_module(%r); "
1515 "fp.close; "1494 "fp.close; "
@@ -1632,6 +1611,7 @@
1632 pkg_resources.working_set.add_entry(sitedir)'''1611 pkg_resources.working_set.add_entry(sitedir)'''
16331612
1634original_path_snippet = '''1613original_path_snippet = '''
1614 sys.__egginsert = len(buildout_paths) # Support distribute.
1635 original_paths = [1615 original_paths = [
1636 %s1616 %s
1637 ]1617 ]
16381618
=== modified file 'src/zc/buildout/easy_install.txt'
--- src/zc/buildout/easy_install.txt 2010-04-29 14:34:36 +0000
+++ src/zc/buildout/easy_install.txt 2010-04-29 14:34:36 +0000
@@ -222,7 +222,9 @@
222 d other-1.0-py2.4.egg222 d other-1.0-py2.4.egg
223223
224We can request that eggs be unzipped even if they are zip safe. This224We can request that eggs be unzipped even if they are zip safe. This
225can be useful when debugging.225can be useful when debugging. (Note that Distribute will unzip eggs by
226default, so if you are using Distribute, most or all eggs will already be
227unzipped without this flag.)
226228
227 >>> rmdir(dest)229 >>> rmdir(dest)
228 >>> dest = tmpdir('sample-install')230 >>> dest = tmpdir('sample-install')
@@ -1284,6 +1286,7 @@
1284 if not sitedircase in known_paths and os.path.exists(sitedir):1286 if not sitedircase in known_paths and os.path.exists(sitedir):
1285 sys.path.append(sitedir)1287 sys.path.append(sitedir)
1286 known_paths.add(sitedircase)1288 known_paths.add(sitedircase)
1289 sys.__egginsert = len(buildout_paths) # Support distribute.
1287 original_paths = [1290 original_paths = [
1288 ...1291 ...
1289 ]1292 ]
@@ -1360,6 +1363,7 @@
1360 sys.path.append(sitedir)1363 sys.path.append(sitedir)
1361 known_paths.add(sitedircase)1364 known_paths.add(sitedircase)
1362 pkg_resources.working_set.add_entry(sitedir)1365 pkg_resources.working_set.add_entry(sitedir)
1366 sys.__egginsert = len(buildout_paths) # Support distribute.
1363 original_paths = [1367 original_paths = [
1364 ...1368 ...
1365 ]1369 ]
@@ -1423,6 +1427,7 @@
1423 sys.path.append(sitedir)1427 sys.path.append(sitedir)
1424 known_paths.add(sitedircase)1428 known_paths.add(sitedircase)
1425 pkg_resources.working_set.add_entry(sitedir)1429 pkg_resources.working_set.add_entry(sitedir)
1430 sys.__egginsert = len(buildout_paths) # Support distribute.
1426 original_paths = [1431 original_paths = [
1427 ...1432 ...
1428 ]1433 ]
@@ -1498,12 +1503,12 @@
1498 ]1503 ]
1499 <BLANKLINE>1504 <BLANKLINE>
1500 <BLANKLINE>1505 <BLANKLINE>
1501 import site # imports custom buildout-generated site.py
1502 import os1506 import os
1503 path = '/interpreter/parts/interpreter'1507 path = sys.path[0]
1504 if os.environ.get('PYTHONPATH'):1508 if os.environ.get('PYTHONPATH'):
1505 path = os.pathsep.join([path, os.environ['PYTHONPATH']])1509 path = os.pathsep.join([path, os.environ['PYTHONPATH']])
1506 os.environ['PYTHONPATH'] = path1510 os.environ['PYTHONPATH'] = path
1511 import site # imports custom buildout-generated site.py
1507 <BLANKLINE>1512 <BLANKLINE>
1508 import eggrecipedemo1513 import eggrecipedemo
1509 <BLANKLINE>1514 <BLANKLINE>
@@ -1542,12 +1547,12 @@
1542 '/interpreter/parts/interpreter',1547 '/interpreter/parts/interpreter',
1543 ]1548 ]
1544 <BLANKLINE>1549 <BLANKLINE>
1545 import site # imports custom buildout-generated site.py
1546 import os1550 import os
1547 path = '/interpreter/parts/interpreter'1551 path = sys.path[0]
1548 if os.environ.get('PYTHONPATH'):1552 if os.environ.get('PYTHONPATH'):
1549 path = os.pathsep.join([path, os.environ['PYTHONPATH']])1553 path = os.pathsep.join([path, os.environ['PYTHONPATH']])
1550 os.environ['PYTHONPATH'] = path1554 os.environ['PYTHONPATH'] = path
1555 import site # imports custom buildout-generated site.py
1551 import os1556 import os
1552 os.chdir("foo")1557 os.chdir("foo")
1553 <BLANKLINE>1558 <BLANKLINE>
15541559
=== modified file 'src/zc/buildout/tests.py'
--- src/zc/buildout/tests.py 2010-04-29 14:34:36 +0000
+++ src/zc/buildout/tests.py 2010-04-29 14:34:36 +0000
@@ -864,7 +864,8 @@
864 - z3c.recipe.scripts.egg-link864 - z3c.recipe.scripts.egg-link
865 - zc.recipe.egg.egg-link865 - zc.recipe.egg.egg-link
866866
867 >>> ls('eggs') # doctest: +ELLIPSIS867 >>> print 'START ->'; ls('eggs') # doctest: +ELLIPSIS
868 START...
868 - foox-0.0.0-py2.4.egg869 - foox-0.0.0-py2.4.egg
869 ...870 ...
870871
@@ -3103,6 +3104,13 @@
3103 >>> write('foo.py', '')3104 >>> write('foo.py', '')
3104 >>> _ = system(buildout+' setup . sdist')3105 >>> _ = system(buildout+' setup . sdist')
31053106
3107 >>> if zc.buildout.easy_install.is_distribute:
3108 ... distribute_version = 'distribute = %s' % (
3109 ... pkg_resources.working_set.find(
3110 ... pkg_resources.Requirement.parse('distribute')).version,)
3111 ... else:
3112 ... distribute_version = ''
3113 ...
3106 >>> write('buildout.cfg',3114 >>> write('buildout.cfg',
3107 ... '''3115 ... '''
3108 ... [buildout]3116 ... [buildout]
@@ -3114,12 +3122,14 @@
3114 ... [versions]3122 ... [versions]
3115 ... setuptools = %s3123 ... setuptools = %s
3116 ... foo = 13124 ... foo = 1
3125 ... %s
3117 ...3126 ...
3118 ... [foo]3127 ... [foo]
3119 ... recipe = zc.recipe.egg3128 ... recipe = zc.recipe.egg
3120 ... eggs = foo3129 ... eggs = foo
3121 ... ''' % pkg_resources.working_set.find(3130 ... ''' % (pkg_resources.working_set.find(
3122 ... pkg_resources.Requirement.parse('setuptools')).version)3131 ... pkg_resources.Requirement.parse('setuptools')).version,
3132 ... distribute_version))
31233133
3124 >>> print system(buildout),3134 >>> print system(buildout),
3125 Installing foo.3135 Installing foo.
@@ -3623,11 +3633,13 @@
36233633
3624 # now let's make the new releases3634 # now let's make the new releases
3625 makeNewRelease('zc.buildout', ws, new_releases)3635 makeNewRelease('zc.buildout', ws, new_releases)
3626 makeNewRelease('setuptools', ws, new_releases)
3627
3628 os.mkdir(os.path.join(new_releases, 'zc.buildout'))3636 os.mkdir(os.path.join(new_releases, 'zc.buildout'))
3629 os.mkdir(os.path.join(new_releases, 'setuptools'))3637 if zc.buildout.easy_install.is_distribute:
36303638 makeNewRelease('distribute', ws, new_releases)
3639 os.mkdir(os.path.join(new_releases, 'distribute'))
3640 else:
3641 makeNewRelease('setuptools', ws, new_releases)
3642 os.mkdir(os.path.join(new_releases, 'setuptools'))
36313643
36323644
3633normalize_bang = (3645normalize_bang = (
@@ -3651,7 +3663,8 @@
3651 '__buildout_signature__ = recipes-SSSSSSSSSSS'),3663 '__buildout_signature__ = recipes-SSSSSSSSSSS'),
3652 (re.compile('executable = [\S ]+python\S*', re.I),3664 (re.compile('executable = [\S ]+python\S*', re.I),
3653 'executable = python'),3665 'executable = python'),
3654 (re.compile('[-d] setuptools-\S+[.]egg'), 'setuptools.egg'),3666 (re.compile('[-d] (setuptools|distribute)-\S+[.]egg'),
3667 'setuptools.egg'),
3655 (re.compile('zc.buildout(-\S+)?[.]egg(-link)?'),3668 (re.compile('zc.buildout(-\S+)?[.]egg(-link)?'),
3656 'zc.buildout.egg'),3669 'zc.buildout.egg'),
3657 (re.compile('creating \S*setup.cfg'), 'creating setup.cfg'),3670 (re.compile('creating \S*setup.cfg'), 'creating setup.cfg'),
@@ -3666,6 +3679,7 @@
3666 r'when that file already exists: '),3679 r'when that file already exists: '),
3667 '[Errno 17] File exists: '3680 '[Errno 17] File exists: '
3668 ),3681 ),
3682 (re.compile('distribute'), 'setuptools'),
3669 ])3683 ])
3670 ),3684 ),
3671 doctest.DocFileSuite(3685 doctest.DocFileSuite(
@@ -3695,9 +3709,18 @@
3695 (re.compile('(zc.buildout|setuptools)-\d+[.]\d+\S*'3709 (re.compile('(zc.buildout|setuptools)-\d+[.]\d+\S*'
3696 '-py\d.\d.egg'),3710 '-py\d.\d.egg'),
3697 '\\1.egg'),3711 '\\1.egg'),
3712 (re.compile('distribute-\d+[.]\d+\S*'
3713 '-py\d.\d.egg'),
3714 'setuptools.egg'),
3698 (re.compile('(zc.buildout|setuptools)( version)? \d+[.]\d+\S*'),3715 (re.compile('(zc.buildout|setuptools)( version)? \d+[.]\d+\S*'),
3699 '\\1 V.V'),3716 '\\1 V.V'),
3700 (re.compile('[-d] setuptools'), '- setuptools'),3717 (re.compile('distribute( version)? \d+[.]\d+\S*'),
3718 'setuptools V.V'),
3719 (re.compile('[-d] (setuptools|distribute)'), '- setuptools'),
3720 (re.compile('distribute'), 'setuptools'),
3721 (re.compile("\nUnused options for buildout: "
3722 "'(distribute|setuptools)\-version'\."),
3723 '')
3701 ])3724 ])
3702 ),3725 ),
37033726
@@ -3713,17 +3736,17 @@
3713 zc.buildout.testing.normalize_egg_py,3736 zc.buildout.testing.normalize_egg_py,
3714 normalize_bang,3737 normalize_bang,
3715 (re.compile('extdemo[.]pyd'), 'extdemo.so'),3738 (re.compile('extdemo[.]pyd'), 'extdemo.so'),
3716 (re.compile('[-d] setuptools-\S+[.]egg'), 'setuptools.egg'),3739 (re.compile('[-d] (setuptools|distribute)-\S+[.]egg'),
3740 'setuptools.egg'),
3717 (re.compile(r'\\[\\]?'), '/'),3741 (re.compile(r'\\[\\]?'), '/'),
3718<<<<<<< TREE
3719 (re.compile(r'\#!\S+\bpython\S*'), '#!/usr/bin/python'),
3720=======
3721 (re.compile(r'\#!\S+\bpython\S*'), '#!/usr/bin/python'),3742 (re.compile(r'\#!\S+\bpython\S*'), '#!/usr/bin/python'),
3722 # Normalize generate_script's Windows interpreter to UNIX:3743 # Normalize generate_script's Windows interpreter to UNIX:
3723 (re.compile(r'\nimport subprocess\n'), '\n'),3744 (re.compile(r'\nimport subprocess\n'), '\n'),
3724 (re.compile('subprocess\\.call\\(argv, env=environ\\)'),3745 (re.compile('subprocess\\.call\\(argv, env=environ\\)'),
3725 'os.execve(sys.executable, argv, environ)'),3746 'os.execve(sys.executable, argv, environ)'),
3726>>>>>>> MERGE-SOURCE3747 (re.compile('distribute'), 'setuptools'),
3748 # Distribute unzips eggs by default.
3749 (re.compile('\- demoneeded'), 'd demoneeded'),
3727 ]+(sys.version_info < (2, 5) and [3750 ]+(sys.version_info < (2, 5) and [
3728 (re.compile('.*No module named runpy.*', re.S), ''),3751 (re.compile('.*No module named runpy.*', re.S), ''),
3729 (re.compile('.*usage: pdb.py scriptfile .*', re.S), ''),3752 (re.compile('.*usage: pdb.py scriptfile .*', re.S), ''),
@@ -3755,7 +3778,7 @@
3755 zc.buildout.testing.normalize_egg_py,3778 zc.buildout.testing.normalize_egg_py,
3756 (re.compile("buildout: Running \S*setup.py"),3779 (re.compile("buildout: Running \S*setup.py"),
3757 'buildout: Running setup.py'),3780 'buildout: Running setup.py'),
3758 (re.compile('setuptools-\S+-'),3781 (re.compile('(setuptools|distribute)-\S+-'),
3759 'setuptools.egg'),3782 'setuptools.egg'),
3760 (re.compile('zc.buildout-\S+-'),3783 (re.compile('zc.buildout-\S+-'),
3761 'zc.buildout.egg'),3784 'zc.buildout.egg'),
@@ -3763,7 +3786,7 @@
3763 'File "one.py"'),3786 'File "one.py"'),
3764 (re.compile(r'We have a develop egg: (\S+) (\S+)'),3787 (re.compile(r'We have a develop egg: (\S+) (\S+)'),
3765 r'We have a develop egg: \1 V'),3788 r'We have a develop egg: \1 V'),
3766 (re.compile('Picked: setuptools = \S+'),3789 (re.compile('Picked: (setuptools|distribute) = \S+'),
3767 'Picked: setuptools = V'),3790 'Picked: setuptools = V'),
3768 (re.compile(r'\\[\\]?'), '/'),3791 (re.compile(r'\\[\\]?'), '/'),
3769 (re.compile(3792 (re.compile(
@@ -3774,6 +3797,9 @@
3774 # for bug_92891_bootstrap_crashes_with_egg_recipe_in_buildout_section3797 # for bug_92891_bootstrap_crashes_with_egg_recipe_in_buildout_section
3775 (re.compile(r"Unused options for buildout: 'eggs' 'scripts'\."),3798 (re.compile(r"Unused options for buildout: 'eggs' 'scripts'\."),
3776 "Unused options for buildout: 'scripts' 'eggs'."),3799 "Unused options for buildout: 'scripts' 'eggs'."),
3800 (re.compile('distribute'), 'setuptools'),
3801 # Distribute unzips eggs by default.
3802 (re.compile('\- demoneeded'), 'd demoneeded'),
3777 ]),3803 ]),
3778 ),3804 ),
3779 zc.buildout.testselectingpython.test_suite(),3805 zc.buildout.testselectingpython.test_suite(),
37803806
=== modified file 'src/zc/buildout/update.txt'
--- src/zc/buildout/update.txt 2010-04-29 14:34:36 +0000
+++ src/zc/buildout/update.txt 2010-04-29 14:34:36 +0000
@@ -100,8 +100,8 @@
100 ...100 ...
101101
102Now, let's recreate the sample buildout. If we specify constraints on102Now, let's recreate the sample buildout. If we specify constraints on
103the versions of zc.buildout and setuptools to use, running the103the versions of zc.buildout and setuptools (or distribute) to use,
104buildout will install earlier versions of these packages:104running the buildout will install earlier versions of these packages:
105105
106 >>> write(sample_buildout, 'buildout.cfg',106 >>> write(sample_buildout, 'buildout.cfg',
107 ... """107 ... """
@@ -112,6 +112,7 @@
112 ... develop = showversions112 ... develop = showversions
113 ... zc.buildout-version = < 99113 ... zc.buildout-version = < 99
114 ... setuptools-version = < 99114 ... setuptools-version = < 99
115 ... distribute-version = < 99
115 ...116 ...
116 ... [show-versions]117 ... [show-versions]
117 ... recipe = showversions118 ... recipe = showversions
118119
=== modified file 'z3c.recipe.scripts_/src/z3c/recipe/scripts/tests.py'
--- z3c.recipe.scripts_/src/z3c/recipe/scripts/tests.py 2010-04-29 14:34:36 +0000
+++ z3c.recipe.scripts_/src/z3c/recipe/scripts/tests.py 2010-04-29 14:34:36 +0000
@@ -423,8 +423,8 @@
423 zc.buildout.tests.normalize_bang,423 zc.buildout.tests.normalize_bang,
424 (re.compile(r'zc.buildout(-\S+)?[.]egg(-link)?'),424 (re.compile(r'zc.buildout(-\S+)?[.]egg(-link)?'),
425 'zc.buildout.egg'),425 'zc.buildout.egg'),
426 (re.compile('[-d] setuptools-[^-]+-'), 'setuptools-X-'),426 (re.compile('[-d] (setuptools|distribute)-[^-]+-'), 'setuptools-X-'),
427 (re.compile(r'setuptools-[\w.]+-py'), 'setuptools-X-py'),427 (re.compile(r'(setuptools|distribute)-[\w.]+-py'), 'setuptools-X-py'),
428 (re.compile(r'eggs\\\\demo'), 'eggs/demo'),428 (re.compile(r'eggs\\\\demo'), 'eggs/demo'),
429 (re.compile(r'[a-zA-Z]:\\\\foo\\\\bar'), '/foo/bar'),429 (re.compile(r'[a-zA-Z]:\\\\foo\\\\bar'), '/foo/bar'),
430 (re.compile(r'\#!\S+\bpython\S*'), '#!/usr/bin/python'),430 (re.compile(r'\#!\S+\bpython\S*'), '#!/usr/bin/python'),
@@ -432,6 +432,7 @@
432 (re.compile(r'\nimport subprocess\n'), '\n'),432 (re.compile(r'\nimport subprocess\n'), '\n'),
433 (re.compile('subprocess\\.call\\(argv, env=environ\\)'),433 (re.compile('subprocess\\.call\\(argv, env=environ\\)'),
434 'os.execve(sys.executable, argv, environ)'),434 'os.execve(sys.executable, argv, environ)'),
435 (re.compile('distribute'), 'setuptools'),
435 ])436 ])
436 ),437 ),
437 doctest.DocTestSuite(438 doctest.DocTestSuite(
438439
=== modified file 'zc.recipe.egg_/src/zc/recipe/egg/tests.py'
--- zc.recipe.egg_/src/zc/recipe/egg/tests.py 2010-04-29 14:34:36 +0000
+++ zc.recipe.egg_/src/zc/recipe/egg/tests.py 2010-04-29 14:34:36 +0000
@@ -50,9 +50,12 @@
50 zc.buildout.tests.normalize_bang,50 zc.buildout.tests.normalize_bang,
51 (re.compile('zc.buildout(-\S+)?[.]egg(-link)?'),51 (re.compile('zc.buildout(-\S+)?[.]egg(-link)?'),
52 'zc.buildout.egg'),52 'zc.buildout.egg'),
53 (re.compile('[-d] setuptools-[^-]+-'), 'setuptools-X-'),53 (re.compile('[-d] (setuptools|distribute)-[^-]+-'),
54 'setuptools-X-'),
54 (re.compile(r'eggs\\\\demo'), 'eggs/demo'),55 (re.compile(r'eggs\\\\demo'), 'eggs/demo'),
55 (re.compile(r'[a-zA-Z]:\\\\foo\\\\bar'), '/foo/bar'),56 (re.compile(r'[a-zA-Z]:\\\\foo\\\\bar'), '/foo/bar'),
57 # Distribute unzips eggs by default.
58 (re.compile('\- demoneeded'), 'd demoneeded'),
56 ])59 ])
57 ),60 ),
58 doctest.DocFileSuite(61 doctest.DocFileSuite(
@@ -64,7 +67,7 @@
64 (re.compile('__buildout_signature__ = '67 (re.compile('__buildout_signature__ = '
65 'sample-\S+\s+'68 'sample-\S+\s+'
66 'zc.recipe.egg-\S+\s+'69 'zc.recipe.egg-\S+\s+'
67 'setuptools-\S+\s+'70 '(setuptools|distribute)-\S+\s+'
68 'zc.buildout-\S+\s*'71 'zc.buildout-\S+\s*'
69 ),72 ),
70 '__buildout_signature__ = sample- zc.recipe.egg-\n'),73 '__buildout_signature__ = sample- zc.recipe.egg-\n'),
@@ -104,14 +107,17 @@
104 zc.buildout.testing.normalize_path,107 zc.buildout.testing.normalize_path,
105 zc.buildout.testing.normalize_endings,108 zc.buildout.testing.normalize_endings,
106 zc.buildout.testing.normalize_script,109 zc.buildout.testing.normalize_script,
107 (re.compile('Got setuptools \S+'), 'Got setuptools V'),110 (re.compile('Got (setuptools|distribute) \S+'),
108 (re.compile('([d-] )?setuptools-\S+-py'),111 'Got setuptools V'),
112 (re.compile('([d-] )?(setuptools|distribute)-\S+-py'),
109 'setuptools-V-py'),113 'setuptools-V-py'),
110 (re.compile('-py2[.][0-35-9][.]'), 'py2.5.'),114 (re.compile('-py2[.][0-35-9][.]'), 'py2.5.'),
111 (re.compile('zc.buildout-\S+[.]egg'),115 (re.compile('zc.buildout-\S+[.]egg'),
112 'zc.buildout.egg'),116 'zc.buildout.egg'),
113 (re.compile('zc.buildout[.]egg-link'),117 (re.compile('zc.buildout[.]egg-link'),
114 'zc.buildout.egg'),118 'zc.buildout.egg'),
119 # Distribute unzips eggs by default.
120 (re.compile('\- demoneeded'), 'd demoneeded'),
115 ]),121 ]),
116 ),122 ),
117 )123 )

Subscribers

People subscribed via source and target branches

to all changes: