mirror of
https://github.com/fabro-sh/fabro.git
synced 2026-10-09 03:20:56 +00:00
parent
61f79a3c12
commit
d1fcb32c16
3 changed files with 178 additions and 7 deletions
174
run.json
174
run.json
|
|
@ -496,14 +496,112 @@
|
|||
}
|
||||
},
|
||||
"web_url": "http://127.0.0.1:32276/runs/01KSN2VNQ496GSM5N0RSZFDNHN",
|
||||
"start": null,
|
||||
"status": {
|
||||
"kind": "starting"
|
||||
"start": {
|
||||
"start_time": "2026-05-27T16:04:24.169450Z",
|
||||
"run_branch": "fabro/run/01KSN2VNQ496GSM5N0RSZFDNHN",
|
||||
"base_sha": "e13de9faafbc61165d6b5115eecbc2f327271eef"
|
||||
},
|
||||
"status_updated_at": "2026-05-27T16:04:09.626894Z",
|
||||
"last_event_at": "2026-05-27T16:04:23.756178Z",
|
||||
"status": {
|
||||
"kind": "running"
|
||||
},
|
||||
"status_updated_at": "2026-05-27T16:04:24.169500Z",
|
||||
"last_event_at": "2026-05-27T16:04:26.525200Z",
|
||||
"pending_control": null,
|
||||
"checkpoints": [],
|
||||
"checkpoints": [
|
||||
{
|
||||
"seq": 21,
|
||||
"checkpoint": {
|
||||
"timestamp": "2026-05-27T16:04:26.525081Z",
|
||||
"current_node": "start",
|
||||
"completed_nodes": [
|
||||
"start"
|
||||
],
|
||||
"node_retries": {},
|
||||
"context_values": {
|
||||
"failure_signature": "",
|
||||
"internal.retry_count.start": 0,
|
||||
"graph.goal": "# Define automation API contract and clients\n\n- Number: #396\n- State: OPEN\n- Author: brynary (Bryan Helmkamp)\n- Created: 2026-05-25T15:06:24Z\n- Updated: 2026-05-25T15:06:24Z\n- URL: https://github.com/fabro-sh/fabro/issues/396\n\n## Body\n\n## Goal\n\nDefine the public Automations API contract, reuse compatible Rust domain types, and regenerate generated API clients.\n\n## Scope\n\nUpdate the OpenAPI spec under `/api/v1` with these paths:\n\n```http\nGET /automations\nPOST /automations\nGET /automations/{id}\nPUT /automations/{id}\nDELETE /automations/{id}\nGET /automations/{id}/runs\nPOST /automations/{id}/runs\n```\n\nAdd schemas for:\n\n- `Automation`\n- `AutomationTarget`\n- `AutomationTrigger`\n- `AutomationApiTrigger`\n- `AutomationScheduleTrigger`\n- `CreateAutomationRequest`\n- `ReplaceAutomationRequest`\n- `AutomationListResponse`\n\nUse this response shape for automations:\n\n```ts\ntype Automation = {\n id: string;\n revision: string;\n name: string;\n description: string | null;\n enabled: boolean;\n target: AutomationTarget;\n triggers: AutomationTrigger[];\n};\n\ntype AutomationTarget = {\n repository: string;\n ref: string;\n workflow: string;\n};\n\ntype AutomationTrigger =\n | { id: string; type: \"api\"; enabled: boolean }\n | { id: string; type: \"schedule\"; enabled: boolean; expression: string };\n```\n\nRequest shapes:\n\n```ts\ntype CreateAutomationRequest = {\n id: string;\n name: string;\n description?: string | null;\n enabled?: boolean;\n target: AutomationTarget;\n triggers: AutomationTrigger[];\n};\n\ntype ReplaceAutomationRequest = {\n name: string;\n description?: string | null;\n enabled: boolean;\n target: AutomationTarget;\n triggers: AutomationTrigger[];\n};\n```\n\nContract details:\n\n- Use an OpenAPI discriminator with `propertyName: type` for trigger variants.\n- Unknown trigger discriminator values should be reported by handlers as domain validation errors with HTTP 422, not malformed JSON errors with HTTP 400.\n- Reuse existing `Run` and paginated run-list envelope schemas for automation run endpoints.\n- Add `If-Match` header parameters for replace and delete operations.\n- Add `ETag` response headers on automation read and replace responses.\n- Response codes should cover 200, 201, 204, 400, 404, 409, 422, and 428 where applicable.\n- Before generating duplicate Rust types, search for matching `fabro-automation` domain types and add `with_replacement(...)` mappings where the serde wire shape is identical.\n- Add JSON parity tests for every reused automation type.\n\n## Files\n\nModify:\n\n- `docs/public/api-reference/fabro-api.yaml`\n- `lib/crates/fabro-api/Cargo.toml`\n- `lib/crates/fabro-api/build.rs`\n- Generated Rust API files under `lib/crates/fabro-api/src`, as produced by build/codegen\n- Generated TypeScript client files under `lib/packages/fabro-api-client`\n\nCreate:\n\n- `lib/crates/fabro-api/tests/automation_round_trip.rs`\n\n## Acceptance Criteria\n\n- The OpenAPI document exposes the full backend Automations API contract.\n- Rust generated API types compile.\n- Compatible automation domain types are reused instead of duplicated.\n- Reused type JSON parity is covered by tests.\n- The TypeScript API client contains generated automation operations and types.\n- No web UI consumer imports are added.\n\n## Verification\n\nRun:\n\n```bash\ncargo build -p fabro-api\ncargo nextest run -p fabro-api\ncd lib/packages/fabro-api-client && bun run generate\ngit diff -- apps/fabro-web lib/crates/fabro-cli\n```\n\nExpected: generated API files may change; application UI and CLI command modules should not change.\n\n\n## Comments\n\nNo comments.\n",
|
||||
"outcome": "succeeded",
|
||||
"internal.work_dir": "/home/daytona/workspace/fabro",
|
||||
"current_node": "start",
|
||||
"internal.run_id": "01KSN2VNQ496GSM5N0RSZFDNHN",
|
||||
"internal.thread_id": null,
|
||||
"internal.fidelity": "compact",
|
||||
"graph.model_stylesheet": "\n * { model: claude-opus-4-7; }\n ",
|
||||
"graph.rankdir": "LR",
|
||||
"internal.node_visit_count": 1,
|
||||
"failure_class": ""
|
||||
},
|
||||
"node_outcomes": {
|
||||
"start": {
|
||||
"status": "succeeded",
|
||||
"usage": null
|
||||
}
|
||||
},
|
||||
"next_node_id": "toolchain",
|
||||
"node_visits": {
|
||||
"start": 1
|
||||
}
|
||||
},
|
||||
"diff": {}
|
||||
},
|
||||
{
|
||||
"seq": 0,
|
||||
"checkpoint": {
|
||||
"timestamp": "2026-05-27T16:04:27.923072Z",
|
||||
"current_node": "toolchain",
|
||||
"completed_nodes": [
|
||||
"start",
|
||||
"toolchain"
|
||||
],
|
||||
"node_retries": {},
|
||||
"context_values": {
|
||||
"command.output": "blob://sha256/fc14b2ba2d770e5cd3169df7a29525c962adfc4cfa3097b9098c63ebd61a748c",
|
||||
"internal.retry_count.toolchain": 0,
|
||||
"failure_signature": "",
|
||||
"current_node": "toolchain",
|
||||
"internal.work_dir": "/home/daytona/workspace/fabro",
|
||||
"graph.model_stylesheet": "\n * { model: claude-opus-4-7; }\n ",
|
||||
"internal.retry_count.start": 0,
|
||||
"failure_class": "",
|
||||
"internal.fidelity": "compact",
|
||||
"internal.thread_id": "start",
|
||||
"outcome": "succeeded",
|
||||
"graph.rankdir": "LR",
|
||||
"internal.run_id": "01KSN2VNQ496GSM5N0RSZFDNHN",
|
||||
"thread.start.current_node": "toolchain",
|
||||
"internal.node_visit_count": 1,
|
||||
"graph.goal": "# Define automation API contract and clients\n\n- Number: #396\n- State: OPEN\n- Author: brynary (Bryan Helmkamp)\n- Created: 2026-05-25T15:06:24Z\n- Updated: 2026-05-25T15:06:24Z\n- URL: https://github.com/fabro-sh/fabro/issues/396\n\n## Body\n\n## Goal\n\nDefine the public Automations API contract, reuse compatible Rust domain types, and regenerate generated API clients.\n\n## Scope\n\nUpdate the OpenAPI spec under `/api/v1` with these paths:\n\n```http\nGET /automations\nPOST /automations\nGET /automations/{id}\nPUT /automations/{id}\nDELETE /automations/{id}\nGET /automations/{id}/runs\nPOST /automations/{id}/runs\n```\n\nAdd schemas for:\n\n- `Automation`\n- `AutomationTarget`\n- `AutomationTrigger`\n- `AutomationApiTrigger`\n- `AutomationScheduleTrigger`\n- `CreateAutomationRequest`\n- `ReplaceAutomationRequest`\n- `AutomationListResponse`\n\nUse this response shape for automations:\n\n```ts\ntype Automation = {\n id: string;\n revision: string;\n name: string;\n description: string | null;\n enabled: boolean;\n target: AutomationTarget;\n triggers: AutomationTrigger[];\n};\n\ntype AutomationTarget = {\n repository: string;\n ref: string;\n workflow: string;\n};\n\ntype AutomationTrigger =\n | { id: string; type: \"api\"; enabled: boolean }\n | { id: string; type: \"schedule\"; enabled: boolean; expression: string };\n```\n\nRequest shapes:\n\n```ts\ntype CreateAutomationRequest = {\n id: string;\n name: string;\n description?: string | null;\n enabled?: boolean;\n target: AutomationTarget;\n triggers: AutomationTrigger[];\n};\n\ntype ReplaceAutomationRequest = {\n name: string;\n description?: string | null;\n enabled: boolean;\n target: AutomationTarget;\n triggers: AutomationTrigger[];\n};\n```\n\nContract details:\n\n- Use an OpenAPI discriminator with `propertyName: type` for trigger variants.\n- Unknown trigger discriminator values should be reported by handlers as domain validation errors with HTTP 422, not malformed JSON errors with HTTP 400.\n- Reuse existing `Run` and paginated run-list envelope schemas for automation run endpoints.\n- Add `If-Match` header parameters for replace and delete operations.\n- Add `ETag` response headers on automation read and replace responses.\n- Response codes should cover 200, 201, 204, 400, 404, 409, 422, and 428 where applicable.\n- Before generating duplicate Rust types, search for matching `fabro-automation` domain types and add `with_replacement(...)` mappings where the serde wire shape is identical.\n- Add JSON parity tests for every reused automation type.\n\n## Files\n\nModify:\n\n- `docs/public/api-reference/fabro-api.yaml`\n- `lib/crates/fabro-api/Cargo.toml`\n- `lib/crates/fabro-api/build.rs`\n- Generated Rust API files under `lib/crates/fabro-api/src`, as produced by build/codegen\n- Generated TypeScript client files under `lib/packages/fabro-api-client`\n\nCreate:\n\n- `lib/crates/fabro-api/tests/automation_round_trip.rs`\n\n## Acceptance Criteria\n\n- The OpenAPI document exposes the full backend Automations API contract.\n- Rust generated API types compile.\n- Compatible automation domain types are reused instead of duplicated.\n- Reused type JSON parity is covered by tests.\n- The TypeScript API client contains generated automation operations and types.\n- No web UI consumer imports are added.\n\n## Verification\n\nRun:\n\n```bash\ncargo build -p fabro-api\ncargo nextest run -p fabro-api\ncd lib/packages/fabro-api-client && bun run generate\ngit diff -- apps/fabro-web lib/crates/fabro-cli\n```\n\nExpected: generated API files may change; application UI and CLI command modules should not change.\n\n\n## Comments\n\nNo comments.\n"
|
||||
},
|
||||
"node_outcomes": {
|
||||
"start": {
|
||||
"status": "succeeded",
|
||||
"usage": null
|
||||
},
|
||||
"toolchain": {
|
||||
"status": "succeeded",
|
||||
"context_updates": {
|
||||
"command.output": "blob://sha256/fc14b2ba2d770e5cd3169df7a29525c962adfc4cfa3097b9098c63ebd61a748c"
|
||||
},
|
||||
"notes": "Script completed: command -v cargo >/dev/null || { curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && sudo ln -sf $HOME/.cargo/bin/* /usr/local/bin/; }; cargo --version 2>&1",
|
||||
"usage": null,
|
||||
"timing": {
|
||||
"wall_time_ms": 0,
|
||||
"inference_time_ms": 0,
|
||||
"tool_time_ms": 1389,
|
||||
"active_time_ms": 1389
|
||||
}
|
||||
}
|
||||
},
|
||||
"next_node_id": "preflight_compile",
|
||||
"node_visits": {
|
||||
"toolchain": 1,
|
||||
"start": 1
|
||||
}
|
||||
},
|
||||
"diff": {}
|
||||
}
|
||||
],
|
||||
"conclusion": null,
|
||||
"sandbox": {
|
||||
"provider": "daytona",
|
||||
|
|
@ -523,5 +621,67 @@
|
|||
"pull_request": null,
|
||||
"superseded_by": null,
|
||||
"pending_interviews": {},
|
||||
"stages": {}
|
||||
"stages": {
|
||||
"start@1": {
|
||||
"first_event_seq": 18,
|
||||
"prompt": null,
|
||||
"response": null,
|
||||
"completion": {
|
||||
"outcome": "succeeded",
|
||||
"notes": null,
|
||||
"failure_reason": null,
|
||||
"timestamp": "2026-05-27T16:04:26.524919Z"
|
||||
},
|
||||
"provider_used": null,
|
||||
"diff": null,
|
||||
"script_invocation": null,
|
||||
"script_timing": null,
|
||||
"parallel_results": null,
|
||||
"output": null,
|
||||
"started_at": "2026-05-27T16:04:26.524332Z",
|
||||
"handler": "start",
|
||||
"timing": {
|
||||
"wall_time_ms": 0,
|
||||
"inference_time_ms": 0,
|
||||
"tool_time_ms": 0,
|
||||
"active_time_ms": 0
|
||||
},
|
||||
"usage": {
|
||||
"input_tokens": 0,
|
||||
"output_tokens": 0,
|
||||
"total_tokens": 0,
|
||||
"reasoning_tokens": 0,
|
||||
"cache_read_tokens": 0,
|
||||
"cache_write_tokens": 0
|
||||
},
|
||||
"state": "succeeded"
|
||||
},
|
||||
"toolchain@1": {
|
||||
"first_event_seq": 22,
|
||||
"prompt": null,
|
||||
"response": null,
|
||||
"completion": null,
|
||||
"provider_used": null,
|
||||
"diff": null,
|
||||
"script_invocation": {
|
||||
"script": "command -v cargo >/dev/null || { curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && sudo ln -sf $HOME/.cargo/bin/* /usr/local/bin/; }; cargo --version 2>&1",
|
||||
"command": "exec 2>&1\ncommand -v cargo >/dev/null || { curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && sudo ln -sf $HOME/.cargo/bin/* /usr/local/bin/; }; cargo --version 2>&1",
|
||||
"language": "shell"
|
||||
},
|
||||
"script_timing": null,
|
||||
"parallel_results": null,
|
||||
"output": null,
|
||||
"started_at": "2026-05-27T16:04:26.525169Z",
|
||||
"handler": "command",
|
||||
"usage": {
|
||||
"input_tokens": 0,
|
||||
"output_tokens": 0,
|
||||
"total_tokens": 0,
|
||||
"reasoning_tokens": 0,
|
||||
"cache_read_tokens": 0,
|
||||
"cache_write_tokens": 0
|
||||
},
|
||||
"state": "running"
|
||||
}
|
||||
}
|
||||
}
|
||||
6
stages/001-start@1/status.json
Normal file
6
stages/001-start@1/status.json
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"outcome": "succeeded",
|
||||
"notes": null,
|
||||
"failure_reason": null,
|
||||
"timestamp": "2026-05-27T16:04:26.524919Z"
|
||||
}
|
||||
5
stages/002-toolchain@1/script_invocation.json
Normal file
5
stages/002-toolchain@1/script_invocation.json
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
{
|
||||
"script": "command -v cargo >/dev/null || { curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && sudo ln -sf $HOME/.cargo/bin/* /usr/local/bin/; }; cargo --version 2>&1",
|
||||
"command": "exec 2>&1\ncommand -v cargo >/dev/null || { curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y && sudo ln -sf $HOME/.cargo/bin/* /usr/local/bin/; }; cargo --version 2>&1",
|
||||
"language": "shell"
|
||||
}
|
||||
Loading…
Add table
Reference in a new issue