Glance download with allowed_direct_url_schemes sometimes fails with Python 3
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Cinder |
Fix Released
|
High
|
Eric Harney | ||
Train |
New
|
Undecided
|
Unassigned | ||
Ussuri |
Fix Committed
|
Undecided
|
Unassigned | ||
Victoria |
New
|
Undecided
|
Unassigned | ||
Wallaby |
Fix Committed
|
Undecided
|
Unassigned | ||
Xena |
Fix Released
|
High
|
Eric Harney |
Bug Description
This is similar to 1775678 and a few others. The code in GlanceImageServ
with open(parsed_
shutil.
This code only takes effect if "file" is specified for allowed_
This results in hard to debug character set errors during image download. Luckily, it seems that the image usually fails to download with an obscure error rather than becoming corrupt.
This should have been caught with the move to Python 3. Python 3 requires "rb" when opening binary files. "r" opens in text mode. It may be that allowed_
https:/ /review. opendev. org/c/openstack /cinder/ +/785878