Skip to content

simiancraft/simiancraft-skills / skills/burn-down-github-issues

burn-down-github-issues

Unverified

Run an unattended burndown of a GitHub issue backlog as cards on a per-operator GitHub Projects board whose lanes are an explicit state machine: appraise and size the inbox, carve what is over the ceiling, fix the ready ones in parallel git worktrees, prove each fix on a draft pull request, have an isolated second-engine reviewer judge it, land one branch at a time with freshness checks, and dead-letter per phase whatever a machine cannot finish. Use when the task is "work the backlog unattended", "triage and fix recent issues", "run the issue loop", "burn down issues", or "where is issue N on the board". Requires a per-repository burn-down-github-issues.config.ts at the target repo's root (the loop refuses to start without it), the prove-work-on-github skill, the codex and claude CLIs for the default seats, and a gh token with the project scope for the board. Skip for one-off fixes to a known issue you are already working interactively, and for backlogs whose issues are mostly product decisions rather than code.

FileKindSize
SKILL.mdskill md17.0 KB
board.tsscript6.5 KB
callbacks/README.mdmarkdown1.1 KB
callbacks/on-size-over-ceilingother843 B
card.tsscript4.3 KB
chart-machine.tsscript3.9 KB
claim-race.tsscript6.1 KB
export-machine.tsscript1.8 KB
lanes.tsscript5.2 KB
lib/admission.test.tsscript7.6 KB
lib/admission.tsscript5.5 KB
lib/board-writer.test.tsscript3.6 KB
lib/board-writer.tsscript11.8 KB
lib/carving-revisit.test.tsscript7.5 KB
lib/carving.tsscript26.9 KB
lib/floor/config.test.tsscript456 B
lib/floor/config.tsscript8.1 KB
lib/floor/floor.test.tsscript9.9 KB
lib/floor/floor.tsscript28.7 KB
lib/floor/incident.tsscript11.2 KB
lib/floor/ledger.tsscript5.6 KB
lib/floor/probe.tsscript3.6 KB
lib/lanes.tsscript4.4 KB
lib/machine.test.tsscript11.2 KB
lib/machine.tsscript52.4 KB
lib/place-callbacks.test.tsscript2.5 KB
lib/place-callbacks.tsscript3.0 KB
lib/preflight.test.tsscript4.5 KB
lib/preflight.tsscript1.2 KB
lib/pressure.test.tsscript56.9 KB
lib/refs.test.tsscript1010 B
lib/refs.tsscript1.9 KB
lib/run-scope.test.tsscript5.4 KB
lib/run-scope.tsscript1.2 KB
lib/scenarios.test.tsscript17.1 KB
lib/simulate.test.tsscript7.3 KB
lib/simulate.tsscript7.0 KB
lib/world-sweep.test.tsscript21.4 KB
loop.source.test.tsscript4.8 KB
loop.tsscript66.2 KB
prompts/diagnose.mdmarkdown2.1 KB
prompts/walk.mdmarkdown3.6 KB
references/adopting.mdmarkdown26.3 KB
references/architecture.mdmarkdown20.7 KB
references/floor.mdmarkdown14.6 KB
references/operating.mdmarkdown19.6 KB
references/state-machine.mdmarkdown31.1 KB
status.tsscript4.9 KB
watch.tsscript6.4 KB

loop.source.test.ts

View on GitHub
import { describe, expect, it } from 'bun:test';
import { readFileSync } from 'node:fs';
import { join } from 'node:path';

const source = readFileSync(join(import.meta.dir, 'loop.ts'), 'utf8');

describe('--only bounds every pass that can land work', () => {
  it('refreshes descendant membership before every backlog consumer reads the shared set', () => {
    expect(source).toContain('const ONLY = SCOPE.effective;');
    expect(source).toMatch(/function allIssues\(\): Issue\[\] \{\s*const all = allOpenIssues\(ctx\);\s*SCOPE.refresh\(all\);\s*return all;/);
    expect(source.match(/allOpenIssues\(ctx\)/g)).toHaveLength(1);
    expect(source).toContain('only: ONLY,');
    expect(source).toContain('ONLY ? ONLY.has(issue.number)');
    expect(source).toContain('{ allAges: ONLY !== null }');
    expect(source).toContain('await CARVING.sweep(allIssues())');
    expect(source).toContain('await placeBacklog(allIssues())');
  });

  it('restricts startup resumption to the --only issues', () => {
    const call = source.split('\n').find((line) => line.includes('findStranded(ctx,'));
    expect(call).toBeDefined();
    expect(call).toContain('ONLY.has(issue.number)');
  });
});

describe('an unreadable thread at startup', () => {
  it('costs one issue its pass in the loop, never the run', () => {
    expect(source).not.toContain('readTree(ctx, issue.number, io)');
    expect(source).toContain('function threadOf(');
  });
});

describe('resume dispatch owns automatic redrive', () => {
  it('calls redriveIssue only inside resumePull, which the pool uses', () => {
    const start = source.indexOf('async function resumePull(');
    expect(start).toBeGreaterThan(-1);
    const end = source.indexOf('\n}', start) + 2;
    expect(source.slice(start, end)).toContain('redriveIssue(');
    expect(source.slice(0, start) + source.slice(end)).not.toContain('redriveIssue(');
    expect(source).toMatch(/await pool\(\s*resumable,\s*CONFIG.concurrency,\s*resumePull,/);
  });
});

describe('drivers drain the board before moving on or exiting', () => {
  const fix = readFileSync(join(import.meta.dir, '../fix-github-issue/fix.ts'), 'utf8');
  const carve = readFileSync(join(import.meta.dir, '../carve-github-issue/carve.ts'), 'utf8');
  const writer = readFileSync(join(import.meta.dir, 'lib/board-writer.ts'), 'utf8');

  it('uses the bounded wait in every stop handler', () => {
    expect(writer).toContain('timeoutMs = 10_000');
    expect(source).toMatch(/installStopHandler\(log, async \(\) => \{\s*FLOOR\?\.stop\(\);\s*await waitForBoard\(BOARD\);\s*releaseLock\(\);/);
    expect(fix).toContain('installStopHandler(log, () => waitForBoard(BOARD))');
    expect(carve).toContain('installStopHandler(log, () => waitForBoard(writer))');
    expect(carve.indexOf('let writer: BoardWriter | undefined')).toBeLessThan(carve.indexOf('installStopHandler(log'));
  });

  it('waits without a bound before normal lock release and exit', () => {
    const finish = source.slice(source.indexOf('const finish = async () =>'), source.indexOf('const stopPulse ='));
    expect(finish).toMatch(/await BOARD\?\.settled\(\);\s*releaseLock\(\);/);
    expect(source).toMatch(/process.exitCode = await walkTheFloorOnly\(FLOOR_MODE\);\s*await BOARD\?\.settled\(\);\s*releaseLock\(\);/);
    expect(carve).toMatch(/await writer\?\.settled\(\);\s*process.exit\(result.outcome/);
    expect(fix.trimEnd().endsWith('await BOARD?.settled();')).toBe(true);
  });
});

describe('the work phase takes on what the run made eligible', () => {
  it('works through a refilling pool whose refill is the mid-run admission', () => {
    expect(source).toMatch(/await refillingPool\(\s*first,\s*CONFIG\.concurrency,[\s\S]*?ADMISSION\.admit,/);
    expect(source).not.toMatch(/await pool\(\s*candidates,/);
  });

  it('records the start batch before any lane runs, and reads the same placement and selection', () => {
    const work = source.indexOf('await refillingPool(');
    expect(source.indexOf('ADMISSION.start(')).toBeGreaterThan(0);
    expect(source.indexOf('ADMISSION.start(')).toBeLessThan(work);
    expect(source).toContain('place: () => placeBacklog(allIssues()),');
    expect(source).toContain("select: (placement) => selectCandidates(placement as Placement, { quiet: true }),");
    expect(source).toContain("release = claimLock(ctx, 'appraise.lock');");
  });

  it('asks the refill before calling a run with nothing Ready idle, so children carved during startup sizing are worked', () => {
    const ask = source.indexOf('await ADMISSION.admit();');
    const idle = source.indexOf("log('nothing in Ready;");
    expect(ask).toBeGreaterThan(0);
    expect(ask).toBeLessThan(idle);
  });

  it('counts the start-of-run appraisals in the run budget', () => {
    expect(source).toContain('for (const n of await sizeTheWindow(placement)) ADMISSION.appraised.add(n);');
  });
});
reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis.Stars: 469kUpdated Claude CodeCodexVerifiedInstall
diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness.Stars: 321kUpdated Claude CodeCodexVerifiedInstall
dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependenciesStars: 321kUpdated Claude CodeCodexVerifiedInstall
executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is availableStars: 321kUpdated Claude CodeCodexVerifiedInstall