Re: django-debug-toolbar with runserver not running on localhost
Or use the SHOW_TOOLBAR_CALLBACK to customize when you want the toolbar displayed... I simply ship with what I consider reasonably safe defaults. For example: # Always show the toolbar DEBUG_TOOLBAR_CONFIG = { 'SHOW_TOOLBAR_CALLBACK: lambda req: True, } # Only show toolbar for super user def custom_show_toolbar(request): if request.user.is_superuser: return True return False DEBUG_TOOLBAR_CONFIG = { 'SHOW_TOOLBAR_CALLBACK': custom_show_toolbar, } -Rob On Feb 5, 1:23 am, chefsmart wrote: > If you use dcamer's forkhttp://github.com/dcramer/django-debug-toolbar > > you won't have to rely on INTERNAL_IPS and you can simply log in as a > superuser to use django-debug-toolbar > > Regards. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@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.
Re: django-debug-toolbar with runserver not running on localhost
If you use dcamer's fork http://github.com/dcramer/django-debug-toolbar you won't have to rely on INTERNAL_IPS and you can simply log in as a superuser to use django-debug-toolbar Regards. On Feb 5, 2:53 am, HARRY POTTRER wrote: > gah you're correct, I can't believe I missed that setting. thanks > > On Feb 4, 4:48 pm, rebus_ wrote: > > > On 4 February 2010 22:06, HARRY POTTRER wrote: > > > > I've noticed that if I run the django dev server on localhost, debug- > > > toolbar works, but if I try to run he server like this: > > > > ./manage.py runserver 192.168.1.145:8000 > > > > the site will work, but the toolbar won't show up. Is there a work- > > > around for this? > > > > -- > > > You received this message because you are subscribed to the Google Groups > > > "Django users" group. > > > To post to this group, send email to django-us...@googlegroups.com. > > > To unsubscribe from this group, send email to > > > django-users+unsubscr...@googlegroups.com. > > > For more options, visit this group > > > athttp://groups.google.com/group/django-users?hl=en. > > > Do you maybe have INTERNAL_IPS set in your settings? > > It's used to decide on which addresses the toolbar will be shown. > > > Read more about this on:http://github.com/robhudson/django-debug-toolbar. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@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.
Re: django-debug-toolbar with runserver not running on localhost
gah you're correct, I can't believe I missed that setting. thanks On Feb 4, 4:48 pm, rebus_ wrote: > On 4 February 2010 22:06, HARRY POTTRER wrote: > > > I've noticed that if I run the django dev server on localhost, debug- > > toolbar works, but if I try to run he server like this: > > > ./manage.py runserver 192.168.1.145:8000 > > > the site will work, but the toolbar won't show up. Is there a work- > > around for this? > > > -- > > You received this message because you are subscribed to the Google Groups > > "Django users" group. > > To post to this group, send email to django-us...@googlegroups.com. > > To unsubscribe from this group, send email to > > django-users+unsubscr...@googlegroups.com. > > For more options, visit this group > > athttp://groups.google.com/group/django-users?hl=en. > > Do you maybe have INTERNAL_IPS set in your settings? > It's used to decide on which addresses the toolbar will be shown. > > Read more about this on:http://github.com/robhudson/django-debug-toolbar. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@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.
Re: django-debug-toolbar with runserver not running on localhost
On 4 February 2010 22:06, HARRY POTTRER wrote: > I've noticed that if I run the django dev server on localhost, debug- > toolbar works, but if I try to run he server like this: > > ./manage.py runserver 192.168.1.145:8000 > > the site will work, but the toolbar won't show up. Is there a work- > around for this? > > -- > You received this message because you are subscribed to the Google Groups > "Django users" group. > To post to this group, send email to django-us...@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. > > Do you maybe have INTERNAL_IPS set in your settings? It's used to decide on which addresses the toolbar will be shown. Read more about this on: http://github.com/robhudson/django-debug-toolbar. -- You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-us...@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.