(Buildout のトラブルシューティング)

Description

How to solve problems related to running buildout and some common exceptions you might encounter when running buildout for Plone.

はじめに

This document tells how to resolve buildout problems.

Network errors and timeouts

The usual reason for download error or timeout is that either

  • pypi.python.org server is down
  • one of plone.org servers is down
  • other Python package source server is down

Here are instructions how to deal with community servers down situations

Mirrors

Individual package failing outside PyPi

To figure out which file buildout tries to download, usually the only way is to use buildout -D pdb debug mode and step up in stack frames to see what is going on.

Version conflicts

Buildout gives you an error if there is a dependency shared by two components, and one of the components wants to have a different version of this dependency.

Example:

  Installing.
  Getting section zeoserver.
  Initializing part zeoserver.
Error: There is a version conflict.
We already have: zope.component 3.8.0
but five.localsitemanager 1.1 requires 'zope.component<3.6dev'.
  • If your buildout is fetching out strange versions

    • try running buildout in verbose mode bin/buildout vvv
    • Use helper recipe dumppickedversions
  • Manually pindown version in [versions]

Further reading

Good-py service

Good-py contains some good known versions sets. These are most convenient to use if you are using complex configuration of add-ons and you don’t know what you are doing.

Some good-py configurations take Plone version as a paremeter.

Example:

[buildout]
extends =
    base.cfg
    http://dist.plone.org/release/3.3.5/versions.cfg
    http://good-py.appspot.com/release/dexterity/1.0-next?plone=3.3.5

For more information, see

Plone 3.1

Plone 3.1 and earlier are not eggified. Below are links how to keep Plone 3.1 and earlier buildouts running .

See

Common pindowns

Here is the latest pindown example (02/2010):

[versions]
# zope.app.catalog 3.6.0 requires zope.index 3.5.0
# zope.index 3.5.0 requires 'ZODB3>=3.8.0b1'
# This will conflict with the fake ZODB egg.
zope.app.catalog = 3.5.2
zope.component = 3.5.1
plone.app.z3cform=0.4.2
plone.recipe.zope2instance = 3.6
zope.sendmail = 3.6.0
Products.PluggableAuthService = 1.6.2
plone.z3cform = 0.5.8
five.intid=0.4.2
plone.reload = 0.11
Products.GenericSetup = 1.5.0

Getting distribution for ‘distribute’.

You try to run buildout, but it is stuck in a loop:

Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.
Getting distribution for 'distribute'.

Your system-wide Distribute version is older than the latest release. Buildout tries to update it, but since system wide site-packages version overrides anything buildout can do, it is stuck in a loop.

Fix: update Distribute in system-wide Python:

easy_install -U Distribute
Searching for Distribute
Reading http://pypi.python.org/simple/Distribute/
Reading http://packages.python.org/distribute
Best match: distribute 0.6.12
Downloading http://pypi.python.org/packages/source/d/distribute/distribute-0.6.12.tar.gz#md5=5a52e961f8d8799d243fe8220f9d760e
Processing distribute-0.6.12.tar.gz
Running distribute-0.6.12/setup.py -q bdist_egg --dist-dir /tmp/easy_install-jlL3e7/distribute-0.6.12/egg-dist-tmp-IV9SiQ
Before install bootstrap.
Scanning installed packages
Setuptools installation detected at /home/moo/py24/lib/python2.4/site-packages
Non-egg installation
Removing elements out of the way...
Already patched.
/home/moo/py24/lib/python2.4/site-packages/setuptools-0.6c11-py2.4.egg-info already patched.
After install bootstrap.
/home/moo/py24/lib/python2.4/site-packages/setuptools-0.6c11-py2.4.egg-info already exists
Removing distribute 0.6.10 from easy-install.pth file
Adding distribute 0.6.12 to easy-install.pth file
Installing easy_install script to /home/moo/py24/bin
Installing easy_install-2.4 script to /home/moo/py24/bin

UnknownExtra: zope.i18n 0.0 has no such extra feature ‘zcml’

You get the following traceback when running buildout:

  File "/home/moo/rtv/eggs/plone.recipe.zope2instance-2.7-py2.4.egg/plone/recipe/zope2instance/__init__.py", line 93, in update
    requirements, ws = self.egg.working_set()
  File "/home/moo/rtv/eggs/zc.recipe.egg-1.1.0-py2.4.egg/zc/recipe/egg/egg.py", line 93, in working_set
    allow_hosts=self.allow_hosts,
  File "/tmp/tmpGFbvPP/zc.buildout-1.5.0b2-py2.4.egg/zc/buildout/easy_install.py", line 800, in install
  File "/tmp/tmpGFbvPP/zc.buildout-1.5.0b2-py2.4.egg/zc/buildout/easy_install.py", line 660, in install
  File "/home/moo/py24/lib/python2.4/site-packages/distribute-0.6.10-py2.4.egg/pkg_resources.py", line 551, in resolve
    requirements.extend(dist.requires(req.extras)[::-1])
  File "/home/moo/py24/lib/python2.4/site-packages/distribute-0.6.10-py2.4.egg/pkg_resources.py", line 2164, in requires
    raise UnknownExtra(
UnknownExtra: zope.i18n 0.0 has no such extra feature 'zcml'

You might be using Plone 4 add-on for Plone 3. Check if setup.py contains Zope2 as a dependency. If it does then it is the end of the story and you need to use earlier add-on version for your Plone 3 site.

More info