Bug 1460351 - oz fails direct boot because requests library automatically decodes gzip content
Summary: oz fails direct boot because requests library automatically decodes gzip content
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: oz
Version: 25
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Brendan Reilly
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-06-09 19:41 UTC by Dusty Mabe
Modified: 2017-11-21 02:10 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-11-21 02:10:53 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Patch to backport gzip decompression fix (3.15 KB, patch)
2017-06-09 20:46 UTC, Brendan Reilly
no flags Details | Diff

Description Dusty Mabe 2017-06-09 19:41:34 UTC
https://github.com/clalancette/oz/issues/237

We [recently](https://github.com/clalancette/oz/pull/231) switched to the requests library in oz. This works fine for the most part but the requests library has an interesting (and mostly useful) [feature](http://docs.python-requests.org/en/master/user/quickstart/#binary-response-content) where `The gzip and deflate transfer-encodings are automatically decoded for you.`

This does not play well with oz when trying to calculate if the file received was the right content length. We [write out the response from the requests library to a file](https://github.com/clalancette/oz/blob/23dafef3fd8e2d0b6426a52fc93f19e437a70c48/oz/ozutil.py#L835-L845) and then we [check](https://github.com/clalancette/oz/blob/23dafef3fd8e2d0b6426a52fc93f19e437a70c48/oz/Guest.py#L972) that the file size matches the content length from the http header. If it doesn't match, we move on to trying to boot from a `boot.iso`, which also [doesn't work](https://github.com/clalancette/oz/issues/236) for aarch64.


We need to get the patch from https://github.com/clalancette/oz/pull/238 into our version of oz.

Comment 1 Brendan Reilly 2017-06-09 20:46:00 UTC
Created attachment 1286532 [details]
Patch to backport gzip decompression fix

I've created and attached a patch for the oz dist git f25 branch using that upstream PR.

Comment 2 Dusty Mabe 2017-06-12 14:56:23 UTC
patch merged and build from koji:

https://koji.fedoraproject.org/koji/taskinfo?taskID=19982881

Comment 3 Fedora End Of Life 2017-11-16 18:49:32 UTC
This message is a reminder that Fedora 25 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 25. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '25'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version'
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not
able to fix it before Fedora 25 is end of life. If you would still like
to see this bug fixed and are able to reproduce it against a later version
of Fedora, you are encouraged  change the 'version' to a later Fedora
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's
lifetime, sometimes those efforts are overtaken by events. Often a
more recent Fedora release includes newer upstream software that fixes
bugs or makes them obsolete.

Comment 4 Chris Lalancette 2017-11-21 02:10:53 UTC
Closing this out, since we got this in.


Note You need to log in before you can comment on or make changes to this bug.