[Checkins] SVN: CMF/branches/2.3/ - backported several changes from trunk

Yvo Schubbe cvs-admin at zope.org
Sat Mar 30 14:05:19 UTC 2013


Log message for revision 130184:
  - backported several changes from trunk

Changed:
  U   CMF/branches/2.3/bootstrap.py
  U   CMF/branches/2.3/buildout.cfg
  U   CMF/branches/2.3/sources.cfg
  _U  CMF/branches/2.3/src/
  U   CMF/branches/2.3/versions.cfg

-=-
Modified: CMF/branches/2.3/bootstrap.py
===================================================================
--- CMF/branches/2.3/bootstrap.py	2013-03-30 14:03:18 UTC (rev 130183)
+++ CMF/branches/2.3/bootstrap.py	2013-03-30 14:05:18 UTC (rev 130184)
@@ -18,13 +18,13 @@
 use the -c option to specify an alternate configuration file.
 """
 
-import os, shutil, sys, tempfile, textwrap, urllib, urllib2, subprocess
+import os, shutil, sys, tempfile, urllib, urllib2, subprocess
 from optparse import OptionParser
 
 if sys.platform == 'win32':
     def quote(c):
         if ' ' in c:
-            return '"%s"' % c # work around spawn lamosity on windows
+            return '"%s"' % c  # work around spawn lamosity on windows
         else:
             return c
 else:
@@ -57,13 +57,13 @@
 # out any namespace packages from site-packages that might have been
 # loaded by .pth files.
 clean_path = sys.path[:]
-import site
+import site  # imported because of its side effects
 sys.path[:] = clean_path
 for k, v in sys.modules.items():
     if k in ('setuptools', 'pkg_resources') or (
         hasattr(v, '__path__') and
-        len(v.__path__)==1 and
-        not os.path.exists(os.path.join(v.__path__[0],'__init__.py'))):
+        len(v.__path__) == 1 and
+        not os.path.exists(os.path.join(v.__path__[0], '__init__.py'))):
         # This is a namespace package.  Remove it.
         sys.modules.pop(k)
 
@@ -72,10 +72,11 @@
 setuptools_source = 'http://peak.telecommunity.com/dist/ez_setup.py'
 distribute_source = 'http://python-distribute.org/distribute_setup.py'
 
+
 # parsing arguments
 def normalize_to_url(option, opt_str, value, parser):
     if value:
-        if '://' not in value: # It doesn't smell like a URL.
+        if '://' not in value:  # It doesn't smell like a URL.
             value = 'file://%s' % (
                 urllib.pathname2url(
                     os.path.abspath(os.path.expanduser(value))),)
@@ -110,7 +111,7 @@
                   help=("Specify a URL or file location for the setup file. "
                         "If you use Setuptools, this will default to " +
                         setuptools_source + "; if you use Distribute, this "
-                        "will default to " + distribute_source +"."))
+                        "will default to " + distribute_source + "."))
 parser.add_option("--download-base", action="callback", dest="download_base",
                   callback=normalize_to_url, nargs=1, type="string",
                   help=("Specify a URL or directory for downloading "
@@ -135,10 +136,6 @@
 
 options, args = parser.parse_args()
 
-# if -c was provided, we push it back into args for buildout's main function
-if options.config_file is not None:
-    args += ['-c', options.config_file]
-
 if options.eggs:
     eggs_dir = os.path.abspath(os.path.expanduser(options.eggs))
 else:
@@ -151,12 +148,11 @@
         options.setup_source = setuptools_source
 
 if options.accept_buildout_test_releases:
-    args.append('buildout:accept-buildout-test-releases=true')
-args.append('bootstrap')
+    args.insert(0, 'buildout:accept-buildout-test-releases=true')
 
 try:
     import pkg_resources
-    import setuptools # A flag.  Sometimes pkg_resources is installed alone.
+    import setuptools  # A flag.  Sometimes pkg_resources is installed alone.
     if not hasattr(pkg_resources, '_distribute'):
         raise ImportError
 except ImportError:
@@ -169,6 +165,8 @@
         setup_args['download_base'] = options.download_base
     if options.use_distribute:
         setup_args['no_fake'] = True
+        if sys.version_info[:2] == (2, 4):
+            setup_args['version'] = '0.6.32'
     ez['use_setuptools'](**setup_args)
     if 'pkg_resources' in sys.modules:
         reload(sys.modules['pkg_resources'])
@@ -191,6 +189,8 @@
 find_links = options.download_base
 if not find_links:
     find_links = os.environ.get('bootstrap-testing-find-links')
+if not find_links and options.accept_buildout_test_releases:
+    find_links = 'http://downloads.buildout.org/'
 if find_links:
     cmd.extend(['-f', quote(find_links)])
 
@@ -211,6 +211,7 @@
     # Figure out the most recent final version of zc.buildout.
     import setuptools.package_index
     _final_parts = '*final-', '*final'
+
     def _final_version(parsed_version):
         for part in parsed_version:
             if (part[:1] == '*') and (part not in _final_parts):
@@ -226,6 +227,8 @@
         bestv = None
         for dist in index[req.project_name]:
             distv = dist.parsed_version
+            if distv >= pkg_resources.parse_version('2dev'):
+                continue
             if _final_version(distv):
                 if bestv is None or distv > bestv:
                     best = [dist]
@@ -235,14 +238,18 @@
         if best:
             best.sort()
             version = best[-1].version
+
 if version:
-    requirement = '=='.join((requirement, version))
+    requirement += '=='+version
+else:
+    requirement += '<2dev'
+
 cmd.append(requirement)
 
 if is_jython:
     import subprocess
     exitcode = subprocess.Popen(cmd, env=env).wait()
-else: # Windows prefers this, apparently; otherwise we would prefer subprocess
+else:  # Windows prefers this, apparently; otherwise we would prefer subprocess
     exitcode = os.spawnle(*([os.P_WAIT, sys.executable] + cmd + [env]))
 if exitcode != 0:
     sys.stdout.flush()
@@ -255,6 +262,16 @@
 ws.add_entry(eggs_dir)
 ws.require(requirement)
 import zc.buildout.buildout
+
+# If there isn't already a command in the args, add bootstrap
+if not [a for a in args if '=' not in a]:
+    args.append('bootstrap')
+
+
+# if -c was provided, we push it back into args for buildout's main function
+if options.config_file is not None:
+    args[0:0] = ['-c', options.config_file]
+
 zc.buildout.buildout.main(args)
-if not options.eggs: # clean up temporary egg directory
+if not options.eggs:  # clean up temporary egg directory
     shutil.rmtree(eggs_dir)

Modified: CMF/branches/2.3/buildout.cfg
===================================================================
--- CMF/branches/2.3/buildout.cfg	2013-03-30 14:03:18 UTC (rev 130183)
+++ CMF/branches/2.3/buildout.cfg	2013-03-30 14:05:18 UTC (rev 130184)
@@ -4,7 +4,7 @@
 extends =
     sources.cfg
     http://download.zope.org/zopetoolkit/index/1.0.7/zopeapp-versions.cfg
-    src/Zope2/versions.cfg
+    https://raw.github.com/zopefoundation/Zope/2.13/versions.cfg
     versions.cfg
 allow-picked-versions = false
 parts =
@@ -26,7 +26,6 @@
     Products.DCWorkflow
     Products.GenericSetup
 develop =
-    src/five.localsitemanager
     src/Products.CMFCalendar
     src/Products.CMFCore
     src/Products.CMFDefault
@@ -34,21 +33,17 @@
     src/Products.CMFUid
     src/Products.DCWorkflow
     src/Products.GenericSetup
-    src/Zope2
-allowed-eggs-from-site-packages =
 unzip = true
 
 extensions = mr.developer
 always-accept-server-certificate = true
+always-checkout = force
 auto-checkout =
+    Zope
+    five.localsitemanager
 sources-dir = develop
 
 
-[versions]
-# develop
-five.localsitemanager =
-
-
 [test]
 recipe = zc.recipe.testrunner
 eggs =
@@ -63,21 +58,21 @@
 
 
 [scripts]
-recipe = z3c.recipe.scripts
+recipe = zc.recipe.egg
 eggs =
     ${buildout:eggs}
     Zope2
 
 
 [zopepy]
-recipe = z3c.recipe.scripts
+recipe = zc.recipe.egg
 eggs = ${buildout:eggs}
 interpreter = zopepy
 scripts = zopepy
 
 
 [docs]
-recipe = z3c.recipe.scripts
+recipe = zc.recipe.egg
 eggs =
     ${buildout:eggs}
     pkginfo
@@ -86,7 +81,7 @@
 
 
 [checkversions]
-recipe = z3c.recipe.scripts
+recipe = zc.recipe.egg
 eggs = z3c.checkversions [buildout]
 
 

Modified: CMF/branches/2.3/sources.cfg
===================================================================
--- CMF/branches/2.3/sources.cfg	2013-03-30 14:03:18 UTC (rev 130183)
+++ CMF/branches/2.3/sources.cfg	2013-03-30 14:05:18 UTC (rev 130184)
@@ -1,21 +1,25 @@
 [buildout]
 extends =
-    http://svn.zope.org/repos/main/Zope/branches/2.13/sources.cfg
+    https://raw.github.com/zopefoundation/Zope/2.13/sources.cfg
+
+[remotes]
 svn-zope-org = ^
+zopegit = git://github.com/zopefoundation
+zopegit_push = git at github.com:zopefoundation
 
 [sources]
 # CMF
-Products.CMFCalendar = svn ${buildout:svn-zope-org}/Products.CMFCalendar/trunk
-Products.CMFCore = svn ${buildout:svn-zope-org}/Products.CMFCore/trunk
-Products.CMFDefault = svn ${buildout:svn-zope-org}/Products.CMFDefault/trunk
-Products.CMFTopic = svn ${buildout:svn-zope-org}/Products.CMFTopic/trunk
-Products.CMFUid = svn ${buildout:svn-zope-org}/Products.CMFUid/trunk
-Products.DCWorkflow = svn ${buildout:svn-zope-org}/Products.DCWorkflow/trunk
-Products.GenericSetup = svn ${buildout:svn-zope-org}/Products.GenericSetup/trunk
+Products.CMFCalendar = svn ${remotes:svn-zope-org}/Products.CMFCalendar/trunk
+Products.CMFCore = svn ${remotes:svn-zope-org}/Products.CMFCore/trunk
+Products.CMFDefault = svn ${remotes:svn-zope-org}/Products.CMFDefault/trunk
+Products.CMFTopic = svn ${remotes:svn-zope-org}/Products.CMFTopic/trunk
+Products.CMFUid = svn ${remotes:svn-zope-org}/Products.CMFUid/trunk
+Products.DCWorkflow = svn ${remotes:svn-zope-org}/Products.DCWorkflow/trunk
+Products.GenericSetup = svn ${remotes:svn-zope-org}/Products.GenericSetup/trunk
 
 # CMF dependencies
-five.globalrequest = svn ${buildout:svn-zope-org}/five.globalrequest/trunk
-five.localsitemanager = svn ${buildout:svn-zope-org}/five.localsitemanager/trunk
-Products.ZSQLMethods = svn ${buildout:svn-zope-org}/Products.ZSQLMethods/trunk
-Zope = svn ${buildout:svn-zope-org}/Zope/branches/2.13
-zope.globalrequest = svn ${buildout:svn-zope-org}/zope.globalrequest/trunk
+five.globalrequest = git ${remotes:zopegit}/five.globalrequest.git pushurl=${remotes:zopegit_push}/five.globalrequest.git
+five.localsitemanager = git ${remotes:zopegit}/five.localsitemanager.git pushurl=${remotes:zopegit_push}/five.localsitemanager.git
+Products.ZSQLMethods = git ${remotes:zopegit}/Products.ZSQLMethods.git pushurl=${remotes:zopegit_push}/Products.ZSQLMethods.git
+Zope = git ${remotes:zopegit}/Zope.git pushurl=${remotes:zopegit_push}/Zope.git branch=2.13
+zope.globalrequest = git ${remotes:zopegit}/zope.globalrequest.git pushurl=${remotes:zopegit_push}/zope.globalrequest.git


Property changes on: CMF/branches/2.3/src
___________________________________________________________________
Modified: svn:externals
   - ^/Zope/branches/2.13 Zope2
^/Products.CMFCalendar/trunk Products.CMFCalendar
^/Products.CMFCore/trunk Products.CMFCore
^/Products.CMFDefault/trunk Products.CMFDefault
^/Products.CMFTopic/trunk Products.CMFTopic
^/Products.CMFUid/trunk Products.CMFUid
^/Products.DCWorkflow/trunk Products.DCWorkflow
^/Products.GenericSetup/trunk Products.GenericSetup
^/five.localsitemanager/trunk five.localsitemanager

   + ^/Products.CMFCalendar/trunk Products.CMFCalendar
^/Products.CMFCore/trunk Products.CMFCore
^/Products.CMFDefault/trunk Products.CMFDefault
^/Products.CMFTopic/trunk Products.CMFTopic
^/Products.CMFUid/trunk Products.CMFUid
^/Products.DCWorkflow/trunk Products.DCWorkflow
^/Products.GenericSetup/trunk Products.GenericSetup


Modified: CMF/branches/2.3/versions.cfg
===================================================================
--- CMF/branches/2.3/versions.cfg	2013-03-30 14:03:18 UTC (rev 130183)
+++ CMF/branches/2.3/versions.cfg	2013-03-30 14:05:18 UTC (rev 130184)
@@ -1,10 +1,10 @@
 [versions]
-# ZTK KGS overrides (for Zope 2.13)
-z3c.recipe.scripts = 1.0.1
-zc.buildout = 1.6.3
+# ZTK KGS overrides
+mr.developer = 1.22
+zc.buildout = 1.7.1
 zc.recipe.egg = 1.3.2
-zc.recipe.testrunner = 1.4.0
-zope.testrunner = 4.0.4
+zc.recipe.testrunner = 2.0.0
+zope.testrunner = 4.2.0
 
 # CMF dependencies
 five.globalrequest = 1.0
@@ -14,7 +14,9 @@
 
 # CMF toolchain
 mailinglogger = 3.7
-pkginfo = 0.9
-plone.recipe.zope2instance = 4.2.1
-repoze.sphinx.autointerface = 0.6.2
+pkginfo = 1.0b2
+plone.recipe.zope2instance = 4.2.10
+repoze.sphinx.autointerface = 0.7.1
+six = 1.3.0
 z3c.recipe.i18n = 0.8.1
+z3c.recipe.scripts = 1.0.1



More information about the checkins mailing list