-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Using the bundler via API doesn't terminate all workers #1723
Comments
hmm it should stop unless there is a watcher. Just looked in the parcel core tests and it adds the |
@devongovett well, but I think this is just a workaround. parcel should cleanup all the workers when used via API. the hanging tests indicate that it doesn't do so. as mentioned above, using a ne WorkerFarm instead of the shared one solves the problem. |
hmm not sure what's going on here then. perhaps because there are multiple bundler instances in the tests something weird is happening. |
The workerfarm ends asynchronously, so perhaps you could try something like |
@DeMoorJasper you're correct. when I change this to
|
I'll create a PR. see #1760 |
Merged! Thanks :) |
🐛 bug report
We have test suite in parcel-plugin-htl that uses the
Bundler
via API to test the plugin. The testrunner doesn't complete if running more than 1 test. I think this has something to do with theWorkers
used inBundler
not being shutdown correctly.🎛 Configuration (.babelrc, package.json, cli command)
npm test
🤔 Expected Behavior
Tests complete without error and test runner terminates.
😯 Current Behavior
Test complete without error; but test runner hangs.
💁 Possible Solution
when using a new farm instead of the shared one, it works:
🔦 Context
Without this fixed, our plugin tests don't complete and we have to disable them on the CI.
💻 Code Sample
https://github.com/adobe/parcel-plugin-htl/blob/master/test/unit/testHTML.js#L66
🌍 Your Environment
The text was updated successfully, but these errors were encountered: