From 9d75bb609e83fc75d1858ebbc7d1bfbcf9c10688 Mon Sep 17 00:00:00 2001 From: Brian Madison Date: Sun, 9 Aug 2026 16:43:02 -0500 Subject: [PATCH] fix: invoke Python scripts with uv run, drop the Python browser opener MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Two ways this module needed a system Python it should not have needed. 61 invocations shelled out to a bare `python3` to run _bmad/scripts/resolve_customization.py, which declares requires-python = ">=3.11" and hard-exits below it (tomllib is a 3.11 stdlib addition). On macOS without Homebrew or Ubuntu 22.04, python3 is 3.10. `uv run` reads the script's own metadata and provisions a matching interpreter instead. Four more spawned a Python interpreter purely to open an HTML file: python3 -c "import webbrowser, pathlib; webbrowser.open(...)" Replaced with the platform opener the rest of BMad already uses — open / xdg-open / start. These were the last place the module assumed a system Python at all, and they failed silently on a machine that has none. Also corrects the README badge, which advertised >=3.10 — a floor that cannot run the module. --- README.md | 2 +- src/agents/gds-agent-game-architect/SKILL.md | 2 +- src/agents/gds-agent-game-designer/SKILL.md | 2 +- src/agents/gds-agent-game-dev/SKILL.md | 2 +- src/agents/gds-agent-game-solo-dev/SKILL.md | 2 +- src/agents/gds-agent-tech-writer/SKILL.md | 2 +- .../1-preproduction/gds-brainstorm-game/SKILL.md | 2 +- .../gds-brainstorm-game/steps/step-04-complete.md | 2 +- .../1-preproduction/gds-create-game-brief/SKILL.md | 2 +- .../1-preproduction/research/gds-domain-research/SKILL.md | 2 +- .../domain-steps/step-06-research-synthesis.md | 2 +- src/workflows/2-design/gds-create-narrative/SKILL.md | 2 +- .../gds-create-narrative/steps/step-11-complete.md | 2 +- src/workflows/2-design/gds-gdd/SKILL.md | 2 +- .../2-design/gds-gdd/references/validation-render.md | 2 +- src/workflows/2-design/gds-prd/SKILL.md | 2 +- src/workflows/2-design/gds-prd/references/validate.md | 6 +++--- src/workflows/2-design/gds-ux/SKILL.md | 2 +- src/workflows/2-design/gds-ux/assets/color-themes.md | 2 +- .../2-design/gds-ux/references/creative-tools.md | 2 +- src/workflows/2-design/gds-ux/references/validate.md | 2 +- .../gds-check-implementation-readiness/SKILL.md | 2 +- .../steps/step-06-final-assessment.md | 2 +- .../3-technical/gds-create-epics-and-stories/SKILL.md | 2 +- .../steps/step-04-final-validation.md | 2 +- src/workflows/3-technical/gds-game-architecture/SKILL.md | 2 +- .../gds-game-architecture/steps/step-09-complete.md | 2 +- .../3-technical/gds-generate-project-context/SKILL.md | 2 +- .../steps/step-03-complete.md | 2 +- src/workflows/4-production/gds-code-review/SKILL.md | 2 +- .../4-production/gds-code-review/steps/step-04-present.md | 2 +- src/workflows/4-production/gds-correct-course/SKILL.md | 4 ++-- src/workflows/4-production/gds-create-story/SKILL.md | 4 ++-- src/workflows/4-production/gds-dev-story/SKILL.md | 4 ++-- src/workflows/4-production/gds-investigate/SKILL.md | 2 +- src/workflows/4-production/gds-retrospective/SKILL.md | 4 ++-- src/workflows/4-production/gds-sprint-planning/SKILL.md | 4 ++-- src/workflows/4-production/gds-sprint-status/SKILL.md | 8 ++++---- src/workflows/gametest/gds-e2e-scaffold/SKILL.md | 4 ++-- src/workflows/gametest/gds-performance-test/SKILL.md | 4 ++-- src/workflows/gametest/gds-playtest-plan/SKILL.md | 4 ++-- src/workflows/gametest/gds-test-automate/SKILL.md | 4 ++-- src/workflows/gametest/gds-test-design/SKILL.md | 4 ++-- src/workflows/gametest/gds-test-framework/SKILL.md | 4 ++-- src/workflows/gametest/gds-test-review/SKILL.md | 4 ++-- src/workflows/gds-document-project/SKILL.md | 2 +- src/workflows/gds-document-project/instructions.md | 2 +- .../workflows/deep-dive-instructions.md | 2 +- .../workflows/full-scan-instructions.md | 2 +- src/workflows/gds-quick-flow/gds-quick-dev/SKILL.md | 2 +- .../gds-quick-flow/gds-quick-dev/step-05-present.md | 2 +- 51 files changed, 68 insertions(+), 68 deletions(-) diff --git a/README.md b/README.md index 02581f8..ae2cdfa 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [![Version](https://img.shields.io/npm/v/bmad-game-dev-studio?color=blue&label=version)](https://www.npmjs.com/package/bmad-game-dev-studio) [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE) -[![Python Version](https://img.shields.io/badge/python-%3E%3D3.10-blue?logo=python&logoColor=white)](https://www.python.org) +[![Python Version](https://img.shields.io/badge/python-%3E%3D3.11-blue?logo=python&logoColor=white)](https://www.python.org) [![uv](https://img.shields.io/badge/uv-package%20manager-blueviolet?logo=uv)](https://docs.astral.sh/uv/) [![Discord](https://img.shields.io/badge/Discord-Join%20Community-7289da?logo=discord&logoColor=white)](https://discord.gg/gk8jAdXWmj) diff --git a/src/agents/gds-agent-game-architect/SKILL.md b/src/agents/gds-agent-game-architect/SKILL.md index 47d7879..7b29438 100644 --- a/src/agents/gds-agent-game-architect/SKILL.md +++ b/src/agents/gds-agent-game-architect/SKILL.md @@ -20,7 +20,7 @@ You are Cloud Dragonborn, the Game Architect. You design scalable game architect ### Step 1: Resolve the Agent Block -Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key agent` +Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key agent` **If the script fails**, resolve the `agent` block yourself by reading these three files in base → team → user order and applying the same structural merge rules as the resolver: diff --git a/src/agents/gds-agent-game-designer/SKILL.md b/src/agents/gds-agent-game-designer/SKILL.md index 11a9c72..6a0888f 100644 --- a/src/agents/gds-agent-game-designer/SKILL.md +++ b/src/agents/gds-agent-game-designer/SKILL.md @@ -20,7 +20,7 @@ You are Samus Shepard, the Game Designer. You drive creative vision, game design ### Step 1: Resolve the Agent Block -Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key agent` +Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key agent` **If the script fails**, resolve the `agent` block yourself by reading these three files in base → team → user order and applying the same structural merge rules as the resolver: diff --git a/src/agents/gds-agent-game-dev/SKILL.md b/src/agents/gds-agent-game-dev/SKILL.md index d75447c..12a43c7 100644 --- a/src/agents/gds-agent-game-dev/SKILL.md +++ b/src/agents/gds-agent-game-dev/SKILL.md @@ -22,7 +22,7 @@ You are Link Freeman, the Game Developer. You implement features, execute dev st ### Step 1: Resolve the Agent Block -Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key agent` +Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key agent` **If the script fails**, resolve the `agent` block yourself by reading these three files in base → team → user order and applying the same structural merge rules as the resolver: diff --git a/src/agents/gds-agent-game-solo-dev/SKILL.md b/src/agents/gds-agent-game-solo-dev/SKILL.md index 9ed16a2..1278b71 100644 --- a/src/agents/gds-agent-game-solo-dev/SKILL.md +++ b/src/agents/gds-agent-game-solo-dev/SKILL.md @@ -20,7 +20,7 @@ You are Indie, the Game Solo Dev. You ship complete games from concept to launch ### Step 1: Resolve the Agent Block -Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key agent` +Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key agent` **If the script fails**, resolve the `agent` block yourself by reading these three files in base → team → user order and applying the same structural merge rules as the resolver: diff --git a/src/agents/gds-agent-tech-writer/SKILL.md b/src/agents/gds-agent-tech-writer/SKILL.md index 1b39ece..5102970 100644 --- a/src/agents/gds-agent-tech-writer/SKILL.md +++ b/src/agents/gds-agent-tech-writer/SKILL.md @@ -20,7 +20,7 @@ You are Paige, the Technical Writer. You transform complex game development conc ### Step 1: Resolve the Agent Block -Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key agent` +Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key agent` **If the script fails**, resolve the `agent` block yourself by reading these three files in base → team → user order and applying the same structural merge rules as the resolver: diff --git a/src/workflows/1-preproduction/gds-brainstorm-game/SKILL.md b/src/workflows/1-preproduction/gds-brainstorm-game/SKILL.md index 50ef110..464a969 100644 --- a/src/workflows/1-preproduction/gds-brainstorm-game/SKILL.md +++ b/src/workflows/1-preproduction/gds-brainstorm-game/SKILL.md @@ -22,7 +22,7 @@ description: 'Facilitate game brainstorming sessions with game-specific techniqu ### Step 1: Resolve the Workflow Block -Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow` +Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow` **If the script fails**, resolve the `workflow` block yourself by reading these three files in base → team → user order and applying the same structural merge rules as the resolver: diff --git a/src/workflows/1-preproduction/gds-brainstorm-game/steps/step-04-complete.md b/src/workflows/1-preproduction/gds-brainstorm-game/steps/step-04-complete.md index 32f550b..91f6a74 100644 --- a/src/workflows/1-preproduction/gds-brainstorm-game/steps/step-04-complete.md +++ b/src/workflows/1-preproduction/gds-brainstorm-game/steps/step-04-complete.md @@ -277,6 +277,6 @@ This step-file architecture ensures consistent, creative brainstorming with user ## On Complete -Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow.on_complete` +Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow.on_complete` If the resolved `workflow.on_complete` is non-empty, follow it as the final terminal instruction before exiting. diff --git a/src/workflows/1-preproduction/gds-create-game-brief/SKILL.md b/src/workflows/1-preproduction/gds-create-game-brief/SKILL.md index 7a8d22a..2d841fa 100644 --- a/src/workflows/1-preproduction/gds-create-game-brief/SKILL.md +++ b/src/workflows/1-preproduction/gds-create-game-brief/SKILL.md @@ -15,7 +15,7 @@ At the opening greeting, let the user know they can invoke `bmad-party-mode` for ## On Activation -1. Resolve customization: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, read `{skill-root}/customize.toml` directly and use defaults. +1. Resolve customization: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, read `{skill-root}/customize.toml` directly and use defaults. 2. Execute each entry in `{workflow.activation_steps_prepend}` in order. 3. Treat every entry in `{workflow.persistent_facts}` as foundational context for the rest of the run. Entries prefixed `file:` are paths or globs under `{project-root}` — load the referenced contents as facts. All other entries are facts verbatim. 4. `{workflow.external_sources}` is an org-configured registry of internal tools (knowledge bases, MCP tools); consult them alongside generic web research on the same triggers in `## Discovery`, org tools preferred when their directive matches. If a named tool is unavailable at runtime, fall back to standard behavior and note the gap when relevant. diff --git a/src/workflows/1-preproduction/research/gds-domain-research/SKILL.md b/src/workflows/1-preproduction/research/gds-domain-research/SKILL.md index 831e762..67f176a 100644 --- a/src/workflows/1-preproduction/research/gds-domain-research/SKILL.md +++ b/src/workflows/1-preproduction/research/gds-domain-research/SKILL.md @@ -20,7 +20,7 @@ description: 'Conduct game domain and industry research. Use when the user says ### Step 1: Resolve the Workflow Block -Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow` +Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow` **If the script fails**, resolve the `workflow` block yourself by reading these three files in base → team → user order and applying the same structural merge rules as the resolver: diff --git a/src/workflows/1-preproduction/research/gds-domain-research/domain-steps/step-06-research-synthesis.md b/src/workflows/1-preproduction/research/gds-domain-research/domain-steps/step-06-research-synthesis.md index e763f33..8f20100 100644 --- a/src/workflows/1-preproduction/research/gds-domain-research/domain-steps/step-06-research-synthesis.md +++ b/src/workflows/1-preproduction/research/gds-domain-research/domain-steps/step-06-research-synthesis.md @@ -446,6 +446,6 @@ Congratulations on completing comprehensive game domain research! ## On Complete -Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow.on_complete` +Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow.on_complete` If the resolved `workflow.on_complete` is non-empty, follow it as the final terminal instruction before exiting. diff --git a/src/workflows/2-design/gds-create-narrative/SKILL.md b/src/workflows/2-design/gds-create-narrative/SKILL.md index 830d8cd..c3d5283 100644 --- a/src/workflows/2-design/gds-create-narrative/SKILL.md +++ b/src/workflows/2-design/gds-create-narrative/SKILL.md @@ -22,7 +22,7 @@ description: 'Create comprehensive narrative documentation with story structure ### Step 1: Resolve the Workflow Block -Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow` +Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow` **If the script fails**, resolve the `workflow` block yourself by reading these three files in base → team → user order and applying the same structural merge rules as the resolver: diff --git a/src/workflows/2-design/gds-create-narrative/steps/step-11-complete.md b/src/workflows/2-design/gds-create-narrative/steps/step-11-complete.md index 2843ab0..81680cc 100644 --- a/src/workflows/2-design/gds-create-narrative/steps/step-11-complete.md +++ b/src/workflows/2-design/gds-create-narrative/steps/step-11-complete.md @@ -333,6 +333,6 @@ This step-file architecture ensures consistent, thorough narrative design with u ## On Complete -Run: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow.on_complete` +Run: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow.on_complete` If the resolved `workflow.on_complete` is non-empty, follow it as the final terminal instruction before exiting. diff --git a/src/workflows/2-design/gds-gdd/SKILL.md b/src/workflows/2-design/gds-gdd/SKILL.md index 3b49e98..a7fd685 100644 --- a/src/workflows/2-design/gds-gdd/SKILL.md +++ b/src/workflows/2-design/gds-gdd/SKILL.md @@ -21,7 +21,7 @@ At the opening greeting, let the user know they can invoke the skills `bmad-part ## On Activation -1. Resolve customization: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, surface the diagnostic and halt. +1. Resolve customization: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, surface the diagnostic and halt. 2. Execute each entry in `{workflow.activation_steps_prepend}` in order. 3. Treat every entry in `{workflow.persistent_facts}` as foundational context. Entries prefixed `file:` are paths or globs under `{project-root}` — load their contents as facts. All others are facts verbatim. 4. Note `{workflow.external_sources}` as a registry to consult on demand when the conversation surfaces a relevant need. Do not query preemptively. If a named tool is unavailable at runtime, fall back to standard behavior and note the gap. diff --git a/src/workflows/2-design/gds-gdd/references/validation-render.md b/src/workflows/2-design/gds-gdd/references/validation-render.md index 898f8cc..51cdb37 100644 --- a/src/workflows/2-design/gds-gdd/references/validation-render.md +++ b/src/workflows/2-design/gds-gdd/references/validation-render.md @@ -44,7 +44,7 @@ Per-finding fields: After the subagent writes findings: ```bash -python3 {skill-root}/scripts/render-validation-html.py \ +uv run {skill-root}/scripts/render-validation-html.py \ --findings {doc_workspace}/validation-findings.json \ --template {workflow.validation_report_template} \ --output {doc_workspace}/validation-report.html \ diff --git a/src/workflows/2-design/gds-prd/SKILL.md b/src/workflows/2-design/gds-prd/SKILL.md index c1e2487..53fdea8 100644 --- a/src/workflows/2-design/gds-prd/SKILL.md +++ b/src/workflows/2-design/gds-prd/SKILL.md @@ -31,7 +31,7 @@ You are a facilitator, not a form. The user is the author; you are the structure ## On Activation -1. Resolve customization: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, read `{skill-root}/customize.toml` directly and proceed with its values. +1. Resolve customization: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, read `{skill-root}/customize.toml` directly and proceed with its values. 2. Execute each entry in `{workflow.activation_steps_prepend}` in order. 3. Treat every entry in `{workflow.persistent_facts}` as foundational context. Entries prefixed `file:` are paths or globs under `{project-root}` — load their contents as facts. All others are facts verbatim. 4. Note `{workflow.external_sources}` as a registry to consult on demand when the conversation surfaces a relevant need. Do not query preemptively. If a named tool is unavailable at runtime, fall back to standard behavior and note the gap. diff --git a/src/workflows/2-design/gds-prd/references/validate.md b/src/workflows/2-design/gds-prd/references/validate.md index 02ea350..5872338 100644 --- a/src/workflows/2-design/gds-prd/references/validate.md +++ b/src/workflows/2-design/gds-prd/references/validate.md @@ -40,13 +40,13 @@ After the subagent writes findings, the parent fills `{workflow.validation_repor Grade derivation: *Excellent* = no fails, no high/critical findings · *Good* = no critical findings, at most minor fails · *Fair* = any high finding or several fails · *Poor* = any critical finding. -For interactive runs, open the HTML: +For interactive runs, open the HTML with the platform opener — `open` on macOS, `xdg-open` on Linux, `start ""` on Windows — double-quoting the path: ```bash -python3 -c "import webbrowser, pathlib; webbrowser.open(pathlib.Path('{doc_workspace}/validation-report.html').resolve().as_uri())" +open "{doc_workspace}/validation-report.html" ``` -Skip the open step in headless mode (see `references/headless.md`). Re-running validation overwrites the report in place. +If the command fails, don't retry with another opener: tell the user the file path and move on. Skip the open step in headless mode (see `references/headless.md`). Re-running validation overwrites the report in place. ## Close diff --git a/src/workflows/2-design/gds-ux/SKILL.md b/src/workflows/2-design/gds-ux/SKILL.md index 77a5ec6..e2d1f1e 100644 --- a/src/workflows/2-design/gds-ux/SKILL.md +++ b/src/workflows/2-design/gds-ux/SKILL.md @@ -33,7 +33,7 @@ UX may lead, follow, or stand alone. Inherit `sources:` by reference; the spines ## On Activation -1. Resolve customization: `python3 {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, read `{skill-root}/customize.toml` directly and use defaults. +1. Resolve customization: `uv run {project-root}/_bmad/scripts/resolve_customization.py --skill {skill-root} --key workflow`. On failure, read `{skill-root}/customize.toml` directly and use defaults. 2. Run `{workflow.activation_steps_prepend}`. Treat `{workflow.persistent_facts}` as foundational context (entries prefixed `file:` are loaded). `{workflow.external_sources}` is an org-configured registry of internal tools; consult them alongside generic web research on the same triggers, org tools preferred when their directive matches. 3. Load `{project-root}/_bmad/gds/config.yaml` (+ `config.user.yaml` if present). Resolve `{user_name}`, `{communication_language}`, `{document_output_language}`, `{planning_artifacts}`, `{project_name}`, `{date}`. Missing keys → neutral defaults; never block. 4. If headless, follow `references/headless.md` for the whole run. Otherwise greet the user **by name** using `{user_name}` and **in their language** using `{communication_language}` — and stay in `{communication_language}` for every turn. In the greeting, let the user know `bmad-party-mode` and `bmad-advanced-elicitation` are always available. Then scan for misroute on the first message: PRD → `gds-prd`; architecture → `gds-game-architecture`; narrative → `gds-create-narrative`; GDD → `gds-gdd`. diff --git a/src/workflows/2-design/gds-ux/assets/color-themes.md b/src/workflows/2-design/gds-ux/assets/color-themes.md index 31169ed..2b23b46 100644 --- a/src/workflows/2-design/gds-ux/assets/color-themes.md +++ b/src/workflows/2-design/gds-ux/assets/color-themes.md @@ -6,4 +6,4 @@ Each variation: header (name + one-line emotional register), token chips for eve Inline CSS only, system font stack, no JS, no network. Document concrete hex values in `