Repository navigation
chore: rolling promotion dev -> main #2817
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 17 commits
beee9e3
ffb39ba
bd99711
80f3f88
f71f1b1
7ac5926
cfc70cd
c5a63d9
73ccdb4
2523a4b
d3e7ff8
05d99d9
dce5752
6a52dac
069bfb1
433f91a
6ecfd81
c8280d4
eccf0ae
a4fddce
b5e68ee
e70dfd5
43699b2
5a6c29f
15c0026
fd27eda
2d6936c
1a6f641
83a9718
c38fe7b
a13384e
b1a31c4
8fe9fb7
f45d634
b3735d1
299358f
e3f7e87
0d0641f
f5ca6df
1db029d
baf75a5
bd6fc03
ef85a90
e575514
7e915b3
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| # Brainstorm: Genie dual-mode Orca plugin | ||
|
|
||
| **Status:** APPROVED — independent review SHIP at `2026-08-29T18:13:16Z`. | ||
|
|
||
| Option A preserves Genie's current standalone lifecycle while adding an explicit Orca mode in which Orca is | ||
| the sole lifecycle authority. The current design fixes the boundary at Orca's public | ||
| `orca orchestration ... --json` CLI, rejects local lifecycle fallback or mirroring, and retires Genie MCP only | ||
| after authority guards, adapter parity, plugin lifecycle, packaging, and documentation are green. | ||
|
|
||
| This DRAFT, [DESIGN.md](DESIGN.md), [WISH.md](../../wishes/genie-dual-mode-orca-plugin/WISH.md), and the | ||
| [INDEX entry](../../INDEX.md) are the four canonical planning documents. Current reviewable DESIGN SHA-256 | ||
| `2499668e81fe3d3f3f7f15bac0246c3e0647a036e9441fa882dcf6a8ecb92bf9` was independently reviewed SHIP by | ||
| `term_6c98a3c8-7ac8-4274-a8e9-ade35e2d82dd` at `2026-08-29T18:13:16Z`; the four-document plan is approved and | ||
| A1–A7 are authorized in the recorded dependency order. The earlier 2026-08-29 SHIP review by | ||
| `term_fb7838bc-745e-45ba-9d62-becc5d842e07` at `2026-08-29T17:57:45Z` covered superseded digest | ||
| `1b8b6c034310fab2699214866893658a4c041d9269a971bb685d57bc359f7dfe` and is retained only as historical | ||
| evidence; it does not approve the current four-document set. Historical v6/Corpo Leve artifacts are evidence, | ||
| not implementation input. |
Large diffs are not rendered by default.
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| import type { OrcaOrchestrationAdapter } from '../../src/lib/orca-orchestration-adapter'; | ||
| import { createOrcaOrchestrationAdapter } from '../../src/lib/orca-orchestration-adapter'; | ||
| import { createOrcaPluginRuntime } from './orca-runtime'; | ||
|
|
||
| export const ORCA_RUN_LIST_COMMAND = 'genie.orca.run-list'; | ||
|
|
||
| interface OrcaPluginActivationContext { | ||
| commands: { | ||
| register(commandId: string, handler: (args?: unknown) => Promise<unknown>): void; | ||
| }; | ||
| } | ||
|
|
||
| export function createOrcaPluginEntrypoint( | ||
| adapter: OrcaOrchestrationAdapter = createOrcaOrchestrationAdapter(), | ||
| ): (context: OrcaPluginActivationContext) => Promise<void> { | ||
| const runtime = createOrcaPluginRuntime(adapter); | ||
| return async (context) => { | ||
| context.commands.register(ORCA_RUN_LIST_COMMAND, () => runtime.execute({ operation: 'run-list', limit: 100 })); | ||
| }; | ||
| } | ||
|
|
||
| export default createOrcaPluginEntrypoint(); |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| { | ||
| "manifestVersion": 1, | ||
| "id": "genie", | ||
| "publisher": "automagik", | ||
| "name": "Genie", | ||
| "version": "5.260829.6", | ||
|
coderabbitai[bot] marked this conversation as resolved.
Resolved
|
||
| "description": "Genie workflows backed by Orca as the sole lifecycle authority.", | ||
| "author": { | ||
| "name": "Namastex Labs", | ||
| "url": "https://github.com/automagik-dev" | ||
| }, | ||
| "repository": "https://github.com/automagik-dev/genie", | ||
| "engines": { | ||
| "orca": ">=1.4.192" | ||
| }, | ||
| "pluginApi": 1, | ||
| "main": "orca-entrypoint.min.js", | ||
|
coderabbitai[bot] marked this conversation as resolved.
Resolved
|
||
| "contributes": { | ||
| "commands": [ | ||
| { | ||
| "id": "genie.orca.run-list", | ||
| "title": "Genie: List Orca Runs" | ||
| } | ||
| ] | ||
| }, | ||
| "capabilities": [] | ||
| } | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,106 @@ | ||
| import { expect, test } from 'bun:test'; | ||
| import { createHash, randomUUID } from 'node:crypto'; | ||
| import { readFile, readdir, stat } from 'node:fs/promises'; | ||
| import { resolve } from 'node:path'; | ||
| import { OrcaAdapterError } from '../../src/lib/orca-orchestration-adapter'; | ||
| import { createOrcaPluginRuntime } from './orca-runtime'; | ||
|
|
||
| const runRealSmoke = process.env.GENIE_ORCA_REAL_RUNTIME_SMOKE === '1' ? test : test.skip; | ||
| const lifecyclePaths = [ | ||
| '.genie/genie.db', | ||
| '.genie/genie.db-wal', | ||
| '.genie/genie.db-shm', | ||
| '.genie/INDEX.md', | ||
| '.genie/wishes', | ||
| ]; | ||
|
|
||
| async function digestPath(path: string): Promise<string> { | ||
| try { | ||
| const metadata = await stat(path); | ||
| if (metadata.isDirectory()) { | ||
| const entries = (await readdir(path)).sort(); | ||
| const children = await Promise.all( | ||
| entries.map(async (entry) => `${entry}:${await digestPath(resolve(path, entry))}`), | ||
| ); | ||
| return createHash('sha256').update(children.join('\n')).digest('hex'); | ||
| } | ||
| return createHash('sha256') | ||
| .update(await readFile(path)) | ||
| .digest('hex'); | ||
| } catch (error) { | ||
| if (error instanceof Error && 'code' in error && error.code === 'ENOENT') return 'absent'; | ||
| throw error; | ||
| } | ||
| } | ||
|
|
||
| async function snapshotLocalLifecycle(): Promise<Readonly<Record<string, string>>> { | ||
| return Object.freeze( | ||
| Object.fromEntries(await Promise.all(lifecyclePaths.map(async (path) => [path, await digestPath(path)]))), | ||
| ); | ||
| } | ||
|
|
||
| function object(value: unknown): Record<string, unknown> { | ||
| if (typeof value !== 'object' || value === null || Array.isArray(value)) throw new Error('expected an object'); | ||
| return value as Record<string, unknown>; | ||
| } | ||
|
|
||
| function receiptEntityId(result: unknown, entity: 'run' | 'task', legacyId: 'runId' | 'taskId'): string { | ||
| const record = object(result); | ||
| const value = record[legacyId] ?? object(record[entity]).id; | ||
| if (typeof value !== 'string') throw new Error(`missing ${entity} identifier`); | ||
| return value; | ||
| } | ||
|
|
||
| runRealSmoke( | ||
| 'real Orca runtime either completes the disposable flow or fails unsupported without mutation', | ||
| async () => { | ||
| const before = await snapshotLocalLifecycle(); | ||
| const runtime = createOrcaPluginRuntime(); | ||
| try { | ||
| await runtime.probe(); | ||
| } catch (error) { | ||
| expect(error).toBeInstanceOf(OrcaAdapterError); | ||
| expect((error as OrcaAdapterError).code).toBe('unsupported_environment'); | ||
| expect(await snapshotLocalLifecycle()).toEqual(before); | ||
| console.warn('Orca real-runtime smoke: unsupported_environment (no local lifecycle mutation)'); | ||
| return; | ||
| } | ||
|
|
||
| const prior = await runtime.execute({ operation: 'run-current' }); | ||
| const priorRunId = String(object(object(prior.result).run).id); | ||
| const suffix = randomUUID().replaceAll('-', '').slice(0, 12); | ||
| let disposableTaskId: string | undefined; | ||
|
|
||
| try { | ||
| const createdRun = await runtime.execute({ | ||
| operation: 'run-create', | ||
| objective: `Genie A3 disposable smoke ${suffix}`, | ||
| }); | ||
|
Comment on lines
+75
to
+78
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🗄️ Data Integrity & Integration | 🟠 Major | 🏗️ Heavy lift Do not leave smoke-test entities in the active Orca state. This test creates a run and task, but the As per coding guidelines: “Fixtures must live under a temporary directory and must isolate Also applies to: 83-84, 96-98 🤖 Prompt for AI AgentsSource: Coding guidelines |
||
| const disposableRunId = receiptEntityId(createdRun.result, 'run', 'runId'); | ||
| const runReadback = await runtime.execute({ operation: 'run-show', id: disposableRunId }); | ||
| expect(object(object(runReadback.result).run).id).toBe(disposableRunId); | ||
|
|
||
| const createdTask = await runtime.execute({ operation: 'task-create', spec: `Disposable A3 task ${suffix}` }); | ||
| disposableTaskId = receiptEntityId(createdTask.result, 'task', 'taskId'); | ||
| await runtime.execute({ | ||
| operation: 'task-update', | ||
| id: disposableTaskId, | ||
| status: 'completed', | ||
| result: { summary: 'Disposable A3 real-runtime smoke settled successfully.' }, | ||
| }); | ||
| const tasks = object(await runtime.execute({ operation: 'task-list' }).then((response) => response.result)).tasks; | ||
| expect( | ||
| Array.isArray(tasks) && | ||
| tasks.some((task) => object(task).id === disposableTaskId && object(task).status === 'completed'), | ||
| ).toBe(true); | ||
| } finally { | ||
| await runtime.execute({ operation: 'run-use', id: priorRunId }); | ||
| } | ||
|
|
||
| expect(disposableTaskId).toBeDefined(); | ||
| const restored = await runtime.execute({ operation: 'run-current' }); | ||
| expect(object(object(restored.result).run).id).toBe(priorRunId); | ||
| expect(await snapshotLocalLifecycle()).toEqual(before); | ||
| }, | ||
| 30_000, | ||
| ); | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This new manifest declares
5.260829.6, while this commit setspackage.jsonand the other plugin manifests to5.260829.7. Consequently,bun test scripts/release-payload-version.test.tsfails its committed-metadata check, and the source version preflight prevents building the promoted release tarballs. Update this manifest as part of the same version bump.AGENTS.md reference: AGENTS.md:L55-L57
Useful? React with 👍 / 👎.