scipy-stubs
The official type stubs for SciPy
Decision gist · record as of 2026-08-14
Yes. If you use SciPy and any static type checker (mypy, pyright, or similar), installing scipy-stubs is a straightforward win: low install friction, no runtime cost, active maintenance, permissive license, and broad tool support. Skip it only if you don't use type checking at all.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.12 or later
- Low friction: a pure-Python wheel with a single runtime dependency (optype).
- Active maintenance with releases every few weeks; last commit 2026-08-14.
License · maintenance · safety
BSD-3-Clause (permissive) — BSD-3-Clause permissive license; no restrictions on use or redistribution in proprietary or open-source projects.
last release 2026-07-12 (33 days) · last repo commit 2026-08-14 · 93 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 3,892,699 downloads/mo, #2,458 on PyPI
Alternatives
Verify before relying
pip install scipy-stubs
import scipy.integrate
from scipy.integrate import BDF- Whether scipy-stubs works correctly with scipy versions newer than the stubs' own release, given the lack of an upper-bound enforcement
- Runtime performance impact of the optype dependency during type checking or IDE operations
What it is and what it does
scipy-stubs is the official type stub package for SciPy, maintained separately from SciPy itself to allow faster iteration and independent release cycles. It annotates the entire public SciPy API with precise type information, including array shapes and dtypes where applicable, and provides generic types for sparse arrays, distributions, splines, and linear operators. The stubs work transparently on install with no runtime impact—they affect only static type checking and IDE autocompletion.
The package is tested against multiple type checkers (mypy, pyright, basedpyright, pyrefly, ty, and zuban) and is used by major projects. It requires Python 3.12 or later and depends on optype for array-like and shape-typing support. Installation is optional and opt-in; users who don't enable type checking won't see any behavioral change.
Use it for
- Enable IDE autocompletion and error detection for SciPy code without modifying existing source
- Run mypy or pyright on scientific Python projects to catch type errors in SciPy function calls
- Track array shapes and dtypes through SciPy operations for numerical correctness verification
- Use generic types for precise type hints on SciPy solver and distribution objects
- Integrate type checking into CI/CD pipelines for scientific Python libraries that depend on SciPy
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
If you use SciPy and any static type checker (mypy, pyright, or similar), installing scipy-stubs is a straightforward win: low install friction, no runtime cost, active maintenance, permissive license, and broad tool support. Skip it only if you don't use type checking at all.
Install
scipy-stubs on PyPI
Before you install
Low friction: a pure-Python wheel with a single runtime dependency (optype). Active maintenance with releases every few weeks; last commit 2026-08-14.
Requires Python 3.12 or later
License in practice
BSD-3-Clause permissive license; no restrictions on use or redistribution in proprietary or open-source projects.
Quickstart
pip install scipy-stubs
import scipy.integrate
from scipy.integrate import BDF
Verify before relying
- Whether scipy-stubs works correctly with scipy versions newer than the stubs' own release, given the lack of an upper-bound enforcement
- Runtime performance impact of the optype dependency during type checking or IDE operations
Package facts
| License | BSD-3-Clause permissive |
| Python support | Supports the current Python release >=3.12 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 1 packageoptype |
| Maintenance | Actively maintained 33 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 3,892,699 / month, #2,458 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 5 - Production/StableIntended Audience :: DevelopersIntended Audience :: Science/ResearchOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Typing :: Stubs Only |
Evidence: scipy_stubs-1.18.0.1-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “scipy type stubs”
- scipy-stubsProvides type stubs for the entire SciPy library, enabling static…
- types-assertpyProvides type stubs enabling static type checkers like mypy and…
- types-appdirsProvides type stubs for the appdirs package to enable static type…
Give your agent the search over MCP, or paste the wish link into any chat.
More Quality Assurance packages
Coverage.py measures which lines of Python code are executed during test runs, reporting coverage percentages and identifying untested code paths.
Install it if you want to measure test completeness or enforce coverage thresholds in your project.
Ruff is a Python linter and code formatter written in Rust that combines linting, formatting, and code fixing into a single tool, replacing Flake8, Black, isort, and related utilities.
Pexpect spawns and controls interactive console applications by sending input and matching output patterns, automating tasks that would otherwise require manual interaction.
Black reformats Python source code to a consistent style by parsing entire files and rewriting them according to an opinionated, deterministic set of rules, eliminating manual formatting decisions.
pytest-xdist distributes pytest tests across multiple CPU cores or machines to speed up test execution, with the simplest usage being `pytest -n auto` to spawn workers equal to available CPUs.
Install it if your test suite takes long enough that parallelization would save meaningful time.
Validates AWS CloudFormation templates in YAML or JSON format against resource provider schemas and best practices, checking property values and configuration correctness.
Install it if you work with CloudFormation templates.
See also joblib-stubs · numpy-typing-compat · types-futures · types-SQLAlchemy · types-Pillow · types-reportlab · types-dataclasses · types-geopandas · sqlalchemy-stubs · types-pika