GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix(cli): Correctly set NoLSI field when askDynamoLSIConfig returns false by bvtujo · Pull Request #1057 · aws/copilot-cli

This repository was archived by the owner on Jun 22, 2026. It is now read-only.

Conversation

@bvtujo

@bvtujo bvtujo commented Jun 26, 2020

Copy link
Copy Markdown
Contributor

This change solves an issue where if a customer selected "No" when asked "Would you like to add any alternate sort keys to this DynamoDB table?", the noLsi option was not properly set and an erroneous line was injected into the CF template.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@bvtujo
Correctly set noLSI when asking for alternate sort keys
b722324
@bvtujo
bvtujo requested a review from a team as a code owner June 26, 2020 17:48
@bvtujo
bvtujo requested a review from kohidave June 26, 2020 17:48
iamhopaul123
iamhopaul123 reviewed Jun 26, 2020
View reviewed changes
Comment thread internal/pkg/cli/storage_init_test.go Resolved

Uh oh!

There was an error while loading. Please reload this page.

@bvtujo bvtujo added the do-not-merge Pull requests that mergify shouldn't merge until the requester allows it. label Jun 26, 2020
bvtujo added 2 commits June 26, 2020 10:56
@bvtujo
Fix further validation bug introduced in previous commit
aceebdd
@bvtujo
remove unused test function
d1fc3a5
@bvtujo bvtujo removed the do-not-merge Pull requests that mergify shouldn't merge until the requester allows it. label Jun 26, 2020
@bvtujo
bvtujo requested a review from iamhopaul123 June 26, 2020 18:00
@bvtujo
Set noLsi to false explicitly if more than 5 lsis are specified.
d1612ac
iamhopaul123
iamhopaul123 approved these changes Jun 26, 2020
View reviewed changes

@iamhopaul123 iamhopaul123 left a comment

Copy link
Copy Markdown
Contributor

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.

ship it! Thanks for the quick turnaround.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
efekarakus
efekarakus reviewed Jun 26, 2020
View reviewed changes
Comment thread internal/pkg/cli/storage_init.go
Comment on lines +407 to 414
if !moreLSI {
if len(o.lsiSorts) == 0 {
o.noLsi = true
} else {
o.noLsi = false
}
break
}

@efekarakus efekarakus Jun 26, 2020

Copy link
Copy Markdown
Contributor

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 have:

Suggested change
if !moreLSI {
if len(o.lsiSorts) == 0 {
o.noLsi = true
} else {
o.noLsi = false
}
break
}
if !moreLSI {
o.noLsi = len(o.lsiSorts) == 0
return nil
}

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@efekarakus efekarakus Jun 26, 2020

Copy link
Copy Markdown
Contributor

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.

also can we update noLsi to noLSI

https://github.com/golang/go/wiki/CodeReviewComments#initialisms

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@bvtujo bvtujo Jun 26, 2020

Copy link
Copy Markdown
Contributor Author

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.

Done.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
bvtujo added 2 commits June 26, 2020 11:45
@bvtujo
Rename noLsi to noLSI; rephrase logic
3413d1a
@bvtujo
Finish renaming Lsi to LSI
bb4a93b
efekarakus
efekarakus approved these changes Jun 26, 2020
View reviewed changes

@efekarakus efekarakus left a comment

Copy link
Copy Markdown
Contributor

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.

awesome, thank you!

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@mergify
Merge branch 'master' into set-noLsi
c9ad814
@mergify
mergify Bot merged commit f2d95e1 into aws:master Jun 26, 2020
@efekarakus efekarakus mentioned this pull request Jun 30, 2020
storage init: DDB with no LSE includes empty LSE section in the template #1072
Closed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Reviewers

@kohidave kohidave Awaiting requested review from kohidave
2 more reviewers
@efekarakus efekarakus efekarakus approved these changes
@iamhopaul123 iamhopaul123 iamhopaul123 approved these changes
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@bvtujo @efekarakus @iamhopaul123
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.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.