AFAICT, this problem was only reported once, here: <a href="https://mail.zope.org/pipermail/zope-dev/2012-February/044108.html">https://mail.zope.org/pipermail/zope-dev/2012-February/044108.html</a> but nobody identified the cause or steps to reproduce.<br>
<br>What I&#39;ve figured out is this: if your buildout&#39;s absolute path is sufficiently long (I believe it&#39;s just if it&#39;s longer than your system site-packages&#39; absolute path), then running bin/buildout (vs. the system buildout) will decide NOT to include eggs/zc.buildout in the buildout_paths list in parts/buildout/site.py.  The result of this is that the zc.buildout egg gets left out of pkg_resources.working_set, which means that when buildout tries to find itself in the working set, it fails, resulting in the following error:<br>
<br>$ bin/buildout<br>Upgraded:<br>  zc.buildout version 1.5.2;<br>restarting.<br>Traceback (most recent call last):<br>  File &quot;bin/buildout&quot;, line 17, in &lt;module&gt;<br>    import zc.buildout.buildout<br>  File &quot;/usr/lib/python2.6/site-packages/zc.buildout-1.5.2-py2.6.egg/zc/buildout/buildout.py&quot;, line 39, in &lt;module&gt;<br>
    import zc.buildout.download<br>  File &quot;/usr/lib/python2.6/site-packages/zc.buildout-1.5.2-py2.6.egg/zc/buildout/download.py&quot;, line 20, in &lt;module&gt;<br>    from zc.buildout.easy_install import realpath<br>
  File &quot;/usr/lib/python2.6/site-packages/zc.buildout-1.5.2-py2.6.egg/zc/buildout/easy_install.py&quot;, line 81, in &lt;module&gt;<br>    pkg_resources.Requirement.parse(&#39;zc.buildout&#39;)).location<br>AttributeError: &#39;NoneType&#39; object has no attribute &#39;location&#39;<br>
<br><br>Notice that the buildout is using the site-packages zc.buildout egg, instead of the one in the local eggs directory.<br><br>Steps to reproduce:<br><br>$ cd really/really/long/directory/name/with/lots/of/stuff/emptydir<br>
$ buildout init<br>$ bin/buildout<br><br>Workaround:  use &quot;include-site-packages = false&quot; in the [buildout] section.<br><br>This strongly suggests to me that some part of the site-packages isolation mechanism is broken, at least for zc.buildout itself.  It is successfully allowing zc.buildout to be imported from site-packages, but not letting setuptools see that it is present in site-packages.  If it does this for other packages that refer to themselves in the way zc.buildout.easy_install does, they will similarly break.  (Likewise anything expecting to find entry points, etc.)<br>
<br>On a somewhat unrelated note, I am as of yesterday a new zc.buildout user...  and I already have a buildout that compiles Erlang, Spidermonkey, CouchDB, and RabbitMQ, and sets them all up with a Celery daemon under Supervisord, all in about 63 lines of .ini file.  To say that I am impressed with buildout is an extreme understatement.  ;-)<br>
<br><br>