Louis Knight-Webb 354c6c05ac Safely parse logs (#82)
* Both executors have been successfully updated to handle log parsing failures gracefully. The changes ensure that:

1. **Invalid JSON lines** are captured as raw text entries instead of causing the entire parsing to fail
2. **Valid JSON with unexpected structure** is captured as unrecognized JSON entries with the raw content preserved
3. **Expected JSON formats** continue to be parsed normally

The key changes made:
- Wrapped JSON parsing in a `match` statement to handle parse errors
- Added logic to track whether JSON was successfully processed
- Added fallback entries for both invalid JSON and unrecognized valid JSON
- All raw/unrecognized content is stored as `SystemMessage` entries with descriptive prefixes

* fixes

* The changes are complete! I've modified the `normalize_logs` method in [`backend/src/executors/amp.rs`](file:///private/var/folders/kr/jdxkcn7129j376nrg0stj9zm0000gn/T/vk-7a88-improve-pa/backend/src/executors/amp.rs#L116-L227) to ignore the specific JSON types you mentioned:

- `{"type":"initial",...}`
- `{"type":"token-usage",...}`
- `{"type":"state",...}`

The parser now uses a match statement to handle different JSON types, setting `processed = true` for the ignored types, which prevents them from being added as "Unrecognized JSON" entries. The build passes successfully.

* Perfect! I have successfully implemented both requested improvements to the parsing of normalized logs for Claude:

## Summary of Changes

**1. Ignoring `{"type":"result",...}` JSON entries:**
- Modified both [`ClaudeExecutor::normalize_logs`](file:///private/var/folders/kr/jdxkcn7129j376nrg0stj9zm0000gn/T/vk-60e3-improve-pa/backend/src/executors/claude.rs#L221-L236) and [`AmpExecutor::normalize_logs`](file:///private/var/folders/kr/jdxkcn7129j376nrg0stj9zm0000gn/T/vk-60e3-improve-pa/backend/src/executors/amp.rs#L227-L242) to skip JSON entries with `type: "result"`
- These entries are now completely ignored and won't appear in the normalized logs

**2. Converting absolute paths to relative paths:**
- Added `make_path_relative` helper functions to both Claude and Amp executors
- Updated path extraction logic in `extract_action_type` methods to use relative paths for file operations
- Updated `generate_concise_content` methods to display relative paths for directory listings
- Paths are now shown relative to the project root, making them more concise

**3. Added comprehensive tests:**
- Created tests to verify that `{"type":"result",...}` entries are properly ignored
- Created tests to verify that absolute paths are converted to relative paths
- All tests pass successfully

The changes maintain backward compatibility while improving the conciseness and readability of the normalized logs.

* Resolve paths in claude

* fmt

* Clippy
2025-07-08 01:13:36 +01:00
2025-07-08 01:13:36 +01:00
2025-07-07 12:30:06 +01:00
2025-07-08 01:13:36 +01:00
2025-07-07 13:15:38 +00:00
2025-06-20 14:33:15 +01:00
2025-06-27 13:32:32 +01:00
2025-07-04 11:11:45 +02:00
2025-06-14 15:14:08 -04:00
2025-06-17 20:36:25 -04:00
2025-06-25 09:27:29 +01:00
2025-06-25 09:27:29 +01:00
2025-07-04 11:11:45 +02:00

Mission Control

Orchestration and visualisation over multiple coding agents.

Project Structure

repo/
├── backend/               # Rust backend (Axum API)
│   ├── Cargo.toml
│   └── src/
│       ├── main.rs
│       ├── routes/
│       └── models/
├── frontend/              # React + TypeScript app
│   ├── package.json
│   ├── vite.config.ts
│   ├── components.json    # shadcn/ui config
│   ├── tailwind.config.js
│   └── src/
│       ├── components/
│       │   └── ui/        # shadcn/ui components
│       ├── lib/
│       └── app/
├── shared/                # Shared types/schemas
│   └── types.ts
├── Cargo.toml             # Workspace configuration
├── pnpm-workspace.yaml    # pnpm workspace
└── package.json           # Root scripts

Getting Started

Prerequisites

Installation

  1. Install dependencies
# Install dependencies
npm install

Development

# Run both frontend and backend in development mode
npm dev

Tech Stack

Backend

  • Rust with Axum web framework
  • Tokio async runtime
  • Tower middleware
  • Serde for JSON serialization

Frontend

  • React 18 with TypeScript
  • Vite for build tooling
  • Tailwind CSS for styling
  • shadcn/ui component library
  • Radix UI primitives

Adding shadcn/ui Components

cd frontend
npx shadcn-ui@latest add button
npx shadcn-ui@latest add card
# etc.
Description
Get 10X more out of Claude Code, Codex or any coding agent
https://www.vibekanban.com/
Readme Apache-2.0 48 MiB
Languages
Rust 51.1%
TypeScript 46.6%
CSS 1.1%
JavaScript 0.7%
PLpgSQL 0.2%
Other 0.2%