Merge pull request #2571 from asherf/lint

Fix some typos
This commit is contained in:
Mike Grima 2019-11-17 15:44:45 -08:00 committed by GitHub
commit a882d022ef
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 11 additions and 11 deletions

View File

@ -624,7 +624,7 @@ class BatchBackend(BaseBackend):
def get_job_definition(self, identifier): def get_job_definition(self, identifier):
""" """
Get job defintiion by name or ARN Get job definitions by name or ARN
:param identifier: Name or ARN :param identifier: Name or ARN
:type identifier: str :type identifier: str
@ -643,7 +643,7 @@ class BatchBackend(BaseBackend):
def get_job_definitions(self, identifier): def get_job_definitions(self, identifier):
""" """
Get job defintiion by name or ARN Get job definitions by name or ARN
:param identifier: Name or ARN :param identifier: Name or ARN
:type identifier: str :type identifier: str
@ -934,7 +934,7 @@ class BatchBackend(BaseBackend):
self.ecs_backend.delete_cluster(compute_env.ecs_name) self.ecs_backend.delete_cluster(compute_env.ecs_name)
if compute_env.env_type == "MANAGED": if compute_env.env_type == "MANAGED":
# Delete compute envrionment # Delete compute environment
instance_ids = [instance.id for instance in compute_env.instances] instance_ids = [instance.id for instance in compute_env.instances]
self.ec2_backend.terminate_instances(instance_ids) self.ec2_backend.terminate_instances(instance_ids)
@ -1195,7 +1195,7 @@ class BatchBackend(BaseBackend):
depends_on=None, depends_on=None,
container_overrides=None, container_overrides=None,
): ):
# TODO parameters, retries (which is a dict raw from request), job dependancies and container overrides are ignored for now # TODO parameters, retries (which is a dict raw from request), job dependencies and container overrides are ignored for now
# Look for job definition # Look for job definition
job_def = self.get_job_definition(job_def_id) job_def = self.get_job_definition(job_def_id)

View File

@ -125,7 +125,7 @@ class HTTPrettyRequest(BaseHTTPRequestHandler, BaseClass):
internal `parse_request` method. internal `parse_request` method.
It also replaces the `rfile` and `wfile` attributes with StringIO It also replaces the `rfile` and `wfile` attributes with StringIO
instances so that we garantee that it won't make any I/O, neighter instances so that we guarantee that it won't make any I/O, neighter
for writing nor reading. for writing nor reading.
It has some convenience attributes: It has some convenience attributes:

View File

@ -190,7 +190,7 @@ def create_backend_app(service):
index = 2 index = 2
while endpoint in backend_app.view_functions: while endpoint in backend_app.view_functions:
# HACK: Sometimes we map the same view to multiple url_paths. Flask # HACK: Sometimes we map the same view to multiple url_paths. Flask
# requries us to have different names. # requires us to have different names.
endpoint = original_endpoint + str(index) endpoint = original_endpoint + str(index)
index += 1 index += 1

View File

@ -147,7 +147,7 @@ class SESBackend(BaseBackend):
def __type_of_message__(self, destinations): def __type_of_message__(self, destinations):
"""Checks the destination for any special address that could indicate delivery, """Checks the destination for any special address that could indicate delivery,
complaint or bounce like in SES simualtor""" complaint or bounce like in SES simulator"""
alladdress = ( alladdress = (
destinations.get("ToAddresses", []) destinations.get("ToAddresses", [])
+ destinations.get("CcAddresses", []) + destinations.get("CcAddresses", [])

View File

@ -227,7 +227,7 @@ class Subscription(BaseModel):
return False return False
for attribute_values in attribute_values: for attribute_values in attribute_values:
# Even the offical documentation states a 5 digits of accuracy after the decimal point for numerics, in reality it is 6 # Even the official documentation states a 5 digits of accuracy after the decimal point for numerics, in reality it is 6
# https://docs.aws.amazon.com/sns/latest/dg/sns-subscription-filter-policies.html#subscription-filter-policy-constraints # https://docs.aws.amazon.com/sns/latest/dg/sns-subscription-filter-policies.html#subscription-filter-policy-constraints
if int(attribute_values * 1000000) == int(rule * 1000000): if int(attribute_values * 1000000) == int(rule * 1000000):
return True return True
@ -573,7 +573,7 @@ class SNSBackend(BaseBackend):
combinations = 1 combinations = 1
for rules in six.itervalues(value): for rules in six.itervalues(value):
combinations *= len(rules) combinations *= len(rules)
# Even the offical documentation states the total combination of values must not exceed 100, in reality it is 150 # Even the official documentation states the total combination of values must not exceed 100, in reality it is 150
# https://docs.aws.amazon.com/sns/latest/dg/sns-subscription-filter-policies.html#subscription-filter-policy-constraints # https://docs.aws.amazon.com/sns/latest/dg/sns-subscription-filter-policies.html#subscription-filter-policy-constraints
if combinations > 150: if combinations > 150:
raise SNSInvalidParameter( raise SNSInvalidParameter(

View File

@ -761,7 +761,7 @@ class SQSBackend(BaseBackend):
new_messages = [] new_messages = []
for message in queue._messages: for message in queue._messages:
# Only delete message if it is not visible and the reciept_handle # Only delete message if it is not visible and the receipt_handle
# matches. # matches.
if message.receipt_handle == receipt_handle: if message.receipt_handle == receipt_handle:
queue.pending_messages.remove(message) queue.pending_messages.remove(message)

View File

@ -430,7 +430,7 @@ class WorkflowExecution(BaseModel):
) )
def fail(self, event_id, details=None, reason=None): def fail(self, event_id, details=None, reason=None):
# TODO: implement lenght constraints on details/reason # TODO: implement length constraints on details/reason
self.execution_status = "CLOSED" self.execution_status = "CLOSED"
self.close_status = "FAILED" self.close_status = "FAILED"
self.close_timestamp = unix_time() self.close_timestamp = unix_time()