adhdev 0.7.30 → 0.7.33
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/dist/cli/index.js +40 -24
- package/dist/cli/index.js.map +1 -1
- package/dist/index.js +39 -21
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/vendor/session-host-daemon/index.d.mts +1 -1
- package/vendor/session-host-daemon/index.d.ts +1 -1
- package/vendor/session-host-daemon/index.js +11 -0
- package/vendor/session-host-daemon/index.js.map +1 -1
- package/vendor/session-host-daemon/index.mjs +11 -0
- package/vendor/session-host-daemon/index.mjs.map +1 -1
package/dist/cli/index.js
CHANGED
|
@@ -583,16 +583,16 @@ async function detectCLIs(providerLoader) {
|
|
|
583
583
|
const results = await Promise.all(
|
|
584
584
|
cliList.map(async (cli) => {
|
|
585
585
|
try {
|
|
586
|
-
const pathResult = await execAsync(`${whichCmd} ${cli.command}
|
|
586
|
+
const pathResult = await execAsync(`${whichCmd} ${cli.command}`);
|
|
587
587
|
if (!pathResult) return { ...cli, installed: false };
|
|
588
588
|
const firstPath = pathResult.split("\n")[0];
|
|
589
589
|
let version2;
|
|
590
590
|
try {
|
|
591
591
|
const versionCommands = [
|
|
592
592
|
cli.versionCommand,
|
|
593
|
-
`${cli.command} --version
|
|
594
|
-
`${cli.command} -V
|
|
595
|
-
`${cli.command} -v
|
|
593
|
+
`${cli.command} --version`,
|
|
594
|
+
`${cli.command} -V`,
|
|
595
|
+
`${cli.command} -v`
|
|
596
596
|
].filter((v2) => !!v2);
|
|
597
597
|
for (const versionCommand of versionCommands) {
|
|
598
598
|
const versionResult = await execAsync(versionCommand, 3e3);
|
|
@@ -2998,10 +2998,13 @@ var init_ide_provider_instance = __esm({
|
|
|
2998
2998
|
if (result?.found && result.x != null && result.y != null) {
|
|
2999
2999
|
const x = result.x;
|
|
3000
3000
|
const y = result.y;
|
|
3001
|
-
|
|
3002
|
-
|
|
3003
|
-
|
|
3004
|
-
|
|
3001
|
+
if (cdp.send) {
|
|
3002
|
+
await cdp.send("Input.dispatchMouseEvent", { type: "mousePressed", x, y, button: "left", clickCount: 1 });
|
|
3003
|
+
await cdp.send("Input.dispatchMouseEvent", { type: "mouseReleased", x, y, button: "left", clickCount: 1 });
|
|
3004
|
+
LOG.info("IdeInstance", `[IdeInstance:${this.type}] autoApprove: dispatched mouse event at ${x},${y}`);
|
|
3005
|
+
} else {
|
|
3006
|
+
LOG.warn("IdeInstance", `[IdeInstance:${this.type}] autoApprove: cdp.send() not available for coordinate click`);
|
|
3007
|
+
}
|
|
3005
3008
|
}
|
|
3006
3009
|
this.pushEvent({
|
|
3007
3010
|
event: "agent:auto_approved",
|
|
@@ -7482,14 +7485,6 @@ var init_provider_loader = __esm({
|
|
|
7482
7485
|
}
|
|
7483
7486
|
/**
|
|
7484
7487
|
* Get raw provider metadata by type (NO scripts loaded).
|
|
7485
|
-
* Use resolve() when you need scripts (readChat, listModels, etc).
|
|
7486
|
-
* @deprecated Use getMeta() for metadata or resolve() for scripts.
|
|
7487
|
-
*/
|
|
7488
|
-
get(type) {
|
|
7489
|
-
return this.providers.get(type);
|
|
7490
|
-
}
|
|
7491
|
-
/**
|
|
7492
|
-
* Get raw provider metadata by type (NO scripts loaded).
|
|
7493
7488
|
* Safe for: category checks, icon, displayName, targetFilter, cdpPorts.
|
|
7494
7489
|
* NOT safe for: script execution (readChat, listModels, sendMessage).
|
|
7495
7490
|
* Use resolve() when scripts are needed.
|
|
@@ -9103,7 +9098,7 @@ var init_router = __esm({
|
|
|
9103
9098
|
}
|
|
9104
9099
|
}
|
|
9105
9100
|
const keysToRemove = [];
|
|
9106
|
-
for (const key of this.deps.instanceManager.
|
|
9101
|
+
for (const key of this.deps.instanceManager.listInstanceIds()) {
|
|
9107
9102
|
if (key === `ide:${ideType}` || typeof key === "string" && key.startsWith(`ide:${ideType}_`)) {
|
|
9108
9103
|
keysToRemove.push(key);
|
|
9109
9104
|
}
|
|
@@ -19157,8 +19152,12 @@ var init_provider_cli_adapter = __esm({
|
|
|
19157
19152
|
LOG.info("CLI", `[${this.cliType}] Using login shell (script shim or non-native binary)`);
|
|
19158
19153
|
}
|
|
19159
19154
|
shellCmd = isWin ? "cmd.exe" : process.env.SHELL || "/bin/zsh";
|
|
19160
|
-
|
|
19161
|
-
|
|
19155
|
+
if (isWin) {
|
|
19156
|
+
shellArgs = ["/c", binaryPath, ...allArgs];
|
|
19157
|
+
} else {
|
|
19158
|
+
const fullCmd = [binaryPath, ...allArgs].map(shSingleQuote).join(" ");
|
|
19159
|
+
shellArgs = ["-l", "-c", fullCmd];
|
|
19160
|
+
}
|
|
19162
19161
|
} else {
|
|
19163
19162
|
shellCmd = binaryPath;
|
|
19164
19163
|
shellArgs = allArgs;
|
|
@@ -38551,6 +38550,12 @@ var init_provider_instance_manager = __esm({
|
|
|
38551
38550
|
get size() {
|
|
38552
38551
|
return this.instances.size;
|
|
38553
38552
|
}
|
|
38553
|
+
/**
|
|
38554
|
+
* All Instance IDs (for iteration without exposing the private Map)
|
|
38555
|
+
*/
|
|
38556
|
+
listInstanceIds() {
|
|
38557
|
+
return [...this.instances.keys()];
|
|
38558
|
+
}
|
|
38554
38559
|
// ─── State collect ────────────────────────────────
|
|
38555
38560
|
/**
|
|
38556
38561
|
* all Instance's current status collect
|
|
@@ -42992,7 +42997,20 @@ var init_dist = __esm({
|
|
|
42992
42997
|
request
|
|
42993
42998
|
};
|
|
42994
42999
|
const response = await new Promise((resolve12, reject) => {
|
|
42995
|
-
|
|
43000
|
+
const timeout = setTimeout(() => {
|
|
43001
|
+
this.requestWaiters.delete(requestId);
|
|
43002
|
+
reject(new Error(`Session host request timed out after 30s (${request.type})`));
|
|
43003
|
+
}, 3e4);
|
|
43004
|
+
this.requestWaiters.set(requestId, {
|
|
43005
|
+
resolve: (value) => {
|
|
43006
|
+
clearTimeout(timeout);
|
|
43007
|
+
resolve12(value);
|
|
43008
|
+
},
|
|
43009
|
+
reject: (error48) => {
|
|
43010
|
+
clearTimeout(timeout);
|
|
43011
|
+
reject(error48);
|
|
43012
|
+
}
|
|
43013
|
+
});
|
|
42996
43014
|
this.socket?.write(serializeEnvelope(envelope));
|
|
42997
43015
|
});
|
|
42998
43016
|
return response;
|
|
@@ -45399,7 +45417,7 @@ var init_adhdev_daemon = __esm({
|
|
|
45399
45417
|
fs14 = __toESM(require("fs"));
|
|
45400
45418
|
path17 = __toESM(require("path"));
|
|
45401
45419
|
import_chalk2 = __toESM(require("chalk"));
|
|
45402
|
-
pkgVersion = "0.7.
|
|
45420
|
+
pkgVersion = "0.7.33";
|
|
45403
45421
|
if (pkgVersion === "unknown") {
|
|
45404
45422
|
try {
|
|
45405
45423
|
const possiblePaths = [
|
|
@@ -46420,7 +46438,7 @@ function registerSetupCommands(program2, providerLoader) {
|
|
|
46420
46438
|
launchWithCdp: launchWithCdp2
|
|
46421
46439
|
} = await Promise.resolve().then(() => (init_src(), src_exports));
|
|
46422
46440
|
const resolvedType = targetArg ? providerLoader.resolveAlias(targetArg.toLowerCase()) : null;
|
|
46423
|
-
const resolvedProvider = resolvedType ? providerLoader.
|
|
46441
|
+
const resolvedProvider = resolvedType ? providerLoader.getMeta(resolvedType) : null;
|
|
46424
46442
|
const cliType = resolvedProvider && (resolvedProvider.category === "cli" || resolvedProvider.category === "acp") ? resolvedType : null;
|
|
46425
46443
|
if (cliType) {
|
|
46426
46444
|
const workingDir = options.dir || options.workspace || process.cwd();
|
|
@@ -47040,7 +47058,6 @@ function registerProviderCommands(program2) {
|
|
|
47040
47058
|
}
|
|
47041
47059
|
}
|
|
47042
47060
|
});
|
|
47043
|
-
provider;
|
|
47044
47061
|
provider.command("create [type]").description("Interactive wizard to scaffold a new provider").option("-n, --name <name>", "Display name").option("-c, --category <cat>", "Category: ide, extension, cli, acp").option("-p, --port <port>", "Starting CDP port").option("--builtin", "Create in builtin directory").action(async (cliType, options) => {
|
|
47045
47062
|
try {
|
|
47046
47063
|
const readline = await import("readline/promises");
|
|
@@ -47332,7 +47349,6 @@ function registerProviderCommands(program2) {
|
|
|
47332
47349
|
}]);
|
|
47333
47350
|
userComment = commentAnswer.comment || "";
|
|
47334
47351
|
}
|
|
47335
|
-
let consecutiveFailures = 0;
|
|
47336
47352
|
const targetDir = loader.getUserProviderDir(providerToFix.category, type);
|
|
47337
47353
|
console.log(import_chalk6.default.bold(`
|
|
47338
47354
|
\u25B6\uFE0F Generating [${functionsToFix.length}] function(s) natively via autonomous agent for ${type}...`));
|