fix misspellings in logs, comments and tests

Flagged with: https://github.com/lyda/misspell-check
Run with: git ls-files | misspellings -f -

Fixes bug: 1100083
Change-Id: Icf1f844fea8ad0a1101d1dc64b9a126608e9536e
This commit is contained in:
Pádraig Brady 2013-01-16 17:52:38 +00:00
parent a4d608fa33
commit f379db545c
25 changed files with 44 additions and 45 deletions

View File

@ -65,7 +65,7 @@ Usage
* aggregate-add-host <id> <host> Add the host to the specified aggregate.
* aggregate-remove-host <id> <host> Remove the specified host from the specfied aggregate.
* aggregate-set-metadata <id> <key=value> [<key=value> ...] Update the metadata associated with the aggregate.
* aggregate-update <id> <name> [<availability_zone>] Update the aggregate's name and optionally availablity zone.
* aggregate-update <id> <name> [<availability_zone>] Update the aggregate's name and optionally availability zone.
* host-list List all hosts by service
* host-update --maintenance [enable | disable] Put/resume host into/from maintenance.

View File

@ -2566,7 +2566,7 @@ class ComputeManager(manager.SchedulerDependentManager):
mp)
except Exception: # pylint: disable=W0702
with excutils.save_and_reraise_exception():
msg = _("Faild to detach volume %(volume_id)s from %(mp)s")
msg = _("Failed to detach volume %(volume_id)s from %(mp)s")
LOG.exception(msg % locals(), context=context,
instance=instance)
volume = self.volume_api.get(context, volume_id)

View File

@ -1163,7 +1163,7 @@ class LinuxNetInterfaceDriver(object):
raise NotImplementedError()
def unplug(self, network):
"""Destory Linux device, return device name."""
"""Destroy Linux device, return device name."""
raise NotImplementedError()
def get_dev(self, network):
@ -1403,7 +1403,7 @@ def remove_ebtables_rules(rules):
def isolate_dhcp_address(interface, address):
# block arp traffic to address accross the interface
# block arp traffic to address across the interface
rules = []
rules.append('INPUT -p ARP -i %s --arp-ip-dst %s -j DROP'
% (interface, address))
@ -1419,7 +1419,7 @@ def isolate_dhcp_address(interface, address):
ipv4_filter.add_rule('FORWARD',
'-m physdev --physdev-out %s -d 255.255.255.255 '
'-p udp --dport 67 -j DROP' % interface, top=True)
# block ip traffic to address accross the interface
# block ip traffic to address across the interface
ipv4_filter.add_rule('FORWARD',
'-m physdev --physdev-in %s -d %s -j DROP'
% (interface, address), top=True)
@ -1429,7 +1429,7 @@ def isolate_dhcp_address(interface, address):
def remove_isolate_dhcp_address(interface, address):
# block arp traffic to address accross the interface
# block arp traffic to address across the interface
rules = []
rules.append('INPUT -p ARP -i %s --arp-ip-dst %s -j DROP'
% (interface, address))
@ -1445,7 +1445,7 @@ def remove_isolate_dhcp_address(interface, address):
ipv4_filter.remove_rule('FORWARD',
'-m physdev --physdev-out %s -d 255.255.255.255 '
'-p udp --dport 67 -j DROP' % interface, top=True)
# block ip traffic to address accross the interface
# block ip traffic to address across the interface
ipv4_filter.remove_rule('FORWARD',
'-m physdev --physdev-in %s -d %s -j DROP'
% (interface, address), top=True)

View File

@ -678,7 +678,7 @@ class FloatingIP(object):
# actually remove the ip address on the host. We are
# safe from races on this host due to the decorator,
# but another host might grab the ip right away. We
# don't worry about this case because the miniscule
# don't worry about this case because the minuscule
# window where the ip is on both hosts shouldn't cause
# any problems.
fixed_address = self.db.floating_ip_disassociate(context, address)

View File

@ -250,7 +250,7 @@ class VIF(Model):
'meta': {...}}]
"""
if self['network']:
# remove unecessary fields on fixed_ips
# remove unnecessary fields on fixed_ips
ips = [IP(**ensure_string_keys(ip)) for ip in self.fixed_ips()]
for ip in ips:
# remove floating ips from IP, since this is a flat structure

View File

@ -54,10 +54,10 @@ class CellsAdminAPITestCase(test.TestCase):
def fake_cast_to_cells(context, instance, method, *args, **kwargs):
"""
Makes sure that the cells recieve the cast to update
Makes sure that the cells receive the cast to update
the cell state
"""
self.cells_recieved_kwargs.update(kwargs)
self.cells_received_kwargs.update(kwargs)
self.admin_api = admin_actions.AdminActionsController()
self.admin_api.compute_api = compute_cells_api.ComputeCellsAPI()
@ -76,14 +76,14 @@ class CellsAdminAPITestCase(test.TestCase):
self.uuid = uuidutils.generate_uuid()
url = '/fake/servers/%s/action' % self.uuid
self.request = fakes.HTTPRequest.blank(url)
self.cells_recieved_kwargs = {}
self.cells_received_kwargs = {}
def test_reset_active(self):
body = {"os-resetState": {"state": "error"}}
result = self.admin_api._reset_state(self.request, 'inst_id', body)
self.assertEqual(result.status_int, 202)
# Make sure the cells recieved the update
self.assertEqual(self.cells_recieved_kwargs,
# Make sure the cells received the update
self.assertEqual(self.cells_received_kwargs,
dict(vm_state=vm_states.ERROR,
task_state=None))

View File

@ -60,7 +60,7 @@ class FakeRequest(object):
GET = {}
class FakeRequestWithSevice(object):
class FakeRequestWithService(object):
environ = {"nova.context": context.get_admin_context()}
GET = {"service": "nova-compute"}
@ -160,7 +160,7 @@ class ServicesTest(test.TestCase):
self.assertEqual(res_dict, response)
def test_services_list_with_service(self):
req = FakeRequestWithSevice()
req = FakeRequestWithService()
res_dict = self.controller.index(req)
response = {'services': [{'binary': 'nova-compute', 'host': 'host1',

View File

@ -618,7 +618,7 @@ class WsgiLimiterTest(BaseLimitTestSuite):
self.app = limits.WsgiLimiter(TEST_LIMITS)
def _request_data(self, verb, path):
"""Get data decribing a limit request verb/path."""
"""Get data describing a limit request verb/path."""
return jsonutils.dumps({"verb": verb, "path": path})
def _request(self, verb, url, username=None):

View File

@ -2961,7 +2961,7 @@ class ComputeTestCase(BaseTestCase):
call_info['expected_instance'] = instances[0]
self.compute._heal_instance_info_cache(ctxt)
self.assertEqual(call_info['get_all_by_host'], 2)
# Stays the same, beacuse the instance came from the DB
# Stays the same, because the instance came from the DB
self.assertEqual(call_info['get_by_uuid'], 3)
self.assertEqual(call_info['get_nw_info'], 4)
@ -5255,14 +5255,14 @@ class ComputeAPITestCase(BaseTestCase):
self.assertTrue(instance3['uuid'] in instance_uuids)
self.assertTrue(instance4['uuid'] in instance_uuids)
# multiple criterias as a dict
# multiple criteria as a dict
instances = self.compute_api.get_all(c,
search_opts={'metadata': {'key3': 'value3',
'key4': 'value4'}})
self.assertEqual(len(instances), 1)
self.assertEqual(instances[0]['uuid'], instance4['uuid'])
# multiple criterias as a list
# multiple criteria as a list
instances = self.compute_api.get_all(c,
search_opts={'metadata': [{'key4': 'value4'},
{'key3': 'value3'}]})
@ -6430,7 +6430,7 @@ class DisabledInstanceTypesTestCase(BaseTestCase):
"""
Some instance-types are marked 'disabled' which means that they will not
show up in customer-facing listings. We do, however, want those
instance-types to be availble for emergency migrations and for rebuilding
instance-types to be available for emergency migrations and for rebuilding
of existing instances.
One legitimate use of the 'disabled' field would be when phasing out a

View File

@ -129,7 +129,7 @@ class TestS3ImageService(test.TestCase):
'snapshot_id': 'snap-12345678',
'delete_on_termination': True},
{'device_name': '/dev/sda2',
'virutal_name': 'ephemeral0'},
'virtual_name': 'ephemeral0'},
{'device_name': '/dev/sdb0',
'no_device': True}]}}
_manifest, image, image_uuid = self.image_service._s3_parse_manifest(
@ -156,7 +156,7 @@ class TestS3ImageService(test.TestCase):
'snapshot_id': 'snap-12345678',
'delete_on_termination': True},
{'device_name': '/dev/sda2',
'virutal_name': 'ephemeral0'},
'virtual_name': 'ephemeral0'},
{'device_name': '/dev/sdb0',
'no_device': True}]
self.assertEqual(block_device_mapping, expected_bdm)

View File

@ -721,7 +721,7 @@ class ImageCacheManagerTestCase(test.TestCase):
def fq_path(path):
return os.path.join('/instance_path/_base/', path)
# Fake base directory existance
# Fake base directory existence
orig_exists = os.path.exists
def exists(path):
@ -747,7 +747,7 @@ class ImageCacheManagerTestCase(test.TestCase):
'/instance_path/_base/%s_sm' % hashed_42]:
return False
self.fail('Unexpected path existance check: %s' % path)
self.fail('Unexpected path existence check: %s' % path)
self.stubs.Set(os.path, 'exists', lambda x: exists(x))

View File

@ -570,7 +570,6 @@ class LibvirtConnTestCase(test.TestCase):
self.context = context.get_admin_context()
self.flags(instances_path='')
self.flags(libvirt_snapshots_directory='')
self.call_libvirt_dependant_setup = False
self.useFixture(fixtures.MonkeyPatch(
'nova.virt.libvirt.driver.libvirt_utils',
fake_libvirt_utils))
@ -3100,7 +3099,7 @@ class LibvirtConnTestCase(test.TestCase):
self.stubs.Set(conn, 'get_info', fake_get_info)
instance = {"name": "instancename", "id": "instanceid",
"uuid": "875a8070-d0b9-4949-8b31-104d125c9a64"}
# NOTE(vish): verifies destory doesn't raise if the instance disappears
# NOTE(vish): verifies destroy doesn't raise if the instance disappears
conn._destroy(instance)
def test_available_least_handles_missing(self):

View File

@ -47,7 +47,7 @@ def _get_connect_string(backend,
passwd="openstack_citest",
database="openstack_citest"):
"""
Try to get a connection with a very specfic set of values, if we get
Try to get a connection with a very specific set of values, if we get
these then we'll run the tests, otherwise they are skipped
"""
if backend == "postgres":
@ -195,7 +195,7 @@ class TestMigrations(test.TestCase):
"~/.pgpass && chmod 0600 ~/.pgpass" % locals())
execute_cmd(createpgpass)
# note(boris-42): We must create and drop database, we can't
# drop database wich we have connected to, so for such
# drop database which we have connected to, so for such
# operations there is a special database template1.
sqlcmd = ("psql -w -U %(user)s -h %(host)s -c"
" '%(sql)s' -d template1")

View File

@ -51,11 +51,11 @@ class PipelibTest(test.TestCase):
def test_setup_security_group(self):
group_name = "%s%s" % (self.project, CONF.vpn_key_suffix)
# First attemp, does not exist (thus its created)
# First attempt, does not exist (thus its created)
res1_group = self.cloudpipe.setup_security_group(self.context)
self.assertEqual(res1_group, group_name)
# Second attem, it exists in the DB
# Second attempt, it exists in the DB
res2_group = self.cloudpipe.setup_security_group(self.context)
self.assertEqual(res1_group, res2_group)
@ -64,10 +64,10 @@ class PipelibTest(test.TestCase):
with utils.tempdir() as tmpdir:
self.flags(keys_path=tmpdir)
# First attemp, key does not exist (thus it is generated)
# First attempt, key does not exist (thus it is generated)
res1_key = self.cloudpipe.setup_key_pair(self.context)
self.assertEqual(res1_key, key_name)
# Second attem, it exists in the DB
# Second attempt, it exists in the DB
res2_key = self.cloudpipe.setup_key_pair(self.context)
self.assertEqual(res2_key, res1_key)

View File

@ -146,7 +146,7 @@ class IptablesFirewallDriver(FirewallDriver):
self.iptables = linux_net.iptables_manager
self.instances = {}
self.network_infos = {}
self.basicly_filtered = False
self.basically_filtered = False
self.iptables.ipv4['filter'].add_chain('sg-fallback')
self.iptables.ipv4['filter'].add_rule('sg-fallback', '-j DROP')

View File

@ -183,7 +183,7 @@ class VolumeOps(baseops.BaseOps):
"SELECT * FROM Msvm_ResourceAllocationSettingData \
WHERE ResourceSubType LIKE 'Microsoft Physical Disk Drive'\
AND Parent = '" + scsi_controller.path_() + "'")
#Slots starts from 0, so the lenght of the disks gives us the free slot
#Slots starts from 0, so the length of the disks gives us the free slot
return len(volumes)
def detach_volume(self, connection_info, instance_name, mountpoint):

View File

@ -123,7 +123,7 @@ class QemuImgInfo(object):
if len(line_pieces) != 6:
break
else:
# Check against this pattern occuring in the final position
# Check against this pattern in the final position
# "%02d:%02d:%02d.%03d"
date_pieces = line_pieces[5].split(":")
if len(date_pieces) != 3:

View File

@ -2768,7 +2768,7 @@ class LibvirtDriver(driver.ComputeDriver):
:param instance_ref:
nova.db.sqlalchemy.models.Instance object
instance object that is migrated.
:param network_info: instance network infomation
:param network_info: instance network information
:param block_migration: if true, post operation of block_migraiton.
"""
# Define migrated instance, otherwise, suspend/destroy does not work.

View File

@ -228,11 +228,11 @@ class IptablesFirewallDriver(base_firewall.IptablesFirewallDriver):
def setup_basic_filtering(self, instance, network_info):
"""Set up provider rules and basic NWFilter."""
self.nwfilter.setup_basic_filtering(instance, network_info)
if not self.basicly_filtered:
if not self.basically_filtered:
LOG.debug(_('iptables firewall: Setup Basic Filtering'),
instance=instance)
self.refresh_provider_fw_rules()
self.basicly_filtered = True
self.basically_filtered = True
def apply_instance_filter(self, instance, network_info):
"""No-op. Everything is done in prepare_instance_filter."""

View File

@ -77,7 +77,7 @@ CONF.import_opt('instances_path', 'nova.compute.manager')
def get_info_filename(base_path):
"""Construct a filename for storing addtional information about a base
"""Construct a filename for storing additional information about a base
image.
Returns a filename.

View File

@ -55,7 +55,7 @@ def get_powervm_disk_adapter():
class PowerVMOperator(object):
"""PowerVM main operator.
The PowerVMOperator is intented to wrapper all operations
The PowerVMOperator is intended to wrap all operations
from the driver and handle either IVM or HMC managed systems.
"""

View File

@ -38,7 +38,7 @@ def get_network_with_the_name(session, network_name="vmnet0"):
vm_networks_ret = hostsystems[0].propSet[0].val
# Meaning there are no networks on the host. suds responds with a ""
# in the parent property field rather than a [] in the
# ManagedObjectRefernce property field of the parent
# ManagedObjectReference property field of the parent
if not vm_networks_ret:
return None
vm_networks = vm_networks_ret.ManagedObjectReference

View File

@ -506,7 +506,7 @@ class XenAPIDriver(driver.ComputeDriver):
:params instance_ref:
nova.db.sqlalchemy.models.Instance object
instance object that is migrated.
:params network_info: instance network infomation
:params network_info: instance network information
:params : block_migration: if true, post operation of block_migraiton.
"""
# TODO(JohnGarbutt) look at moving/downloading ramdisk and kernel

View File

@ -1510,7 +1510,7 @@ def fetch_bandwidth(session):
def compile_metrics(start_time, stop_time=None):
"""Compile bandwidth usage, cpu, and disk metrics for all VMs on
this host.
Note that some stats, like bandwith, do not seem to be very
Note that some stats, like bandwidth, do not seem to be very
accurate in some of the data from XenServer (mdragon). """
start_time = int(start_time)

View File

@ -16,7 +16,7 @@
# under the License.
"""
XenAPI Plugin for transfering data between host nodes
XenAPI Plugin for transferring data between host nodes
"""
import utils