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

refactor: [UIE-8245] - DBaaS: Replace Select component with Autocomplete #11245

Merged

Conversation

mpolotsk-akamai
Copy link
Contributor

Description 📝

DBaaS: Replace the deprecated Select component with Autocomplete.

Changes 🔄

Replaced Select with Autocomplete

  • Engine Select in Database Create
  • Maintenance Window in Settings Tab

Target release date 🗓️

12/10/2024

As an Author I have considered 🤔

Check all that apply

  • 👀 Doing a self review
  • ❔ Our contribution guidelines
  • 🤏 Splitting feature into small PRs
  • ➕ Adding a changeset
  • 🧪 Providing/Improving test coverage
  • 🔐 Removing all sensitive information from the code and PR description
  • 🚩 Using a feature flag to protect the release
  • 👣 Providing comprehensive reproduction steps
  • 📑 Providing or updating our documentation
  • 🕛 Scheduling a pair reviewing session
  • 📱 Providing mobile support
  • ♿ Providing accessibility support

@mpolotsk-akamai mpolotsk-akamai requested a review from a team as a code owner November 12, 2024 15:25
@mpolotsk-akamai mpolotsk-akamai requested review from mjac0bs and cpathipa and removed request for a team November 12, 2024 15:25
Copy link

github-actions bot commented Nov 12, 2024

Coverage Report:
Base Coverage: 87.32%
Current Coverage: 87.3%

@jcallahan-akamai jcallahan-akamai added the DBaaS Relates to Database as a Service label Nov 12, 2024
Copy link
Contributor

@mjac0bs mjac0bs left a comment

Choose a reason for hiding this comment

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

Hey @mpolotsk-akamai - left you a few questions and notes in my review. Thank you for doing the swap from Select to Autocomplete, we appreciate it!

Copy link
Contributor

Choose a reason for hiding this comment

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

A general note on error handling: surfacing the API error looks good. But I am wondering what happened to our schema validation on this field - it doesn't appear to be validating the Engine in prod, either, so this was an existing issue - optional but encouraged to address here. The engine field's behavior would ideally be consistent with that of other fields, validating before we get that API error. If not addressed in this PR, could you create a follow up to address?

Screenshot 2024-11-12 at 3 59 10 PM

Screenshot 2024-11-12 at 3 59 52 PM

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The schema validation didn't work because the field wasn’t empty; it had a default value intended to display prices in the Plan Table, which caused a minor bug. After discussing with Amit, I fixed it to properly display the default value in the 'Select a Database Engine' field.

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah, I see. Thanks for looking into this. Things for further consideration by you, the rest of the DBaaS folks, and UX: Is showing the priced plans in the Plan Table prior to any Engine selection a requirement? And does surfacing a default Engine selection have any implications we want to avoid?

In other sections of the app, when we require a selection (in this case, region) to be made first, we display the following in the Plan Table. I'm wondering if a 'Select an engine to view plans and prices' would be desirable for consistency here.

Screenshot 2024-11-14 at 12 44 25 PM
Screenshot 2024-11-14 at 12 44 36 PM

I think that change would probably require more code changes even further outside the scope of the Autocomplete swap, so potentially a follow up.

Copy link
Contributor

@mjac0bs mjac0bs left a comment

Choose a reason for hiding this comment

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

Thanks for the updates! A couple of suggestions related to the Database Engine field for consideration, but the Autocompletes looked good overall.

@mjac0bs mjac0bs added the Add'tl Approval Needed Waiting on another approval! label Nov 14, 2024
@mpolotsk-akamai mpolotsk-akamai force-pushed the change-select-to-autocomplete branch from 5522c2e to 611e4ca Compare November 15, 2024 15:17
Copy link
Contributor

@cpathipa cpathipa left a comment

Choose a reason for hiding this comment

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

@mpolotsk-akamai Thank you for replacing select with Autocomplete component. Overall LGTM!

@cpathipa cpathipa added Approved Multiple approvals and ready to merge! and removed Add'tl Approval Needed Waiting on another approval! labels Nov 15, 2024
@mpolotsk-akamai
Copy link
Contributor Author

@cpathipa , @mjac0bs , thank you for the review!

@linode-gh-bot
Copy link
Collaborator

Cloud Manager UI test results

🔺 1 failing test on test run #4 ↗︎

❌ Failing✅ Passing↪️ Skipped🕐 Duration
1 Failing440 Passing6 Skipped104m 41s

Details

Failing Tests
SpecTest
switch-linode-state.spec.tsswitch linode state » "before each" hook for "powers off a linode from details page"

Troubleshooting

Use this command to re-run the failing tests:

yarn cy:run -s "cypress/e2e/core/linodes/switch-linode-state.spec.ts"

@cpathipa cpathipa merged commit 6898013 into linode:develop Nov 15, 2024
22 of 23 checks passed
Copy link

cypress bot commented Nov 15, 2024

Cloud Manager E2E    Run #6829

Run Properties:  status check passed Passed #6829  •  git commit 68980134bc: refactor: [UIE-8245] - DBaaS: Replace Select component with Autocomplete (#11245...
Project Cloud Manager E2E
Branch Review develop
Run status status check passed Passed #6829
Run duration 26m 26s
Commit git commit 68980134bc: refactor: [UIE-8245] - DBaaS: Replace Select component with Autocomplete (#11245...
Committer mpolotsk-akamai
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 2
Tests that did not run due to a developer annotating a test with .skip  Pending 2
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 445
View all changes introduced in this branch ↗︎

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Approved Multiple approvals and ready to merge! DBaaS Relates to Database as a Service
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants