Closed jdetle closed 2 years ago
Sep 8 18:59:22.568 [info] Creating a new Flow server
Sep 8 18:59:23.474 [error] Closing connection 'some ephemeral connection' due to uncaught exception in read loop: End_of_file
Sep 8 18:59:23.474 [error] backtrace:
Sep 8 18:59:23.474 [error] Raised at file "map.ml", line 130, characters 10-25
Sep 8 18:59:23.474 [error] Called from file "src/core/lwt.ml", line 817, characters 20-60
Sep 8 18:59:23.474 [error]
Sep 8 18:59:23.474 [error] Failed to shutdown socket client: Unix.Unix_error(Unix.ENOTCONN, "shutdown", "")
Sep 8 18:59:23.474 [error] backtrace:
Sep 8 18:59:23.474 [error] Raised by primitive operation at file "src/unix/lwt_unix.cppo.ml", line 1533, characters 2-38
Sep 8 18:59:23.474 [error] Called from file "src/monitor/socketAcceptor.ml", line 148, characters 18-49
Sep 8 18:59:23.474 [error]
Unable to obtain kernel buffer: Operation not permitted
usage: sudo dmesg
Sep 8 18:59:28.011 [error] Flow server (pid 3686) exited with code Unknown_error (110)
Sep 8 18:59:28.011 [info] Monitor is exiting (Dying along with server)
Sep 8 18:59:28.011 [info] Broadcasting to threads and waiting 1 second for them to exit
more errors
Closed because duplication of https://github.com/facebook/flow/issues/5919, but this is a really difficult to debug error.
Not sure if its the same issue so I'm going to leave this open for visibility
Seeing the same issue in v0.82.0:
Oct 3 10:19:24.763 [info] argv=/some_path/node_modules/flow-bin/flow-osx-v0.82.0/flow start
Oct 3 10:19:24.764 [info] Creating a new Flow server
Oct 3 10:20:03.298 [error] Closing connection 'server #1' due to uncaught exception in read loop: End_of_file
Oct 3 10:20:03.298 [error] backtrace:
Oct 3 10:20:03.298 [error] Raised at file "map.ml", line 130, characters 10-25
Oct 3 10:20:03.298 [error] Called from file "src/unix/lwt_engine.ml", line 318, characters 8-36
Oct 3 10:20:03.298 [error]
Unable to obtain kernel buffer: Operation not permitted
usage: sudo dmesg
Oct 3 10:20:03.314 [error] Flow server (pid 74556) exited with code Unknown_error (110)
Oct 3 10:20:03.314 [info] Monitor is exiting (Dying along with server)
Oct 3 10:20:03.314 [info] Broadcasting to threads and waiting 1 second for them to exit
In my case, I suspect this to be due to the number of files Flow is trying to parse (running this from the root of a monorepo with 165K files including node_modules
).
We've been seeing this failure on our CI too.
yarn run v1.9.2
$ flow check
Worker interrupted with signal: sigkill
Subprocess(108): fail 2Unhandled exception: Worker_failed (process_id = 108): (Worker_quit WEXITED 2)
Raised at file "src/core/lwt.ml", line 3008, characters 20-29
Called from file "src/unix/lwt_main.ml", line 42, characters 8-18
Called from file "src/commands/checkCommands.ml", line 108, characters 57-132
Called from file "src/flow.ml", line 86, characters 6-34
Worker slave 144 exception: Unix.Unix_error(Unix.EPIPE, "write", "")
Worker slave 144 Potential backtrace:
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-312
Called from file "hack/utils/measure.ml", line 238, characters 12-16
Called from file "hack/procs/worker.ml", line 88, characters 14-143
Called from file "hack/procs/worker.ml", line 128, characters 4-37
Worker slave 138 exception: Unix.Unix_error(Unix.EPIPE, "write", "")
Worker slave 138 Potential backtrace:
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-312
Called from file "hack/utils/measure.ml", line 238, characters 12-16
Called from file "hack/procs/worker.ml", line 88, characters 14-143
Called from file "hack/procs/worker.ml", line 128, characters 4-37
Worker slave 146 exception: Unix.Unix_error(Unix.EPIPE, "write", "")
Worker slave 146 Potential backtrace:
Worker slave 150 exception: Unix.Unix_error(Unix.EPIPE, "write", "")
Worker slave 150 Potential backtrace:
Unix.Unix_error(Unix.EPIPE, "write", "")
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-312
Called from file "hack/utils/measure.ml", line 238, characters 12-16
Called from file "hack/procs/worker.ml", line 88, characters 14-143
Called from file "hack/procs/worker.ml", line 128, characters 4-37
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-312
Called from file "hack/utils/measure.ml", line 238, characters 12-16
Called from file "hack/procs/worker.ml", line 88, characters 14-143
Called from file "hack/procs/worker.ml", line 128, characters 4-37
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-63
Called from file "hack/utils/sys/timeout.ml", line 28, characters 12-18
Worker slave 152 exception: Unix.Unix_error(Unix.EPIPE, "write", "")
Worker slave 152 Potential backtrace:
Worker slave 151 exception: Unix.Unix_error(Unix.EPIPE, "write", "")
Worker slave 151 Potential backtrace:
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-312
Called from file "hack/utils/measure.ml", line 238, characters 12-16
Called from file "hack/procs/worker.ml", line 88, characters 14-143
Called from file "hack/procs/worker.ml", line 128, characters 4-37
Worker slave 149 exception: Unix.Unix_error(Unix.EPIPE, "write", "")
Worker slave 149 Potential backtrace:
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-312
Called from file "hack/utils/measure.ml", line 238, characters 12-16
Called from file "hack/procs/worker.ml", line 88, characters 14-143
Called from file "hack/procs/worker.ml", line 128, characters 4-37
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-312
Called from file "hack/utils/measure.ml", line 238, characters 12-16
Called from file "hack/procs/worker.ml", line 88, characters 14-143
Called from file "hack/procs/worker.ml", line 128, characters 4-37
Worker slave 147 exception: Unix.Unix_error(Unix.EPIPE, "write", "")
Worker slave 147 Potential backtrace:
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-312
Called from file "hack/utils/measure.ml", line 238, characters 12-16
Called from file "hack/procs/worker.ml", line 88, characters 14-143
Called from file "hack/procs/worker.ml", line 128, characters 4-37
Unix.Unix_error(Unix.EPIPE, "write", "")
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-63
Called from file "hack/utils/sys/timeout.ml", line 28, characters 12-18
Unix.Unix_error(Unix.EPIPE, "write", "")
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-63
Called from file "hack/utils/sys/timeout.ml", line 28, characters 12-18
Unix.Unix_error(Unix.EPIPE, "write", "")
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-63
Called from file "hack/utils/sys/timeout.ml", line 28, characters 12-18
Unix.Unix_error(Unix.EPIPE, "write", "")
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-63
Called from file "hack/utils/sys/timeout.ml", line 28, characters 12-18
error Command failed with exit code 110.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Unix.Unix_error(Unix.EPIPE, "write", "")
Raised by primitive operation at file "unix.ml", line 257, characters 7-34
Called from file "hack/utils/marshal_tools.ml", line 145, characters 6-67
Called from file "hack/utils/marshal_tools.ml", line 158, characters 4-63
Called from file "hack/utils/sys/timeout.ml", line 28, characters 12-18
Exited with code 1
I may be full of it but I think it usually comes from a typo that leads to fatal error parsing flow
To be clear, it's not consistent for us. Rerunning the workflow on Circle usually does the trick.
we have the same issue (v0.84). On CircleCI only, never occurs on local machines
Same here. Never fails on local machines, fails 70% of the time on CircleCI.
I ran into this issue when another script failed to terminate the flow server once it finished running. In my case, flow-coverage-report was the culprit.
For those arriving here via google with CI (particularly CircleCI) failures; add the following:
.flowconfig
[options]
server.max_workers=1
This will stop flow from trying to consume too many virtual CPUs (which CircleCI doesn't actually provide), letting it run to completion without first running out of memory and killing its sub processes.
Thanks @jesstelford. For circleCI, it also works with server.max_workers=4
and is probably faster.
In my case, I launched flow during yarn install
with CircleCI :
{
"scripts": {
"prepublish": "yarn test && yarn build",
"test": "eslint . && flow && jest --coverage --forceExit"
},
}
I replaced prepublish
with prepublishOnly
to fix the problem.
Closing out old issues. This repository is just packaging prebuilt binaries. Please report issues with Flow itself on facebook/flow
Issue
Hi All, sorry if I can't help much which the log dump, but I'm trying to run
yarn flow
and getting this issue from the hack workers. Should I crosspost this in https://github.com/facebook/hhvm?Error Dump
Versions
Version of flow-bin: '0.80.0'. Yarn version: '1.9.4'