Development Status
- 5 - Production/Stable
Intended Audience
- Developers
Environment
- Console
License
- OSI Approved :: MIT License
Natural Language
- English
Operating System
- OS Independent
Programming Language
- Python :: 3
- Python :: 3.8
- Python :: 3.9
- Python :: 3.10
- Python :: 3.11
- Python :: 3.12
- Python :: 3.13
- Python :: 3.14
- Python :: 3 :: Only
- Python :: Implementation :: CPython
Typing
- Stubs Only
mypy-boto3-s3outposts

Type annotations for boto3 S3Outposts 1.40.15 compatible with VSCode, PyCharm, Emacs, Sublime Text, mypy, pyright and other tools.
Generated with mypy-boto3-builder 8.11.0.
More information can be found on boto3-stubs page and in mypy-boto3-s3outposts docs.
See how it helps you find and fix potential bugs:

- mypy-boto3-s3outposts
How to install
Generate locally (recommended)
You can generate type annotations for boto3 package locally with
mypy-boto3-builder. Use
uv for build
isolation.
- Run mypy-boto3-builder in your package root directory:
uvx --with 'boto3==1.40.15' mypy-boto3-builder - Select
boto3-stubsAWS SDK. - Add
S3Outpostsservice. - Use provided commands to install generated packages.
VSCode extension
Add
AWS Boto3
extension to your VSCode and run AWS boto3: Quick Start command.
Click Modify and select boto3 common and S3Outposts.
From PyPI with pip
Install boto3-stubs for S3Outposts service.
# install with boto3 type annotations
python -m pip install 'boto3-stubs[s3outposts]'
# 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[s3outposts]'
# standalone installation
python -m pip install mypy-boto3-s3outposts
How to uninstall
python -m pip uninstall -y mypy-boto3-s3outposts
Usage
VSCode
- Install Python extension
- Install Pylance extension
- Set
Pylanceas your Python Language Server - Install
boto3-stubs[s3outposts]in your environment:
python -m pip install 'boto3-stubs[s3outposts]'
Both type checking and code completion should now work. No explicit type
annotations required, write your boto3 code as usual.
PyCharm
⚠️ Due to slow PyCharm performance on
Literaloverloads (issue PY-40997), it is recommended to use boto3-stubs-lite until the issue is resolved.
⚠️ If you experience slow performance and high CPU usage, try to disable
PyCharmtype checker and use mypy or pyright instead.
⚠️ To continue using
PyCharmtype checker, you can try to replaceboto3-stubswith boto3-stubs-lite:
pip uninstall boto3-stubs
pip install boto3-stubs-lite
Install boto3-stubs[s3outposts] in your environment:
python -m pip install 'boto3-stubs[s3outposts]'
Both type checking and code completion should now work.
Emacs
- Install
boto3-stubswith services you use in your environment:
python -m pip install 'boto3-stubs[s3outposts]'
- Install use-package, lsp, company and flycheck packages
- Install lsp-pyright package
(use-package lsp-pyright
:ensure t
:hook (python-mode . (lambda ()
(require 'lsp-pyright)
(lsp))) ; or lsp-deferred
:init (when (executable-find "python3")
(setq lsp-pyright-python-executable-cmd "python3"))
)
- Make sure emacs uses the environment where you have installed
boto3-stubs
Type checking should now work. No explicit type annotations required, write
your boto3 code as usual.
Sublime Text
- Install
boto3-stubs[s3outposts]with services you use in your environment:
python -m pip install 'boto3-stubs[s3outposts]'
- Install LSP-pyright package
Type checking should now work. No explicit type annotations required, write
your boto3 code as usual.
Other IDEs
Not tested, but as long as your IDE supports mypy or pyright, everything
should work.
mypy
- Install
mypy:python -m pip install mypy - Install
boto3-stubs[s3outposts]in your environment:
python -m pip install 'boto3-stubs[s3outposts]'
Type checking should now work. No explicit type annotations required, write
your boto3 code as usual.
pyright
- Install
pyright:npm i -g pyright - Install
boto3-stubs[s3outposts]in your environment:
python -m pip install 'boto3-stubs[s3outposts]'
Optionally, you can install boto3-stubs to typings directory.
Type checking should now work. No explicit type annotations required, write
your boto3 code as usual.
Pylint compatibility
It is totally safe to use TYPE_CHECKING flag in order to avoid
mypy-boto3-s3outposts dependency in production. However, there is an issue in
pylint that it complains about undefined variables. To fix it, set all types
to object in non-TYPE_CHECKING mode.
from typing import TYPE_CHECKING
if TYPE_CHECKING:
from mypy_boto3_ec2 import EC2Client, EC2ServiceResource
from mypy_boto3_ec2.waiters import BundleTaskCompleteWaiter
from mypy_boto3_ec2.paginators import DescribeVolumesPaginator
else:
EC2Client = object
EC2ServiceResource = object
BundleTaskCompleteWaiter = object
DescribeVolumesPaginator = object
...
Explicit type annotations
Client annotations
S3OutpostsClient provides annotations for boto3.client("s3outposts").
from boto3.session import Session
from mypy_boto3_s3outposts import S3OutpostsClient
client: S3OutpostsClient = Session().client("s3outposts")
# now client usage is checked by mypy and IDE should provide code completion
Paginators annotations
mypy_boto3_s3outposts.paginator module contains type annotations for all
paginators.
from boto3.session import Session
from mypy_boto3_s3outposts import S3OutpostsClient
from mypy_boto3_s3outposts.paginator import (
ListEndpointsPaginator,
ListOutpostsWithS3Paginator,
ListSharedEndpointsPaginator,
)
client: S3OutpostsClient = Session().client("s3outposts")
# Explicit type annotations are optional here
# Types should be correctly discovered by mypy and IDEs
list_endpoints_paginator: ListEndpointsPaginator = client.get_paginator("list_endpoints")
list_outposts_with_s3_paginator: ListOutpostsWithS3Paginator = client.get_paginator(
"list_outposts_with_s3"
)
list_shared_endpoints_paginator: ListSharedEndpointsPaginator = client.get_paginator(
"list_shared_endpoints"
)
Literals
mypy_boto3_s3outposts.literals module contains literals extracted from shapes
that can be used in user code for type checking.
Full list of S3Outposts Literals can be found in
docs.
from mypy_boto3_s3outposts.literals import EndpointAccessTypeType
def check_value(value: EndpointAccessTypeType) -> bool: ...
Type definitions
mypy_boto3_s3outposts.type_defs module contains structures and shapes
assembled to typed dictionaries and unions for additional type checking.
Full list of S3Outposts TypeDefs can be found in
docs.
# TypedDict usage example
from mypy_boto3_s3outposts.type_defs import CreateEndpointRequestTypeDef
def get_value() -> CreateEndpointRequestTypeDef:
return {
"OutpostId": ...,
}
How it works
Fully automated
mypy-boto3-builder carefully
generates type annotations for each service, patiently waiting for boto3
updates. It delivers drop-in type annotations for you and makes sure that:
- All available
boto3services are covered. - Each public class and method of every
boto3service gets valid type annotations extracted frombotocoreschemas. - Type annotations include up-to-date documentation.
- Link to documentation is provided for every method.
- Code is processed by ruff for readability.
What's new
Implemented features
- Fully type annotated
boto3,botocore,aiobotocoreandaioboto3libraries mypy,pyright,VSCode,PyCharm,Sublime TextandEmacscompatibilityClient,ServiceResource,Resource,WaiterPaginatortype annotations for each service- Generated
TypeDefsfor each service - Generated
Literalsfor each service - Auto discovery of types for
boto3.clientandboto3.resourcecalls - Auto discovery of types for
session.clientandsession.resourcecalls - Auto discovery of types for
client.get_waiterandclient.get_paginatorcalls - Auto discovery of types for
ServiceResourceandResourcecollections - Auto discovery of types for
aiobotocore.Session.create_clientcalls
Latest changes
Builder changelog can be found in Releases.
Versioning
mypy-boto3-s3outposts version is the same as related boto3 version and
follows
Python Packaging version specifiers.
Thank you
- Allie Fitter for boto3-type-annotations, this package is based on top of his work
- black developers for an awesome formatting tool
- Timothy Edmund Crosley for isort and how flexible it is
- mypy developers for doing all dirty work for us
- pyright team for the new era of typed Python
Documentation
All services type annotations can be found in boto3 docs
Support and contributing
This package is auto-generated. Please reports any bugs or request new features in mypy-boto3-builder repository.