Senthil Kumaran <orsent...@gmail.com> added the comment:

Change is reverted from other branches too. Discussed in IRC, that changes made 
to an existing API like add_data,may break some existing applications, even if 
its done to prevent unsupported usage. 

Specifically, in mechanize's case, it was not reusing req object, but using 
add_data method more than once before req was getting submitted. This is under 
scenarios wherein code as in zope.testbrowser) is centered on the browser 
controls; any twiddle to a control could update the req object before its 
submitted. This could be changed in mechanize, but in general agreed to fact 
that changes to existing API should not result in breaking of apps.

We can address the non-reusablity of request by adding a boolean that signifies 
if a request has been used and throw an exception if one is used a second time 
( benji's suggestion). And of course clarify the supported and intended 
scenarios via documentation.

----------
resolution: fixed -> accepted

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue7540>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to