Message96915
The problem here is that the headers are not updated if they already
exists. The solution is quite simple but breaks the tests because it
"clobbers the existing headers".
You can do this:
...
req.add_data(some_data)
req.add_unredirected_header('Content-Length', len(some_data))
urllib2.urlopen(req)
...
But is risky because all the other headers are still outdated.
Is there any reason why you need to reuse the request object? |
|
Date |
User |
Action |
Args |
2009-12-27 17:18:20 | pablomouzo | set | recipients:
+ pablomouzo, orsenthil, nirai, till |
2009-12-27 17:18:20 | pablomouzo | set | messageid: <1261934300.42.0.948657793798.issue7540@psf.upfronthosting.co.za> |
2009-12-27 17:18:18 | pablomouzo | link | issue7540 messages |
2009-12-27 17:18:18 | pablomouzo | create | |
|