{"id":23179,"library":"types-boto3-comprehend","title":"types-boto3-comprehend","description":"Type annotations for boto3 Comprehend 1.43.0 service, generated with mypy-boto3-builder 8.12.0. Version 1.43.0 supports Python >=3.9. Provides static type checking for Amazon Comprehend client operations, service resources, and paginators. Part of the mypy-boto3-builder ecosystem. Release cadence follows boto3 service updates.","status":"active","version":"1.43.0","language":"python","source_language":"en","source_url":"https://github.com/youtype/mypy_boto3_builder","tags":["boto3","type-annotations","comprehend","aws","stubs","mypy"],"install":[{"cmd":"pip install types-boto3-comprehend","lang":"bash","label":"Install types for Comprehend"}],"dependencies":[{"reason":"Required for TypedDict and other type constructs on older Python versions (though Python >=3.9 minimizes need).","package":"typing-extensions","optional":false}],"imports":[{"note":"","wrong":"","symbol":"ComprehendClient","correct":"from mypy_boto3_comprehend import ComprehendClient"},{"note":"","wrong":"","symbol":"ComprehendServiceResource","correct":"from mypy_boto3_comprehend import ComprehendServiceResource"},{"note":"types_boto3_comprehend is a PyPI package name, not a module. The actual module is mypy_boto3_comprehend.","wrong":"from types_boto3_comprehend.paginator import ...","symbol":"Paginator","correct":"from mypy_boto3_comprehend.paginator import ..."}],"quickstart":{"code":"import boto3\nfrom mypy_boto3_comprehend import ComprehendClient\n\nclient: ComprehendClient = boto3.client('comprehend', region_name='us-east-1')\n# Example: detect dominant language\nresponse = client.detect_dominant_language(Text='Hello world')\nprint(response['Languages'])","lang":"python","description":"Type-annotated Comprehend client usage. Assumes boto3 and valid AWS credentials are configured."},"warnings":[{"fix":"Upgrade to Python 3.9+.","message":"Python 3.8 support removed since mypy-boto3-builder 8.12.0 (v1.43.0). Requires Python >=3.9.","severity":"breaking","affected_versions":">=1.43.0"},{"fix":"Use 'from mypy_boto3_comprehend import ...' instead.","message":"The import module is 'mypy_boto3_comprehend', not 'types_boto3_comprehend'. The PyPI package name differs from the Python module name. Many users mistakenly try to import from the package name.","severity":"gotcha","affected_versions":"all"},{"fix":"Check the generated TypeDef names after upgrading; use IDE type hints to discover new names.","message":"TypeDef names may change between major versions of mypy-boto3-builder (e.g., shortened names in v8.9.0). In Comprehend, this affects some nested Request/Response TypeDefs.","severity":"deprecated","affected_versions":"before 1.43.0? (builder 8.9.0+)"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Install the correct package: pip install types-boto3-comprehend. Ensure your type checker configuration includes the package (e.g., mypy: follows imports).","cause":"IDE or type checker is looking at the wrong stub package, possibly due to incorrect deployment of stubs or missing 'mypy_boto3_comprehend' in type-checker paths.","error":"Cannot find reference 'ComprehendClient' in '__init__.py'"},{"fix":"Install the package: pip install types-boto3-comprehend. The import module is 'mypy_boto3_comprehend'.","cause":"The user tried to import 'mypy_boto3_comprehend' without installing the package, or confusion between PyPI package name and module name.","error":"ModuleNotFoundError: No module named 'mypy_boto3_comprehend'"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}