@open-mercato/cezar 0.9.1-pr694.813 → 0.9.1-pr694.821
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/core/codex-ui-mapper.js +27 -0
- package/dist/core/codex-ui-mapper.js.map +1 -1
- package/dist/server/forge/github.d.ts +1 -0
- package/dist/server/forge/github.js +12 -2
- package/dist/server/forge/github.js.map +1 -1
- package/dist/server/forge/types.d.ts +2 -0
- package/dist/server/project-context.d.ts +4 -0
- package/dist/server/project-context.js +2 -1
- package/dist/server/project-context.js.map +1 -1
- package/dist/server/server.d.ts +5 -0
- package/dist/server/server.js +31 -9
- package/dist/server/server.js.map +1 -1
- package/package.json +1 -1
- package/web/dist/assets/arrow-left-BWue3Imk.js +1 -0
- package/web/dist/assets/bundle-mjs-BT31bpU6.js +1 -0
- package/web/dist/assets/{centered-state-D-hkkRHv.js → centered-state-DsblJe6Q.js} +2 -2
- package/web/dist/assets/{chunk-BO2N2NFS-DtrdTCWa.js → chunk-BO2N2NFS-DE6qKn3r.js} +8 -8
- package/web/dist/assets/circle-check-TKq6_8_Y.js +1 -0
- package/web/dist/assets/circle-x-bH39f-Yh.js +1 -0
- package/web/dist/assets/commit-list-CAwllMBX.js +1 -0
- package/web/dist/assets/compare-variants-JnaeMTz5.js +1 -0
- package/web/dist/assets/{core-DePtBHcl.js → core-BCsw8oQw.js} +1 -1
- package/web/dist/assets/diff-Drvekr61.js +3 -0
- package/web/dist/assets/{diff-view-BBgUutQ0.js → diff-view-Ct3kYFRM.js} +2 -2
- package/web/dist/assets/dist-CngV8tyE.js +1 -0
- package/web/dist/assets/{ellipsis-vertical-DFAnsUi4.js → ellipsis-vertical-WowqAN6-.js} +1 -1
- package/web/dist/assets/{file-vT36R94R.js → file-BWgi5VOt.js} +1 -1
- package/web/dist/assets/{git-pull-request-BvjQwr12.js → git-pull-request-D8yt-2Tr.js} +1 -1
- package/web/dist/assets/git-toolbar-BLqu97v8.js +1 -0
- package/web/dist/assets/github-hrWK-ST8.js +1 -0
- package/web/dist/assets/highlighted-body-OFNGDK62-BL-MfFgl.js +1 -0
- package/web/dist/assets/image-preview-B3W7bWIq.js +1 -0
- package/web/dist/assets/index-B96YnNHc.js +22 -0
- package/web/dist/assets/index-DdBHg6_F.css +2 -0
- package/web/dist/assets/lib-BQXq3kEf.js +1 -0
- package/web/dist/assets/lib-BxQXEXDF.js +1 -0
- package/web/dist/assets/mermaid-GHXKKRXX-C4jxqUUb.js +1 -0
- package/web/dist/assets/project-router-CnKsyZKI.js +1 -0
- package/web/dist/assets/react-runtime-CCIEwYL0.js +9 -0
- package/web/dist/assets/{refresh-cw-BgVxWSof.js → refresh-cw-CFp_jUZr.js} +1 -1
- package/web/dist/assets/repo-git-DnkvanyM.js +1 -0
- package/web/dist/assets/rolldown-runtime-QTnfLwEv.js +1 -0
- package/web/dist/assets/{run-diff-DeWQ1xve.js → run-diff-LyXkHJCR.js} +1 -1
- package/web/dist/assets/run-header-BtH23tbQ.js +1 -0
- package/web/dist/assets/{search-x-CbHLclyX.js → search-x-CaddQd7u.js} +1 -1
- package/web/dist/assets/skill-empty-hint-D5QzmqHj.js +1 -0
- package/web/dist/assets/skills-CE0HAI_G.js +1 -0
- package/web/dist/assets/{square-terminal-DRmz43dF.js → square-terminal-CoE5Kj-S.js} +1 -1
- package/web/dist/assets/tab-link-BbQLZUG5.js +1 -0
- package/web/dist/assets/task-changes-BYNpnV0E.js +1 -0
- package/web/dist/assets/task-commits-DRnMTXtG.js +1 -0
- package/web/dist/assets/task-files-DAqPuHp1.js +2 -0
- package/web/dist/assets/{task-thread-x1axqNnn.js → task-thread-DMM5s2zt.js} +2 -2
- package/web/dist/assets/textarea-Dd8d_Pwi.js +1 -0
- package/web/dist/assets/{trash-2-ObVP5T4c.js → trash-2-aYhsIRM2.js} +1 -1
- package/web/dist/assets/{triangle-alert-CHtGkjPK.js → triangle-alert-BMsU3ymT.js} +1 -1
- package/web/dist/assets/{upload-Dx__Y6Lu.js → upload-DH2pWIfO.js} +1 -1
- package/web/dist/assets/use-desktop-BAHxMKrE.js +1 -0
- package/web/dist/assets/utils-D27OaPrA.js +1 -0
- package/web/dist/assets/{workflows-C3gTBtmF.js → workflows-DCkK4Bsn.js} +2 -2
- package/web/dist/assets/zoomable-image-BBB-AoPi.js +1 -0
- package/web/dist/index.html +14 -12
- package/web/dist/assets/arrow-left-BmHnLe4M.js +0 -1
- package/web/dist/assets/bundle-mjs-BegPhL5c.js +0 -1
- package/web/dist/assets/circle-check-CH4jMJue.js +0 -1
- package/web/dist/assets/commit-list-BXNfseD5.js +0 -1
- package/web/dist/assets/compare-variants-CkvpSWZa.js +0 -1
- package/web/dist/assets/diff-CITBzanN.js +0 -3
- package/web/dist/assets/dist-C553orO_.js +0 -1
- package/web/dist/assets/git-toolbar-ChCEnVjR.js +0 -1
- package/web/dist/assets/github-B8nK4e73.js +0 -1
- package/web/dist/assets/highlighted-body-OFNGDK62-BuFJwunK.js +0 -1
- package/web/dist/assets/image-preview-B6kVovYD.js +0 -1
- package/web/dist/assets/index-BWzcnzgp.js +0 -30
- package/web/dist/assets/index-pJfUoRGK.css +0 -2
- package/web/dist/assets/lib-DPEZDBUN.js +0 -1
- package/web/dist/assets/lib-uHpeUPzK.js +0 -1
- package/web/dist/assets/mermaid-GHXKKRXX-CN2zQue0.js +0 -1
- package/web/dist/assets/project-router-C-gp_QmI.js +0 -1
- package/web/dist/assets/repo-git-DW8ekpNQ.js +0 -1
- package/web/dist/assets/run-header-BaLnTHQf.js +0 -1
- package/web/dist/assets/skill-empty-hint-CzXygdIH.js +0 -1
- package/web/dist/assets/skills-Bt9YVDdo.js +0 -1
- package/web/dist/assets/tab-link-C2tgsylt.js +0 -1
- package/web/dist/assets/task-changes-CluQWIkd.js +0 -1
- package/web/dist/assets/task-commits-BJRUd8fY.js +0 -1
- package/web/dist/assets/task-files-CpWfXD2B.js +0 -2
- package/web/dist/assets/textarea-BhdkPlu6.js +0 -1
- package/web/dist/assets/use-desktop-BB0Ck5sN.js +0 -1
- package/web/dist/assets/utils-B8xGEgP3.js +0 -1
- package/web/dist/assets/zoomable-image-Bb6ydBLq.js +0 -1
package/dist/server/server.js
CHANGED
|
@@ -5,7 +5,7 @@ import { AutomationCoordinator } from '../automations/coordinator.js';
|
|
|
5
5
|
import { GithubPoller } from '../automations/github-poller.js';
|
|
6
6
|
import { ProjectAutomationScheduler, WorkspaceAutomationScheduler } from '../automations/scheduler.js';
|
|
7
7
|
import { launchAutomationRun, reconcileAutomationReceipts, validateAutomationPrompt } from '../automations/task-template.js';
|
|
8
|
-
import { automationEventSchema, automationFiltersSchema, automationTaskSchema, } from '../automations/types.js';
|
|
8
|
+
import { automationEventSchema, automationFiltersSchema, automationLogResultSchema, automationTaskSchema, } from '../automations/types.js';
|
|
9
9
|
import { access, constants as fsConstants, mkdir, readFile, realpath, stat, unlink, writeFile } from 'node:fs/promises';
|
|
10
10
|
import { basename, dirname, join, resolve, sep } from 'node:path';
|
|
11
11
|
import { fileURLToPath } from 'node:url';
|
|
@@ -87,7 +87,7 @@ const automationUpdateSchema = automationEditableSchema.extend({ expectedRevisio
|
|
|
87
87
|
const automationCheckSchema = z.object({ mode: z.enum(['preview', 'execute']) }).strict();
|
|
88
88
|
const automationLogQuerySchema = z.object({
|
|
89
89
|
automationId: z.string().optional(),
|
|
90
|
-
result:
|
|
90
|
+
result: automationLogResultSchema.optional(),
|
|
91
91
|
event: automationEventSchema.optional(),
|
|
92
92
|
since: z.string().datetime().optional(),
|
|
93
93
|
cursor: z.coerce.number().int().positive().optional(),
|
|
@@ -628,7 +628,7 @@ export function createApp(deps) {
|
|
|
628
628
|
dataDir: bootDataDir,
|
|
629
629
|
store: deps.store,
|
|
630
630
|
manager: deps.manager,
|
|
631
|
-
automationStore: AutomationStore.open(bootDataDir),
|
|
631
|
+
automationStore: deps.automationStore ?? AutomationStore.open(bootDataDir),
|
|
632
632
|
launchKey: ensureLaunchKey(bootDataDir), // bookmarklet auto-start secret (spec 011)
|
|
633
633
|
};
|
|
634
634
|
// Non-boot projects build lazily on first scoped request; their managers
|
|
@@ -645,7 +645,12 @@ export function createApp(deps) {
|
|
|
645
645
|
// Workspace-level SSE bus (step 2.8) — the registry mutators and the
|
|
646
646
|
// checkout flow (Phase 4) emit here; /api/workspace/events relays.
|
|
647
647
|
const workspaceEvents = deps.workspaceEvents ?? new WorkspaceEventBus();
|
|
648
|
-
const emitAutomationChange = (project, automationId, revision) => workspaceEvents.emit('automation-change', {
|
|
648
|
+
const emitAutomationChange = (project, automationId, revision, deleted = false) => workspaceEvents.emit('automation-change', {
|
|
649
|
+
project: project.id,
|
|
650
|
+
automationId,
|
|
651
|
+
revision,
|
|
652
|
+
...(deleted ? { deleted: true } : {}),
|
|
653
|
+
});
|
|
649
654
|
const automationsChanged = () => deps.automationsChanged?.();
|
|
650
655
|
const providerRuntimeAuth = deps.providerRuntimeAuth
|
|
651
656
|
?? new ProviderRuntimeAuthObserver(providerAuth, (status) => {
|
|
@@ -1964,9 +1969,11 @@ export function createApp(deps) {
|
|
|
1964
1969
|
});
|
|
1965
1970
|
api.delete('/automations/:id', (c) => {
|
|
1966
1971
|
const id = c.req.param('id');
|
|
1967
|
-
|
|
1972
|
+
const store = c.get('project').automationStore;
|
|
1973
|
+
const current = store.get(id);
|
|
1974
|
+
if (!current || !store.delete(id))
|
|
1968
1975
|
return c.json({ error: 'not found' }, 404);
|
|
1969
|
-
emitAutomationChange(c.get('project'), id,
|
|
1976
|
+
emitAutomationChange(c.get('project'), id, current.revision, true);
|
|
1970
1977
|
automationsChanged();
|
|
1971
1978
|
return c.body(null, 204);
|
|
1972
1979
|
});
|
|
@@ -3269,6 +3276,7 @@ export function createApp(deps) {
|
|
|
3269
3276
|
const mergeBodySchema = z.object({
|
|
3270
3277
|
method: z.enum(['merge', 'squash', 'rebase']),
|
|
3271
3278
|
expectedHeadSha: z.string().regex(/^[0-9a-f]{40}$/),
|
|
3279
|
+
overrideRules: z.boolean().optional().default(false),
|
|
3272
3280
|
}).strict();
|
|
3273
3281
|
api.get('/github/prs/:number/merge-state', async (c) => {
|
|
3274
3282
|
const { root: repoRoot } = c.get('project');
|
|
@@ -3633,9 +3641,24 @@ export function startServer(deps, port) {
|
|
|
3633
3641
|
// The subscription hub rides the same HTTP server (one port, zero config):
|
|
3634
3642
|
// createApp registers the topics, the `upgrade` hook below owns the socket.
|
|
3635
3643
|
const socketHub = deps.socketHub ?? createSocketHub();
|
|
3636
|
-
const
|
|
3644
|
+
const automationCoordinator = new AutomationCoordinator({ listProjects });
|
|
3645
|
+
const bootProjectId = deps.bootProjectId ?? 'default';
|
|
3646
|
+
const bootAutomationStore = automationCoordinator.store(bootProjectId, deps.repoRoot);
|
|
3647
|
+
const sharedContexts = deps.contexts ?? new ProjectContexts({
|
|
3648
|
+
listProjects,
|
|
3649
|
+
semaphore: deps.semaphore,
|
|
3650
|
+
automationStore: (projectId, root) => automationCoordinator.store(projectId, root),
|
|
3651
|
+
});
|
|
3637
3652
|
let rescheduleAutomations = () => { };
|
|
3638
|
-
const app = createApp({
|
|
3653
|
+
const app = createApp({
|
|
3654
|
+
...deps,
|
|
3655
|
+
contexts: sharedContexts,
|
|
3656
|
+
automationStore: bootAutomationStore,
|
|
3657
|
+
workspaceEvents,
|
|
3658
|
+
skillsUpdate,
|
|
3659
|
+
socketHub,
|
|
3660
|
+
automationsChanged: () => rescheduleAutomations(),
|
|
3661
|
+
});
|
|
3639
3662
|
// SECURITY: default to loopback. This server executes agents locally and its endpoints are
|
|
3640
3663
|
// same-origin-trusted (only /api/health is CORS-open); binding to a non-loopback host would
|
|
3641
3664
|
// expose an agent-executing box to the network. `bindHost` exists only for a deliberate
|
|
@@ -3648,7 +3671,6 @@ export function startServer(deps, port) {
|
|
|
3648
3671
|
});
|
|
3649
3672
|
const coordinator = new SkillsUpdateCoordinator(skillsUpdate, async () => effectiveSkillsAutoUpdate(await loadWorkspaceConfig()));
|
|
3650
3673
|
const automationProjects = new Map();
|
|
3651
|
-
const automationCoordinator = new AutomationCoordinator({ listProjects });
|
|
3652
3674
|
const automationScheduler = new WorkspaceAutomationScheduler({
|
|
3653
3675
|
coordinator: automationCoordinator,
|
|
3654
3676
|
handle: (projectId, store) => {
|