Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#4356 closed (invalid)

Problem with Template library django.template.loader_tag - SVN Version 5311

Reported by: anonymous Owned by: jacob
Component: Uncategorized Version: 0.96
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description (last modified by mtredinnick)

Traceback (most recent call last):
File "/home/meli/Projet/atelier_rouelibre/django/core/handlers/base.py" in get_response
  68. callback, callback_args, callback_kwargs = resolver.resolve(request.path)
File "/home/meli/Projet/atelier_rouelibre/django/core/urlresolvers.py" in resolve
  1
69. for pattern in self.urlconf_module.urlpatterns:
File "/home/meli/Projet/atelier_rouelibre/django/core/urlresolvers.py" in _get_urlconf_module
  186. self._urlconf_module = __import__(self.urlconf_name, {}, {}, [''])
File "/home/meli/Projet/atelier_rouelibre/../atelier_rouelibre/urls.py" in
  2. from atelier_rouelibre.views import index
File "/home/meli/Projet/atelier_rouelibre/../atelier_rouelibre/views.py" in
  2. from django.template import Context, loader
File "/home/meli/Projet/atelier_rouelibre/../atelier_rouelibre/django/template/loader.py" in
  118. add_to_builtins('django.template.loader_tags')
File "/home/meli/Projet/atelier_rouelibre/../atelier_rouelibre/django/template/__init__.py" in add_to_builtins
  933. builtins.append(get_library(module_name))
File "/home/meli/Projet/atelier_rouelibre/../atelier_rouelibre/django/template/__init__.py" in get_library
  922. mod = __import__(module_name, {}, {}, [''])
File "/home/meli/Projet/atelier_rouelibre/django/template/loader_tags.py" in
  3. from django.template.loader import get_template, get_template_from_string, find_template_source
File "/home/meli/Projet/atelier_rouelibre/../atelier_rouelibre/django/template/loader.py" in
  118. add_to_builtins('django.template.loader_tags')
File "/home/meli/Projet/atelier_rouelibre/../atelier_rouelibre/django/template/__init__.py" in add_to_builtins
  933. builtins.append(get_library(module_name))
File "/home/meli/Projet/atelier_rouelibre/../atelier_rouelibre/django/template/__init__.py" in get_library
  929. raise InvalidTemplateLibrary, "Template library %s does not have a variable named 'register'" % module_name

  InvalidTemplateLibrary at /
  Template library django.template.loader_tags does not have a variable named 'register'

Change History (8)

comment:1 Changed 8 years ago by mtredinnick

  • Description modified (diff)
  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

(Fixed description formatting)

What were you doing to trigger this traceback? The loader_tags.py module definitely does have a variable named register in it, so there is something else going on here.

Can you run "svn status" and check that no files in your source tree are changed from the versions in trunk?

comment:2 Changed 8 years ago by melindia777@…

Everything is in sync...

I didn't do nothing ! I swear ... not my fault ;)

Seriously, I updated with svn and then, this traceback.
Just began this project.

comment:3 Changed 8 years ago by mtredinnick

Then we have a problem, because I cannot replicate this at all. :-(

What checkout version are you using? Run "svn info" in, say, the root directory of your source and see what it says for "Revision". I really cannot think of anything we've done to cause this, though.

One thing to do is to try backing up a few revisions and see if you can work out where things start to go wrong. So if, for example, you are at revision 5319, go back to 5200 and see if the problem reoccurs (svn update -r 5200). If it doesn't happen then, move forwards halfway. Rinse, wash, repeat. If we at least know what checkin causes the problem, if might give us some clues.

comment:4 Changed 8 years ago by Melindia <melindia777@…>

We figure it out. Yé !
We used a symlink django-­>django.svn/django in our project folder. It was working until now. We did proper system install and it works...

Do you know if we can use the symlink trick ? It was handy!

Thanks for your very nice answer !

comment:5 Changed 8 years ago by Simon G. <dev@…>

  • Resolution set to invalid
  • Status changed from new to closed

Hmm.. did you have another version of django installed? maybe in your site-packages library?

comment:6 Changed 8 years ago by Pashka R. <pashka.reznikov@…>

  • Version changed from SVN to 0.96

I have 0.95 installed in the system but I want to use 0.96.... so I've setup .htaccess:

SetHandler python-program
PythonPath "['/webhomes/exclaim/public_html/kids2', '/webhomes/exclaim/public_html/kids2/..'] + sys.path"
PythonHandler django.core.handlers.modpython
SetEnv DJANGO_SETTINGS_MODULE settings
PythonDebug On

all works (http://kids.dn.ua/info/project.html [ru]) except of / (http://kids.dn.ua/) ... I've got the same error.....

has someone any idea about how can I fix this? Thnx

wbr Pashka R.

comment:7 Changed 8 years ago by Pashka R. <pashka.reznikov@…>

....and.... I have symlink /webhomes/exclaim/public_html/kids2/django --> /path/to/django0.96...

wbr Pashka R.

comment:8 Changed 8 years ago by mtredinnick

Please don't use the Trac system for support requests. We have mailing lists for that.

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