def describe_active_stacks(b3_cloudformation):
    """Gets all active stacks in the aws account

    Args:
        b3_cloudformation: boto3 cloudformation client

    Returns:
        All active stacks
    """
    paginator = b3_cloudformation.get_paginator('describe_stacks')
    page_iterator = paginator.paginate()

    active_stacks = []

    # The 'StackStatus' can be any of the following
    # we only want to include 'active' stacks
    # that is, stacks which aren't being deleted, or didn't fail to create
    # 'CREATE_IN_PROGRESS'|'CREATE_FAILED'|'CREATE_COMPLETE'|
    # 'ROLLBACK_IN_PROGRESS'|'ROLLBACK_FAILED'|'ROLLBACK_COMPLETE'|
    # 'DELETE_IN_PROGRESS'|'DELETE_FAILED'|'DELETE_COMPLETE'|
    # 'UPDATE_IN_PROGRESS'|'UPDATE_COMPLETE_CLEANUP_IN_PROGRESS'|'UPDATE_COMPLETE'|
    # 'UPDATE_ROLLBACK_IN_PROGRESS'|'UPDATE_ROLLBACK_FAILED'|
    # 'UPDATE_ROLLBACK_COMPLETE_CLEANUP_IN_PROGRESS'|'UPDATE_ROLLBACK_COMPLETE'|
    # 'REVIEW_IN_PROGRESS',

    for page in page_iterator:
        for stack in page['Stacks']:
            if stack["StackStatus"] not in [
                    'CREATE_FAILED',
                    'DELETE_IN_PROGRESS',
                    'DELETE_COMPLETE',
                    'DELETE_FAILED'
                ]:
                active_stacks.append(stack)

    return active_stacks