mirror of
https://github.com/rennf93/roboco.git
synced 2026-08-03 07:23:24 +02:00
Feat/v0.13.0 (#270)
* feat(release): add release-manager feature flag (default off) * feat(release): change classification + semver-bump derivation * feat(release): readiness audit (changelog/version-ref/docs/migration/gate) * feat(release): release-manager engine proposes a gated release * feat(release): fail-closed release executor (bump, gate, publish) * feat(release): CEO approve/reject release-proposal surface * docs(release): document the gated release manager * feat(memory): add org-memory feature flags (default off) * feat(memory): add playbooks table + status enum + migration * feat(memory): playbook service with auditor curation transitions * feat(memory): playbooks RAG index plugin * feat(memory): index a playbook into RAG on approval * feat(memory): distill a high-signal lesson at task completion * feat(memory): keep private journal reflections out of the shared RAG corpus * feat(memory): draft_playbook verb + auditor curation verbs * fix(ci): resolve mypy tests/ errors blocking the gate (UUID casts, annotations) * feat(memory): auto-inject similar lessons/playbooks into the briefing * feat(memory): auditor playbook review queue (api + panel) * docs(memory): document the org-memory loop + playbook verbs * fix(provisioning): idempotent pitch provisioning (reuse product/project by slug on re-approval) * fix(memory): add chunks_playbooks to the chunk schema + isolate release route tests - Migration 030's CHUNK_TABLES was missing chunks_playbooks, breaking the IndexType<->migration parity guard once the PLAYBOOKS index landed. The upgrade is ALTER ... IF EXISTS so adding it is safe on any DB shape. - The release-route fixture's approve/reject paths call db.commit() (real behavior), so a held proposal outlived the per-test rollback and leaked into engine tests that read the global list_open_release_proposals(). Tear down source=release_manager rows after each test. - Make the gather_snapshot real-repo smoke version-agnostic (semver match) so it stops pinning the literal repo version. * chore(release): 0.13.0 * ++ --------- Co-authored-by: Renn F <rennf93@users.noreply.github.com>
This commit is contained in:
@@ -15,3 +15,12 @@ export { streamApi } from "./stream";
|
||||
export { groupsApi } from "./groups";
|
||||
export { settingsApi } from "./settings";
|
||||
export { companyGoalsApi } from "./company-goals";
|
||||
export { releaseApi } from "./release";
|
||||
export type {
|
||||
ReleaseProposal,
|
||||
ReleaseReport,
|
||||
ReleaseGap,
|
||||
ReleaseExecuteResult,
|
||||
} from "./release";
|
||||
export { playbooksApi } from "./playbooks";
|
||||
export type { Playbook } from "./playbooks";
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
import api from "./client";
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// Playbooks — curated, reusable procedures. Delivery agents draft them; the
|
||||
// Auditor (or CEO, via this panel) approves → indexed + auto-suggested, or
|
||||
// rejects → archived.
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export interface Playbook {
|
||||
id: string;
|
||||
title: string;
|
||||
slug: string;
|
||||
problem: string;
|
||||
procedure: string;
|
||||
tags: string[];
|
||||
team?: string | null;
|
||||
scope: string;
|
||||
status: string;
|
||||
created_at?: string | null;
|
||||
}
|
||||
|
||||
export const playbooksApi = {
|
||||
listDrafts: async (): Promise<Playbook[]> => {
|
||||
const { data } = await api.get<Playbook[]>("/playbooks", {
|
||||
params: { status: "draft" },
|
||||
});
|
||||
return data;
|
||||
},
|
||||
approve: async (id: string): Promise<Playbook> => {
|
||||
const { data } = await api.post<Playbook>(`/playbooks/${id}/approve`);
|
||||
return data;
|
||||
},
|
||||
reject: async (id: string, reason: string): Promise<Playbook> => {
|
||||
const { data } = await api.post<Playbook>(`/playbooks/${id}/reject`, { reason });
|
||||
return data;
|
||||
},
|
||||
};
|
||||
@@ -0,0 +1,68 @@
|
||||
import axios from "axios";
|
||||
import api from "./client";
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// Release manager — the CEO approves or rejects a held release proposal that
|
||||
// the release-manager engine prepared (deterministic readiness sweep). Nothing
|
||||
// publishes until the CEO approves; the executor is fail-closed on a red gate.
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export interface ReleaseGap {
|
||||
category: string;
|
||||
detail: string;
|
||||
}
|
||||
|
||||
export interface ReleaseReport {
|
||||
proposed_version: string;
|
||||
bump_kind: string;
|
||||
change_summary: string[];
|
||||
drafted_changelog: string;
|
||||
version_bump_plan: string[];
|
||||
gaps: ReleaseGap[];
|
||||
migration_notes: string[];
|
||||
gate_state: string;
|
||||
}
|
||||
|
||||
export interface ReleaseProposal {
|
||||
task_id: string;
|
||||
title: string;
|
||||
status: string;
|
||||
required_changes?: string | null;
|
||||
report: ReleaseReport;
|
||||
}
|
||||
|
||||
export interface ReleaseExecuteResult {
|
||||
status: string;
|
||||
version: string;
|
||||
files_changed: string[];
|
||||
commit_sha?: string | null;
|
||||
release_url?: string | null;
|
||||
detail: string;
|
||||
}
|
||||
|
||||
export const releaseApi = {
|
||||
// 404 means "no open proposal" — a normal empty state, returned as null.
|
||||
getProposal: async (): Promise<ReleaseProposal | null> => {
|
||||
try {
|
||||
const { data } = await api.get<ReleaseProposal>("/release/proposal");
|
||||
return data;
|
||||
} catch (err) {
|
||||
if (axios.isAxiosError(err) && err.response?.status === 404) {
|
||||
return null;
|
||||
}
|
||||
throw err;
|
||||
}
|
||||
},
|
||||
approve: async (): Promise<ReleaseExecuteResult> => {
|
||||
const { data } = await api.post<ReleaseExecuteResult>(
|
||||
"/release/proposal/approve",
|
||||
);
|
||||
return data;
|
||||
},
|
||||
reject: async (requiredChanges: string): Promise<ReleaseProposal> => {
|
||||
const { data } = await api.post<ReleaseProposal>("/release/proposal/reject", {
|
||||
required_changes: requiredChanges,
|
||||
});
|
||||
return data;
|
||||
},
|
||||
};
|
||||
Reference in New Issue
Block a user