You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A "global" version was already installed during DevContainer spin up
Run nx run example:c --verbose
The terminal looks like the following:
$ nx run example:c --verbose
NX Running target c for project example and 2 tasks it depends on:
—————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————
> nx run example:a
> nx run example:b
—————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————————
NX Running target c for project example and 2 tasks it depends on failed
Failed tasks:
- example:b
Hint: run the command with --verbose for more details.
Inspecting the nx.json file, every task is a simple nx:noop executor.
The selected task C depends on both A + B. A is successful, but B fails.
No extra information is outputted with the failure.
Nx Report
NX Report complete - copy this into the issue template
Node : 20.11.1
OS : linux-arm64
npm : 10.2.4
nx (global) : 18.1.3
nx : 18.1.3
@nrwl/tao : 18.1.3
Failure Logs
Error: Operation not permitted (os error 1)
at PseudoTerminal.fork (/workspace/node_modules/nx/src/tasks-runner/pseudo-terminal.js:42:73)
at ForkedProcessTaskRunner.forkProcessWithPseudoTerminal (/workspace/node_modules/nx/src/tasks-runner/forked-process-task-runner.js:141:45)
at ForkedProcessTaskRunner.forkProcess (/workspace/node_modules/nx/src/tasks-runner/forked-process-task-runner.js:127:25)
at TaskOrchestrator.runTaskInForkedProcess (/workspace/node_modules/nx/src/tasks-runner/task-orchestrator.js:260:54)
at TaskOrchestrator.applyFromCacheOrRunTask (/workspace/node_modules/nx/src/tasks-runner/task-orchestrator.js:243:61)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async TaskOrchestrator.executeNextBatchOfTasksUsingTaskSchedule (/workspace/node_modules/nx/src/tasks-runner/task-orchestrator.js:76:13)
at async Promise.all (index 1)
at async TaskOrchestrator.run (/workspace/node_modules/nx/src/tasks-runner/task-orchestrator.js:53:9)
at async defaultTasksRunner (/workspace/node_modules/nx/src/tasks-runner/default-tasks-runner.js:18:16) {
code: 'GenericFailure'
}
Package Manager Version
npm - 10.2.4
Operating System
macOS
Linux
Windows
Other (Please specify)
Additional Information
Issue appears specific to devcontainer. I am not able to reproduce when using local terminal.
Devcontainer is based on debian, so while I am on a mac, this may be caused by some linux incompatability.
I encountered the same issue in my project. Also managed to find the Error: Operation not permitted (os error 1). Setting NX_NATIVE_COMMAND_RUNNER environment variable to false helps, but it's not real solution. Is there any progress in fixing this issue?
Current Behavior
Open a code repo in a devcontainer.
Define 3 tasks. They can do literally nothing (
nx:noop
)A
B
C
A
+B
Attempt to execute task
C
:nx run example:c
.Nx fails to run task
B
, but provides no extra info even in--verbose
modeExpected Behavior
All 3 tasks should execute correctly, in the order defined by the dependency graph.
Since the tasks themselves do literally nothing, it should not be possible for this command to fail.
GitHub Repo
https://github.com/JacobLey/issue-recreator/tree/nx-parallel-devcontainer
Steps to Reproduce
(Copied from README of github repo)
npm i
to install Nxnx run example:c --verbose
The terminal looks like the following:
Inspecting the
nx.json
file, every task is a simplenx:noop
executor.The selected task
C
depends on bothA
+B
.A
is successful, butB
fails.No extra information is outputted with the failure.
Nx Report
Failure Logs
Error: Operation not permitted (os error 1) at PseudoTerminal.fork (/workspace/node_modules/nx/src/tasks-runner/pseudo-terminal.js:42:73) at ForkedProcessTaskRunner.forkProcessWithPseudoTerminal (/workspace/node_modules/nx/src/tasks-runner/forked-process-task-runner.js:141:45) at ForkedProcessTaskRunner.forkProcess (/workspace/node_modules/nx/src/tasks-runner/forked-process-task-runner.js:127:25) at TaskOrchestrator.runTaskInForkedProcess (/workspace/node_modules/nx/src/tasks-runner/task-orchestrator.js:260:54) at TaskOrchestrator.applyFromCacheOrRunTask (/workspace/node_modules/nx/src/tasks-runner/task-orchestrator.js:243:61) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) at async TaskOrchestrator.executeNextBatchOfTasksUsingTaskSchedule (/workspace/node_modules/nx/src/tasks-runner/task-orchestrator.js:76:13) at async Promise.all (index 1) at async TaskOrchestrator.run (/workspace/node_modules/nx/src/tasks-runner/task-orchestrator.js:53:9) at async defaultTasksRunner (/workspace/node_modules/nx/src/tasks-runner/default-tasks-runner.js:18:16) { code: 'GenericFailure' }
Package Manager Version
npm - 10.2.4
Operating System
Additional Information
Issue appears specific to devcontainer. I am not able to reproduce when using local terminal.
Devcontainer is based on debian, so while I am on a mac, this may be caused by some linux incompatability.
The error is swallowed here: https://github.com/nrwl/nx/blob/master/packages/nx/src/tasks-runner/task-orchestrator.ts#L495
Editing the line of code locally to print the failure message provided above.
The forking happens on a native binding, which is why the stack trace does not go farther.
It appears that more than one fork at a time is not supported.
The text was updated successfully, but these errors were encountered: