pi-subagents 0.8.4 → 0.8.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/async-execution.ts +15 -4
- package/index.ts +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
## [Unreleased]
|
|
4
4
|
|
|
5
|
+
## [0.8.5] - 2026-02-16
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
- Async subagent execution no longer fails with "jiti not found" on machines without a global `jiti` install. The jiti resolution now tries three strategies: vanilla `jiti`, the `@mariozechner/jiti` fork, and finally resolves `@mariozechner/jiti` from pi's own installation via `process.argv[1]`. Since pi always ships the fork as a dependency, async mode now works out of the box.
|
|
9
|
+
- Improved the "jiti not found" error message to explain what's needed and how to fix it.
|
|
10
|
+
|
|
5
11
|
## [0.8.4] - 2026-02-13
|
|
6
12
|
|
|
7
13
|
### Fixed
|
package/async-execution.ts
CHANGED
|
@@ -24,11 +24,22 @@ import {
|
|
|
24
24
|
|
|
25
25
|
const require = createRequire(import.meta.url);
|
|
26
26
|
const jitiCliPath: string | undefined = (() => {
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
27
|
+
const candidates: Array<() => string> = [
|
|
28
|
+
() => path.join(path.dirname(require.resolve("jiti/package.json")), "lib/jiti-cli.mjs"),
|
|
29
|
+
() => path.join(path.dirname(require.resolve("@mariozechner/jiti/package.json")), "lib/jiti-cli.mjs"),
|
|
30
|
+
() => {
|
|
31
|
+
const piEntry = fs.realpathSync(process.argv[1]);
|
|
32
|
+
const piRequire = createRequire(piEntry);
|
|
33
|
+
return path.join(path.dirname(piRequire.resolve("@mariozechner/jiti/package.json")), "lib/jiti-cli.mjs");
|
|
34
|
+
},
|
|
35
|
+
];
|
|
36
|
+
for (const candidate of candidates) {
|
|
37
|
+
try {
|
|
38
|
+
const p = candidate();
|
|
39
|
+
if (fs.existsSync(p)) return p;
|
|
40
|
+
} catch {}
|
|
31
41
|
}
|
|
42
|
+
return undefined;
|
|
32
43
|
})();
|
|
33
44
|
|
|
34
45
|
export interface AsyncExecutionContext {
|
package/index.ts
CHANGED
|
@@ -335,7 +335,7 @@ MANAGEMENT (use action field — omit agent/task/chain/tasks):
|
|
|
335
335
|
if (effectiveAsync) {
|
|
336
336
|
if (!isAsyncAvailable()) {
|
|
337
337
|
return {
|
|
338
|
-
content: [{ type: "text", text: "jiti not found" }],
|
|
338
|
+
content: [{ type: "text", text: "Async mode requires jiti for TypeScript execution but it could not be found. Install globally: npm install -g jiti" }],
|
|
339
339
|
isError: true,
|
|
340
340
|
details: { mode: "single" as const, results: [] },
|
|
341
341
|
};
|
package/package.json
CHANGED