Type annotations for boto3.ConfigService 1.14.44 service, generated by mypy-boto3-buider 2.2.0
Project description
mypy-boto3-config
Type annotations for boto3.ConfigService 1.14.44 service compatible with mypy, VSCode, PyCharm and other tools.
Generated by mypy-boto3-buider 2.2.0.
More information can be found on boto3-stubs page.
How to install
Make sure you have mypy installed and activated in your IDE.
Install boto3-stubs
for ConfigService
service.
python -m pip install boto3-stubs[config]
How to use
Client annotations
ConfigServiceClient
provides annotations for boto3.client("config")
.
import boto3
from mypy_boto3_config import ConfigServiceClient
from mypy_boto3_config.paginator import (
DescribeAggregateComplianceByConfigRulesPaginator,
DescribeAggregationAuthorizationsPaginator,
DescribeComplianceByConfigRulePaginator,
DescribeComplianceByResourcePaginator,
DescribeConfigRuleEvaluationStatusPaginator,
DescribeConfigRulesPaginator,
DescribeConfigurationAggregatorSourcesStatusPaginator,
DescribeConfigurationAggregatorsPaginator,
DescribePendingAggregationRequestsPaginator,
DescribeRemediationExecutionStatusPaginator,
DescribeRetentionConfigurationsPaginator,
GetAggregateComplianceDetailsByConfigRulePaginator,
GetComplianceDetailsByConfigRulePaginator,
GetComplianceDetailsByResourcePaginator,
GetResourceConfigHistoryPaginator,
ListAggregateDiscoveredResourcesPaginator,
ListDiscoveredResourcesPaginator,
)
from mypy_boto3_config.type_defs import AccountAggregationSourceTypeDef, ...
client: ConfigServiceClient = boto3.client("config")
# now client usage is checked by mypy and IDE should provide code auto-complete
# works for session as well
session = boto3.session.Session(region="us-west-1")
session_client: ConfigServiceClient = session.client("config")
Paginators annotations
mypy_boto3_config.paginator
module contains type annotations for all paginators.
client: ConfigServiceClient = boto3.client("config")
# Explicit type annotations are optional here
# Type should be correctly discovered by mypy and IDEs
# VSCode requires explicit type annotations
describe_aggregate_compliance_by_config_rules_paginator: DescribeAggregateComplianceByConfigRulesPaginator = client.get_paginator("describe_aggregate_compliance_by_config_rules")
describe_aggregation_authorizations_paginator: DescribeAggregationAuthorizationsPaginator = client.get_paginator("describe_aggregation_authorizations")
describe_compliance_by_config_rule_paginator: DescribeComplianceByConfigRulePaginator = client.get_paginator("describe_compliance_by_config_rule")
describe_compliance_by_resource_paginator: DescribeComplianceByResourcePaginator = client.get_paginator("describe_compliance_by_resource")
describe_config_rule_evaluation_status_paginator: DescribeConfigRuleEvaluationStatusPaginator = client.get_paginator("describe_config_rule_evaluation_status")
describe_config_rules_paginator: DescribeConfigRulesPaginator = client.get_paginator("describe_config_rules")
describe_configuration_aggregator_sources_status_paginator: DescribeConfigurationAggregatorSourcesStatusPaginator = client.get_paginator("describe_configuration_aggregator_sources_status")
describe_configuration_aggregators_paginator: DescribeConfigurationAggregatorsPaginator = client.get_paginator("describe_configuration_aggregators")
describe_pending_aggregation_requests_paginator: DescribePendingAggregationRequestsPaginator = client.get_paginator("describe_pending_aggregation_requests")
describe_remediation_execution_status_paginator: DescribeRemediationExecutionStatusPaginator = client.get_paginator("describe_remediation_execution_status")
describe_retention_configurations_paginator: DescribeRetentionConfigurationsPaginator = client.get_paginator("describe_retention_configurations")
get_aggregate_compliance_details_by_config_rule_paginator: GetAggregateComplianceDetailsByConfigRulePaginator = client.get_paginator("get_aggregate_compliance_details_by_config_rule")
get_compliance_details_by_config_rule_paginator: GetComplianceDetailsByConfigRulePaginator = client.get_paginator("get_compliance_details_by_config_rule")
get_compliance_details_by_resource_paginator: GetComplianceDetailsByResourcePaginator = client.get_paginator("get_compliance_details_by_resource")
get_resource_config_history_paginator: GetResourceConfigHistoryPaginator = client.get_paginator("get_resource_config_history")
list_aggregate_discovered_resources_paginator: ListAggregateDiscoveredResourcesPaginator = client.get_paginator("list_aggregate_discovered_resources")
list_discovered_resources_paginator: ListDiscoveredResourcesPaginator = client.get_paginator("list_discovered_resources")
Typed dictionations
mypy_boto3_config.type_defs
module contains structures and shapes assembled
to typed dictionaries for additional type checking.
def get_structure() -> AccountAggregationSourceTypeDef:
return {
...
}
Dynamic type annotations
mypy_boto3
command generates boto3.client/resource
type annotations for
mypy_boto3_config
and other installed services.
# Run this command after you add or remove service packages
python -m mypy_boto3
Generated type annotations provide overloads for boto3.client
and boto3.resource
,
boto3.Session.client
and boto3.Session.resource
functions,
so explicit type annotations are not needed.
mypy
supports function overloads as expectedPyCharm
also supports function overloads, but consumes a lot of RAM, use carefully if you have many services installedVSCode
does not currently support function overloads, use explicit type annotations
# Type is discovered correctly by mypy and PyCharm
# VSCode still needs explicit type annotations
client = boto3.client("config")
session_client = boto3.Session().client("config")
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for mypy-boto3-config-1.14.44.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 10796ad8f49f34c067c287368156e42cde776ec89f713abb580796fa24a86386 |
|
MD5 | ca53c23ae69b6fa44c8725dbfc583ae4 |
|
BLAKE2b-256 | 5c1c90245cf675ec724d2e24880dd9bdfad0bb3b860b48dccad27718b9b86677 |
Hashes for mypy_boto3_config-1.14.44.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2d353456ea0b5111645fc9b3ac3dee1f5896dd6c48624c18df0d883dd096654d |
|
MD5 | 2eb8859f6912958367da662fddca72f7 |
|
BLAKE2b-256 | 2611abfc5972048133c84f3a6c3bdbe68bc446f266b723bb81959300200b4a71 |