First off, thanks for this package, it really cuts down on the boto3 error handling boilerplate and makes it more like a proper Python package!
Problem
Pyright complains symbols like errors are not publicly exported, which breaks auto-completion and other IDE features.
So direct imports work: from aws_error_utils.aws_error_utils import errors
But not lib-level imports: from aws_error_utils import errors
After a bit of research, it seems Python type checkers expect py.typed libraries to re-export symbols to make them public based on guidance from PEP 484.
Proposal
I opened PR #8 to solve this issue by redundantly re-exporting symbols. Not the most elegant solution, but it seems to be what Python type checkers expect.
First off, thanks for this package, it really cuts down on the boto3 error handling boilerplate and makes it more like a proper Python package!
Problem
Pyright complains symbols like
errorsare not publicly exported, which breaks auto-completion and other IDE features.So direct imports work:
from aws_error_utils.aws_error_utils import errorsBut not lib-level imports:
from aws_error_utils import errorsAfter a bit of research, it seems Python type checkers expect
py.typedlibraries to re-export symbols to make them public based on guidance from PEP 484.Proposal
I opened PR #8 to solve this issue by redundantly re-exporting symbols. Not the most elegant solution, but it seems to be what Python type checkers expect.