Update docstring and type hint for lambda_handler #95
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Update the type hint for skill_builder's
lambda_handler
, to reflect the (de) serialization component. Also add docstring information to mention how thelambda_handler
is processing the input from AWS Lambda.Motivation and Context
Fixes #93 . Since
sb.lambda_handler
is specific to AWS Lambda, the underlying function should only accept parameter types specific to Lambda processing. So changing the type hinting to reflect that. Also mentioning more information on how this is processed in the skill code.Testing
Generated sphinx docs locally to check the docstrings. Checked the automated documentation in IDE's to reflect the type hints. Since the
lambda_handler
function is a wrapper function and the actual type hints are on the wrapper, the IDE doesn't show any hints for thelambda_handler
function itself.mypy
tests onask-sdk-core
also passes through travis.Screenshots (if appropriate)
Types of changes
Checklist
License