summaryrefslogtreecommitdiff
path: root/cloudinit
diff options
context:
space:
mode:
authorShreenidhi Shedi <53473811+sshedi@users.noreply.github.com>2021-09-01 19:53:55 +0530
committerGitHub <noreply@github.com>2021-09-01 09:23:55 -0500
commit58c2de4c97de6cfa6edbf5319641f2ef71284895 (patch)
tree3f8806eeb1e61a408f85f48b9a07d85b981acf50 /cloudinit
parent76cff793840be63a69a74293170122c189ebaead (diff)
downloadvyos-cloud-init-58c2de4c97de6cfa6edbf5319641f2ef71284895.tar.gz
vyos-cloud-init-58c2de4c97de6cfa6edbf5319641f2ef71284895.zip
Fix `make style-check` errors (#1000)
Using flake8 inplace of pyflakes Renamed run-pyflakes -> run-flake8 Changed target name to flake8 in Makefile With pyflakes we can't suppress warnings/errors in few required places. flake8 is flexible in that regard. Hence using flake8 seems to be a better choice here. flake8 does the job of pep8 anyway. So, removed pep8 target from Makefile along with tools/run-pep8 script. Included setup.py in flake8 checks
Diffstat (limited to 'cloudinit')
-rw-r--r--cloudinit/cmd/devel/hotplug_hook.py3
-rwxr-xr-xcloudinit/distros/__init__.py2
-rw-r--r--cloudinit/sources/__init__.py2
-rw-r--r--cloudinit/stages.py2
4 files changed, 5 insertions, 4 deletions
diff --git a/cloudinit/cmd/devel/hotplug_hook.py b/cloudinit/cmd/devel/hotplug_hook.py
index a0058f03..d4f0547e 100644
--- a/cloudinit/cmd/devel/hotplug_hook.py
+++ b/cloudinit/cmd/devel/hotplug_hook.py
@@ -13,7 +13,8 @@ from cloudinit.net import activators, read_sys_net_safe
from cloudinit.net.network_state import parse_net_config_data
from cloudinit.reporting import events
from cloudinit.stages import Init
-from cloudinit.sources import DataSource, DataSourceNotFoundException
+from cloudinit.sources import DataSource # noqa: F401
+from cloudinit.sources import DataSourceNotFoundException
LOG = log.getLogger(__name__)
diff --git a/cloudinit/distros/__init__.py b/cloudinit/distros/__init__.py
index a634623a..2e629143 100755
--- a/cloudinit/distros/__init__.py
+++ b/cloudinit/distros/__init__.py
@@ -16,7 +16,7 @@ import stat
import string
import urllib.parse
from io import StringIO
-from typing import Any, Mapping
+from typing import Any, Mapping # noqa: F401
from cloudinit import importer
from cloudinit import log as logging
diff --git a/cloudinit/sources/__init__.py b/cloudinit/sources/__init__.py
index cc7e1c3c..54b8240a 100644
--- a/cloudinit/sources/__init__.py
+++ b/cloudinit/sources/__init__.py
@@ -13,7 +13,7 @@ import copy
import json
import os
from collections import namedtuple
-from typing import Dict, List
+from typing import Dict, List # noqa: F401
from cloudinit import dmi
from cloudinit import importer
diff --git a/cloudinit/stages.py b/cloudinit/stages.py
index bc164fa0..80aa9f5e 100644
--- a/cloudinit/stages.py
+++ b/cloudinit/stages.py
@@ -9,7 +9,7 @@ import os
import pickle
import sys
from collections import namedtuple
-from typing import Dict, Set
+from typing import Dict, Set # noqa: F401
from cloudinit.settings import (
FREQUENCIES, CLOUD_CONFIG, PER_INSTANCE, PER_ONCE, RUN_CLOUD_CONFIG)