glance/glance/contrib
Victor Stinner 6652f4b029 Fix Python 3 issues
* Replace unicode with six.text_type
* Replace "raise a, b, c" with six.reraise(a, b, c)
* Replace dict.iteritems() with six.iteritems(dict)
* Replace StringIO.StringIO with six.BytesIO for image content
* Get AssertionError from builtins, don't use the exceptions module
  which was removed in Python 3
* Open configuration file in text mode (not in binary mode) in
  functional tests
* Use absolute imports in artifacts_sample and image_artifact plugins
  instead of relative imports.
* Fix usage of __import__() function: the level parameter expects a
  positive integer, use level=0, not level=-1
* Get the input function from six.moves: use raw_input() on Python 2 and
  input() on Python 3. raw_input() was renamed to input() in Python 3.
* Unpacking parameters in function definition is no more possible:
  unpack the tuple manually in test_glance_replicator.py
* On Python 3, socket.fromfd() now returns directly the right socket
  type. It's not more needed to cast manually the result of
  socket.fromfd().

For more information on Python 3, see:
https://wiki.openstack.org/wiki/Python3

Change-Id: Iaa1a392590154058eab4645fb288d1534f66e528
2015-06-12 09:15:02 +00:00
..
plugins Fix Python 3 issues 2015-06-12 09:15:02 +00:00
__init__.py Artifact Plugins Loader 2015-03-30 20:51:10 +03:00