I created a simple code in AWS Lambda for listing my buckets
import boto3
import botocore
s3 = boto3.client('s3')
response = s3.list_buckets()
print('Existing buckets:')
for bucket in response['Buckets']:
print(f' {bucket["Name"]}')
When I Deploy and test it, it gives me the right logs (my list of buckets) but it also gives me the error
Handler 'lambda_handler' missing on module 'lambda_function'
Do i have to write lambda_function(event,context) for everything?