{"id":3006,"library":"mypy-boto3-acm-pca","title":"mypy-boto3-acm-pca","description":"mypy-boto3-acm-pca provides type annotations (stubs) for the boto3 ACMPCA service, enabling static type checking with tools like MyPy. It is part of the broader mypy-boto3-builder project, which generates stubs for all AWS services. The current version is 1.42.3 and new versions are released regularly to keep pace with boto3 updates.","status":"active","version":"1.42.3","language":"en","source_language":"en","source_url":"https://github.com/youtype/mypy_boto3_builder","tags":["mypy","boto3","aws","type-hints","stubs","acmpca","aws-sdk"],"install":[{"cmd":"pip install mypy-boto3-acm-pca boto3","lang":"bash","label":"Install with boto3"}],"dependencies":[{"reason":"This package provides type stubs for boto3; boto3 itself is required for runtime execution.","package":"boto3","optional":false}],"imports":[{"symbol":"ACMPCAClient","correct":"from mypy_boto3_acm_pca.client import ACMPCAClient"},{"note":"Recommended pattern for conditional import of type stubs to avoid runtime dependency.","symbol":"ACMPCAClient","correct":"from typing import TYPE_CHECKING\n\nif TYPE_CHECKING:\n    from mypy_boto3_acm_pca.client import ACMPCAClient"}],"quickstart":{"code":"import boto3\nfrom typing import TYPE_CHECKING\n\n# The actual boto3 client is used at runtime\nsession = boto3.Session()\nclient = session.client(\"acm-pca\")\n\n# For type checking only, use conditional import\nif TYPE_CHECKING:\n    from mypy_boto3_acm_pca.client import ACMPCAClient\n\n    # Type-hint the client for static analysis\n    typed_client: ACMPCAClient = client\n    \n    # Example usage with type-hinted client\n    # These calls will be type-checked by MyPy\n    response = typed_client.list_certificate_authorities(\n        MaxResults=5,\n        Status='ACTIVE' \n    )\n    print(response.get('CertificateAuthorities'))\nelse:\n    # Runtime execution will use the untyped client\n    response = client.list_certificate_authorities(MaxResults=5)\n    print(response.get('CertificateAuthorities'))","lang":"python","description":"Initializes a boto3 ACMPCA client and demonstrates how to use the type annotations for static analysis while maintaining standard boto3 runtime behavior."},"warnings":[{"fix":"Upgrade your Python environment to 3.9 or newer.","message":"Starting with `mypy-boto3-builder` version 8.12.0, support for Python 3.8 has been removed across all `mypy-boto3` packages. This library (v1.42.3) requires Python >= 3.9.","severity":"breaking","affected_versions":">=8.12.0 (builder), >=1.42.0 (package)"},{"fix":"Review your explicit TypeDef imports and adjust names according to the new generation rules. Consult the source code or rebuild your project to identify new TypeDef names.","message":"In `mypy-boto3-builder` version 8.9.0, there were changes to how TypeDef names are generated, including shortening packed method argument TypeDefs and reordering postfixes for conflicting names. If you were directly importing and using these generated TypeDefs, your code may break.","severity":"breaking","affected_versions":">=8.9.0 (builder), specific service packages generated with this builder version"},{"fix":"Always install `boto3` (e.g., `pip install boto3 mypy-boto3-acm-pca`).","message":"This package provides only type stubs. The `boto3` library itself is still required at runtime for your application to function correctly. Ensure `boto3` is installed alongside `mypy-boto3-acm-pca`.","severity":"gotcha","affected_versions":"All versions"},{"fix":"Update your `mypy` installation (`pip install --upgrade mypy`) and ensure your `mypy` configuration (`pyproject.toml`, `mypy.ini`) correctly points to site-packages or doesn't exclude stub files.","message":"The `mypy-boto3` project migrated to PEP 561 compliant packages with `mypy-boto3-builder` version 8.12.0. While this is a standard for type stubs, older `mypy` versions or custom `mypy` configurations might struggle to locate the stubs correctly. Ensure `mypy` is up-to-date and configured to find installed packages.","severity":"gotcha","affected_versions":">=8.12.0 (builder), >=1.42.0 (package)"}],"env_vars":null,"last_verified":"2026-04-11T00:00:00.000Z","next_check":"2026-07-10T00:00:00.000Z"}