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.
feat(parameters): accept boto3_client to support private endpoints and ease testing #1096
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(parameters): accept boto3_client to support private endpoints and ease testing #1096
Changes from 3 commits
ce851e9
b9b6753
159ca22
d33201e
2fbdca3
ac5554f
cd426fe
cd71ee0
ccc378b
2a77841
9b99f0b
d2c8f30
d854f1c
63bdde6
3528b8e
579f8e1
a8350ae
cec2f33
19ec9ae
58e2d5e
98dc539
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we turn this into a builder static method in the parent class? Return type could be Any as we will be able to cast the correct one for each client built w/ mypy_boto3.
This will prevent future an accidental logic discrepancy between them and localize change. It could accept the
boto3_client
,boto3_session
,boto3_config
, andboto3_service_name
to initialize.Let me know if it doesn't make sense
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i didnt add it to the dymamo class becuase we dont use a client there, not usre you can create a table from a client class.
so if it's not the dynamodb, it shouldn't be in the parent
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would update the example to still use boto session to create the client (see boto3 Sessions, and Why You Should Use Them ). And showcase what you can do when you create your own client, like customerize the endpoint url as per the original issue.