divio/django-cms — Issue #1190: Coudn't add child for article
Author: jbzdak
Created: 2012-03-05 11:35:48+00:00
State: open

When I try to add first child to article i get an exception that beaks admin page that contains page list

Environment:

Request Method: GET
Request URL: http://lfitj.if.pw.edu.pl/lfitjcms/admin/cms/page/

Django Version: 1.3.1
Python Version: 2.6.5
Installed Applications:
['django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.sites',
'django.contrib.messages',
'django.contrib.admin',
'django.contrib.staticfiles',
'cms',
'menus',
'mptt',
'south',
'cms.plugins.text',
'cms.plugins.picture',
'cms.plugins.link',
'cms.plugins.file',
'cms.plugins.snippet',
'cms.plugins.googlemap',
'sekizai']
Installed Middleware:
('django.middleware.common.CommonMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'cms.middleware.page.CurrentPageMiddleware',
'cms.middleware.user.CurrentUserMiddleware',
'cms.middleware.toolbar.ToolbarMiddleware')

Traceback:
File "/usr/local/lib/python2.6/dist-packages/django/core/handlers/base.py" in get_response
111. response = callback(request, *callback_args, **callback_kwargs)
File "/usr/local/lib/python2.6/dist-packages/django/contrib/admin/options.py" in wrapper
307. return self.admin_site.admin_view(view)(*args, **kwargs)
File "/usr/local/lib/python2.6/dist-packages/django/utils/decorators.py" in _wrapped_view
93. response = view_func(request, *args, **kwargs)
File "/usr/local/lib/python2.6/dist-packages/django/views/decorators/cache.py" in _wrapped_view_func
79. response = view_func(request, *args, **kwargs)
File "/usr/local/lib/python2.6/dist-packages/django/contrib/admin/sites.py" in inner
197. return view(request, *args, **kwargs)
File "/usr/local/lib/python2.6/dist-packages/cms/admin/pageadmin.py" in changelist_view
657. cl.set_items(request)
File "/usr/local/lib/python2.6/dist-packages/cms/admin/change_list.py" in set_items
198. children[-1].last = False
File "/usr/local/lib/python2.6/dist-packages/django/db/models/query.py" in __getitem__
157. "Negative indexing is not supported."

Exception Type: AssertionError at /admin/cms/page/
Exception Value: Negative indexing is not supported.