Skip to content
Back to skills

1 Version Constraints

ASecurity

Sub-skill of pyproject-toml: 1. Version Constraints (+3).

  • 17 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added September 9, 2026
datago

Security analysis

A100/100

Scanned September 9, 2026

npx -y skills add vamseeachanta/workspace-hub --skill 1-version-constraints --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of 1 Version Constraints?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for 1 Version Constraints
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vamseeachanta-1-version-constraints/badge)](https://www.skillsdirectory.com/skills/vamseeachanta-1-version-constraints)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: pyproject-toml-1-version-constraints
description: 'Sub-skill of pyproject-toml: 1. Version Constraints (+3).'
version: 1.0.0
category: development
type: reference
scripts_exempt: true
---

# 1. Version Constraints (+3)

## 1. Version Constraints


```toml
# Recommended patterns
dependencies = [
    "pandas>=2.0.0",           # Minimum version (most common)
    "numpy>=1.24,<2.0",        # Range for major version compatibility
    "requests~=2.28",          # Compatible release (~=2.28 means >=2.28,<3.0)
]

# Avoid
dependencies = [
    "pandas==2.1.3",           # Too strict, causes conflicts
    "numpy",                   # Too loose, may break with updates
]
```


## 2. Organize Optional Dependencies


```toml
[project.optional-dependencies]
# Group by purpose
dev = ["pytest", "ruff", "mypy"]
docs = ["mkdocs", "mkdocs-material"]
viz = ["plotly", "matplotlib"]

# Convenience groups
test = ["pytest", "pytest-cov"]
lint = ["ruff", "mypy"]
all = ["my-project[dev,docs,viz]"]
```


## 3. Use src Layout


```
my-project/
├── pyproject.toml
├── src/
│   └── my_project/
│       ├── __init__.py
│       └── core.py
└── tests/
    └── test_core.py
```


## 4. Keep Tools Consistent


```toml
# Use same line-length everywhere
[tool.ruff]
line-length = 88

[tool.black]
line-length = 88

[tool.isort]
line_length = 88
```

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.