@forge/manifest
11.3.1-next.211.3.1-next.3
out/validators/modules-validators/rovo/validate-agent-connector-remote-endpoints.jsout/validators/modules-validators/rovo/validate-agent-connector-remote-endpoints.js+18−20
Index: package/out/validators/modules-validators/rovo/validate-agent-connector-remote-endpoints.js
===================================================================
--- package/out/validators/modules-validators/rovo/validate-agent-connector-remote-endpoints.js
+++ package/out/validators/modules-validators/rovo/validate-agent-connector-remote-endpoints.js
@@ -10,29 +10,27 @@
const endpointModuleKey = (0, utils_1.cleanKey)(types_1.AllModuleTypes.CoreEndpoint);
const endpointModules = allModules[endpointModuleKey] ?? [];
agentConnectors?.forEach((agentConnector) => {
const a2aProtocol = agentConnector.protocols.agent2Agent;
- const endpointReferences = [a2aProtocol.agentCard.endpoint, a2aProtocol.jsonRpcTransport?.endpoint].filter(Boolean);
+ const endpointReference = a2aProtocol.jsonRpcTransport?.endpoint;
const agentKey = agentConnector.key;
- endpointReferences.forEach((endpointReference) => {
- const endpointModule = endpointModules.find((e) => e.key === endpointReference);
- if (!endpointModule) {
- validationErrors.push({
- message: text_1.errors.modules.rovo.incorrectA2AEndpointReference(agentKey, endpointReference),
- reference: text_1.References.Modules,
- level: 'error',
- ...(0, utils_1.findPosition)(agentKey, yamlContentByLine)
- });
- }
- if (endpointModule && !endpointModule?.remote) {
- validationErrors.push({
- message: text_1.errors.modules.rovo.incorrectA2AEndpointConfiguration(agentKey, endpointReference),
- reference: text_1.References.Modules,
- level: 'error',
- ...(0, utils_1.findPosition)(endpointReference, yamlContentByLine)
- });
- }
- });
+ const endpointModule = endpointModules.find((e) => e.key === endpointReference);
+ if (!endpointModule) {
+ validationErrors.push({
+ message: text_1.errors.modules.rovo.incorrectA2AEndpointReference(agentKey, endpointReference),
+ reference: text_1.References.Modules,
+ level: 'error',
+ ...(0, utils_1.findPosition)(agentKey, yamlContentByLine)
+ });
+ }
+ if (endpointModule && !endpointModule?.remote) {
+ validationErrors.push({
+ message: text_1.errors.modules.rovo.incorrectA2AEndpointConfiguration(agentKey, endpointReference),
+ reference: text_1.References.Modules,
+ level: 'error',
+ ...(0, utils_1.findPosition)(endpointReference, yamlContentByLine)
+ });
+ }
});
return validationErrors;
};
exports.validateAgentConnectorRemoteEndpoints = validateAgentConnectorRemoteEndpoints;