Skip to content
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"plugins": [
{
"name": "genie",
"version": "3.260316.16",
"version": "3.260316.17",
"source": "./plugins/genie",
"description": "Human-AI partnership for Claude Code. Share a terminal, orchestrate workers, evolve together. Brainstorm ideas, wish them into plans, make with parallel agents, ship as one team. A coding genie that grows with your project."
}
Expand Down
2 changes: 1 addition & 1 deletion openclaw.plugin.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"id": "genie",
"name": "Genie",
"description": "Skills, agents, and hooks for the Genie CLI terminal orchestration toolkit",
"version": "3.260316.16",
"version": "3.260316.17",
"configSchema": {
"type": "object",
"additionalProperties": false,
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@automagik/genie",
"version": "3.260316.16",
"version": "3.260316.17",
"description": "Collaborative terminal toolkit for human + AI workflows",
"type": "module",
"bin": {
Expand Down
2 changes: 1 addition & 1 deletion plugins/genie/.claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "genie",
"version": "3.260316.16",
"version": "3.260316.17",
"description": "Human-AI partnership for Claude Code. Share a terminal, orchestrate workers, evolve together. Brainstorm ideas, turn them into wishes, execute with /work, validate with /review, and ship as one team.",
"author": {
"name": "Namastex Labs"
Expand Down
2 changes: 1 addition & 1 deletion plugins/genie/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "genie-plugin",
"version": "3.260316.16",
"version": "3.260316.17",
"private": true,
"description": "Runtime dependencies for genie bundled CLIs",
"type": "module",
Expand Down
8 changes: 4 additions & 4 deletions plugins/genie/scripts/smart-install.js
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,9 @@ function installBun() {
console.error('Installing Bun runtime...');
try {
if (IS_WINDOWS) {
execSync('powershell -c "irm bun.com/install.ps1 | iex"', { stdio: 'inherit', shell: true });
execSync('powershell -c "irm bun.com/install.ps1 | iex"', { stdio: ['pipe', 'pipe', 'inherit'], shell: true });
} else {
execSync('curl -fsSL https://bun.com/install | bash', { stdio: 'inherit', shell: true });
execSync('curl -fsSL https://bun.com/install | bash', { stdio: ['pipe', 'pipe', 'inherit'], shell: true });
Comment on lines +77 to +79

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

The change from stdio: 'inherit' to stdio: ['pipe', 'pipe', 'inherit'] for execSync will suppress the standard output of the installation commands. The output is piped but not captured or displayed, which will hide installation progress from the user. This can make it seem like the installation is hanging and complicates debugging.

For interactive installation scripts like this, showing the output is crucial for user experience. I recommend reverting this change to restore the previous behavior.

This feedback also applies to the other execSync calls modified in this file (lines 162 and 390).

Suggested change
execSync('powershell -c "irm bun.com/install.ps1 | iex"', { stdio: ['pipe', 'pipe', 'inherit'], shell: true });
} else {
execSync('curl -fsSL https://bun.com/install | bash', { stdio: 'inherit', shell: true });
execSync('curl -fsSL https://bun.com/install | bash', { stdio: ['pipe', 'pipe', 'inherit'], shell: true });
execSync('powershell -c "irm bun.com/install.ps1 | iex"', { stdio: 'inherit', shell: true });
} else {
execSync('curl -fsSL https://bun.com/install | bash', { stdio: 'inherit', shell: true });

}
if (!isBunInstalled()) {
throw new Error('Bun installation completed but binary not found. Please restart your terminal.');
Expand Down Expand Up @@ -159,7 +159,7 @@ function installDeps() {
}

const bunCmd = IS_WINDOWS && bunPath.includes(' ') ? `"${bunPath}"` : bunPath;
execSync(`${bunCmd} install`, { cwd: ROOT, stdio: 'inherit', shell: IS_WINDOWS });
execSync(`${bunCmd} install`, { cwd: ROOT, stdio: ['pipe', 'pipe', 'inherit'], shell: IS_WINDOWS });

// Write version marker
let version = 'unknown';
Expand Down Expand Up @@ -387,7 +387,7 @@ function installGenieCli() {

const bunCmd = IS_WINDOWS && bunPath.includes(' ') ? `"${bunPath}"` : bunPath;
const versionSuffix = pluginVersion ? `@${pluginVersion}` : '';
execSync(`${bunCmd} install -g @automagik/genie${versionSuffix}`, { stdio: 'inherit', shell: IS_WINDOWS });
execSync(`${bunCmd} install -g @automagik/genie${versionSuffix}`, { stdio: ['pipe', 'pipe', 'inherit'], shell: IS_WINDOWS });

const newVersion = getGenieVersion();
if (!newVersion) {
Expand Down
14 changes: 14 additions & 0 deletions src/lib/team-manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -426,6 +426,20 @@ export async function listMembers(teamName: string): Promise<string[] | null> {
return config.members;
}

/** Kill all running workers for a team's members. Best-effort — continues on failure. */
export async function killTeamMembers(teamName: string): Promise<void> {
const config = await getTeam(teamName);
if (!config) return;

for (const member of config.members) {
try {
await killWorkersByName(member);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Restrict done/blocked worker kill to the selected team

killTeamMembers now drives team done/team blocked, but it kills by member name only (killWorkersByName(member)), and that matcher filters on role/id without any team check. In a normal multi-team setup where both teams have roles like engineer, marking team A as done/blocked will also terminate team B's workers with the same role, interrupting unrelated work. Please scope the worker match to teamName before killing/unregistering.

Useful? React with 👍 / 👎.

} catch {
// Best-effort — continue with other members
}
Comment on lines +437 to +439

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

While the "best-effort" approach of continuing on failure is reasonable here, completely swallowing errors in the empty catch block can make debugging difficult if killWorkersByName fails for an unexpected reason.

It would be beneficial to log the error to provide visibility into potential issues.

    } catch (error) {
      console.error(`Failed to kill workers for member "${member}":`, error);
      // Best-effort — continue with other members
    }

}
}

/** Set team lifecycle status. */
export async function setTeamStatus(teamName: string, status: TeamStatus): Promise<void> {
const filePath = teamFilePath(teamName);
Expand Down
10 changes: 6 additions & 4 deletions src/term-commands/team.ts
Original file line number Diff line number Diff line change
Expand Up @@ -157,11 +157,12 @@ export function registerTeamNamespace(program: Command): void {
// team done
team
.command('done <name>')
.description('Mark a team as done')
.description('Mark a team as done and kill all members')
.action(async (name: string) => {
try {
await teamManager.setTeamStatus(name, 'done');
console.log(`Team "${name}" marked as done.`);
await teamManager.killTeamMembers(name);
console.log(`Team "${name}" marked as done. All members killed.`);
} catch (error) {
const message = error instanceof Error ? error.message : String(error);
console.error(`Error: ${message}`);
Expand All @@ -172,11 +173,12 @@ export function registerTeamNamespace(program: Command): void {
// team blocked
team
.command('blocked <name>')
.description('Mark a team as blocked')
.description('Mark a team as blocked and kill all members')
.action(async (name: string) => {
try {
await teamManager.setTeamStatus(name, 'blocked');
console.log(`Team "${name}" marked as blocked.`);
await teamManager.killTeamMembers(name);
console.log(`Team "${name}" marked as blocked. All members killed.`);
} catch (error) {
const message = error instanceof Error ? error.message : String(error);
console.error(`Error: ${message}`);
Expand Down
Loading