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

chore: Update Vite to 4.3.0 #26553

Merged
merged 32 commits into from
Apr 27, 2023
Merged

chore: Update Vite to 4.3.0 #26553

merged 32 commits into from
Apr 27, 2023

Conversation

mike-plummer
Copy link
Contributor

Additional details

  • Upgrade internal Vite version to 4.3.0 (versions 4.2.* exhibited a strange hang on rebuild due to issues with the markdown-it library)
  • Upgrade all Vite plugins to latest (some of these were missed in the Vite 4.x upgrade so there are some significant version bumps), make necessary config changes
  • Fix browser support baseline in Vite legacy plugin

Steps to test

  • General smoke test of launchpad and app
  • Verify rebuild works as expected with yarn dev

How has the user experience changed?

  • No user-facing change

PR Tasks

@cypress
Copy link

cypress bot commented Apr 20, 2023

3 flaky tests on run #45884 ↗︎

0 5193 77 0 Flakiness 3

Details:

Fix yarn.lock
Project: cypress Commit: 69f1a1900e
Status: Passed Duration: 13:16 💡
Started: Apr 27, 2023 1:58 PM Ended: Apr 27, 2023 2:11 PM
Flakiness  cypress/e2e/cypress/cypress.cy.js • 3 flaky tests • 5x-driver-electron

View Output Video

Test Artifacts
... > correctly returns currentRetry Output Video
... > correctly returns currentRetry Output Video
... > correctly returns currentRetry Output Video

This comment has been generated by cypress-bot as a result of this project's GitHub integration settings.

@@ -103,7 +103,7 @@
"@types/glob": "7.1.1",
"@types/gulp": "^4.0.9",
"@types/lodash": "^4.14.168",
"@types/markdown-it": "0.0.9",
"@types/markdown-it": "12.2.3",
Copy link
Contributor

Choose a reason for hiding this comment

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

Woah, we were 12 majors behind!
I know it's just types, but 🤦

@lmiller1990
Copy link
Contributor

Seems main issue is https://app.circleci.com/pipelines/github/cypress-io/cypress/51867/workflows/9c1df45e-4cf8-4489-be3b-07f659e10bf2/jobs/2140361?invite=true#step-112-1939

✘ [ERROR] Could not resolve "@babel/preset-typescript/package.json"

    node_modules/@babel/core/lib/config/files/module-types.js:87:40:
      87 │ ...st packageJson = require("@babel/preset-typescript/package.json");

Only used in packages/web-config as a devDep, weird it's breaking now.

It's pulled in here https://github.com/babel/babel/blob/202e4fa60b27d3d8de933abe113cd0a2efacd476/packages/babel-core/src/config/files/module-types.ts#L100

We should find out why this is happening and what esbuild version introduced this.

@lmiller1990
Copy link
Contributor

@mike-plummer I found out we can add babel/typescript-preset to the external array and it (seems) to work: 2372f98

I will build a binary and find out if this is going to be fine.

@lmiller1990 lmiller1990 requested a review from a team April 24, 2023 12:53
@lmiller1990
Copy link
Contributor

I pushed a bunch of code, some to fix issues here, some to fix a weird race condition with building the icons - I am not sure if it will work, let's see how CI goes. I am sure this icons race condition pre-dates this PR, though.

Copy link
Contributor

@astone123 astone123 left a comment

Choose a reason for hiding this comment

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

I ran this with yarn dev and everything looks good to me. Live reloading worked as expected and I didn't see any issues during smoke tests

@@ -98,7 +98,7 @@
},
params: props.type === 'component' || props.type === 'componentEmpty'
? {
shouldShowTroubleRenderingAlert: true
shouldShowTroubleRenderingAlert: 'true'
Copy link
Contributor

Choose a reason for hiding this comment

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

Why are these changes necessary?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Making typescript happy - a boolean didn't satisfy the type contract, has to be a string or number

@lmiller1990 lmiller1990 self-requested a review April 25, 2023 02:29
@lmiller1990
Copy link
Contributor

This is done, we just need to rebase. We will hold off on merging since there is some associated risk. We will merge post release.

I am going to close the issue for the sake of tracking sprint points.

@lmiller1990 lmiller1990 changed the title chore: Update Vite to 4.3.0 [NO MERGE UNTIL RELEASE GOES OUT] chore: Update Vite to 4.3.0 Apr 25, 2023
@lmiller1990 lmiller1990 changed the title [NO MERGE UNTIL RELEASE GOES OUT] chore: Update Vite to 4.3.0 chore: Update Vite to 4.3.0 Apr 26, 2023
@mike-plummer mike-plummer merged commit 91cbc67 into develop Apr 27, 2023
3 checks passed
@mike-plummer mike-plummer deleted the mikep/26161-vite-upgrade branch April 27, 2023 20:09
tgriesser added a commit that referenced this pull request May 3, 2023
* feat/protocol:
  refactor: migrate from windi to tailwind (#26516)
  chore: update v8 generation vars so that from scratch depends implies updating the metafile (#26472)
  chore: Update Vite to 4.3.0 (#26553)
  fix: unify cdp approach to fix devtools in electron (#26573)
  dependency(deps): update dependency deps-ok to v1.4.1 🌟 (#26612)
  chore: update 12.11.0 release date (#26587)
  chore: 12.11.0 release (#26582)
  chore: implement experimental ESM stub/spy for Vite (#26536)
  chore: try triggering mouseleave on buttons to ensure that tooltips aren't showing (#26524)
  chore: add support for Angular 16 (#26052)
  chore: upgrade Vue to 3.2.47 (#26555)
  chore: Update v8 snapshot cache (#26537)
  chore: add missing utm parameters for cloud links to Debug page (#26556)
  chore: update stalebot to respect new labels and up process rate (#26552)
  fix: don't display run passing status if Cloud org is over run limit (#26533)
  chore: update vm2 to 3.9.17 (#26534)
  feat: display a limit warning on the run navigation component when there are 100 total runs (#26523)
  chore: Update v8 snapshot cache (#26476)
  chore: upgrade vm2 (#26495)
  fix: Treat Video compression 0 as false.  (#26503)
@cypress-bot
Copy link
Contributor

cypress-bot bot commented May 12, 2023

Released in 12.12.0.

This comment thread has been locked. If you are still experiencing this issue after upgrading to
Cypress v12.12.0, please open a new issue.

@cypress-bot cypress-bot bot locked as resolved and limited conversation to collaborators May 12, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update to Vite 4.2
3 participants