mechanize
mechanize copied to clipboard
Redirect request must visit if original request does
If you navigate to a page A that redirect to page B, the page you visit is the page B. This is the page that must be added to the history. When reload()ing the browser, that the page B that must be requested, not page A
This is really problematic if the page A is a submitted form.
The fix is easy, however it break a doctest but, as explain above, this test seems based on a false assumption.
Patch: http://paste.pocoo.org/show/229138/
For testing purpose, here is a simple server and a test script http://paste.pocoo.org/show/229139/ http://paste.pocoo.org/show/229140/