[Zope] getSlice error in wiki folder with many objects?
Troy Farrell
troy@entheossoft.com
Sun, 04 May 2003 12:53:11 -0500
My knowledge of DTML may be a bit rusty, but from what I see, the
rendering of 'manage_options' is trying to execute this:
URL[-(_.len(action)):]==action or URL[-17:]=='/manage_workspace' and
_['sequence-start'])
which, since it is in DTML, calls careful_getslice. At line 174[1],
careful_getslice executes this:
v=seq[indexes[0]:]
where seq is the sequence it is trying to slice. In our case, I bet
that seq is the URL from above. It looks to me like the URL above is
not a string, or at least doesn't have a __get_slice__ method.
Unfortunately, I don't know why this would be the case...
One thing that might help: create a dtml method in a folder above this
one with this one line in it:
<dtml-var REQUEST>
Then visit http://server/folderparent/foldernotworking/dtmlrequest and
see what it tells you. Is URL a string (I hope so...)
Troy
[1]
http://cvs.zope.org/*checkout*/Zope2/lib/python/DocumentTemplate/DT_Util.py?rev=1.71.8.1&content-type=text/plain
Bill Seitz wrote:
> I thought maybe the problem below was related to
> running zope 2.3.2. But experimenting on my laptop
> with v2.5.1 doesn't seem to help, either. This makes
> it impossible to change object properties, etc.
>
> ------
>
> I get this when I try to view a particular folder
> through the ZMI.
>
> I suspect I have too many items in the folder.
>
> I'm running zope 2.3.2, and don't want to change right
> now (until I make some zwiki code changes).
>
> Is there a workaround? Or a hack to add/copy a DTML
> document into the folder?
>
> Error Type: AttributeError
> Error Value: __getslice__
>
>
>
> Traceback (innermost last):
> File
> /usr/local/Zope-2.3.2-src/lib/python/ZPublisher/Publish.py,
> line 223, in publish_module
> File
> /usr/local/Zope-2.3.2-src/lib/python/ZPublisher/Publish.py,
> line 187, in publish
> File
> /usr/local/Zope-2.3.2-src/lib/python/Zope/__init__.py,
> line 221, in zpublisher_exception_hook
> (Object: Traversable)
> File
> /usr/local/Zope-2.3.2-src/lib/python/ZPublisher/Publish.py,
> line 171, in publish
> File
> /usr/local/Zope-2.3.2-src/lib/python/ZPublisher/mapply.py,
> line 160, in mapply
> (Object: manage_main)
> File
> /usr/local/Zope-2.3.2-src/lib/python/ZPublisher/Publish.py,
> line 112, in call_object
> (Object: manage_main)
> File
> /usr/local/Zope-2.3.2-src/lib/python/Shared/DC/Scripts/Bindings.py,
> line 324, in __call__
> (Object: manage_main)
> File
> /usr/local/Zope-2.3.2-src/lib/python/Shared/DC/Scripts/Bindings.py,
> line 354, in _bindAndExec
> (Object: manage_main)
> File
> /usr/local/Zope-2.3.2-src/lib/python/App/special_dtml.py,
> line 236, in _exec
> (Object: manage_main)
> File
> /usr/local/Zope-2.3.2-src/lib/python/Shared/DC/Scripts/Bindings.py,
> line 338, in __render_with_namespace__
> (Object: manage_tabs)
> File
> /usr/local/Zope-2.3.2-src/lib/python/Shared/DC/Scripts/Bindings.py,
> line 354, in _bindAndExec
> (Object: manage_tabs)
> File
> /usr/local/Zope-2.3.2-src/lib/python/App/special_dtml.py,
> line 236, in _exec
> (Object: manage_tabs)
> File
> /usr/local/Zope-2.3.2-src/lib/python/DocumentTemplate/DT_With.py,
> line 146, in render
> (Object:
> _(manage_options=filtered_manage_options()))
> File
> /usr/local/Zope-2.3.2-src/lib/python/DocumentTemplate/DT_In.py,
> line 717, in renderwob
> (Object: manage_options)
> File
> /usr/local/Zope-2.3.2-src/lib/python/DocumentTemplate/DT_Util.py,
> line 334, in eval
> (Object: URL[-(_.len(action)):]==action or
> URL[-17:]=='/manage_workspace' and
> _['sequence-start'])
> (Info: action)
> File <string>, line 0, in ?
> File
> /usr/local/Zope-2.3.2-src/lib/python/DocumentTemplate/DT_Util.py,
> line 174, in careful_getslice
> AttributeError: (see above)