Django

Code

Ticket #653 (closed: fixed)

Opened 3 years ago

Last modified 7 months ago

setup.py doesn't create django/contrib/admin/templates/

Reported by: Tom Tobin <korpios@korpios.com> Assigned to: adrian
Milestone: Component: Admin interface
Version: SVN Keywords:
Cc: Triage Stage: Unreviewed
Has patch: 0 Needs documentation: 0
Needs tests: 0 Patch needs improvement: 0

Description

With a recent svn pull (968) and a fresh install using setup.py, django/contrib/admin/templates/ is not copied over. The result is that the admin interface fails with a traceback:

There's been an error:

Traceback (most recent call last):

  File "/home/korpios/devel/py3p/django/core/handlers/base.py", line 68, in get_response
    response = callback(request, **param_dict)

  File "/home/korpios/devel/py3p/django/contrib/admin/views/decorators.py", line 60, in _checklogin
    return _display_login_form(request, message)

  File "/home/korpios/devel/py3p/django/contrib/admin/views/decorators.py", line 26, in _display_login_form
    }, context_instance=DjangoContext(request))

  File "/home/korpios/devel/py3p/django/core/extensions.py", line 11, in render_to_response
    return HttpResponse(loader.render_to_string(*args, **kwargs))

  File "/home/korpios/devel/py3p/django/core/template/loader.py", line 77, in render_to_string
    t = get_template(template_name)

  File "/home/korpios/devel/py3p/django/core/template/loader.py", line 57, in get_template
    return get_template_from_string(load_template_source(template_name))

  File "/home/korpios/devel/py3p/django/core/template/loader.py", line 47, in load_template_source
    raise TemplateDoesNotExist, name

TemplateDoesNotExist: admin/login

This issue is likely not a problem for those merely linking to the checked out django directory, rather than using setup.py.

The workaround is to copy django/contrib/admin/templates/ from the checked out django directory to the corresponding location in the installed directory.

Attachments

Change History

10/20/05 00:35:34 changed by adrian

  • status changed from new to closed.
  • resolution set to fixed.

(In [972]) Fixed #653 -- setup.up now accounts for admin file moves. Thanks, korpios@gmail.com

07/12/07 13:05:15 changed by korpios

  • reporter changed from korpios@gmail.com to Tom Tobin <korpios@korpios.com>.

12/06/07 15:13:58 changed by kumar.nimesh@gmail.com

I started django-ing since 3 weeks. OS is WinXP. setup.py does create django/contrib/admin/templates/ but the problem still exist for me. Works on linux.

TemplateDoesNotExist? at /admin/ admin/login.html

Any help?

(follow-up: ↓ 5 ) 12/06/07 19:50:49 changed by Simon G <dev@simon.net.nz>

Kumar - please take support requests to the django-users mailing list. What version of Django are you using?

(in reply to: ↑ 4 ) 12/07/07 09:41:32 changed by anonymous

Replying to Simon G <dev@simon.net.nz>:

Kumar - please take support requests to the django-users mailing list. What version of Django are you using?

Django Ver 0.96.1. downloaded on 10/26/07. I will seek support from user list from now on. Thank you.

01/29/08 09:55:21 changed by gherndon@eyeontech.com

  • version set to SVN.

i saw this behavior when installing django today on osx 10.5.2+, python 2.5.1 and django from SVN version build 7049.

i did a ln -s from my django-svn/django directory to my site-packages directory and it's working now

-geo


Add/Change #653 (setup.py doesn't create django/contrib/admin/templates/)




Change Properties
Action