Robie Basak 232a73de31 ubuntutools/misc: swap iter_content for raw stream
This is a partial revert of 1e20363.

When downloading a .diff.gz source package file, we do expect it to be
written to disk still compressed. If we were to uncompress it, then we
would get a size mismatch and even if we were to ignore that, we'd get a
hash mismatch.

On the other hand when downloading a changes file we need to make sure
that is written to disk uncompressed.

To make this work in both cases we can ask the HTTP server for no
special content encoding using "Accept-Encoding: identity". This is what
wget requests, for example. Then we can write the output to the file
without performing any decoding at our end by using the raw response
object again.

This fixes both cases.

LP: #2025748
2023-07-06 11:28:21 +01:00
..
2023-04-04 12:11:36 +02:00
2023-01-31 19:32:58 +01:00
2023-01-31 19:32:58 +01:00
2023-01-30 23:10:31 +01:00
2023-01-31 19:32:58 +01:00
2023-01-31 19:32:58 +01:00
2023-01-31 19:32:58 +01:00