Registry / type-stubs / mypy-boto3-rds

mypy-boto3-rds

JSON →
library1.43.62pypypi✓ verified 24d ago

mypy-boto3-rds provides type annotations for the AWS boto3 RDS service, enhancing static analysis and code completion for `boto3.client("rds")` and related service components. It is automatically generated by `mypy-boto3-builder` and aims to synchronize its version with the corresponding `boto3` release, offering up-to-date type hints for mypy, pyright, and various IDEs. The current version is 1.42.75, reflecting its alignment with `boto3`.

pip install mypy-boto3-rds
INSTALL
IMPORT
SIG · MYPY-BOTO3-RDS
M
mypy-boto3-rds
type-stubspythonv1.43.62
Install
3.5s avg
Import
Disk
19MB
Pass rate
10/ 10
Env Coverage10 / 10
glibc
3.93.13
musl
3.93.13
Install & Compatibility
Where this runs
tested against v1.43.62 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
py 3.103.910 runs
installs and imports cleanly · install 0.0s · import 0.000s · 20.8MB
glibc
py 3.103.910 runs
installs and imports cleanly · install 3.5s · import 0.000s · 21MB
19MB installed
● package 19MB
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

RDSClient
from mypy_boto3_rds import RDSClient
from mypy_boto3_rds import RDSClient

This quickstart demonstrates how to use `mypy-boto3-rds` for type-hinting a `boto3` RDS client. It shows explicit type annotation for the client, an API call with type-hinted response, and usage of a paginator. The `TYPE_CHECKING` block ensures that type-only imports do not affect runtime dependencies. Note that `boto3-stubs[rds]` is the idiomatic way to install type annotations for a specific service.

import boto3 from typing import TYPE_CHECKING # It is generally recommended to install 'boto3-stubs[rds]' for full integration. # For explicit type annotation of the client: if TYPE_CHECKING: from mypy_boto3_rds.client import RDSClient from mypy_boto3_rds.type_defs import DescribeDBInstancesMessageTypeDef # Example of a Paginator from mypy_boto3_rds.paginators import DescribeDBInstancesPaginator # Initialize boto3 client # For better type inference, explicitly annotate the client if TYPE_CHECKING is True client: RDSClient = boto3.client("rds") if TYPE_CHECKING else boto3.client("rds") try: # Example API call with type-hinted response response = client.describe_db_instances( MaxRecords=20 ) # The 'response' object will have type hints based on DescribeDBInstancesMessageTypeDef print(f"Found {len(response.get('DBInstances', []))} DB instances.") # Example usage of a Paginator paginator: DescribeDBInstancesPaginator = client.get_paginator("describe_db_instances") for page in paginator.paginate(): print(f"Processing page with {len(page.get('DBInstances', []))} instances.") except Exception as e: print(f"An error occurred: {e}")
Debug
Known issues
breakingPython 3.8 support has been explicitly removed in `mypy-boto3-builder` version 8.12.0 and subsequent releases. Users on Python 3.8 or older will not receive updates or new stubs.
fix
Upgrade your Python environment to 3.9 or newer. The `requires_python` field is `>=3.9`.
affects: >=8.12.0 (builder), >=1.42.x (stubs)
breakingMigration to PEP 561 compliant packages in `mypy-boto3-builder` 8.12.0. This might affect how type checkers locate stubs in complex environments or if you rely on older non-PEP 561 compliant patterns.
fix
Ensure your type checker (e.g., mypy, pyright) is up-to-date and configured to correctly resolve PEP 561 packages. Generally, this migration improves discoverability.
affects: >=8.12.0 (builder), >=1.42.x (stubs)
breakingTypeDef naming conventions may change between major `mypy-boto3-builder` versions, leading to potential breaking changes if you directly import or refer to specific TypeDef names. For example, `CreateDistributionRequestRequestTypeDef` became `CreateDistributionRequestTypeDef`.
fix
Refer to the `mypy-boto3-builder` release notes and the specific service documentation for `mypy-boto3-rds` when upgrading to check for TypeDef name changes. Update your code to use the new names.
affects: >=8.9.0 (builder)
gotchaWhen using `mypy-boto3` stubs with linters like Pylint, you might encounter 'undefined variable' errors if you directly import stub classes without a runtime equivalent. This often happens because stubs are only for type-checking and not available at runtime.
fix
Use a `from typing import TYPE_CHECKING` block. Inside this block, import the `mypy-boto3-rds` types. In the runtime path, assign `object` to these type aliases, e.g., `if TYPE_CHECKING: from mypy_boto3_rds.client import RDSClient else: RDSClient = object`.
affects: All versions
gotchaFor optimal type checking, it is crucial to ensure that the version of `mypy-boto3-rds` (or `boto3-stubs`) installed matches or is compatible with the version of `boto3` you are using at runtime. Mismatched versions can lead to incorrect type hints or missing definitions.
fix
Always pin your `boto3` and `mypy-boto3-rds` (or `boto3-stubs`) versions in your `requirements.txt` or `pyproject.toml` to ensure consistency. For example: `boto3==1.x.y` and `boto3-stubs[rds]==1.x.y`.
affects: All versions
breaking`mypy-boto3-rds` provides type stubs for `boto3`, but does not install `boto3` itself as a dependency. If `boto3` is not installed in your environment, you will encounter a `ModuleNotFoundError: No module named 'boto3'` when trying to import `boto3`.
fix
Ensure `boto3` is installed alongside `mypy-boto3-rds`. For example, `pip install boto3 mypy-boto3-rds`.
affects: All versions
Upgrade
Version history
1.43.62latest on PyPI · released Jul 31, 2026
Audit
Dependencies
boto3requiredRuntime dependency for AWS SDK functionality, stubs are for this library.
mypyoptionalStatic type checker (optional, but primary use case).
pyrightoptionalStatic type checker (optional, alternative to mypy).
Agent activity
23 hits · last 30 days
node
20
Amazon
1
OpenAI (training)
1
Resources
mypy-boto3-rds — pip install mypy-boto3-rds · libregistry