| Age | Commit message (Collapse) | Author |
|
Adds GET /api/version endpoint and uses the first 6 hex chars of the
commit hash to derive an HSL hue for the header h1 logo color.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
|
|
- GET /api/stats?window=7d: pre-aggregated SQL queries for errors, throughput, billing
- Errors section: category summary (quota/rate_limit/timeout/git/failed) + failure table
- Throughput section: stacked hourly bar chart (completed/failed/other) over 7d
- Billing section: KPIs (7d total, avg/day, cost/run) + daily cost bar chart
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
detection
- Detect Gemini TerminalQuotaError (daily quota) as BUDGET_EXCEEDED, not generic FAILED
- Surface container stderr tail in error so quota/rate-limit classifiers can match it
- Add agent_events table to persist rate-limit start/recovery events across restarts
- Add GET /api/agents/status endpoint returning live agent state + 24h event history
- Stats dashboard: agent status cards, 24h availability timeline, per-run execution table
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
- Fix host/container path confusion for --env-file
- Fix --resume flag to only be used during resumptions
- Fix instruction passing to Claude CLI via shell-wrapped cat
- Restore streamErr return logic to detect task-level failures
- Improve success flag logic for workspace preservation
- Remove duplicate RepositoryURL from AgentConfig
- Fix app.js indentation and reformat DOMContentLoaded block
- Restore behavioral test coverage in container_test.go
|
|
- Fix Critical Bug 1: Only remove workspace on success, preserve on failure/BLOCKED.
- Fix Critical Bug 2: Use correct Claude flag (--resume) and pass instructions via file.
- Fix Critical Bug 3: Actually mount and use the instructions file in the container.
- Address Design Issue 4: Implement Resume/BLOCKED detection and host-side workspace re-use.
- Address Design Issue 5: Consolidate RepositoryURL to Task level and fix API fallback.
- Address Design Issue 6: Make agent images configurable per runner type via CLI flags.
- Address Design Issue 7: Secure API keys via .claudomator-env file and --env-file flag.
- Address Code Quality 8: Add unit tests for ContainerRunner arg construction.
- Address Code Quality 9: Fix indentation regression in app.js.
- Address Code Quality 10: Clean up orphaned Claude/Gemini runner files and move helpers.
- Fix tests: Update server_test.go and executor_test.go to work with new model.
|
|
This commit implements the architectural shift from local directory-based
sandboxing to containerized execution using canonical repository URLs.
Key changes:
- Data Model: Added RepositoryURL and ContainerImage to task/agent configs.
- Storage: Updated SQLite schema and queries to handle new fields.
- Executor: Implemented ContainerRunner using Docker/Podman for isolation.
- API/UI: Overhauled task creation to use Repository URLs and Image selection.
- Webhook: Updated GitHub webhook to derive Repository URLs automatically.
- Docs: Updated ADR-005 with risk feedback and added ADR-006 to document the
new containerized model.
- Defaults: Updated serve command to use ContainerRunner for all agents.
This fixes systemic task failures caused by build dependency and permission
issues on the host system.
|
|
When the VAPID key changes (e.g. after the key-swap fix), the browser's
cached PushSubscription was created with the old key. Calling
PushManager.subscribe() with a different applicationServerKey then throws
"The provided applicationServerKey is not valid".
Fix by calling getSubscription()/unsubscribe() before subscribe() so any
stale subscription is cleared. Adds web test covering both the stale and
fresh subscription paths.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
On tab click, store the tab name under 'activeMainTab' in localStorage.
On DOMContentLoaded, restore the previously active tab instead of
always defaulting to 'queue'.
Exported getActiveMainTab/setActiveMainTab for testability, following
the same pattern as getTaskFilterTab/setTaskFilterTab.
Tests: web/test/tab-persistence.test.mjs (6 tests, all green).
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
|
|
navigator.serviceWorker.register() returns before the SW is active.
Use navigator.serviceWorker.ready which resolves only once a SW is
controlling the page, so pushManager.subscribe() always has an active SW.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
The app is served at /claudomator/ so the SW and scope must use
BASE_PATH + '/api/push/sw.js' and BASE_PATH + '/' respectively.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
- Deployment badge now returns null (hidden) when includes_fix is false instead of showing "Not deployed" noise
- Badge also suppressed when fix_commits is empty (no tracked commits to check)
- Notification button label trimmed to just the bell emoji
- Preamble: warn agents not to use absolute paths in git commands (sandbox bypass)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Show task.project as a badge in task card meta row and as a field
in the task detail overview grid. Both display conditionally only
when project is non-empty.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Apache fronts the Go service and only proxies /api/ paths; /sw.js hits
Apache's filesystem and 404s. Serve the service worker from
/api/push/sw.js with Service-Worker-Allowed: / so the browser allows
it to control the full origin scope. Update SW registration URL.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Web Push:
- WebPushNotifier with VAPID auth; urgency mapped to event type
(BLOCKED=urgent, FAILED=high, COMPLETED=low)
- Auto-generates VAPID keys on first serve, persists to config file
- push_subscriptions table in SQLite (upsert by endpoint)
- GET /api/push/vapid-key, POST/DELETE /api/push/subscribe endpoints
- Service worker (sw.js) handles push events and notification clicks
- Notification bell button in web UI; subscribes on click
File Drop:
- GET /api/drops, GET /api/drops/{filename}, POST /api/drops
- Persistent ~/.claudomator/drops/ directory
- CLAUDOMATOR_DROP_DIR env var passed to agent subprocesses
- Drops tab (📁) in web UI with file listing and download links
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Add deployment_status field to task list/get API responses for READY
tasks. The field includes deployed_commit, fix_commits, and includes_fix
so the UI can show whether the deployed server includes each fix.
- internal/api/task_view.go: taskView struct + enrichTask() helper
- handleListTasks/handleGetTask: return enriched taskView responses
- web/app.js: export renderDeploymentBadge(); add badge to READY cards
- web/test/deployment-badge.test.mjs: 8 tests for renderDeploymentBadge
- web/style.css: .deployment-badge--deployed / --pending styles
- server_test.go: 3 new tests (red→green) for enriched task responses
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
- next-task script: exclude rejected tasks from fallback selection; only
pick PENDING tasks with no rejection comment and no prior executions,
or QUEUED tasks (e.g. BUDGET_EXCEEDED retries)
- web/app.js: prompt for optional rejection comment when rejecting a task,
passing it through to the API instead of always sending an empty string
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
- Add ElaborationInput field to Task struct (task.go)
- Add DB migration and update CREATE/SELECT/scan in storage/db.go
- Update handleCreateTask to accept elaboration_input from API
- Update renderSubtaskRollup in app.js to prefer elaboration_input over description
- Capture elaborate prompt in createTask() form submission
- Update subtask-placeholder tests to cover elaboration_input priority
- Fix missing io import in gemini.go
When a task card is waiting for subtasks, it now shows:
1. The raw user prompt from elaboration (if stored)
2. The task description truncated at word boundary (~120 chars)
3. The task name as fallback
4. 'Waiting for subtasks…' only when all fields are empty
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
When a BLOCKED/READY task has no subtasks yet, show the task description
(truncated to ~120 chars at a word boundary) instead of the generic
'Waiting for subtasks…' text. Falls back to task.name if no description,
and finally to the original generic text if neither is present.
- Add truncateToWordBoundary(text, maxLen=120) helper
- Update renderSubtaskRollup(task, footer) to use task object instead of taskId
- Update both READY and BLOCKED call sites
- Add web/test/subtask-placeholder.test.mjs with 11 tests
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
- poll() now calls renderActiveTab(cache) on early-return so switching
tabs always renders immediately instead of leaving the panel blank
- renderRunningView unchanged check now requires running.length > 0,
fixing the empty-state message never appearing when no tasks run
- Extract renderActiveTab() to avoid duplicating the tab switch logic
- Throttle execution history fetch to once per 60s (was every poll)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
updates
|
|
READY tasks now call renderSubtaskRollup identical to BLOCKED tasks
(without a question). The rollup appears above Accept/Reject buttons.
New test: web/test/ready-subtasks.test.mjs (10 assertions, all pass).
|
|
- Fix ephemeral sandbox deletion issue by passing $CLAUDOMATOR_PROJECT_DIR to agents and using it for subtask project_dir.
- Implement sandbox autocommit in teardown to prevent task failures from uncommitted work.
- Track git commits created during executions and persist them in the DB.
- Display git commits and changestats badges in the Web UI execution history.
- Add badge counts to Web UI tabs for Interrupted, Ready, and Running states.
- Improve scripts/next-task to handle QUEUED tasks and configurable DB path.
|
|
- Add UpdateTaskAgent to Store interface and DB implementation
- Call UpdateTaskAgent in Pool.execute to persist assigned agent/model
to database before the runner starts
- Update runTask in app.js to pass selected agent as query param
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
When a task is BLOCKED due to spawned subtasks (no question), the card
footer now fetches and renders a list of subtask names with their state
emoji instead of showing the question/answer input UI. The Cancel button
remains in both cases.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Two fixes for BLOCKED task issues:
1. Allow BLOCKED → CANCELLED state transition so users can cancel tasks
stuck waiting for input. Adds Cancel button to BLOCKED task cards in
the UI alongside the question/answer controls.
2. Detect when agents write completion reports to $CLAUDOMATOR_QUESTION_FILE
instead of real questions. If the question JSON has no options and no "?"
in the text, treat it as a summary (stored on the execution) and fall
through to normal completion + sandbox teardown rather than blocking.
Also tightened the preamble to make the distinction explicit.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
All, Stats, Settings)
- Replace Tasks/Active tabs with Queue (QUEUED+PENDING), Interrupted, Ready top-level tabs
- Add All tab (COMPLETED, TIMED_OUT, BUDGET_EXCEEDED within last 24h) and Settings placeholder
- Export filterQueueTasks, filterReadyTasks, filterAllDoneTasks from app.js
- Refactor poll() to dispatch to active tab's render function instead of always rendering all panels
- Add renderQueuePanel, renderInterruptedPanel, renderReadyPanel, renderAllPanel helpers
- Add tests in web/test/tab-filters.test.mjs covering all new filter functions (16 tests)
- All 165 JS tests and all Go tests pass
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
GeminiRunner.buildArgs was missing --yolo (auto-approve all tools)
so the gemini CLI only registered 3 tools (read_file, write_todos,
cli_help) and write_file was not available. Agents that needed to
create files silently failed (exit 0, no files written).
Also switch instructions from bare positional arg to -p flag, which
is required for non-interactive headless mode.
Update preamble tests to match file-based summary approach
(CLAUDOMATOR_SUMMARY_FILE) kept from the merge conflict resolution.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Keep file-based summary approach (CLAUDOMATOR_SUMMARY_FILE) from HEAD.
Combine Q&A History and Stats tab CSS from both branches.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Interrupted tasks (CANCELLED, FAILED, BUDGET_EXCEEDED) now support session
resume in addition to restart. Both buttons are shown on the task card.
- executor: extend resumablePoolStates to include CANCELLED, FAILED, BUDGET_EXCEEDED
- api: extend handleResumeTimedOutTask to accept all resumable states with
state-specific resume messages; replace hard-coded TIMED_OUT check with a
resumableStates map
- web: add RESUME_STATES set; render Resume + Restart buttons for interrupted
states; TIMED_OUT keeps Resume only
- tests: 5 new Go tests (TestResumeInterrupted_*); updated task-actions.test.mjs
with 17 tests covering dual-button behaviour
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
- Export computeTaskStats and computeExecutionStats from app.js
- Add renderStatsPanel with state count grid, KPI row (total/success-rate/cost/avg-duration), and outcome bar chart
- Wire stats tab into switchTab and poll for live refresh
- Add Stats tab button and panel to index.html
- Add CSS for .stats-counts, .stats-kpis, .stats-bar-chart using existing state color variables
- Add docs/stats-tab-plan.md with component structure and data flow
- 14 new unit tests in web/test/stats.test.mjs (140 total, all passing)
No backend changes — derives all metrics from existing /api/tasks and /api/executions endpoints.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
|
|
Each running task card now shows a meta row with the assigned agent
type (e.g. "claude" or "gemini") and the short execution ID, which is
filled in asynchronously once the execution record is fetched.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Prevents periodic poll from clearing the task panel, open modals,
or inline edit forms while the user is interacting with them.
- isUserEditing() now also detects any open <dialog> or task-panel
- poll() checks isUserEditing() before calling destructive renders
|
|
Removed all template-related code from frontend (tabs, modals, logic) and backend (routes, files, DB table). Updated BUDGET_EXCEEDED tasks to be requeueable with a Restart button. Fixed ReferenceError in isUserEditing for Node.js tests.
|
|
Updated sortTasksByDate to support descending sort. Changed renderTaskList to use descending sort for Done and Interrupted tabs. Updated filterTasksByTab to hide Done tasks older than 24 hours by default. Updated frontend tests to match new behavior.
|
|
Permitted BUDGET_EXCEEDED -> QUEUED transition in ValidTransition. Updated frontend to show 'Restart' button for BUDGET_EXCEEDED tasks, allowing them to be requeued after failure.
|
|
Moved BUDGET_EXCEEDED and BLOCKED states from DONE and ACTIVE sets to the INTERRUPTED set in the frontend, ensuring they appear in the correct tab.
|
|
As the system now automatically classifies and assigns the best agent and model per task, manual selection is no longer required and has been removed from New Task, Edit Task, and Template forms.
|
|
- Remove unresolved merge markers in app.js.
- Set 'tasks' as the default active tab and panel on boot.
- Synchronize initial HTML state with JS tab switching logic.
- Fix broken Draft with AI button handler from bad merge.
|
|
- Resolve conflicts in API server, CLI, and executor.
- Maintain Gemini classification and assignment logic.
- Update UI to use generic agent config and project_dir.
- Fix ProjectDir/WorkingDir inconsistencies in Gemini runner.
- All tests passing after merge.
|
|
- ClaudeConfig.WorkingDir → ProjectDir (json: project_dir)
- UnmarshalJSON fallback reads legacy working_dir from DB records
- New executions with project_dir clone into a temp sandbox via git clone --local
- Non-git project_dirs get git init + initial commit before clone
- After success: verify clean working tree, merge --ff-only back to project_dir, remove sandbox
- On failure/BLOCKED: sandbox preserved, path included in error message
- Resume executions run directly in project_dir (no re-clone)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
- Running tab in nav with live SSE log streams per running task
- Execution history table (last 24h) with duration, cost, exit code, view logs
- Poll loop refreshes running view when tab is active
- Smart diff: only full re-render when task set changes; elapsed updated in place
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
|
|
The elaborate call now sends working_dir from the Project dropdown.
The backend uses it (falling back to server workDir) when building
the system prompt, so AI-drafted tasks are contextualised to the
selected project.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
/workspace/claudomator
- Moved working directory to first field, renamed to "Project"
- Replaced text input with a select populated from GET /api/workspaces
(lists subdirs of /workspace dynamically)
- "Create new project…" option reveals a custom path input
- elaborate result handler sets select or falls back to new-project input
- Added GET /api/workspaces endpoint in server.go
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
|
Recovered files with no Claude→Agent contamination:
- docs/adr/002-task-state-machine.md
- internal/api/logs.go/logs_test.go: task-level log streaming endpoint
- internal/api/validate.go/validate_test.go: POST /api/tasks/validate
- internal/api/server_test.go, storage/db_test.go: expanded test coverage
- scripts/reset-failed-tasks, reset-running-tasks
- web/app.js, index.html, style.css: frontend improvements
- web/test/: active-tasks-tab, delete-button, filter-tabs, sort-tasks tests
Manually applied from server.go diff (skipping Claude→Agent rename):
- taskLogStore field + validateCmdPath field
- DELETE /api/tasks/{id} route + handleDeleteTask
- GET /api/tasks/{id}/logs/stream route
- POST /api/tasks/{id}/resume route + handleResumeTimedOutTask
- handleCancelTask: allow cancelling PENDING/QUEUED tasks directly
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|