]> git.apps.os.sepia.ceph.com Git - teuthology.git/commitdiff
Fix unused vars, unused imports, and aliasing
authorJosh Durgin <josh.durgin@inktank.com>
Thu, 21 Feb 2013 22:47:00 +0000 (14:47 -0800)
committerJosh Durgin <josh.durgin@inktank.com>
Thu, 21 Feb 2013 22:47:00 +0000 (14:47 -0800)
Found by pyflakes

Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
teuthology/nuke.py
teuthology/task/ceph.py
teuthology/task/install.py
teuthology/task/manypools.py

index 0c6b8a5e04f046d731d7274e777e0af73ddde321..01390da5210ba1b7c303e4b73c196245957bf1f6 100644 (file)
@@ -152,7 +152,6 @@ def remove_osd_mounts(ctx, log):
     unmount any osd data mounts (scratch disks)
     """
     from .orchestra import run
-    from teuthology.misc import get_testdir
     ctx.cluster.run(
         args=[
             'grep',
index be6b7eee3334d8498c38eff9c58b3bda45833631..3c69f502e7be90adef4ee231673c0418bd1e37ef 100644 (file)
@@ -8,7 +8,6 @@ import sys
 
 from teuthology import misc as teuthology
 from teuthology import contextutil
-from teuthology.parallel import parallel
 from ..orchestra import run
 
 log = logging.getLogger(__name__)
@@ -210,7 +209,6 @@ def valgrind_post(ctx, config):
 
 
 def mount_osd_data(ctx, remote, osd):
-    testdir = teuthology.get_testdir(ctx)
     log.debug('Mounting data for osd.{o} on {r}'.format(o=osd, r=remote))
     if remote in ctx.disk_config.remote_to_roles_to_dev and osd in ctx.disk_config.remote_to_roles_to_dev[remote]:
         dev = ctx.disk_config.remote_to_roles_to_dev[remote][osd]
@@ -308,8 +306,8 @@ def cluster(ctx, config):
 
     log.info('Generating config...')
     remotes_and_roles = ctx.cluster.remotes.items()
-    roles = [roles for (remote, roles) in remotes_and_roles]
-    ips = [host for (host, port) in (remote.ssh.get_transport().getpeername() for (remote, roles) in remotes_and_roles)]
+    roles = [role_list for (remote, role_list) in remotes_and_roles]
+    ips = [host for (host, port) in (remote.ssh.get_transport().getpeername() for (remote, role_list) in remotes_and_roles)]
     conf = teuthology.skeleton_config(ctx, roles=roles, ips=ips)
     for remote, roles_to_journals in remote_to_roles_to_journals.iteritems():
         for role, journal in roles_to_journals.iteritems():
index 8b6025fb9fd9c0876f967e97cdb165e47989e350..9a745aaebfdae6bf16a68fad8cb4270af33738cc 100644 (file)
@@ -1,10 +1,7 @@
 from cStringIO import StringIO
 
-import argparse
 import contextlib
 import logging
-import os
-import sys
 
 from teuthology import misc as teuthology
 from teuthology import contextutil
index 8e02ca4d48554af0de9f89d17cbde663d326781f..cf9d5b54da56c24a39aad9b1aac030f361227b77 100644 (file)
@@ -28,8 +28,6 @@ def task(ctx, config):
         time: 360
     """
     
-    testdir = teuthology.get_testdir(ctx)
-
     log.info('creating {n} pools'.format(n=config))
     
     poolnum = int(config)