diff options
author | Daniel Watkins <oddbloke@ubuntu.com> | 2020-07-13 12:00:32 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-07-13 12:00:32 -0400 |
commit | 3cec3881062490727c5fff1b16b53f0176f976f0 (patch) | |
tree | a26576249a456556bfe2557d273af5192bd41985 /cloudinit/config | |
parent | fecbd81889011e8a75badd18935297f3494fe485 (diff) | |
download | vyos-cloud-init-3cec3881062490727c5fff1b16b53f0176f976f0.tar.gz vyos-cloud-init-3cec3881062490727c5fff1b16b53f0176f976f0.zip |
cloudinit: remove global disable of pylint W0105 and fix errors (#480)
This includes a fix to a test that had a string concatenation issue, and
so was only testing a prefix of what was intended.
Diffstat (limited to 'cloudinit/config')
-rw-r--r-- | cloudinit/config/cc_resizefs.py | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/cloudinit/config/cc_resizefs.py b/cloudinit/config/cc_resizefs.py index 8de4db30..978d2ee0 100644 --- a/cloudinit/config/cc_resizefs.py +++ b/cloudinit/config/cc_resizefs.py @@ -118,14 +118,12 @@ def _can_skip_resize_ufs(mount_point, devpth): if o == "-f": frag_sz = int(a) # check the current partition size - """ - # gpart show /dev/da0 -=> 40 62914480 da0 GPT (30G) - 40 1024 1 freebsd-boot (512K) - 1064 58719232 2 freebsd-ufs (28G) - 58720296 3145728 3 freebsd-swap (1.5G) - 61866024 1048496 - free - (512M) - """ + # Example output from `gpart show /dev/da0`: + # => 40 62914480 da0 GPT (30G) + # 40 1024 1 freebsd-boot (512K) + # 1064 58719232 2 freebsd-ufs (28G) + # 58720296 3145728 3 freebsd-swap (1.5G) + # 61866024 1048496 - free - (512M) expect_sz = None m = re.search('^(/dev/.+)p([0-9])$', devpth) gpart_res = _get_gpart_output(m.group(1)) |