diff options
author | Christian Heimes <cheimes@redhat.com> | 2015-06-15 17:22:09 +0200 |
---|---|---|
committer | Christian Heimes <cheimes@redhat.com> | 2015-06-16 16:57:24 +0200 |
commit | 6286bcbdc3675c4d5c92ac65a6602d136911a0f7 (patch) | |
tree | e17be3b1c9b18f88186f573ad59a70cd6b018c8f /base/common/upgrade | |
parent | a277f2740398a5574f9b4da46e869b05fef17a18 (diff) | |
download | pki-6286bcbdc3675c4d5c92ac65a6602d136911a0f7.tar.gz pki-6286bcbdc3675c4d5c92ac65a6602d136911a0f7.tar.xz pki-6286bcbdc3675c4d5c92ac65a6602d136911a0f7.zip |
Run pylint on upgrade scripts
pylint-build-scan.sh doesn't checked the upgrader's Python files yet.
This patch adds the common and server upgrade scripts to
pylint-build-scan.sh. It also fixes a couple of pylint violations,
mostly missing calls to __init__().
Diffstat (limited to 'base/common/upgrade')
-rwxr-xr-x | base/common/upgrade/10.0.1/01-AddJniJarDir | 8 | ||||
-rwxr-xr-x | base/common/upgrade/10.0.3/01-RemoveJniJarDir | 8 |
2 files changed, 8 insertions, 8 deletions
diff --git a/base/common/upgrade/10.0.1/01-AddJniJarDir b/base/common/upgrade/10.0.1/01-AddJniJarDir index 58b634f7f..1419eb9e5 100755 --- a/base/common/upgrade/10.0.1/01-AddJniJarDir +++ b/base/common/upgrade/10.0.1/01-AddJniJarDir @@ -28,7 +28,7 @@ import pki.upgrade class AddJniJarDir(pki.upgrade.PKIUpgradeScriptlet): def __init__(self): - + super(AddJniJarDir, self).__init__() self.message = 'Add JNI_JAR_DIR into pki.conf' def upgrade_system(self): @@ -40,11 +40,11 @@ class AddJniJarDir(pki.upgrade.PKIUpgradeScriptlet): default_path = default_conf.get('JNI_JAR_DIR') - file = os.path.join(pki.CONF_DIR, 'pki.conf') - self.backup(file) + filename = os.path.join(pki.CONF_DIR, 'pki.conf') + self.backup(filename) # read pki.conf - conf = pki.PropertyFile(file) + conf = pki.PropertyFile(filename) conf.read() # find JNI_JAR_DIR diff --git a/base/common/upgrade/10.0.3/01-RemoveJniJarDir b/base/common/upgrade/10.0.3/01-RemoveJniJarDir index 4efbfc6b6..86ff54a60 100755 --- a/base/common/upgrade/10.0.3/01-RemoveJniJarDir +++ b/base/common/upgrade/10.0.3/01-RemoveJniJarDir @@ -28,16 +28,16 @@ import pki.upgrade class RemoveJniJarDir(pki.upgrade.PKIUpgradeScriptlet): def __init__(self): - + super(RemoveJniJarDir, self).__init__() self.message = 'Remove JNI_JAR_DIR from /etc/pki/pki.conf' def upgrade_system(self): - file = os.path.join(pki.CONF_DIR, 'pki.conf') - self.backup(file) + filename = os.path.join(pki.CONF_DIR, 'pki.conf') + self.backup(filename) # read pki.conf - conf = pki.PropertyFile(file) + conf = pki.PropertyFile(filename) conf.read() self.update_system_config(conf) |