epsagon/list-lambdas

Unhandled ResourceNotFoundException

ceich opened this issue · 3 comments

ceich commented
 73% (11 of 15) |######################################################################################################################################                                                  | Elapsed Time: 0:00:15 ETA:  0:00:05Traceback (most recent call last):
  File "list_lambdas.py", line 230, in <module>
    print_lambda_list(args)
  File "list_lambdas.py", line 144, in print_lambda_list
    descending=True
  File "/Library/Python/2.7/site-packages/botocore/client.py", line 317, in _api_call
    return self._make_api_call(operation_name, kwargs)
  File "/Library/Python/2.7/site-packages/botocore/client.py", line 615, in _make_api_call
    raise error_class(parsed_response, operation_name)
botocore.errorfactory.ResourceNotFoundException: An error occurred (ResourceNotFoundException) when calling the DescribeLogStreams operation: The specified log group does not exist.

Thanks for the report.

Would you be able to check whether you have a log group in CloudWatch for the relevant Lambda function?
(By default every lambda has log group with the name of the function, and in the same region).

ceich commented

Indeed, I found a lambda without a log group. When I created one (with the prefix /aws/lambda/), the tool ran to completion. Not sure how it got this way, but there was an "extra" log group so the Lambda may have been renamed.

Thanks,

the code now catching botocore exception if the is not log group for the relevant data, and a N/A will be displayed as the last invocation for the Lambda.