You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Add UV_DEFAULT_INDEX and UV_INDEX_URL env vars to CI for public PyPI
- Simplify agent rules section to be Claude Code-specific
- Add note that other agents like Amp may not need extra config
- Move "Why MCP" section to bottom of README
- Convert CLI vs MCP diagram to Mermaid flowchart
- Use @latest for all uvx commands
Or add to `.amp/settings.json` (workspace) or global settings. See [Amp Manual](https://ampcode.com/manual) for details.
@@ -137,7 +137,7 @@ Or add to `.amp/settings.json` (workspace) or global settings. See [Amp Manual](
137
137
Install via CLI (<ahref="https://docs.anthropic.com/en/docs/claude-code/mcp">guide</a>):
138
138
139
139
```bash
140
-
claude mcp add agent-task-queue -- uvx agent-task-queue
140
+
claude mcp add agent-task-queue -- uvx agent-task-queue@latest
141
141
```
142
142
143
143
</details>
@@ -177,7 +177,7 @@ Config file locations:
177
177
"agent-task-queue": {
178
178
"type": "stdio",
179
179
"command": "uvx",
180
-
"args": ["agent-task-queue"]
180
+
"args": ["agent-task-queue@latest"]
181
181
}
182
182
}
183
183
}
@@ -251,15 +251,11 @@ run_task(
251
251
)
252
252
```
253
253
254
-
### Important: Configure Agent Rules
254
+
### Note for Claude Code Users
255
255
256
-
**The MCP tool won't be used automatically.** AI agents default to their built-in shell/Bash tools. You must add explicit instructions telling the agent to use `run_task` instead.
256
+
Claude Code defaults to its built-in Bash tool for shell commands. To ensure it uses `run_task` instead, add instructions to your `CLAUDE.md` file.
257
257
258
-
Without these rules, the agent will bypass the queue entirely and run builds directly via Bash, defeating the purpose of this tool.
259
-
260
-
#### Claude Code
261
-
262
-
Add to `~/.claude/CLAUDE.md` (applies to all projects) or `.claude/CLAUDE.md` (project-specific):
258
+
Add to `~/.claude/CLAUDE.md` (global) or `.claude/CLAUDE.md` (project-specific):
263
259
264
260
```markdown
265
261
## Build Queue
@@ -281,57 +277,8 @@ For expensive build commands, ALWAYS use the `run_task` MCP tool instead of Bash
281
277
NEVER run these commands directly via Bash. Always use the run_task MCP tool to prevent resource contention.
282
278
```
283
279
284
-
#### Cursor
285
-
286
-
Add to `.cursorrules` in your project root:
287
-
288
-
```markdown
289
-
## Build Queue
290
-
291
-
For expensive build commands (gradle, bazel, docker, pytest, npm build), ALWAYS use the `run_task` MCP tool instead of running shell commands directly.
292
-
293
-
Parameters:
294
-
- command: The full shell command to run
295
-
- working_directory: Absolute path to the project root
296
-
- queue_name: Optional queue name for isolation (default: "global")
297
-
- env_vars: Optional environment variables in "KEY=value,KEY2=value2" format
298
-
299
-
This ensures builds are queued and don't compete for system resources.
300
-
```
301
-
302
-
#### Other Agents
303
-
304
-
Add similar instructions to your agent's configuration file (`.windsurfrules`, `AGENTS.md`, etc.) telling it to use `run_task` for build commands.
305
-
306
-
## Why MCP Instead of a CLI Tool?
307
-
308
-
The first attempt at solving this problem was a file-based queue CLI that wrapped commands:
309
-
310
-
```bash
311
-
queue-cli ./gradlew build
312
-
```
313
-
314
-
**The fatal flaw:** AI tools have built-in shell timeouts (30s-120s). If a job waited in queue longer than the timeout, the agent gave up—even though the job would eventually run.
| Agent compatibility | Varies by tool | Universal |
280
+
> [!NOTE]
281
+
> Other agents like Amp may automatically use MCP tools without additional configuration.
335
282
336
283
## Configuration
337
284
@@ -353,7 +300,7 @@ Pass options via the `args` property in your MCP config:
353
300
"agent-task-queue": {
354
301
"command": "uvx",
355
302
"args": [
356
-
"agent-task-queue",
303
+
"agent-task-queue@latest",
357
304
"--max-output-files=100",
358
305
"--lock-timeout=60"
359
306
]
@@ -362,7 +309,7 @@ Pass options via the `args` property in your MCP config:
362
309
}
363
310
```
364
311
365
-
Run `uvx agent-task-queue --help` to see all options.
312
+
Run `uvx agent-task-queue@latest --help` to see all options.
366
313
367
314
## Architecture
368
315
@@ -479,7 +426,7 @@ tail -f /tmp/agent-task-queue/agent-task-queue-logs.json # Follow live
479
426
### Server not connecting
480
427
481
428
1. Ensure `uvx` is in your PATH (install [uv](https://github.com/astral-sh/uv) if needed)
482
-
2. Test manually: `uvx agent-task-queue`
429
+
2. Test manually: `uvx agent-task-queue@latest`
483
430
484
431
## Development
485
432
@@ -498,6 +445,45 @@ uv run python task_queue.py # Run server locally
498
445
- macOS
499
446
- Linux
500
447
448
+
## Why MCP Instead of a CLI Tool?
449
+
450
+
The first attempt at solving this problem was a file-based queue CLI that wrapped commands:
451
+
452
+
```bash
453
+
queue-cli ./gradlew build
454
+
```
455
+
456
+
**The fatal flaw:** AI tools have built-in shell timeouts (30s-120s). If a job waited in queue longer than the timeout, the agent gave up—even though the job would eventually run.
457
+
458
+
```mermaid
459
+
flowchart LR
460
+
subgraph cli [CLI Approach]
461
+
A1[Agent] --> B1[Shell]
462
+
B1 --> C1[CLI]
463
+
C1 --> D1[Queue]
464
+
B1 -.-> |"⏱️ TIMEOUT!"| A1
465
+
end
466
+
467
+
subgraph mcp [MCP Approach]
468
+
A2[Agent] --> |MCP Protocol| B2[Server]
469
+
B2 --> C2[Queue]
470
+
B2 -.-> |"✓ blocks until complete"| A2
471
+
end
472
+
```
473
+
474
+
**Why MCP solves this:**
475
+
- The MCP server keeps the connection alive indefinitely
476
+
- The agent's tool call blocks until the task completes
477
+
- No timeout configuration needed—it "just works"
478
+
- The server manages the queue; the agent just waits
0 commit comments