Skip to content
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

Feature - Amazon Q Code Transform Update #648

Conversation

damntrecky
Copy link
Contributor

@damntrecky damntrecky commented Dec 11, 2023

Problem

Sub PR for -> https://github.com/aws/aws-toolkit-common/pull/641/files

Solution

License

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

- Update allowedValues for definition to remove spaces from values
- Update Typescript to NOT replace spaces in allowedValues with underscores
@damntrecky damntrecky requested a review from a team as a code owner December 11, 2023 19:32
@awschristou awschristou merged commit d0940bb into aws:main Dec 11, 2023
7 checks passed
const modifiedVal = typeof v === "string" ? v.replace(/\s/g, "_") : v;
return `'${modifiedVal}'`
}).join(' | '),
type: m.allowedValues.map(v => `'${v}'`).join(' | '),
Copy link
Contributor

@justinmk3 justinmk3 Dec 11, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible that allowedValues is undefined?

Comment on lines +1044 to +1051
"NoPom",
"NoJavaProject",
"MixedLanguages",
"UnsupportedJavaVersion",
"NonMavenProject",
"EmptyProject",
"NonSsoLogin",
"RemoteRunProject"
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we map these values to a proper error message?

const modifiedVal = typeof v === "string" ? v.replace(/\s/g, "_") : v;
return `'${modifiedVal}'`
}).join(' | '),
type: m.allowedValues.map(v => `'${v}'`).join(' | '),
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible that allowedValues is undefined?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants