Opened 19 years ago

Closed 19 years ago

Last modified 17 years ago

#653 closed defect (fixed)

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

Reported by: Tom Tobin <korpios@…> Owned by: Adrian Holovaty
Component: contrib.admin Version: dev
Severity: normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

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.

Change History (6)

comment:1 by Adrian Holovaty, 19 years ago

Resolution: fixed
Status: newclosed

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

comment:2 by korpios, 17 years ago

Reporter: changed from korpios@… to Tom Tobin <korpios@…>

comment:3 by kumar.nimesh@…, 17 years ago

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?

comment:4 by Simon G <dev@…>, 17 years ago

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

in reply to:  4 comment:5 by anonymous, 17 years ago

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.

comment:6 by gherndon@…, 17 years ago

Version: 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

Note: See TracTickets for help on using tickets.
Back to Top