more useful logs

This commit is contained in:
Jun-te Kim 2026-02-09 18:53:49 +00:00
parent b9d31fa615
commit 10c552772b

View file

@ -119,8 +119,17 @@ def main():
def handler(event, context):
print("hello Postcode splitter world")
return {"statusCode": 200, "body": "hello world"}
print(f"Function: {context.function_name}")
print(f"Function Version: {context.function_version}")
print(f"Log Group: {context.log_group_name}")
print(f"Log Stream: {context.log_stream_name}")
print(f"Request ID: {context.aws_request_id}")
print(f"Memory Limit: {context.memory_limit_in_mb} MB")
print(f"Remaining Time: {context.get_remaining_time_in_millis()} ms")
print(f"Event: {event}")
print("Postcode splitter handler invoked")
return {"statusCode": 200, "body": "postcode splitter executed"}
if __name__ == "__main__":