mirror of
https://github.com/morluto/rea.git
synced 2026-11-19 13:12:26 +00:00
fix(process): classify macOS ownership helper capacity exhaustion as resource constraint (#11771)
* fix(process): classify macOS ownership helper capacity exhaustion as resource constraint Refs #11679 Refs #11714 * fix(process): exclude cancelled preparation from host capacity detection
This commit is contained in:
1 parent
0ef08895f1
commit
bc8b3c4cfa
11 files changed
+293
-41
No files matched your search
@@ -24,6 +24,7 @@ import { jsonValueSchema, type JsonValue } from "../domain/jsonValue.js";
|
||||
import { err, ok, type Result } from "../domain/result.js";
|
||||
import {
|
||||
prepareOwnedCommand,
|
||||
preparationHostCapacityFailure,
|
||||
runOwnedCommand,
|
||||
OwnedCommandFailure,
|
||||
} from "../process/OwnedCommand.js";
|
||||
@@ -221,7 +222,11 @@ export const inspectJadxJava = async (
|
||||
},
|
||||
},
|
||||
});
|
||||
} else if (preparation !== undefined && command?.reason !== "timeout") {
|
||||
} else if (
|
||||
preparation !== undefined &&
|
||||
command?.reason !== "timeout" &&
|
||||
hostConstraint === undefined
|
||||
) {
|
||||
primary = new ProviderAdapterError("jadx", operation, {
|
||||
cause,
|
||||
...(output === undefined ? {} : { capturedOutput: output }),
|
||||
@@ -295,7 +300,9 @@ const hostLaunchConstraint = (
|
||||
command: Pick<OwnedCommandFailure, "processError"> | undefined,
|
||||
cause: unknown,
|
||||
) => {
|
||||
const launch = launcherFailureOf(command?.processError ?? cause);
|
||||
const launch =
|
||||
preparationHostCapacityFailure(cause) ??
|
||||
launcherFailureOf(command?.processError ?? cause);
|
||||
return launch?.kind === "host-exhausted" || launch?.kind === "argument-list"
|
||||
? launch
|
||||
: undefined;
|
||||
|
||||
Reference in new issue
Block a user