skillfed

types-pyserial

Typing stubs for pyserial

types-pyserial v3.5.0.20260712 1.4M downloads/30d#3,912 on PyPI37
Permissive license Apache-2.0 Active released

What it is and what it does

types-pyserial is a type stub package that adds static type information to the pyserial library. It allows Python type checkers like mypy and pyright to understand and validate code that uses pyserial's serial port APIs, catching type errors before runtime. The stubs are maintained as part of the typeshed project and are kept in sync with pyserial 3.5.* releases.

This package contains no runtime code—it only provides type annotations. You install it alongside pyserial to enable type checking in your IDE and CI/CD pipelines. It requires Python 3.10 or later and has no external dependencies, making it a lightweight addition to any project that already uses pyserial.

Use it for:

  • Enable type checkers to validate code that uses pyserial for serial port communication.
  • Catch type mismatches in serial port configuration at development time.
  • Add IDE autocomplete and inline type hints for pyserial methods and properties.
  • Enforce type safety in embedded systems or IoT projects that communicate over serial interfaces.
  • Integrate serial port code into a strictly typed Python codebase without disabling type checking.

Worth the install?

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

Provides type hints for the pyserial library, enabling static type checkers like mypy and pyright to validate code that uses serial port communication.

Yes, if you use pyserial and want static type checking. Install it alongside pyserial to enable type validation in mypy or pyright with zero runtime overhead. No security concerns, actively maintained, and permissively licensed. Only skip it if you don't use a type checker or don't use pyserial.

Install

types-pyserial on PyPI

pip

pip install types-pyserial

uv

uv add types-pyserial

poetry

poetry add types-pyserial

Installing types-pyserial

Before you install

Low friction installation with no runtime dependencies. Actively maintained as part of the typeshed project with recent updates.

License in practice

Apache-2.0 permissive license allows use in most projects without restriction.

Quickstart

pip install types-pyserial

# Type checkers will now understand pyserial code in your project

Requires Python 3.10 or later. Only useful when used alongside the actual pyserial package and a compatible type checker.

Verify before relying

  • Whether these stubs cover all pyserial 3.5.* APIs or only a subset of the public interface.
  • Compatibility with type checkers other than mypy 2.2.0 and pyright 1.1.411.
  • Whether installing types-pyserial automatically satisfies type checking for existing pyserial code without additional configuration.

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 — 33 days since the last release
Last repo commit
First released
Downloads 1,431,771/month — #3,912 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: types_pyserial-3.5.0.20260712-py3-none-any.whl

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

Tags

type stubs pyserialpyserial type hintsserial port typingstatic type checking serialpyserial type checkingtype annotations serialtypeshed stubs
type-stubsserial-communication

More Software Development packages