Registry /
type-stubs / mypy-boto3-dataexchange
Install & Compatibility
Where this runs
tested against v1.43.0 · 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
muslpy 3.10–3.95 runs
installs and imports cleanly · install 0.0s · import 0.628s · 52MB
glibcpy 3.10–3.95 runs
installs and imports cleanly · install 3.9s · import 0.582s · 53MB
50MB installed
● package 50MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
DataExchangeClient
✓ from mypy_boto3_dataexchange.client import DataExchangeClient
This imports the typed client for DataExchange, enabling type-checking and auto-completion for boto3.client('dataexchange').
This quickstart demonstrates how to obtain a type-hinted DataExchange client using `mypy-boto3-dataexchange` and perform a basic operation like listing data sets. The `TYPE_CHECKING` block ensures that the type stub is only imported during type-checking, avoiding runtime dependencies. Remember to configure your AWS credentials.
import boto3
from typing import TYPE_CHECKING
if TYPE_CHECKING:
from mypy_boto3_dataexchange.client import DataExchangeClient
# Ensure AWS credentials are set up (e.g., via environment variables, ~/.aws/credentials)
# For example, export AWS_ACCESS_KEY_ID='YOUR_ACCESS_KEY_ID'
# export AWS_SECRET_ACCESS_KEY='YOUR_SECRET_ACCESS_KEY'
# export AWS_DEFAULT_REGION='us-east-1'
def get_dataexchange_client() -> DataExchangeClient:
"""Returns a type-hinted DataExchange client."""
client: DataExchangeClient = boto3.client("dataexchange")
return client
if __name__ == "__main__":
dataexchange_client = get_dataexchange_client()
print(f"Client type: {type(dataexchange_client)}")
try:
# Example: List your Data Exchange data sets
response = dataexchange_client.list_data_sets()
print(f"Successfully listed {len(response.get('DataSets', []))} data sets.")
# Accessing typed attributes will be auto-completed and type-checked
for dataset in response.get('DataSets', []):
print(f" - DataSetId: {dataset.get('DataSetId')}, Name: {dataset.get('Name')}")
except Exception as e:
print(f"Error listing data sets: {e}")
Debug
Known issues
breakingSupport for Python 3.8 has been removed in `mypy-boto3-builder` version 8.12.0. Projects using `mypy-boto3-dataexchange` (and other `mypy-boto3` packages) must use Python 3.9 or newer.fixUpgrade your Python environment to 3.9 or a later version.
affects: mypy-boto3-builder >= 8.12.0
breakingVersion 8.9.0 of `mypy-boto3-builder` introduced breaking changes in TypeDef naming conventions. Specifically, TypeDefs for packed method arguments use shorter names (e.g., `CreateDistributionRequestRequestTypeDef` -> `CreateDistributionRequestTypeDef`), and conflicting `Extra` postfixes were moved (e.g., `CreateDistributionExtraRequestTypeDef` -> `CreateDistributionRequestExtraTypeDef`). This impacts explicit type annotations.fixReview and update explicit TypeDef imports and usages in your codebase according to the new naming conventions. Refer to the specific service documentation for updated TypeDef names.
affects: mypy-boto3-builder >= 8.9.0
gotchaPyCharm users might experience slow performance or high CPU usage due to literal overloads. It is recommended to use `boto3-stubs-lite` packages or disable PyCharm's internal type checker and rely on `mypy` or `pyright` instead.fixConsider installing the `*-lite` version of the stubs (e.g., `boto3-stubs-lite[dataexchange]`) or configure your IDE to use external type checkers like `mypy` or `pyright`.
affects: All versions
gotchaWhen using `TYPE_CHECKING` for conditional imports with `pylint`, it may complain about undefined variables in the runtime block. To avoid this, set types to `object` in the `else` branch of the `TYPE_CHECKING` block.fixImplement a pattern like `if TYPE_CHECKING: from mypy_boto3_dataexchange.client import DataExchangeClient else: DataExchangeClient = object`.
affects: All versions
Upgrade
Version history
1.43.0latest on PyPI · released Apr 29, 2026
Audit
Dependencies
boto3requiredRuntime dependency for the AWS SDK, which these stubs provide type hints for.
mypyoptionalThe primary static type checker these annotations are designed for.
pythonrequiredRequires Python 3.9 or newer.