Add strictness emphasis to project and stubs README, add PyPI badges

Highlight basedpyright `all` mode and zero typing.Any as key
differentiators in both the project README description and the
per-version stubs README template.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Joseph HENRY 2026-04-03 11:43:19 +02:00
parent 199bad568a
commit 7fde7f53da
2 changed files with 16 additions and 13 deletions

View File

@ -3,8 +3,9 @@
![Python](https://img.shields.io/badge/Python-3776AB?style=for-the-badge&logo=python&logoColor=white)
![Blender](https://img.shields.io/badge/Blender-E87D0D?style=for-the-badge&logo=blender&logoColor=white)
![License: MIT](https://img.shields.io/badge/License-MIT-green.svg?style=for-the-badge)
[![PyPI](https://img.shields.io/pypi/v/blender-python-stubs?style=for-the-badge&logo=pypi&logoColor=white)](https://pypi.org/project/blender-python-stubs/)
Type stubs for the Blender Python API. Provides autocomplete, type checking, and inline documentation for `bpy`, `mathutils`, `bmesh`, `gpu`, `freestyle`, and all other Blender Python modules.
Strict type stubs for the Blender Python API. Provides autocomplete, type checking, and inline documentation for `bpy`, `mathutils`, `bmesh`, `gpu`, `freestyle`, and all other Blender Python modules. Generated stubs pass [basedpyright](https://docs.basedpyright.com) `all` mode with 0 errors and use zero `typing.Any`.
## Installation
@ -14,16 +15,16 @@ pip install blender-python-stubs==5.1.0
The version matches your target Blender version:
| Blender Version | Install Command |
| --------------- | ---------------------------------------------- |
| 5.1 | `pip install "blender-python-stubs>=5.1,<5.2"` |
| 5.0 | `pip install "blender-python-stubs>=5.0,<5.1"` |
| 4.5 | `pip install "blender-python-stubs>=4.5,<4.6"` |
| 4.4 | `pip install "blender-python-stubs>=4.4,<4.5"` |
| 4.3 | `pip install "blender-python-stubs>=4.3,<4.4"` |
| 4.2 | `pip install "blender-python-stubs>=4.2,<4.3"` |
| 4.1 | `pip install "blender-python-stubs>=4.1,<4.2"` |
| 4.0 | `pip install "blender-python-stubs>=4.0,<4.1"` |
| Blender Version | Install Command | PyPI |
| --------------- | ---------------------------------------------- | ---- |
| 5.1 | `pip install "blender-python-stubs>=5.1,<5.2"` | [![PyPI](https://img.shields.io/badge/PyPI-5.1-blue?logo=pypi)](https://pypi.org/project/blender-python-stubs/5.1.0.1/) |
| 5.0 | `pip install "blender-python-stubs>=5.0,<5.1"` | [![PyPI](https://img.shields.io/badge/PyPI-5.0-blue?logo=pypi)](https://pypi.org/project/blender-python-stubs/5.0.1.0/) |
| 4.5 | `pip install "blender-python-stubs>=4.5,<4.6"` | [![PyPI](https://img.shields.io/badge/PyPI-4.5-blue?logo=pypi)](https://pypi.org/project/blender-python-stubs/4.5.8.1/) |
| 4.4 | `pip install "blender-python-stubs>=4.4,<4.5"` | |
| 4.3 | `pip install "blender-python-stubs>=4.3,<4.4"` | |
| 4.2 | `pip install "blender-python-stubs>=4.2,<4.3"` | |
| 4.1 | `pip install "blender-python-stubs>=4.1,<4.2"` | |
| 4.0 | `pip install "blender-python-stubs>=4.0,<4.1"` | |
## Usage

View File

@ -159,9 +159,11 @@ def build_generated_pyproject(
README_TEMPLATE = """\
# blender-python-stubs
Type stubs for Blender {blender_version} Python API.
[![PyPI](https://img.shields.io/pypi/v/blender-python-stubs?logo=pypi&logoColor=white)](https://pypi.org/project/blender-python-stubs/)
Provides autocomplete, type checking, and inline documentation for `bpy`, `mathutils`, `bmesh`, `gpu`, `freestyle`, and all other Blender Python modules.
Strict type stubs for Blender {blender_version} Python API.
Provides autocomplete, type checking, and inline documentation for `bpy`, `mathutils`, `bmesh`, `gpu`, `freestyle`, and all other Blender Python modules. Generated stubs pass [basedpyright](https://docs.basedpyright.com) `all` mode with 0 errors and use zero `typing.Any`.
## Installation