title: mechanize raises BrowserStateError
body: <p>I have the following code:</p>
  
  <pre><code>br = mechanize.Browser()
  br._factory.is_html = True
  br.form = mechanize._form.ParseString('&lt;form method="post"&lt;/form&gt;', 'http://localhost/post.php')[1]
  
  br.form.new_control('text', 'test',{'value':'something'})
  br.form.fixup()
  br.submit()
  </code></pre>
  
  <p>The code works sometimes but other times it raises BrowserStateError: not viewing HTML. Am I not overriding _factory.is_html correctly?</p>