Registry /
type-stubs / mypy-boto3-codeguru-security
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.910 runs
installs and imports cleanly · install 0.0s · import 0.592s · 51.9MB
glibcpy 3.10–3.910 runs
installs and imports cleanly · install 3.6s · import 0.550s · 52MB
50MB installed
● package 50MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
CodeGuruSecurityClient
✓ from mypy_boto3_codeguru_security.client import CodeGuruSecurityClient
Import the specific client type for explicit type hinting of the boto3 client object.
ListFindingsResponseTypeDef
✓ from mypy_boto3_codeguru_security.type_defs import ListFindingsResponseTypeDef
Import specific TypedDicts for precise type hinting of API responses or request parameters. These are nested under `type_defs`.
This example demonstrates how to create a `boto3` client for CodeGuruSecurity with explicit type hints and then use it to list findings, leveraging paginators. To run this, ensure `boto3` and `mypy-boto3-codeguru-security` are installed, and your AWS credentials are configured (e.g., via environment variables or AWS CLI configuration).
import boto3
from mypy_boto3_codeguru_security.client import CodeGuruSecurityClient
from mypy_boto3_codeguru_security.type_defs import ListFindingsResponseTypeDef
def get_codeguru_security_client() -> CodeGuruSecurityClient:
"""Initializes and returns a CodeGuruSecurity client with type hints."""
# boto3 automatically picks up credentials from environment variables or IAM roles
# For local testing, ensure AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY, AWS_SESSION_TOKEN (optional) are set.
return boto3.client("codeguru-security")
def list_all_findings(client: CodeGuruSecurityClient) -> None:
"""Lists CodeGuruSecurity findings and prints their IDs."""
print("Listing CodeGuruSecurity findings...")
paginator = client.get_paginator("list_findings")
page_iterator = paginator.paginate()
found_findings = 0
for page in page_iterator:
page_data: ListFindingsResponseTypeDef = page
for finding in page_data.get("findings", []):
print(f" Finding ID: {finding.get('id')}")
found_findings += 1
if found_findings == 0:
print(" No findings found.")
else:
print(f"Found {found_findings} findings.")
if __name__ == "__main__":
# Example usage
codeguru_client = get_codeguru_security_client()
list_all_findings(codeguru_client)
Debug
Known issues
breakingThe `mypy-boto3-builder` (which generates this stub package) dropped support for Python 3.8 in version 8.12.0. All generated stub packages now require Python 3.9 or newer.fixUpgrade your Python environment to 3.9 or higher.
affects: mypy-boto3-builder >= 8.12.0 (affecting mypy-boto3-codeguru-security >= 1.42.0)
gotchaThis package provides only type stubs and does not install `boto3` itself. You must explicitly install `boto3` alongside this stub package for your application to function at runtime.fixEnsure `boto3` is included in your project's dependencies and installed (e.g., `pip install boto3 mypy-boto3-codeguru-security`).
affects: All versions
breakingFor advanced users who directly import `TypeDef` objects, `mypy-boto3-builder` version 8.9.0 introduced breaking changes to TypeDef naming conventions (e.g., `CreateDistributionRequestRequestTypeDef` -> `CreateDistributionRequestTypeDef`).fixReview your imports of specific `TypeDef` classes and update their names according to the new conventions (e.g., look for removed `Request` suffixes or shifted `Extra` postfixes).
affects: mypy-boto3-builder >= 8.9.0 (affecting mypy-boto3-codeguru-security >= 1.39.0)
gotchaAWS service names can occasionally change or be deprecated (e.g., 'sms-voice' to 'pinpoint-sms-voice' in older builder versions). While 'codeguru-security' is stable, be aware that the specific stub package you need might change if the underlying AWS service name evolves.fixAlways refer to the official `mypy-boto3` documentation or `boto3` documentation for the latest service names and corresponding stub package names if you encounter import errors for specific services.
affects: All versions (potential for future changes)
Upgrade
Version history
1.43.0latest on PyPI · released Apr 29, 2026
Audit
Dependencies
boto3requiredThis package provides type stubs for boto3's CodeGuruSecurity service. boto3 itself is a runtime dependency for using the AWS SDK.
mypyoptionalThis package is designed to be consumed by static type checkers like Mypy to provide type safety for boto3 operations.