On Oct 1, 4:00 pm, Karen Tracey <kmtra...@gmail.com> wrote:

>
> Yes, you must simply ensure you name things in such a way that the models
> module you want to access is not hidden by something else. The original
> problem noted in the thread you reference resulted from re-using the
> application's name (bookmarks) as the name of the template tags file
> (bookmarks.py), which then attempted to import from the applications models
> (bookmarks.models).  Renaming the bookmarks.py template tags file to

Found the problem. There were no namespace problems in my template
tag, but there were (are) in the external app I'm using, which is the
RSS aggregator used by the djangoproject.com site itself:

http://code.djangoproject.com/browser/djangoproject.com/django_website/apps/aggregator

The app is called "aggregator" and it includes  templatetags/
aggregator.py

So apparently this hasn't bitten the devs of the djangoproject.com
site, but it bit me!

> Since you didn't include any specifics of the names you were using for
> anything here, it's hard to say what exactly was causing the problem in your
> case.  But there are no restrictions placed by Django on what a template
> tags library is "allowed" to access. Django doesn't attempt to enforce any
> sort of "only touch stuff from your own app" requirement.

That's what I thought :)
Thanks for nudging me to look more closely at this.

Scot

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to