Headless simulation / CLI
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 48/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Quiet
- Tech stack
- node.js, typescript
Research direction
Start with server/src/api/mcp.ts to understand runMatchToDecision and buildMatchSummary, then read server/src/api/arena.ts and server/src/api/token.ts for the existing arena endpoints and bearer token flow. The issue describes either a Node CLI using those REST endpoints or a CLI calling MCP tools; compare both paths and existing tests in server/test/mcp.test.ts and server/test/api.test.ts. Done means bot matches can be run headlessly with a reproducible seed and pass/fail plus leaderboard output.
Written by the indexing model from the issue text.
Description
A command (or thin client over the existing /arenas API) to run a match between bots without the UI — enables scripting, local iteration, and CI for your bot. The multi-arena API was built for exactly this kind of tooling.
Effort: M
Migrated from ENHANCEMENTS.md (§4 Developer experience).
Implementation notes
Priority: medium — Valuable for bot-author workflow/CI iteration, but the core capability (run_match/run_tournament) already ships via MCP; this is packaging, not core-path stability or security.
Purpose
Bot authors want to iterate and run CI checks without opening the UI: a scriptable way to run a match to a decision and get pass/fail + leaderboard output. This is mostly a packaging problem — runMatchToDecision and buildMatchSummary already implement the exact semantics needed; the gap is a client that doesn't require an MCP-capable agent.
Implementation approach
- Reuse
server/src/api/mcp.ts'srunMatchToDecision(seed → restart → resume → pollbuildMatchSummary→ pause → restore speed) as the reference algorithm; either extract it to a sharedutil/matchRunner.tsused by both the MCP tools (run_match,run_tournament) and a new CLI, or have the CLI call it indirectly. - Two viable shapes, both "thin client over
/arenas": (a) a Nodebin/script inserver/using an API token (server/src/api/token.ts) to call the existing REST endpoints —POST .../arenas/:arenaId/seed,/restart,/resume,GET .../arenas/:arenaId/summary(server/src/api/arena.ts,util/matchSummary.ts) — polling likerunMatchToDecisiondoes; or (b) a CLI that speaks MCP directly toPOST /api/mcpand invokesrun_match/run_tournament(auth already bearer-token based, per CLAUDE.md's MCP section). - No compiler.ts or bot-facing sandbox API changes — this only orchestrates existing arena control endpoints.
- No UI changes required; SSE/reducer (
arenaReducer.ts) untouched since this is a headless poll loop, not a stream consumer.
Key details to plan
- No DB schema changes (
services/*Service.tsuntouched); note the no-migrations caveat from #142 doesn't apply here. - Auth: needs a bearer API token flow (
api/token.ts) rather than the browser cookie session — document token creation as a prerequisite. - Determinism: expose
seed(mirrorsset_arena_seed/setSeed) so CI runs are reproducible, consistent withutil/random.ts's mulberry32 PRNG. - Testing: extend
server/test/mcp.test.tsandserver/test/api.test.tspatterns (both already exercise restart/resume/seed/summary flows) rather than inventing new fixtures; if extractingrunMatchToDecision, add unit coverage alongsidesimulation.test.ts's mock-tank style. - Depends on nothing blocking; complements #122's sibling MCP tools already shipped (
run_match,run_tournament,match_status). Low technical risk — mostly plumbing/packaging (CLI entry point, token bootstrap, output formatting), effort M as labeled.
- Dominant language
- TypeScript
- Stars
- 0
- Forks
- 0
- Avg merge
- 11h 21m
- Merged PRs (30d)
- 21
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from LeeAdcock/robocodeJs.com
-
enhancement priority: medium
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
LeeAdcock/robocodeJs.com#254 ·
Maintainers usually reply within 1 day
-
good first issue priority: low tech-debt
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
LeeAdcock/robocodeJs.com#146 ·
Maintainers usually reply within 1 day
-
PR #319's 4xx health-rule change never took effect — env-level ConfigDocument shadows .ebextensionsOpenbug priority: medium tech-debt
Difficulty 4/5 Half a day Newbie friendliness 12/100
LeeAdcock/robocodeJs.com#410 ·
Maintainers usually reply within 1 day
-
priority: high tech-debt
Difficulty 3/5 Half a day Newbie friendliness 25/100
LeeAdcock/robocodeJs.com#409 · 2 comments ·
Maintainers usually reply within 1 day
-
priority: high tech-debt
Difficulty 4/5 1-2 days Newbie friendliness 8/100
LeeAdcock/robocodeJs.com#407 ·
Maintainers usually reply within 1 day
All issues in LeeAdcock/robocodeJs.com
Similar issues
-
e2e-failure ready-to-code
Difficulty 1/5 Under an hour Newbie friendliness 82/100
redhat-developer/rhdh-plugin-export-overlays#4616 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
Maintainers usually reply within 1 day
-
ai-handle
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
nextlevelbuilder/dewee-web-v2#73 ·
Maintainers usually reply within 1 day
-
backend bug good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
PoCInnovation/Distribox#255 ·
Maintainers usually reply within 1 day