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

fix: await scanner #11242

Merged
merged 4 commits into from
Dec 7, 2022
Merged

fix: await scanner #11242

merged 4 commits into from
Dec 7, 2022

Conversation

sapphi-red
Copy link
Member

Description

When scanner didn't finish before server is closed, esbuild hanged up, I guess.

  1. scanner starts
  2. server close
  3. scanner ends

refs #11239

Additional context


What is the purpose of this pull request?

  • Bug fix
  • New Feature
  • Documentation update
  • Other

@@ -202,7 +208,9 @@ async function createDepsOptimizer(
try {
Copy link
Member Author

Choose a reason for hiding this comment

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

Maybe we should wrap this callback and await that instead of just awaiting this part?

Copy link
Member

Choose a reason for hiding this comment

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

I think the whole promise handling here is due a refactoring. Lets merge this this change that works so we can release a patch

@patak-dev
Copy link
Member

Great finding!

@patak-dev patak-dev merged commit 52a6732 into vitejs:main Dec 7, 2022
@sapphi-red sapphi-red deleted the fix/await-scanner branch December 8, 2022 04:17
futurGH pushed a commit to futurGH/vite that referenced this pull request Feb 26, 2023
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.

2 participants