Chui Tey
Chui Tey

Reputation: 5564

Zope buildout for development environment

Is it possible to have Zope2 buildout unpack python files into their normal directories like how standard python modules do, and not under separate .egg directories? It makes looking for files easier when debugging.

Upvotes: 0

Views: 90

Answers (1)

Martijn Pieters
Martijn Pieters

Reputation: 1121972

The 'regular' setup doesn't support namespaced packages very well, where multiple eggs share a top-level name (such as plone.app and zope, etc.)

Use the collective.recipe.omelette buildout recipe to build a 'regular' setup, it uses symlinks to give you a searchable structure of all eggs used.

[buildout]
parts =
    omelette
    ...

[omelette]
recipe = collective.recipe.omelette
eggs = ${instance:eggs}

You'll find the result in parts/omelette. Note that this structure uses symlinks, so if you use tools like find or ack make sure to configure them to follow symlinks (e.g. find parts/omelette -L and ack --follow).

The omelette directory structure is not used by Python itself, it is purely intended for presenting a coherent library structure from all eggs used in your buildout.

Note that for Windows, you need to install the junction utility as well for the recipe to work.

Upvotes: 5

Related Questions