Re: django error page: traceback too shallow?

2009-12-02 Thread notcourage
def home (request): if (request.user.is_authenticated()): artifacts = Artifact.objects.filter (member__exact=request.user.profile.id) ... else: ... In this case, the user is authenticated but the predicate is failing as expected because user.profile is NULL. The

django error page: traceback too shallow?

2009-12-01 Thread notcourage
Is there a way to force django to show the full traceback? It only shows the following though the query is called from the view home(req) in my views.py: Traceback: File "C:\swe\Python25\lib\site-packages\django\core\handlers\base.py" in get_response 92. response =

.values('model__field')

2009-07-16 Thread notcourage
You can write: ...select_related('model').order_by('model__field') This avoids writing ugly .extra() code. You can't write: ...select_related('model').values('model__field') Does anybody else think this would be nice? On another topic, I'd like to write model methods which invoke custom SQL

active django battery projects

2009-06-19 Thread notcourage
I for one would be interested in replies showcasing django battery projects underway. As a new django user, I'm stumbling on some active, useful projects (django piston, south) and wondering if there are projects addressing my wish list (django model cache, django parsed template cache, multi DB,

production sites powered by django

2009-06-19 Thread notcourage
http://www.djangosites.org/ is missing info like load, scaling techniques used, utilities written (e.g., custom tags, custom form fields, custom model fields, wish list. I don't see how one adds a site. I for one would be interested in replies to this post about production sites created

urlconf doesn't coerce

2009-06-11 Thread notcourage
From: http://docs.djangoproject.com/en/dev/topics/http/urls/#topics-http-urls Each captured argument is sent to the view as a plain Python string, regardless of what sort of match the regular expression makes. * * * Does anybody think it would be nice to specify coercions like you can on

Re: Modifying the way a ChoiceField is rendered

2009-06-04 Thread notcourage
I wish there was an easy way to customize CheckboxSelectMultiple. The widget library doesn't seem to have a well-defined customization method beyond subclass, paste the superclass impl, and edit it. I don't like the . I want to create a variant which shows thumbnails for image choices. On Jun 4,

Re: use of HttpResponseForbidden(), etc.

2009-05-25 Thread notcourage
@require_GET def forbiddenView(request): return HttpResponseForbidden() --~--~-~--~~~---~--~~ 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

Re: use of HttpResponseForbidden(), etc.

2009-05-24 Thread notcourage
xt/html; charset=utf-8 < Location: http://localhost:8000/resources/users/login?next=/resources/users999/forbbidenView/ < * Closing connection #0 On May 24, 8:40 am, Karen Tracey <kmtra...@gmail.com> wrote: > On Sun, May 24, 2009 at 11:33 AM, notcourage <klr...@gmail.com> wro

Re: use of HttpResponseForbidden(), etc.

2009-05-24 Thread notcourage
I'm accustomed to seeing the browser present an error message instead of a blank page. curl shows a 301: curl -v http://localhost:8000/resources/users999/forbbidenView * About to connect() to localhost port 8000 (#0) * Trying 127.0.0.1... connected * Connected to localhost (127.0.0.1) port

ManyToMany relationships in an object creation view

2009-05-03 Thread notcourage
I'm interested in hearing how you cope w/ the problem of specifying ManyToMany relationships in an object creation view. Consider two models M1 & M2 and a creation view/form for M1. A technique I'm using is to specify M2 values as an unbound field in a ModelForm for M1. When the form validates: