skillfed

types-greenlet

Typing stubs for greenlet

types-greenlet v3.5.0.20260518 724.6K downloads/30d#5,222 on PyPI37
Permissive license Apache-2.0 Active released

What it is and what it does

types-greenlet is a type stub package that supplies type annotations for the greenlet library, a Python package for lightweight concurrent programming using microthreads. It exists solely to help static type checkers (mypy, pyright, and others) understand greenlet's API surface and validate code that uses it. The stubs are maintained as part of the typeshed project and are kept in sync with greenlet 3.5.x releases.

When installed, this package enables your type checker to catch type errors in greenlet-based code without needing greenlet itself to ship its own inline type hints. It has no runtime dependencies and no runtime behavior—it is purely a development tool for improving code quality during static analysis.

Use it for:

  • Enable mypy or pyright to type-check code that imports and uses greenlet for concurrent tasks.
  • Catch type errors in greenlet-based coroutine functions before runtime.
  • Integrate greenlet into a typed codebase where all dependencies have type stubs available.
  • Validate greenlet API usage in CI/CD pipelines running static type checkers.
  • Support IDE autocomplete and hover documentation for greenlet APIs in editors that use type stubs.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Provides type stubs for the greenlet package, enabling static type checkers like mypy and pyright to understand and validate code that uses greenlet.

Yes, if you use greenlet and run static type checkers. It has no runtime cost, low install friction, and is actively maintained. If you do not use greenlet or do not use type checkers, it provides no value.

Install

types-greenlet on PyPI

pip

pip install types-greenlet

uv

uv add types-greenlet

poetry

poetry add types-greenlet

Installing types-greenlet

Before you install

Low friction installation with no runtime dependencies. Actively maintained as part of the typeshed project, with recent releases and ongoing commits.

License in practice

Licensed under Apache-2.0 (permissive), allowing use in most projects without significant legal constraints.

Quickstart

pip install types-greenlet

# In your code, type checkers will now understand greenlet imports:
from greenlet import greenlet

def worker():
    pass

g = greenlet(worker)

Requires Python 3.10 or later. Only provides type information; greenlet itself must be installed separately for runtime use.

Verify before relying

  • Whether types-greenlet is automatically discovered by type checkers or requires explicit configuration in pyproject.toml or mypy.ini.
  • Coverage completeness: which greenlet APIs are fully annotated versus partially or not covered.

Package facts

License Apache-2.0 (permissive)
Python support supports the current Python release (>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies none
Maintenance actively maintained — 88 days since the last release
Last repo commit
First released
Downloads 724,563/month — #5,222 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: types_greenlet-3.5.0.20260518-py3-none-any.whl

Programming Language :: Python :: 3Typing :: Stubs Only

Tags

greenlet type stubsgreenlet typing annotationstype checking greenlet codemypy greenlet supportpyright greenlet stubsgreenlet type hintsstatic type checking coroutines
type-stubsstatic-analysis

More Software Development packages