Skip to content
This repository was archived by the owner on Mar 23, 2026. It is now read-only.

Commit 93d96f4

Browse files
add boto3-stubs to development deps (#8064)
1 parent e1b8023 commit 93d96f4

3 files changed

Lines changed: 14 additions & 2 deletions

File tree

Makefile

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,9 @@ install-test-only: venv
4747
install-dev: venv ## Install developer requirements into venv
4848
$(VENV_RUN); $(PIP_CMD) install $(PIP_OPTS) -e ".[cli,runtime,test,dev]"
4949

50+
install-dev-types: venv ## Install developer requirements incl. type hints into venv
51+
$(VENV_RUN); $(PIP_CMD) install $(PIP_OPTS) -e ".[cli,runtime,test,dev,typehint]"
52+
5053
install: install-dev entrypoints ## Install full dependencies into venv
5154

5255
entrypoints: ## Run setup.py develop to build entry points
Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,17 @@
1+
"""
2+
A simple script to generate a pip install command for all boto3-stubs packages we're currently using in LocalStack
3+
"""
4+
15
import os
26
import re
37

48
if __name__ == "__main__":
59
with open(
6-
os.path.join(os.path.dirname(__file__), "../localstack/testing/pytest/fixtures.py")
10+
os.path.join(os.path.dirname(__file__), "../localstack/utils/aws/client_types.py")
711
) as fd:
812
content = fd.read()
9-
result = re.findall(r"\smypy_boto3_([a-z]+)\s", content)
13+
result = re.findall(r"\smypy_boto3_([a-z0-9_]+)\s", content)
14+
result = [r.replace("_", "-") for r in set(result)]
1015
result.sort()
1116

1217
print(f'pip install "boto3-stubs[{",".join(result)}]"', end="")

setup.cfg

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,3 +129,7 @@ dev =
129129
# enables flake8 configuration through pyproject.toml
130130
pyproject-flake8>=6.0.0.post1
131131
rstr>=3.2.0
132+
133+
# not strictly necessary for development, but provides type hint support for a better developer experience
134+
typehint =
135+
boto3-stubs[acm,amplify,apigateway,apigatewayv2,appconfig,appsync,athena,autoscaling,backup,batch,ce,cloudformation,cloudfront,cloudtrail,cloudwatch,codecommit,cognito-identity,cognito-idp,dms,docdb,dynamodb,dynamodbstreams,ec2,ecr,ecs,efs,eks,elasticache,elasticbeanstalk,elbv2,emr,es,events,firehose,fis,glacier,glue,iam,iot,iot-data,iotanalytics,iotwireless,kafka,kinesis,kinesisanalytics,kinesisanalyticsv2,kms,lakeformation,lambda,logs,mediastore,mq,mwaa,neptune,opensearch,organizations,pi,qldb,qldb-session,rds,rds-data,redshift,redshift-data,resource-groups,resourcegroupstaggingapi,route53,route53resolver,s3,s3control,sagemaker,sagemaker-runtime,secretsmanager,serverlessrepo,servicediscovery,ses,sesv2,sns,sqs,ssm,stepfunctions,sts,timestream-query,timestream-write,transcribe,xray]

0 commit comments

Comments
 (0)