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

Hangs while "Building" on Windows #1137

Closed
catamphetamine opened this issue Apr 5, 2018 · 2 comments
Closed

Hangs while "Building" on Windows #1137

catamphetamine opened this issue Apr 5, 2018 · 2 comments

Comments

@catamphetamine
Copy link

catamphetamine commented Apr 5, 2018

I tried creating a simple project using a couple of not-so-simple libraries and it was good but now it hangs on random files while "Building".

Sometimes it builds and outputs this error:

√  Built in 5.48s.
‼  c:\dev\react-website-basic-example\node_modules\mime\mime.js:52:32: Cannot statically evaluate fs argument
  50 |   // Read file and split into lines
  51 |   var map = {},
> 52 |       content = fs.readFileSync(file, 'ascii'),
     |                                 ^
  53 |       lines = content.split(/[\r\n]+/);
  54 |
  55 |   lines.forEach(function(line) {

I'm on Windows, perhaps I'll share the project if I find which import causes that.
Perhaps a cyclic dependency?

@catamphetamine
Copy link
Author

Strange, now it built and didn't output any errors.

@fathyb
Copy link
Contributor

fathyb commented Apr 5, 2018

The fs.readFileSync message is just a warning. Freezing on Windows is a known bug unfortunately, see #900 for the issue and #901 for a workaround PR.

@fathyb fathyb closed this as completed Apr 5, 2018
@fathyb fathyb changed the title Hangs while "Building" Hangs while "Building" on Windows Apr 5, 2018
piscisaureus added a commit to libuv/libuv that referenced this issue May 24, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the amount of data
written exceeds the size of the pipe buffer.

Fixes: #1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 24, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 24, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 24, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 24, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to piscisaureus/libuv that referenced this issue May 24, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: libuv#1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to piscisaureus/libuv that referenced this issue May 24, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: libuv#1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 24, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 25, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 25, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 25, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 25, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Fixes: nodejs/node#7657
Fixes: electron/electron#10107
Fixes: parcel-bundler/parcel#637
Fixes: parcel-bundler/parcel#900
Fixes: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 25, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Refs: nodejs/node#7657
Refs: electron/electron#10107
Refs: parcel-bundler/parcel#637
Refs: parcel-bundler/parcel#900
Refs: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 25, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Refs: nodejs/node#7657
Refs: electron/electron#10107
Refs: parcel-bundler/parcel#637
Refs: parcel-bundler/parcel#900
Refs: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 25, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Refs: nodejs/node#7657
Refs: electron/electron#10107
Refs: parcel-bundler/parcel#637
Refs: parcel-bundler/parcel#900
Refs: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 25, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Refs: nodejs/node#7657
Refs: electron/electron#10107
Refs: parcel-bundler/parcel#637
Refs: parcel-bundler/parcel#900
Refs: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 25, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Refs: nodejs/node#7657
Refs: electron/electron#10107
Refs: parcel-bundler/parcel#637
Refs: parcel-bundler/parcel#900
Refs: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 25, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Refs: nodejs/node#7657
Refs: electron/electron#10107
Refs: parcel-bundler/parcel#637
Refs: parcel-bundler/parcel#900
Refs: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 28, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Refs: nodejs/node#7657
Refs: electron/electron#10107
Refs: parcel-bundler/parcel#637
Refs: parcel-bundler/parcel#900
Refs: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 29, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Refs: nodejs/node#7657
Refs: electron/electron#10107
Refs: parcel-bundler/parcel#637
Refs: parcel-bundler/parcel#900
Refs: parcel-bundler/parcel#1137
piscisaureus added a commit to libuv/libuv that referenced this issue May 29, 2018
This fixes a bug where IPC pipe communication would deadlock when both
ends of the pipe are written to simultaneously, and the kernel pipe
buffer has already been filled up by earlier writes.

The root cause of the deadlock is that, while writes to an IPC pipe are
generally asynchronous, the IPC frame header is written synchronously.
So when both ends of the pipe are sending a frame header at the same
time, neither will read data off the pipe, causing both header writes
to block indefinitely.

Additionally, this patch somewhat reduces the spaghetti level in
win/pipe.c.

Fixes: #1099
Refs: nodejs/node#7657
Refs: electron/electron#10107
Refs: parcel-bundler/parcel#637
Refs: parcel-bundler/parcel#900
Refs: parcel-bundler/parcel#1137
PR-URL: #1843
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Bartosz Sosnowski <bartosz@janeasystems.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants