Skip to content

Conversation

@radoslavirha
Copy link
Contributor

Additional details

Because server.fs.allow is defined, I need to detect workspace root correctly.

https://vitejs.dev/config/server-options.html#server-fs-allow

Steps to test

Create monorepo with Vite app and test with Cypress.

How has the user experience changed?

PR Tasks

@CLAassistant
Copy link

CLAassistant commented Mar 7, 2023

CLA assistant check
All committers have signed the CLA.

@cypress
Copy link

cypress bot commented Mar 7, 2023

Passing run #44666 ↗︎

0 576 0 0 Flakiness 0

Details:

misc: Vite dev server add searchForWorkspaceRoot
Project: cypress Commit: a09449acd3
Status: Passed Duration: 07:16 💡
Started: Mar 10, 2023 12:24 AM Ended: Mar 10, 2023 12:32 AM

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

@lmiller1990 lmiller1990 requested a review from a team March 10, 2023 00:38
@lmiller1990
Copy link
Contributor

Nice, thanks a lot! We will get one more ✅ and this can go in the next release.

Copy link
Contributor

@lmiller1990 lmiller1990 left a comment

Choose a reason for hiding this comment

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

Hi, I realized this won't work as is, but can be fixed with a small change, see comment, thanks!

@lmiller1990
Copy link
Contributor

Nice - @mike-plummer can you take a quick 👀 , too?

Copy link
Contributor

@mike-plummer mike-plummer left a comment

Choose a reason for hiding this comment

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

LGTM, will merge this later today

@emilyrohrbough emilyrohrbough changed the title misc: Vite dev server add searchForWorkspaceRoot fix: Vite dev server add searchForWorkspaceRoot Mar 14, 2023
@lmiller1990
Copy link
Contributor

lmiller1990 commented Mar 15, 2023

We've actually got a real failure now, we may need to rework one test: https://app.circleci.com/pipelines/github/cypress-io/cypress/50439/workflows/06809a66-8100-450e-a443-61812ef1d6d0/jobs/2094959/tests#failed-test-0

I think it's now detecting the vite version in the main monorepo, not the stale version the test is supposed to be detecting. I don't expect this will happen in production, it's a side effect of us running tests against the non-built Cypress binary.

Maybe someone internally can pick this up? I will try and take a look.

@lmiller1990
Copy link
Contributor

lmiller1990 commented Mar 16, 2023

Ahh, this API is new, we just need a null check. It's in v3 and v4.

image

@lmiller1990 lmiller1990 merged commit 6397ac6 into cypress-io:develop Mar 16, 2023
@radoslavirha
Copy link
Contributor Author

Thank you @lmiller1990 !

@lmiller1990
Copy link
Contributor

Yep, pls wait around 2 weeks for the next release.

@radoslavirha radoslavirha deleted the issue-26035 branch March 17, 2023 17:26
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.

Vite server not working in monorepo

6 participants