8b42f8a40c

This patch forces swiftclient to encode to utf-8 all url and headers arguments, to avoid the UnicodeDecodeError which is raised by '\r\n'.join([]) invoked in htplib.py. Currently the affected projects are Horizon(upload file with unicode name) and swiftclient CLI('swift post' with unicode filename as header) This is also a follow-up of this review: https://review.openstack.org/#/c/14216/ I'd still want to hear what the Swift core devs think of it. Is it better to create a new AutoEncodingHTTPConnection? Or to handle the connection creation and make sure there are no unicode and utf-8 string at the same time. If these unicode checks have to be added in the calling code(Dashboard, CLI), there are so many places to be added, and also in all new commands that might be exposed from the API. Fixes bug 1008940 Change-Id: Ice2aa29024429d3e6f569a88d5cf8b4202537827
Python bindings to the OpenStack Object Storage API
This is a python client for the Swift API. There's a Python API (the
swiftclient
module), and a command-line script
(swift
).
Development takes place via the usual OpenStack processes as outlined in the OpenStack wiki. The master repository is on GitHub.
This code is based on original the client previously included with OpenStack's swift The python-swiftclient is licensed under the Apache License like the rest of OpenStack.
Contents:
Description
Languages
Python
99.9%
Shell
0.1%