Reputation: 168
I\ve got a problem similar to this topic Django-MPTT, how to
I've added 'mptt' to INSTALLED_APPS
INSTALLED_APPS = (
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'app',
'south',
'mptt',
)
But steel I have this error
TemplateDoesNotExist at /admin/app/category/
admin/mptt_change_list.html
Request Method: GET
Request URL: http://127.0.0.1:8000/admin/app/category/
Django Version: 1.6.5
Exception Type: TemplateDoesNotExist
Exception Value:
admin/mptt_change_list.html
Exception Location: /usr/local/lib/python2.7/dist-packages/django/template/loader.py in find_template, line 131
Python Executable: /usr/bin/python
Python Version: 2.7.6
It seems that template is not on it's path, but mptt is installed correctly and is on PYTHONPATH
Template-loader postmortem
Django tried loading these templates, in this order:
Using loader django.template.loaders.filesystem.Loader:
Using loader django.template.loaders.app_directories.Loader:
/usr/local/lib/python2.7/dist-packages/django/contrib/admin/templates/admin/mptt_change_list.html (File does not exist)
/usr/local/lib/python2.7/dist-packages/django/contrib/auth/templates/admin/mptt_change_list.html (File does not exist)
/home/islam/DM/repo/dm/DM-165/app/templates/admin/mptt_change_list.html (File does not exist)
/usr/local/lib/python2.7/dist-packages/debug_toolbar/templates/admin/mptt_change_list.html (File does not exist)
Upvotes: 3
Views: 2949
Reputation: 168
The solution was to delete mptt using sudo pip uninstall django-mptt
and install it again using pip: sudo pip install django-mptt --upgrade
Upvotes: 3
Reputation: 10315
Well as for as i know you can install Any python django package there easy ways:
1.)
You can do like via
pip install
<package Nmae>
for sometime sudo pip install <packageName>
also works
2.)
Then download the tar file
and extract from that directory you can install via
python setup.py insatll
3.)
And here you did two so try this thing also
download the mptt folder
and put it into your django project. Hope this will work
Upvotes: 1