← Back to team overview

cloud-init-dev team mailing list archive

[Merge] lp:~james-slagle/cloud-init/lp-1260072 into lp:cloud-init

 

James Slagle has proposed merging lp:~james-slagle/cloud-init/lp-1260072 into lp:cloud-init.

Requested reviews:
  cloud init development team (cloud-init-dev)
Related bugs:
  Bug #1260072 in cloud-init: "TypeError trying to write a file specified in OpenStack Configuration Drive"
  https://bugs.launchpad.net/cloud-init/+bug/1260072

For more details, see:
https://code.launchpad.net/~james-slagle/cloud-init/lp-1260072/+merge/198964

Proposed patch for https://bugs.launchpad.net/cloud-init/+bug/1260072
-- 
https://code.launchpad.net/~james-slagle/cloud-init/lp-1260072/+merge/198964
Your team cloud init development team is requested to review the proposed merge of lp:~james-slagle/cloud-init/lp-1260072 into lp:cloud-init.
=== modified file 'cloudinit/util.py'
--- cloudinit/util.py	2013-11-14 03:28:52 +0000
+++ cloudinit/util.py	2013-12-13 15:44:46 +0000
@@ -170,6 +170,8 @@
     def __exit__(self, excp_type, excp_value, excp_traceback):
         if self.selinux and self.selinux.is_selinux_enabled():
             path = os.path.realpath(os.path.expanduser(self.path))
+            # path should be a string, not unicode
+            path = str(path)
             do_restore = False
             try:
                 # See if even worth restoring??


Follow ups