mypy-boto3-wisdom
mypy-boto3-wisdom provides type annotations for the `boto3` ConnectWisdomService, ensuring static type checking and improved IDE auto-completion for AWS SDK operations. It is currently at version 1.42.3 and is actively maintained with frequent updates tied to `boto3` releases and the `mypy-boto3-builder` project.
Warnings
- breaking Python 3.8 support was removed with `mypy-boto3-builder` version 8.12.0. Users on Python 3.8 or older must upgrade their Python version to continue receiving updates.
- breaking The `mypy-boto3` ecosystem migrated to PEP 561 compatible packages in `mypy-boto3-builder` version 8.12.0. This fundamentally changes how type checkers discover and use the stubs.
- breaking Starting with `mypy-boto3-builder` version 8.9.0, certain TypeDef names for packed method arguments were shortened (e.g., `CreateDistributionRequestRequestTypeDef` became `CreateDistributionRequestTypeDef`). This can break existing type annotations if your code explicitly referenced these TypeDefs.
- gotcha PyCharm users may experience slow performance or high CPU usage due to an issue with `Literal` overloads (PyCharm issue PY-40997) when using `boto3-stubs` or `mypy-boto3-*` packages. It is recommended to use `boto3-stubs-lite` (if applicable) or rely on external type checkers like Mypy/Pyright.
Install
-
pip install mypy-boto3-wisdom
Imports
- ConnectWisdomServiceClient
from mypy_boto3_wisdom import ConnectWisdomServiceClient
Quickstart
import boto3
from boto3.session import Session
from mypy_boto3_wisdom import ConnectWisdomServiceClient
def get_wisdom_client() -> ConnectWisdomServiceClient:
session = Session()
client: ConnectWisdomServiceClient = session.client("wisdom")
return client
# Example usage:
wisdom_client = get_wisdom_client()
response = wisdom_client.list_assistants()
print(response)