[Zope-CMF] Re: ImportError: No module named CMFActionIcons:1.5

Sebastian Tennant sebyte at smolny.plus.com
Tue May 2 05:11:41 EDT 2006


Quoth Tres Seaver <tseaver-npLdOuuzvjyaMJb+Lgu22Q at public.gmane.org>:
> Note that I disagree with Debian's choice to put the entire instance
> under '/var':  most of it is *not* runtime-modifiable.  Only the 'var'
> subdirectory (and 'logs', if so configured) should be under '/var':  the
> rest should be either under '/etc' (e.g., in '/etc/zope', for the
> instance configuration) or under '/usr' or '/usr/share'.

Hmm yes I see your point.

> A workaround would be to symlink the CMF products from their current
> installation directory into $INSTANCE_HOME/Products:  this is in fact
> the *preferred* mechanism within the Zope community.

dzhandle does this, or something like this.  It creates a directory
structure in $INSTANCE/Products that mirrors /usr/share/zope/Products
and then symlinks each individual file in each directory to it's
counterpart.  For example:

  /var/lib/zope2.8/instance/z286one/Products:
  used 44K available 2432920K
  drwxr-xr-x  10 zope zope 4K Apr 29 18:56 .
  drwxr-xr-x   8 root root 4K Apr 29 18:16 ..
  drwxr-xr-x   8 zope zope 4K Apr 29 19:04 CMFActionIcons
  drwxr-xr-x   8 zope zope 4K Apr 29 19:04 CMFCalendar
  drwxr-xr-x   9 zope zope 4K Apr 29 19:04 CMFCore
  drwxr-xr-x  12 zope zope 4K Apr 29 19:04 CMFDefault
  drwxr-xr-x   6 zope zope 4K Apr 29 19:04 CMFSetup
  drwxr-xr-x   7 zope zope 4K Apr 29 19:04 CMFTopic
  drwxr-xr-x   5 zope zope 4K Apr 29 19:04 CMFUid
  drwxr-xr-x   7 zope zope 4K Apr 29 19:04 DCWorkflow
  -rw-r--r--   1 zope zope 1K Apr 29 18:16 README.txt

  /var/lib/zope2.8/instance/z286one/Products/CMFActionIcons:
  used 68K available 2432920K
  drwxr-xr-x   8 zope zope  4K Apr 29 19:04 .
  drwxr-xr-x  10 zope zope  4K Apr 29 18:56 ..
  lrwxrwxrwx   1 root root  1K Apr 29 18:56 .dzproduct -> /usr/share/zope/Products/CMFActionIcons:1.5/.dzproduct
  lrwxrwxrwx   1 root root  1K Apr 29 18:56 ActionIconsTool.py -> /usr/share/zope/Products/CMFActionIcons:1.5/ActionIcons\Tool.py
  -rw-r--r--   1 zope zope 16K Apr 29 19:04 ActionIconsTool.pyc
  lrwxrwxrwx   1 root root  1K Apr 29 18:56 DEPENDENCIES.txt -> /usr/share/zope/Products/CMFActionIcons:1.5/DEPENDENCIES.\txt
  drwxr-xr-x   2 zope zope  4K Apr 29 18:56 Extensions
  lrwxrwxrwx   1 root root  1K Apr 29 18:56 README.txt -> /usr/share/zope/Products/CMFActionIcons:1.5/README.txt
  lrwxrwxrwx   1 root root  1K Apr 29 18:56 __init__.py -> /usr/share/zope/Products/CMFActionIcons:1.5/__init__.py
  -rw-r--r--   1 zope zope  2K Apr 29 19:04 __init__.pyc
  lrwxrwxrwx   1 root root  1K Apr 29 18:56 exportimport.py -> /usr/share/zope/Products/CMFActionIcons:1.5/exportimport.p\y
  lrwxrwxrwx   1 root root  1K Apr 29 18:56 permissions.py -> /usr/share/zope/Products/CMFActionIcons:1.5/permissions.py
  -rw-r--r--   1 zope zope  1K Apr 29 19:04 permissions.pyc
  drwxr-xr-x   3 zope zope  4K Apr 29 18:56 profiles
  drwxr-xr-x   3 zope zope  4K Apr 29 18:56 skins
  lrwxrwxrwx   1 root root  1K Apr 29 18:56 standard_mappings.py -> /usr/share/zope/Products/CMFActionIcons:1.5/standard_\mappings.py
  drwxr-xr-x   2 zope zope  4K Apr 29 18:56 tests
  lrwxrwxrwx   1 root root  1K Apr 29 18:56 tool.gif -> /usr/share/zope/Products/CMFActionIcons:1.5/tool.gif
  [...]

It would seem to me to be far simpler to just symlink the two Products
directories, but no doubt there's a good reason why they don't do
that.

sdt



More information about the Zope-CMF mailing list