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.660s · 52.3MB
glibcpy 3.10–3.95 runs
installs and imports cleanly · install 3.8s · import 0.610s · 53MB
51MB installed
● package 51MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
Macie2Client
✓ from mypy_boto3_macie2 import Macie2Client
Main client class for the Macie2 service.
ListFindingsRequestRequestTypeDef
✓ from mypy_boto3_macie2.type_defs import ListFindingsRequestRequestTypeDef
Import TypeDef objects for request/response structures.
FindingStatusType
✓ from mypy_boto3_macie2.literals import FindingStatusType
Import literal types for specific enum-like values.
Demonstrates how to initialize a type-hinted Macie2 client and use a type-checked request parameter, allowing MyPy to validate method calls and data structures.
import boto3
from mypy_boto3_macie2 import Macie2Client
from mypy_boto3_macie2.type_defs import ListFindingsRequestRequestTypeDef
def analyze_macie_findings() -> None:
# mypy will now correctly type-check the client
client: Macie2Client = boto3.client("macie2")
# Example of a type-checked request parameter
request_params: ListFindingsRequestRequestTypeDef = {
"maxResults": 10
}
try:
response = client.list_findings(**request_params)
print(f"Found {len(response.get('findingIds', []))} Macie findings.")
except Exception as e:
print(f"Error listing Macie findings: {e}")
if __name__ == "__main__":
analyze_macie_findings()
Debug
Known issues
breakingSupport for Python 3.8 was removed in version 8.12.0 of the mypy-boto3-builder. Users on Python 3.8 will need to upgrade to Python 3.9 or newer to use current versions of mypy-boto3-macie2.fixUpgrade your Python environment to 3.9 or newer.
affects: >=8.12.0 (builder)
breakingAll packages migrated to PEP 561 compliant distribution. This change (introduced in builder version 8.12.0) might affect how type checkers discover the packages if you had specific configurations relying on older distribution methods.fixEnsure your `mypy` configuration is up-to-date and correctly pointing to your virtual environment or site-packages. Reinstalling the package may resolve discovery issues.
affects: >=8.12.0 (builder)
breakingSome TypeDef naming conventions were changed (e.g., `CreateDistributionRequestRequestTypeDef` to `CreateDistributionRequestTypeDef`). This impacts direct references to these generated type definition classes in your code.fixReview the `type_defs` module for the affected service and update the TypeDef class names in your code accordingly.
affects: >=8.9.0 (builder)
gotchaThis library only provides type stubs; `boto3` must be installed separately as a runtime dependency. Without `boto3` installed, your application will fail at runtime despite passing type checks.fixEnsure `boto3` is installed in your environment alongside `mypy-boto3-macie2` using `pip install boto3`.
affects: All
gotchaFor type checking a specific AWS service, you must install the corresponding `mypy-boto3-*` package (e.g., `mypy-boto3-macie2`). Installing only `boto3-stubs` (the meta-package) or `boto3` will not provide specific service client type annotations.fixInstall the exact stub package for each AWS service you are using type checking for (e.g., `pip install mypy-boto3-macie2`).
affects: All
Upgrade
Version history
1.43.0latest on PyPI · released Apr 29, 2026
Audit
Dependencies
boto3requiredRuntime dependency for the AWS SDK for Python, required to use the type-annotated client. Not an explicit install_requires of the stub package itself.
mypyoptionalStatic type checker required to utilize the type annotations provided by this library.