← Back to team overview

cloud-init-dev team mailing list archive

[Merge] lp:~harlowja/cloud-init/fix-auto-bool into lp:cloud-init

 

Joshua Harlow has proposed merging lp:~harlowja/cloud-init/fix-auto-bool into lp:cloud-init.

Requested reviews:
  cloud init development team (cloud-init-dev)

For more details, see:
https://code.launchpad.net/~harlowja/cloud-init/fix-auto-bool/+merge/208950

Remove usage of bool as string

The net_util format is that 'auto' if
it exists will be a boolean so it is likely
that the code that exists does not correctly
work in this mode (since it tries to do a
lower() call on a boolean, which will not work).
-- 
https://code.launchpad.net/~harlowja/cloud-init/fix-auto-bool/+merge/208950
Your team cloud init development team is requested to review the proposed merge of lp:~harlowja/cloud-init/fix-auto-bool into lp:cloud-init.
=== modified file 'cloudinit/distros/sles.py'
--- cloudinit/distros/sles.py	2014-01-23 19:06:13 +0000
+++ cloudinit/distros/sles.py	2014-03-02 01:30:27 +0000
@@ -65,7 +65,7 @@
         for (dev, info) in entries.iteritems():
             net_fn = self.network_script_tpl % (dev)
             mode = info.get('auto')
-            if mode and mode.lower() == 'true':
+            if mode:
                 mode = 'auto'
             else:
                 mode = 'manual'


Follow ups