python-venv
Always use this skill before any explicit or implicit Python execution in a workspace (for example python/python3 commands, shebang scripts, test/build tools…
Skill by anaregdesign
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/anaregdesign-python-venv
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: testing
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/python-venv
What's inside
- Skill name
python-venv- Description
- Always use this skill before any explicit or implicit Python execution in a workspace (for example python/python3 commands, shebang scripts, test/build tools that invoke Python, uv run, uvx, pip, poetry, tox, or nox). Provision and activate uv environments under workspace-dir/python/vX.Y.Z, switch Python versions, and manage dependencies with uv add, uv lock, and uv sync.
- License
- MIT
- Instructions
- 102 lines in SKILL.md · view on GitHub
Before installing
- Instructions call the network
Files (2)
- SKILL.md
- .gitkeep · assets/
SKILL.md (first lines)
# Python Venv Environment Provider
## Hard Rules
- Always place projects under `<workspace-dir>/python/vX.Y.Z`.
- Resolve absolute `<workspace-dir>` from MCPHost app context (for example workspace metadata, current project root, or an environment variable such as `PYTHON_VENV_WORKSPACE_DIR`).
- Never depend on caller `cwd` to choose project location.
- MCPHost can run CLI directly. Do not require helper script files.
- Invoke this skill before any Python code execution in the workspace.
- This skill performs environment provisioning only. Do not execute user Python code in this skill.
- Do not generate business/domain artifacts (for example deck plans, chart specs, PPTX files).
- If the requested version does not exist yet, create it and activate it.
- For dependency changes, run `uv add`, then `uv lock`, then `uv sync` in the target version project.
- If version is not specified, default to `3.12.8`.
- Call `path` at most once at the end of provisioning. Do not poll it in a loop.
## Prerequisites
- Require `uv` in `PATH`. Check with `uv --version`.
- If `uv` is missing on macOS, run `brew install uv`.
- If `uv` is missing on Linux, run `curl -LsSf https://astral.sh/uv/install.sh | sh`.
- If `uv` is missing on Windows (PowerShell), run `winget install --id=astral-sh.uv -e`.
- If `winget` is unavailable, run `powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"`.
- For current options, see `https://docs.astral.sh/uv/getting-started/installation/`.
## Handoff Contract
- Scope of this skill: create/switch Python virtual environments and manage Python packages only.
- After provisioning, return only:
- version used,
- resolved environment directory from `path <version>`,
- packages added (if any).
- Do not continue into domain workflow steps after this handoff.
## Action Semantics
Use these action labels as procedural units. Implement them with direct shell commands.
1. `ensure <version>`
- Create `<workspace-dir>/python/vX.Y.Z`.
- Initialize uv project if missing.
- Create `.venv` with the requested Python version.
2. `activate <version>`
- Activate existing venv.
- If venv is missing, run `ensure` first.
3. `deactivate`
- Deactivate current venv if active.
- Use this only when you explicitly want to leave the active environment.
4. `use <version>`
- Run `ensure`.
- If another venv is active, `deactivate` first.
- Activate requested version.
5. `add <version> <deps...>`
- Run `ensure`.
- Run `uv add <deps...>`, `uv lock`, `uv sync`.
- If non-Python dependencies are included (for example `pptxgenjs`), skip them and show install guidance.
6. `path <version>`
- Print resolved `<workspace-dir>/python/vX.Y.Z` path.
## Environment Provisioning Protocol
When asked for a Python environment, perform the following in order:
1. Choose version:
- User-specified version if provided.
- Otherwise `3.12.8`.
2. Resolve `env_dir="<workspace-dir>/python/v<version>"`.
3. Run `ensure` then `activate`.
4. If dependency updates are requested, run `add`.
5. Return `path` once at the end.
## MCPHost CLI Contract
1. Resolve absolute `<workspace-dir>` first.
2. Execute one `bash -lc` command that includes:
- workspace path input passed from MCPHost (for example `PYTHON_VENV_WORKSPACE_DIR="<workspace-dir>"`),
- direct `uv` commands for `ensure` and (if needed) `activate` / `add` / `path`.
3. Run in this order:
- `use`,
- optional `add`,
- `path` (once at end).
```bash
bash -lc '
PYTHON_VENV_WORKSPACE_DIR="<workspace-dir>"
version="3.12.8"
env_dir="$PYTHON_VENV_WORKSPACE_DIR/python/v$version"
mkdir -p "$env_dir"
cd "$env_dir"
test -f pyproject.toml || uv init --bare --python "$version" --name "python_v${version//./_}"
uv venv --python "$version" --allow-existing
source "$env_dir/.venv/bin/activate"
'
```
## Direct Command Notes
- `add` should skip non-Python dependencies such as `pptxgenjs` / `npm:pptxgenjs` and print install guidance instead of failing.
- `path` should print `<workspace-dir>/python/v<version>`.
- `deactivate` should be used only when explicitly switching environments.From anaregdesign/skills, MIT.
More from anaregdesign/skills
- 0.448score
spec-driven-workflow
anaregdesign
Own the spec-first planning workflow for feature or behavior work.
SkillDFreshness: D★ 2Claude Code +9 - 0.448score
azure-spa-clean-architecture-bootstrap
anaregdesign
Own Azure platform, identity, secretless config, IaC, and GitHub release and deployment automation for React Router + Prisma v7 web apps that already follow…
SkillDFreshness: D★ 2Claude Code +9 - 0.448score
enforce-react-spa-architecture
anaregdesign
Own code-level clean-architecture guardrails for Vite-powered React Router + Prisma v7 applications.
SkillDFreshness: D★ 2Claude Code +9 - 0.443score
python-current-time
anaregdesign
Return the current local time by running a bundled Python script.
SkillDFreshness: D★ 2Claude Code +9 - 0.440score
nisa-growth-tech
anaregdesign
NISA成長投資枠で買付可能な個別株(ETF除く)を対象に、産業ごとの非連続成長に着目し、投資テーマごとに複数の強豪銘柄を選定して分散しつつ、最大許容ドローダウンとリスク予算(テーマ/銘柄)を事前定義して、ベンチマーク超のボラティリティとリターンを狙う運用改善提案を行う。
SkillDFreshness: D★ 2Claude Code +9 - 0.440score
jp-business-email-reply
anaregdesign
Draft Japanese business email replies by extracting stakeholders, classifying intent, coordinating schedules via Work IQ MCP server, and answering Microsoft…
SkillDFreshness: D★ 2Claude Code +9 - 0.422score
theme-template-ppt
anaregdesign
Create PowerPoint decks from assets/template.pptx by first structuring each slide's core claim, then inspecting/ranking template slide-master layouts…
SkillDFreshness: D★ 2Claude Code +9
Signals
- Stars
- 2
- Forks
- 0
- Open issues
- 0
- Last commit (this folder)
- Mar 8, 2026 (7 months ago)
- Last release
- Mar 11, 2026 (7 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- License
- MIT
- Repository
- github.com/anaregdesign/skills
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
More from anaregdesign
- 0.448score
spec-driven-workflow
anaregdesign
Own the spec-first planning workflow for feature or behavior work.
SkillDFreshness: D★ 2Claude Code +9 - 0.448score
azure-spa-clean-architecture-bootstrap
anaregdesign
Own Azure platform, identity, secretless config, IaC, and GitHub release and deployment automation for React Router + Prisma v7 web apps that already follow…
SkillDFreshness: D★ 2Claude Code +9 - 0.448score
enforce-react-spa-architecture
anaregdesign
Own code-level clean-architecture guardrails for Vite-powered React Router + Prisma v7 applications.
SkillDFreshness: D★ 2Claude Code +9 - 0.443score
python-current-time
anaregdesign
Return the current local time by running a bundled Python script.
SkillDFreshness: D★ 2Claude Code +9 - 0.440score
nisa-growth-tech
anaregdesign
NISA成長投資枠で買付可能な個別株(ETF除く)を対象に、産業ごとの非連続成長に着目し、投資テーマごとに複数の強豪銘柄を選定して分散しつつ、最大許容ドローダウンとリスク予算(テーマ/銘柄)を事前定義して、ベンチマーク超のボラティリティとリターンを狙う運用改善提案を行う。
SkillDFreshness: D★ 2Claude Code +9 - 0.440score
jp-business-email-reply
anaregdesign
Draft Japanese business email replies by extracting stakeholders, classifying intent, coordinating schedules via Work IQ MCP server, and answering Microsoft…
SkillDFreshness: D★ 2Claude Code +9
Cite this page
python-venv skill. Agent Mart. https://agentmart.dev/skills/anaregdesign-python-venv (last updated 2026-10-24)