-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
DynamoDB: Fix empty replicas list in response #12047
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
Conversation
LocalStack Community integration with Pro 2 files ± 0 2 suites ±0 31m 41s ⏱️ - 1h 24m 41s Results for commit 8a0668b. ± Comparison against base commit 1dba4f3. This pull request removes 2836 tests.
♻️ This comment has been updated with latest results. |
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'll review as I was, by mistake I think, pinged on the pipeline alert by Alex 😅 LGTM, I'll also merge the PR to unblock the pipeline, hope that's alright!
also: sorry for the having to duplicate all fixes to the DDB v2 provider 😕
@@ -752,7 +752,8 @@ def describe_table( | |||
if replica_region != context.region: | |||
replica_description_list.append(replica_description) | |||
|
|||
table_description.update({"Replicas": replica_description_list}) | |||
if replica_description_list: | |||
table_description.update({"Replicas": replica_description_list}) |
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.
nit: I think we could do table_description["Replicas"] = replica_description_list
instead, but it was that way before so let's keep it, only a nit anyway 😄
Changes
This PR fixes a regression caused by #11938 which would cause an empty list to be returned when no replicas are configured (reference test run). The behaviour is AWS validated by the tests in the reference run.
Tests
Randomised MA/MR tests: https://app.circleci.com/pipelines/github/localstack/localstack/30321/workflows/ade8da0d-d52a-453e-8c4f-efc418e5d8c3