Skip to content

Commit

Permalink
🐛 End browser process pipes during cleanup
Browse files Browse the repository at this point in the history
This is needed specifically for Windows
  • Loading branch information
wwilsman committed Feb 23, 2021
1 parent ac1a812 commit 7d153e8
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/core/src/discovery/browser.js
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,11 @@ export default class Browser extends EventEmitter {

// after closing, attempt to clean up the profile directory
await closed.then(() => new Promise(resolve => {
// needed due to a bug in Node 12 - https://github.com/nodejs/node/issues/27097
this.process?.stdin.end();
this.process?.stdout.end();
this.process?.stderr.end();

/* istanbul ignore else: sanity */
if (this.profile) {
rimraf(this.profile, error => {
Expand Down

0 comments on commit 7d153e8

Please sign in to comment.