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: [M3-8843] - StackScript Landing page #11215

Conversation

bnussman-akamai
Copy link
Member

@bnussman-akamai bnussman-akamai commented Nov 5, 2024

Description 📝

  • Begins refactoring the StackScript section of the app to use modern patterns 🧹
    • This effort will allow us to clean up many class components and use of outdated packages like recompose and ramada 🧹
    • Refactors to use React Query 🌎 rather than the crazy StackScriptBase HOC
    • Gets StackScript code more stylistically similar to the rest of Cloud Manager which will help maintainability and readability 📖
    • The diff will look a lot nicer when we can remove things like StackScriptBase but that can't happen until we refactor the RebuidFromStackScript component 😮‍💨

Preview 📷

Before After
Screenshot 2024-11-05 at 4 57 23 PM Screenshot 2024-11-05 at 4 56 36 PM

How to test 🧪

  • Verify all existing Cypress test for StackScripts pass ✅
  • Test general functionality of the StackScripts landing and details page 👀

As an Author I have considered 🤔

  • 👀 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

@bnussman-akamai bnussman-akamai added the StackScripts relates to StackScripts label Nov 5, 2024
@bnussman-akamai bnussman-akamai self-assigned this Nov 5, 2024
@bnussman-akamai bnussman-akamai marked this pull request as ready for review November 6, 2024 17:21
@bnussman-akamai bnussman-akamai requested review from a team as code owners November 6, 2024 17:21
@bnussman-akamai bnussman-akamai requested review from jdamore-linode, carrillo-erik and cpathipa and removed request for a team November 6, 2024 17:21
Copy link

github-actions bot commented Nov 6, 2024

Coverage Report:
Base Coverage: 79.27%
Current Coverage: 79.27%

@jaalah-akamai
Copy link
Contributor

👀 Reviewing this, but meanwhile you'll need to update to latest path for Typography from linode/ui

@bnussman-akamai
Copy link
Member Author

closing for now to prioritize other work

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.

CRUD functionality is looking good with the refactoring here and tests are passing.

I was wondering about:

  • disabled Create buttons for restricted users on the landing page (empty and stateful)
  • addressing the Linode Create flow -> from Deploy from StackScript in another PR
  • copy improvements to match our normal tone

});
it('gracefully handles a null image', () => {
const images = ['linode/ubuntu20.04', null, 'linode/debian9'];
// @ts-expect-error intentionally testing invalid value because API is known to return null
Copy link
Contributor

Choose a reason for hiding this comment

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

Potentially worth a ticket for maybe the full-stack team to look into?

Copy link
Member Author

Choose a reason for hiding this comment

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

Created ARB-6097

bnussman-akamai and others added 3 commits February 4, 2025 14:13
Co-authored-by: Mariah Jacobs <114685994+mjac0bs@users.noreply.github.com>
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.

Restricted state and copy improvements look good now - approving pending we fix the test failure that's going to result from the latter.

Screenshot 2025-02-04 at 1 26 54 PM

Thanks Banks 🚢

@mjac0bs mjac0bs added the Add'tl Approval Needed Waiting on another approval! label Feb 4, 2025
@linode-gh-bot
Copy link
Collaborator

Cloud Manager UI test results

🎉 495 passing tests on test run #30 ↗︎

❌ Failing✅ Passing↪️ Skipped🕐 Duration
0 Failing495 Passing2 Skipped101m 2s

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.

Nice work @bnussman-akamai!
Confirming on the functionality StackScript landing page.

@cpathipa cpathipa added Approved Multiple approvals and ready to merge! and removed Add'tl Approval Needed Waiting on another approval! labels Feb 5, 2025
@bnussman-akamai bnussman-akamai merged commit c19c8ce into linode:develop Feb 5, 2025
23 checks passed
Copy link

cypress bot commented Feb 5, 2025

Cloud Manager E2E    Run #7182

Run Properties:  status check passed Passed #7182  •  git commit c19c8cea26: refactor: [M3-8843] - StackScript Landing page (#11215)
Project Cloud Manager E2E
Branch Review develop
Run status status check passed Passed #7182
Run duration 29m 17s
Commit git commit c19c8cea26: refactor: [M3-8843] - StackScript Landing page (#11215)
Committer Banks Nussman
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 500
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! Ready for Review StackScripts relates to StackScripts
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants