I just learnt that with Rails is possible to simulate HTTP requests in the console with few lines of code.
Check out: http://37signals.com/svn/posts/3176-three-quick-rails-console-tips (section "Dive into your app").
Is there a similar way to do that with Django? Would be handy.
How I simulate requests from the python command line is:
A simple way of simulating requests is:
Update: be sure to launch the django shell (via
manage.py shell
), not a classic python shell.Update 2: For Django <1.10, change the first line to