aws / aws/aws-lambda-python-runtime-interface-client

Typing annotations

Đang mở
#18 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
Python
Star
294
Fork
84
Merge trung bình
3 ngày 7 phút
Pull request đã merge (30 ngày)
3

Mô tả

I've created typing annotations for `LambdaContext` and corresponding classes.

https://github.com/toidi/awslambdaric-stubs

It's useful in lambda handlers:

```python
import typing
if typing.TYPE_CHECKING: # pragma: no cover
from awslambdaric.lambda_context import LambdaContext

def lambda_handler(event: dict, context: "LambdaContext") -> typing.Any:
print(context.memory_limit_in_mb)
...
```

Perhaps, it would be better to move typing definition in this repository?

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.