fix: rebuild mac app for generated protocol changes (#104839)

This commit is contained in:
Peter Steinberger
2026-07-11 18:00:42 -07:00
committed by GitHub
parent 4bbca30990
commit 3fe61030be
2 changed files with 22 additions and 1 deletions
@@ -118,7 +118,13 @@ export function classifyActions(
changedPaths,
{ buildProvenanceKnown, buildRequired, nodeModulesPresent },
) {
const runMacos = changedPaths.length > 0 && detectChangedScope(changedPaths).runMacos;
// CI skips generated protocol-only macOS jobs, but the live app embeds these Swift sources.
const generatedMacProtocolChanged = changedPaths.some((changedPath) =>
/^apps\/shared\/OpenClawKit\/Sources\/OpenClawProtocol\//u.test(changedPath),
);
const runMacos =
changedPaths.length > 0 &&
(detectChangedScope(changedPaths).runMacos || generatedMacProtocolChanged);
const macUiVerification =
runMacos &&
changedPaths.some((changedPath) =>
@@ -337,6 +337,21 @@ describe("openclaw live updater", () => {
macAppRebuild: true,
macUiVerification: true,
});
expect(
classifyActions(["apps/shared/OpenClawKit/Sources/OpenClawProtocol/GatewayModels.swift"], {
buildProvenanceKnown: true,
buildRequired: true,
nodeModulesPresent: true,
}),
).toEqual({
dependencyInstall: false,
gatewayBuild: true,
gatewayProbe: true,
gatewayRestart: true,
gatewaySelfHeal: false,
macAppRebuild: true,
macUiVerification: true,
});
});
test("accepts only the delayed exact target bundle process", () => {