Recipe's sys.path not correct
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Buildout |
New
|
Undecided
|
Unassigned |
Bug Description
Often, recipes themselves require other packages. These will be installed together with the recipe egg when needed. The problem is that these dependencies do not have priority on the sys.path.
For example, zc.zope3recipes requires ZConfig. In particular, it requires a very recent version of ZConfig. Now suppose you have ZConfig on your PYTHONPATH already, but an older version (for reproducibility, try putting a Zope 3.3 installation on your PYTHONPATH). When you now execute a buildout that uses zc.zope3recipes, it will fail with the following error message:
ImportError:
No module named schemaless
This is due to the fact that the ZConfig version distributed with Zope 3.3 does not have the ZConfig.schemaless module yet and the newer version that was installed as a dependency is not being prioritized on sys.path.
It also happens while running in a brand new virtualenv (just installed today, on Debian/Etch/amd64):
(virtualgrok)birch 11:05:10 /home/zope/grok toni/buildout- eggs']: /home/zope/ grok/buildout- eggs >=0.5.3: application.
$ grokproject Sample
Enter user (Name of an initial administrator user): admin
Enter passwd (Password for the initial administrator user): admin
Enter eggs_dir (Location where zc.buildout will look for and place packages) ['/home/
Creating directory ./Sample
Downloading zc.buildout...
Invoking zc.buildout...
While:
Installing.
Getting section app.
Initializing section app.
Loading zc.buildout recipe entry zc.zope3recipes
An internal error occured due to a bug in either zc.buildout or in a
recipe being used:
ImportError:
No module named schemaless