Skip to content

MainframeModernization module#

Index > MainframeModernization

Auto-generated documentation for MainframeModernization type annotations stubs module mypy-boto3-m2.

How to install#

VSCode extension#

Add AWS Boto3 extension to your VSCode and run AWS boto3: Quick Start command.

Click Modify and select boto3 common and MainframeModernization.

From PyPI with pip#

Install boto3-stubs for MainframeModernization service.

# install with boto3 type annotations
python -m pip install 'boto3-stubs[m2]'

# Lite version does not provide session.client/resource overloads
# it is more RAM-friendly, but requires explicit type annotations
python -m pip install 'boto3-stubs-lite[m2]'

# standalone installation
python -m pip install mypy-boto3-m2

How to uninstall#

python -m pip uninstall -y mypy-boto3-m2


Code samples can be found in Examples.


Type annotations and code completion for boto3.client("m2") as MainframeModernizationClient boto3 documentation

# MainframeModernizationClient usage example

from boto3.session import Session

from mypy_boto3_m2.client import MainframeModernizationClient

def get_client() -> MainframeModernizationClient:
    return Session().client("m2")


Type annotations and code completion for paginators from boto3.client("m2").get_paginator("...").

# ListApplicationVersionsPaginator usage example

from boto3.session import Session

from mypy_boto3_m2.paginator import ListApplicationVersionsPaginator

def get_list_application_versions_paginator() -> ListApplicationVersionsPaginator:
    return Session().client("m2").get_paginator("list_application_versions"))


Type annotations for literals used in methods and schemas.

# ApplicationDeploymentLifecycleType usage example

from mypy_boto3_m2.literals import ApplicationDeploymentLifecycleType

def get_value() -> ApplicationDeploymentLifecycleType:
    return "Deployed"

Typed dictionaries#

Type annotations for typed dictionaries used in methods and schema.

# AlternateKeyTypeDef usage example

from mypy_boto3_m2.type_defs import AlternateKeyTypeDef

def get_value() -> AlternateKeyTypeDef:
    return {
        "length": ...,
        "offset": ...,