poetry-rye-dependency-management
Python dependency management with Poetry and Rye -- lockfile-driven workflows, dependency groups, monorepo patterns, and migration paths. Covers…
от oimiragieo★ 48 звёзд на GitHub
Установить poetry-rye-dependency-management в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Poetry / Rye Dependency Management Skill
Python dependency management specialist for Poetry and Rye workflows. Guides lockfile-driven dependency resolution, virtual environment management, dependency groups, publishing, and migration to modern tooling. Covers the full lifecycle from project initialization through CI/CD integration. - Initialize new Python projects with Poetry or Rye - Manage dependency groups (main, dev, test, docs, optional extras) - Configure lockfile-driven builds for reproducibility - Set up CI/CD pipelines with cached dependency installation - Migrate between Poetry, Rye, pip, and uv workflows - Configure monorepo dependency management with workspaces - Audit dependencies for security vulnerabilities - Publish packages to PyPI using Poetry or RyeOverview
Poetry and Rye are Python dependency managers that enforce lockfile-driven, deterministic builds. Both use pyproject.toml as the single configuration file. Poetry is the established standard (since 2018); Rye is a newer Astral tool that bridges to uv. For greenfield projects, consider modern-python skill (uv-native). This skill covers Poetry/Rye for existing codebases and teams already invested in these tools.
When to Use
- When maintaining existing Poetry or Rye projects
- When a team has standardized on Poetry and migration to uv is not planned
- When publishing Python packages to PyPI (Poetry has mature publishing support)
- When managing monorepo Python workspaces
- When auditing or upgrading dependency lockfiles
Iron Laws
- ALWAYS commit the lockfile (
poetry.lockorrequirements.lock) -- without it, builds are non-deterministic and CI/CD will resolve different versions than development. - NEVER use
pip installin a Poetry/Rye-managed project -- it bypasses the resolver and creates ghost dependencies invisible to the lockfile. - ALWAYS use
poetry add/rye addto add dependencies -- manualpyproject.tomledits without re-locking create stale lockfiles. - NEVER pin transitive dependencies manually -- let the solver manage the full dependency graph; pinning transitive deps causes resolver conflicts.
- ALWAYS separate runtime and development dependencies into groups -- shipping dev/test dependencies in production images wastes space and expands attack surface.
Anti-Patterns
| Anti-Pattern | Why It Fails | Correct Approach |
|---|---|---|
Editing pyproject.toml deps without running poetry lock |
Lockfile becomes stale; CI installs different versions than intended | Always run poetry lock or rye lock after any dependency change |
Using poetry install without --no-root in CI |
Installs the project in editable mode unnecessarily; slower CI builds | Use poetry install --no-root for library deps only, --only main for production |
Committing .venv/ directory to version control |
Bloats repo; virtualenvs are platform-specific and non-portable | Add .venv/ to .gitignore; recreate with poetry install or rye sync |
| Mixing pip and Poetry in the same project | Creates two dependency graphs; pip-installed packages invisible to Poetry | Use only poetry add/rye add for all dependency changes |
Using * version constraints for all dependencies |
No upper bound protection; major version bumps break silently | Use compatible release (^ in Poetry) or upper-bounded ranges |
Workflow
Poetry Project Setup
# Initialize new project
poetry init --name my-project --python ">=3.12"
# Add dependencies by group
poetry add requests httpx
poetry add --group dev ruff pytest pytest-cov
poetry add --group docs sphinx
# Install all groups
poetry install
# Install production only
poetry install --only main
Rye Project Setup
# Initialize new project
rye init my-project
cd my-project
# Add dependencies
rye add requests httpx
rye add --dev ruff pytest pytest-cov
# Sync (install) dependencies
rye sync
pyproject.toml Configuration (Poetry)
[tool.poetry]
name = "my-project"
version = "0.1.0"
description = "Project description"
authors = ["Team <[email protected]>"]
readme = "README.md"
[tool.poetry.dependencies]
python = ">=3.12"
requests = "^2.31"
httpx = "^0.27"
[tool.poetry.group.dev.dependencies]
ruff = "^0.9"
pytest = "^8.0"
pytest-cov = "^6.0"
[build-system]
requires = ["poetry-core"]
build-backend = "poetry.core.masonry.api"
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
- 01
Read - 02
Write - 03
Edit - 04
Bash - 05
Glob - 06
Grep
Вложенные файлы
- commands/poetry-rye-dependency-management.md
- hooks/post-execute.cjs
- hooks/pre-execute.cjs
- references/research-requirements.md
- rules/poetry-rye-dependency-management.md
- schemas/input.schema.json
- schemas/output.schema.json
- scripts/main.cjs
- templates/implementation-template.md
FAQ
Что делает скилл poetry-rye-dependency-management?
Python dependency management with Poetry and Rye -- lockfile-driven workflows, dependency groups, monorepo patterns, and migration paths. Covers pyproject.toml-centric packaging for projects not yet on uv.
Как установить скилл poetry-rye-dependency-management?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл poetry-rye-dependency-management запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
theme-factory
AnthropicToolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
access
AnthropicManage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
configure
AnthropicSet up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
access
AnthropicManage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…