Django: Ticket #15050: FormWizard URLConf documentation misleading <p> The documentation suggests the following way to plug a FormWizard into the URLConf: </p> <pre class="wiki">from django.conf.urls.defaults import * from testapp.forms import ContactForm1, ContactForm2, ContactWizard urlpatterns = patterns('', (r'^contact/$', ContactWizard([ContactForm1, ContactForm2])), ) </pre><p> Unfortunately, this causes a single instance of the wizard to serve the whole application. Basically, all instance attributes are shared between all visitors (e.g. self.step, so the wizard is effectively unusable). </p> <p> To make the wizard handle every request in a dedicated instance, a wrapper function could be used, a'la: </p> <pre class="wiki">def contact_wizard(request, *args, **kwargs): wizard = ContactWizard([ContactForm1, ContactForm2]) return wizard(request, *args, **kwargs) urlpatterns = patterns('', (r'^contact/$', contact_wizard), ) </pre> en-us Django Trac 1.0 russellm Fri, 14 Jan 2011 15:12:35 GMT component, stage changed; needs_better_patch, needs_tests, keywords, needs_docs set <ul> <li><strong>needs_better_patch</strong> unset </li> <li><strong>component</strong> changed from <em>Documentation</em> to <em>django.contrib.formtools</em> </li> <li><strong>needs_tests</strong> unset </li> <li><strong>keywords</strong> <em>wizard</em> added </li> <li><strong>needs_docs</strong> unset </li> <li><strong>stage</strong> changed from <em>Unreviewed</em> to <em>Accepted</em> </li> </ul> <p> This isn't just a documentation issue -- it's pointing at a pretty glaring hole in the formwizard as currently implemented. </p> <p> Essentially, FormWizard needs to be updated to use Django's own class-based view structure (which took a long time to finalize specifically because of the issue you describe here). The good news is that there is at least one effort in the works to do just this -- Stephan Jäkel, has been working on <a class="ext-link" href=""><span class="icon">​</span>django-formwizard</a> to address this, and a couple of other problems with the FormWizard framework (<a class="closed ticket" href="" title="New feature: FormWizard don't process multipart forms (closed: fixed)">#7439</a>, <a class="closed ticket" href="" title="New feature: Add a session based form wizard (closed: fixed)">#9200</a>, <a class="closed ticket" href="" title="New feature: Formsets not supported as steps in FormWizard (closed: fixed)">#11112</a>). </p> Ticket anonymous Thu, 14 Apr 2011 02:59:17 GMT type, severity set <ul> <li><strong>type</strong> set to <em>Bug</em> </li> <li><strong>severity</strong> set to <em>Normal</em> </li> </ul> Ticket jezdez Wed, 01 Jun 2011 14:01:53 GMT status changed; resolution, easy set <ul> <li><strong>status</strong> changed from <em>new</em> to <em>closed</em> </li> <li><strong>resolution</strong> set to <em>fixed</em> </li> <li><strong>easy</strong> unset </li> </ul> <p> Superseded by <a class="closed ticket" href="" title="New feature: Add a session based form wizard (closed: fixed)">#9200</a>. </p> Ticket