agentwheel 0.18.2 → 0.18.3
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/index.js +26 -2
- package/openpack.json +1 -1
- package/package.json +1 -1
- package/skills/agentwheel/SKILL.md +1 -1
- package/skills/agentwheel-discovery/SKILL.md +1 -1
package/dist/index.js
CHANGED
|
@@ -13918,10 +13918,34 @@ function isCurrentLocalTarget(scope, graph) {
|
|
|
13918
13918
|
}
|
|
13919
13919
|
async function hasRelevantLegacyManifestCandidate(scope, graph, selected) {
|
|
13920
13920
|
if (!isCurrentLocalTarget(scope, graph)) return false;
|
|
13921
|
-
const
|
|
13922
|
-
const manifest = (await collectManifestPaths([
|
|
13921
|
+
const manifestPath = await legacyManifestPathForConfiguredTarget(scope, graph) ?? (await legacyTargetStateForGraph(scope, graph)).manifestPath;
|
|
13922
|
+
const manifest = (await collectManifestPaths([manifestPath]))[0];
|
|
13923
13923
|
return manifest?.manifest.entries.some((entry) => entryMatchesGraphPackages(entry, graph.lock, selected)) ?? false;
|
|
13924
13924
|
}
|
|
13925
|
+
async function legacyManifestPathForConfiguredTarget(scope, graph) {
|
|
13926
|
+
const agent = scope.config.agents[graph.targetKey];
|
|
13927
|
+
if (!agent || !agent.installationType) return void 0;
|
|
13928
|
+
if (agent.transport === "ssh") {
|
|
13929
|
+
throw new Error(`Installed-state normalization cannot hand off SSH target '${graph.targetKey}' locally.`);
|
|
13930
|
+
}
|
|
13931
|
+
if (agent.adapter !== graph.adapter) {
|
|
13932
|
+
throw new Error(`Graph adapter '${graph.adapter}' does not match configured target adapter '${agent.adapter}'.`);
|
|
13933
|
+
}
|
|
13934
|
+
const adapter = await resolveAdapter({
|
|
13935
|
+
adapter: agent.adapter,
|
|
13936
|
+
adapterConfig: agent.adapterConfig,
|
|
13937
|
+
adapterModule: agent.adapterModule,
|
|
13938
|
+
allowAdapterCode: false,
|
|
13939
|
+
baseDir: scope.root
|
|
13940
|
+
});
|
|
13941
|
+
const targetRoot = resolveConfigPath(agent.root, scope.root);
|
|
13942
|
+
const installRoot = resolve25(installRootForAdapterInstallationType(adapter, targetRoot, agent.installationType, false));
|
|
13943
|
+
const stateKey = stateKeyFor(adapter.name, {
|
|
13944
|
+
installationType: agent.installationType,
|
|
13945
|
+
targetFingerprint: graph.lock.canonical.targetFingerprint
|
|
13946
|
+
});
|
|
13947
|
+
return installManifestPath(installRoot, adapter.name, { installationType: agent.installationType, stateKey });
|
|
13948
|
+
}
|
|
13925
13949
|
async function targetStateForGraph(scope, graph, identityFleetId = scope.fleetId ?? null) {
|
|
13926
13950
|
const agent = scope.config.agents[graph.targetKey];
|
|
13927
13951
|
if (agent?.transport === "ssh") {
|
package/openpack.json
CHANGED
package/package.json
CHANGED