Registry /
type-stubs / mypy-boto3-codepipeline
This library provides type annotations (stubs) for the `boto3` AWS CodePipeline client. It enables static type checking for `boto3` usage with tools like `mypy`, enhancing developer productivity and catching potential errors at compile time. Maintained by the `mypy-boto3-builder` project, it receives frequent updates to align with new `boto3` releases and `botocore` service definitions.
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
py 3.10
8/10 runs
8/10 runs
py 3.11
8/10 runs
8/10 runs
py 3.12
8/10 runs
8/10 runs
py 3.13
8/10 runs
8/10 runs
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
from mypy_boto3_codepipeline import CodePipelineClient
This quickstart demonstrates how to use `mypy-boto3-codepipeline` to add static type checking to your `boto3` CodePipeline client interactions. The `TYPE_CHECKING` guard ensures that the stub imports are only processed by type checkers like `mypy` and are not loaded during runtime, improving application startup performance.
import boto3
from typing import TYPE_CHECKING, List, Dict, Any
# Guard type imports for runtime efficiency
if TYPE_CHECKING:
from mypy_boto3_codepipeline.client import CodePipelineClient
from mypy_boto3_codepipeline.type_defs import ListPipelinesOutputTypeDef
def get_codepipeline_pipelines() -> List[str]:
# The actual runtime client from boto3
client: CodePipelineClient = boto3.client("codepipeline")
# The type checker knows the methods available on 'client'
response: ListPipelinesOutputTypeDef = client.list_pipelines()
pipeline_names = [
p['name'] for p in response.get("pipelines", [])
if 'name' in p and isinstance(p['name'], str)
]
print(f"CodePipeline Pipelines: {pipeline_names}")
return pipeline_names
if __name__ == "__main__":
# This example does not require specific credentials beyond default AWS configuration.
# Ensure boto3 is configured (e.g., via AWS_ACCESS_KEY_ID, AWS_SECRET_ACCESS_KEY,
# or ~/.aws/credentials, or IAM roles).
try:
pipelines = get_codepipeline_pipelines()
except Exception as e:
print(f"Error fetching CodePipeline pipelines: {e}")
print("Please ensure your AWS credentials and region are configured.")
Upgrade
Version history
Breaking-change detection hasn't run for this library yet.
Audit
Security & dependencies
CVE tracking and dependency tree are planned for a later release.