diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f7d0bb835..afa858b64 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,17 +1,16 @@ name: CI on: - push: - branches: - - develop pull_request: branches: - develop +env: + UV_SYSTEM_PYTHON: true + jobs: - test: + ci: runs-on: ubuntu-latest - strategy: fail-fast: false matrix: @@ -21,95 +20,43 @@ jobs: - name: Checkout Repository uses: actions/checkout@v4 - - name: Set up Python for CI - ${{ matrix.python-version }} + - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v5 - with: - python-version: ${{ matrix.python-version }} - - - name: Initialize Pants - uses: pantsbuild/actions/init-pants@main - with: - # cache0 makes it easy to bust the cache if needed - # just increase the integer to start with a fresh cache - gha-cache-key: cache0-py${{ matrix.python_version }} - named-caches-hash: ${{ hashFiles('python-default.lock') }} - pants-ci-config: pants.ci.toml - - - name: Run tests - run: | - make test-py - - - name: Upload coverage - if: matrix.python-version == 3.12 - uses: codecov/codecov-action@v3 - with: - token: ${{ secrets.CODECOV_TOKEN }} - file: ./dist/coverage/python/coverage.xml - flags: unittests - name: codecov-umbrella - fail_ci_if_error: true - - test-codegen: - runs-on: ubuntu-latest - - strategy: - fail-fast: false - matrix: - python-version: ["3.12"] - - name: Codegen Java 17 / Python ${{ matrix.python-version }} - - steps: - - name: Checkout Repository - uses: actions/checkout@v4 - - - name: Download Corretto 17 JDK - run: | - download_url="https://corretto.aws/downloads/latest/amazon-corretto-17-x64-linux-jdk.tar.gz" - wget -O $RUNNER_TEMP/java_package.tar.gz $download_url - - - name: Set up Corretto 17 JDK + - name: Set up JDK 17 uses: actions/setup-java@v4 with: - distribution: 'jdkfile' - jdkFile: ${{ runner.temp }}/java_package.tar.gz java-version: 17 - architecture: x64 + distribution: 'corretto' - - name: clean and build without python - run: cd codegen && ./gradlew clean build -Plog-tests + - name: Setup Gradle + uses: gradle/actions/setup-gradle@v4 - - name: Set Up Python for CI - ${{ matrix.python-version }} - uses: actions/setup-python@v5 - with: - python-version: ${{ matrix.python-version }} - - - name: Initialize Pants - uses: pantsbuild/actions/init-pants@main - with: - # cache0 makes it easy to bust the cache if needed - gha-cache-key: cache0-py${{ matrix.python_version }} - named-caches-hash: ${{ hashFiles('python-default.lock') }} - pants-ci-config: pants.ci.toml + - name: Install uv + uses: astral-sh/setup-uv@v5 - - name: Install smithy-python + - name: Setup workspace run: | - make install-python-components + export UV_PROJECT_ENVIRONMENT="${pythonLocation}" + echo "UV_PROJECT_ENVIRONMENT=$UV_PROJECT_ENVIRONMENT" >> "$GITHUB_ENV" + make install - - name: clean and build without formatting/linting installed - run: cd codegen && ./gradlew clean build -Plog-tests + - name: Check python packages + run: | + make check-py - - name: Install black + - name: Test python packages run: | - python${{ matrix.python-version }} -m pip install --upgrade black + make test-py - - name: clean and build without linting installed - run: cd codegen && ./gradlew clean build -Plog-tests + - name: Build python packages + run: | + make build-py - - name: Install mypy and other libraries necessary for typing + - name: Build (and test) java packages run: | - python${{ matrix.python-version }} -m pip install --upgrade mypy pytest pytest-asyncio + make build-java - - name: clean and build with all optional tools installed - run: cd codegen && ./gradlew clean build -Plog-tests + - name: Run protocol tests + run: | + make test-protocols diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml deleted file mode 100644 index 657ef417f..000000000 --- a/.github/workflows/lint.yml +++ /dev/null @@ -1,34 +0,0 @@ -name: Lint code - -on: - push: - branches: - - develop - pull_request: - branches: - - develop - -jobs: - lint: - runs-on: ubuntu-latest - - steps: - - name: Checkout Repository - uses: actions/checkout@v4 - - - name: Set up Python for linting - 3.12 - uses: actions/setup-python@v5 - with: - python-version: 3.12 - - - name: Initialize Pants - uses: pantsbuild/actions/init-pants@main - with: - # v0 makes it easy to bust the cache if needed - # just increase the integer to start with a fresh cache - gha-cache-key: v0 - named-caches-hash: ${{ hashFiles('python-default.lock') }} - pants-ci-config: pants.ci.toml - - - name: Run pre-commit - uses: pre-commit/action@v3.0.1 diff --git a/.github/workflows/protocol-test.yml b/.github/workflows/protocol-test.yml deleted file mode 100644 index 06674cf70..000000000 --- a/.github/workflows/protocol-test.yml +++ /dev/null @@ -1,40 +0,0 @@ -name: Protocol Tests - -on: - push: - branches: - - develop - pull_request: - branches: - - develop - -jobs: - protocol-test: - runs-on: ubuntu-latest - name: RestJson1 - - steps: - - uses: actions/checkout@v4 - - - name: Set up Corretto 17 JDK - uses: actions/setup-java@v4 - with: - distribution: corretto - java-version: 17 - - - name: Set up Python for protocol tests - 3.12 - uses: actions/setup-python@v5 - with: - python-version: 3.12 - - - name: Initialize Pants - uses: pantsbuild/actions/init-pants@main - with: - # v0 makes it easy to bust the cache if needed - # just increase the integer to start with a fresh cache - gha-cache-key: v0 - named-caches-hash: ${{ hashFiles('python-default.lock') }} - pants-ci-config: pants.ci.toml - - - name: Run protocol tests - run: make test-protocols diff --git a/.github/workflows/typecheck.yml b/.github/workflows/typecheck.yml deleted file mode 100644 index c207d9a2d..000000000 --- a/.github/workflows/typecheck.yml +++ /dev/null @@ -1,35 +0,0 @@ -name: Type Check - -on: - push: - branches: - - develop - pull_request: - branches: - - develop - -jobs: - mypy: - runs-on: ubuntu-latest - - steps: - - name: Checkout Repository - uses: actions/checkout@v4 - - - name: Set up Python for type checking - 3.12 - uses: actions/setup-python@v5 - with: - python-version: 3.12 - - - name: Initialize Pants - uses: pantsbuild/actions/init-pants@main - with: - # v0 makes it easy to bust the cache if needed - # just increase the integer to start with a fresh cache - gha-cache-key: v0 - named-caches-hash: ${{ hashFiles('python-default.lock') }} - pants-ci-config: pants.ci.toml - - - name: Run type checks - run: | - make check-py diff --git a/.gitignore b/.gitignore index b7477c32a..93e515667 100644 --- a/.gitignore +++ b/.gitignore @@ -19,10 +19,10 @@ target/ **/dependency-reduced-pom.xml # Gradle -/.gradle +**/.gradle build/ */out/ -*/*/out/ +**/*/out/ # Python __pycache__ @@ -33,10 +33,4 @@ coverage.xml htmlcov *.egg-info dist - -# Pants workspace files -/.pants.d/ -/dist/ -/.pids -/.pants.workdir.file_lock* -pants +.venv diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml deleted file mode 100644 index 33aa414c3..000000000 --- a/.pre-commit-config.yaml +++ /dev/null @@ -1,16 +0,0 @@ -repos: - - repo: 'https://github.com/pre-commit/pre-commit-hooks' - rev: v2.3.0 - hooks: - - id: check-yaml - - id: end-of-file-fixer - exclude: python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/ - - id: trailing-whitespace - - repo: local - hooks: - - id: linting - name: lint - description: runs make lint-py - entry: 'make lint-py' - language: system - pass_filenames: false diff --git a/.python-version b/.python-version new file mode 100644 index 000000000..e4fba2183 --- /dev/null +++ b/.python-version @@ -0,0 +1 @@ +3.12 diff --git a/BUILD b/BUILD deleted file mode 100644 index 279b84c39..000000000 --- a/BUILD +++ /dev/null @@ -1,2 +0,0 @@ -# This is needed for mypy to be able to typecheck the tests properly -python_requirements(name="test-reqs", source="requirements-dev.txt") diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 905fa66eb..0bb6185d8 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -31,8 +31,8 @@ To send us a pull request, please: 1. Fork the repository. 2. Modify the source; please focus on the specific change you are contributing. If you also reformat all the code, it will be hard for us to focus on your change. -3. Ensure local tests pass. -4. Run `./pants fmt ::`, `./pants lint ::`, and `./pants check ::` if you've changed any python source. +3. Ensure local tests pass (`make test-py` and `make test-protocols`). +4. Run `make lint-py` if you've changed any python sources. 4. Commit to your fork using clear commit messages. 5. Send us a pull request, answering any default questions in the pull request interface. 6. Pay attention to any automated CI failures reported in the pull request, and stay involved in the conversation. diff --git a/Makefile b/Makefile index 629a7254f..787c48574 100644 --- a/Makefile +++ b/Makefile @@ -1,88 +1,46 @@ -help: ## Show this help. - @sed -ne '/@sed/!s/## //p' $(MAKEFILE_LIST) - - -## Installs pants launcher binary using the get-pants script. -## If $CI is true, assume it's installed already (through GHA), so just copy the wrapper script. -pants: -ifeq ($(CI),true) - cp scripts/pantsw pants -else - ./get-pants --bin-dir . -endif - - -## Packages and installs the python packages. -install-python-components: pants - ./pants package :: - python3 -m pip install dist/*.whl --force-reinstall - +.DEFAULT_GOAL:=help -## Publishes java packages to maven local. -install-java-components: - cd codegen && ./gradlew publishToMavenLocal +help: ## Show this help. + @awk 'BEGIN {FS = ":.*##"; printf "\nUsage:\n make \033[36m\033[0m\n\nTargets:\n"} /^[a-zA-Z_-]+:.*?##/ { printf " \033[36m%-25s\033[0m %s\n", $$1, $$2 }' $(MAKEFILE_LIST) -## Installs java and python components locally. -install-components: install-python-components install-java-components +install: ## Sets up workspace (* you should run this first! *) + uv sync --all-packages --all-extras + cd codegen && ./gradlew + @printf "\n\nWorkspace initialized, please run:\n\033[36msource .venv/bin/activate\033[0m" -## Builds the Java code generation packages. -smithy-build: +build-java: ## Builds the Java code generation packages. cd codegen && ./gradlew clean build -## Generates the protocol tests, rebuilding necessary Java packages. -generate-protocol-tests: - cd codegen && ./gradlew clean :smithy-python-protocol-test:build - - -## Runs already-generated protocol tests. -run-protocol-tests: - cd codegen/smithy-python-protocol-test/build/smithyprojections/smithy-python-protocol-test/rest-json-1/python-client-codegen && \ - python3 -m pip install '.[tests]' && \ - python3 -m pytest tests - - -## Generates and runs protocol tests. -test-protocols: install-python-components generate-protocol-tests run-protocol-tests +test-protocols: ## Generates and runs the restJson1 protocol tests. + cd codegen && ./gradlew :protocol-test:build + uv run pytest codegen/protocol-test/build/smithyprojections/protocol-test/rest-json-1/python-client-codegen -## Runs formatters/fixers/linters for the python packages. -lint-py: pants - ./pants fix lint python-packages/smithy-core:: - ./pants fix lint python-packages/smithy-http:: - ./pants fix lint python-packages/smithy-aws-core:: - ./pants fix lint python-packages/smithy-json:: - ./pants fix lint python-packages/smithy-event-stream:: - ./pants fix lint python-packages/aws-event-stream:: +lint-py: ## Runs linters and formatters on the python packages. + uv run docformatter packages --in-place || true + uv run ruff check packages --fix + uv run ruff format packages -## Runs checkers for the python packages. -check-py: pants - ./pants check python-packages/smithy-core:: - ./pants check python-packages/smithy-http:: - ./pants check python-packages/smithy-aws-core:: - ./pants check python-packages/smithy-json:: - ./pants check python-packages/smithy-event-stream:: - ./pants check python-packages/aws-event-stream:: +check-py: ## Runs checks (formatting, lints, type-checking) on the python packages. + uv run docformatter packages + uv run ruff check packages + uv run ruff format --check + uv run pyright packages -## Runs tests for the python packages. -test-py: pants - ./pants test python-packages/smithy-core:: - ./pants test python-packages/smithy-http:: - ./pants test python-packages/smithy-aws-core:: - ./pants test python-packages/smithy-json:: - ./pants test python-packages/smithy-event-stream:: - ./pants test python-packages/aws-event-stream:: +test-py: ## Runs tests for the python packages. + uv run pytest packages -## Runs formatters/fixers/linters/checkers/tests for the python packages. -build-py: lint-py check-py test-py +build-py: ## Builds the python packages. + uv build --all-packages -## Clean up generated code, artifacts, and remove pants. -clean: - rm -rf pants dist/ +clean: ## Clean up workspace, generated code, and other artifacts. + uv run virtualenv --clear .venv + rm -r dist .pytest_cache .ruff_cache || true cd codegen && ./gradlew clean diff --git a/README.md b/README.md index a94c5b3aa..e904b4eec 100644 --- a/README.md +++ b/README.md @@ -110,25 +110,46 @@ With both files your project directory should look like this: ``` -The code generator, `smithy-python-codegen`, hasn't been published yet, so -you'll need to build it yourself. To build and run the generator you will need +The code generator libraries have not been published yet, so +you'll need to build it yourself. To build and run the generator, you will need the following prerequisites: -* Python 3.12 or newer - * (optional) Install [black](https://black.readthedocs.io/en/stable/) in your - environment to have the generated output be auto-formatted. +* [uv](https://docs.astral.sh/uv/) * The [Smithy CLI](https://smithy.io/2.0/guides/smithy-cli/cli_installation.html) * JDK 17 or newer * make -Now run `make install-components` from the root of this repository. This will -install the python dependencies in your environment and make the code generator -available locally. For more information on the underlying build process, see the +This project uses [uv](https://docs.astral.sh/uv/) for managing all things python. +Once you have it installed, run the following command to check that it's ready to use: + +```shell +uv --help +``` + +With `uv` installed, run `make install` from the root of this repository. This will +set up your workspace with all of the dependencies and tools needed to build the +project. For more information on the underlying process, see the "Using repository tooling" section. -Now from your project directory run `smithy build` and you'll have a generated -client! The client can be found in `build/smithy/client/python-client-codegen`. -The following is a snippet showing how you might use it: +> [!TIP] +> Make sure to run the following command as directed before proceeding: +>```shell +> source .venv/bin/activate +> ``` +> This will activate the [virtual environment](https://docs.python.org/3/library/venv.html) +> in your current shell. + +With your workspace set up and activated, run the following command to install the +the codegen libraries locally: + +```shell +cd codegen && ./gradlew publishToMavenLocal +``` + +Finally, change into your smithy project's directory, run `smithy build`, and you'll +have a generated client! The client can be found in +`build/smithy/client/python-client-codegen`. The following is a snippet showing how +you might use it: ```python import asyncio @@ -152,7 +173,7 @@ if __name__ == "__main__": Only for now. Once the generator has been published, the Smithy CLI will be able to run it without a separate Java installation. Similarly, once the python -helper libraries have been published you won't need to install them manually. +helper libraries have been published you won't need to install them locally. ### Core Modules and Interfaces @@ -180,7 +201,7 @@ creating are well-supported, understood, and maintained. Customers should not have to hack on internal or undocumented interfaces to achieve their goals. * **Components must be typed** - All the buildings blocks we create must be -typed and usable via `mypy`. Given the nature of gradual typing, it is paramount +typed and usable via `pyright`. Given the nature of gradual typing, it is paramount that foundational components and interfaces be typed to preserve the integrity of the typing system. @@ -195,7 +216,7 @@ by the [smithy-typescript](https://github.com/awslabs/smithy-typescript/) and We're currently heavily investing in writing proposals and documenting the design decisions made. Feedback on the -[proposed designs and interfaces](https://github.com/awslabs/smithy-python/tree/develop/designs) +[proposed designs and interfaces](https://github.com/smithy-lang/smithy-python/tree/develop/designs) is extremely helpful at this stage to ensure we're providing functional and ergonomic interfaces that meet customer expectations. @@ -219,77 +240,29 @@ to install yourself. We recommend the distribution, but any JDK that's at least version 17 will work. To build and run all the Java packages, simply run `./gradlew clean build` from -the `codegen` directory. If this is the first time you have run this, it will -download Gradle onto your system to run along with any dependencies of the Java -packages. +the `codegen` directory. If this is the first time you have run this +(or if you didn't already run `make install`), it will download Gradle onto your +system to run along with any dependencies of the Java packages. For more details on working on the code generator, see the readme in the `codegen` directory. -#### Python - pants +#### Python - uv Building multiple python packages in a single repo is a little less common than -it is for Java or some other languages, so even if you're a python expert you -may be unfamiliar with the tooling. The tool we're using is called -[pants](https://www.pantsbuild.org), and you use it pretty similarly to how you -use Gradle. - -Like Gradle, pants provides a wrapper script that downloads its dependencies as -needed. Currently, pants requires python 3.7, 3.8, or 3.9 to run, so one of -those must be available on your path. (It doesn't have to be the version that -is linked to `python` or `python3`, it just needs `python3.9` etc.) It is, -however, fully capable of building and working with code that uses newer python -versions like we do. This repository uses a minimum python version of 3.12 -for all its packages, so you will need that too to work on it. - -Pants provides a number of python commands it calls goals, documented -[here](https://www.pantsbuild.org/docs/python-goals). In short: - -* `./pants fmt ::` - This will run our formatters on all the python library - code. Use `fix` instead of this, since it runs all the formatters AND fixers. -* `./pants fix ::` - This will run the formatters/fixers on python library - code, and apply the changes. Use this before making commits. -* `./pants lint ::` - This will run our formatters/fixers/linters on all the - python library code. You should also use this before you make commits, and particularly - before you make a pull request. It will not apply formatting or fixes for you. -* `./pants check ::` - This will run mypy on all the python library code. - This should be used regularly, and must pass for any pull request. -* `./pants test ::` - This will run all the tests written for the python - library code. Use this as often as you'd run pytest or any other testing - tool. Under the hood, we are using pytest. -* `./pants update-build-files ::` - This will auto-format all the `BUILD` files. Use this if - you are making changes to or adding new `BUILD` files. - -There are other commands as well that you can find in the -[docs](https://www.pantsbuild.org/docs/python-goals), but these are the ones -you'll use the most. - -Important to note is those pairs of colons. These are pants -[targets](https://www.pantsbuild.org/docs/targets#target-addresses). The double -colon is a special target that means "everything". So running exactly what's -listed above will run those goals on every python file or other relevant file. -You can also target just `smithy_core`, for example, with -`./pants check python-packages/smithy-python/smithy_core:source`, or even -individual files with something like -`./pants check python-packages/smithy-python/smithy_core/interfaces/identity.py:../source`. -To list what targets are available in a directory, run -`./pants list path/to/dir:`. For more detailed information, see the -[docs](https://www.pantsbuild.org/docs/targets#target-addresses). +it is for Java or some other languages. If you've kept up with python tooling lately, +you've likely heard of uv. + +TODO: uv section #### Common commands - make There is also a `Makefile` that bridges the Python and Java build systems together to -make common workflows simple, single commands. The two most important commands are: +make common workflows simple, single commands. The most important commands are: -* `make install-components` which builds and installs the Java generator and the python - packages. The generator is published to maven local and the python packages are - installed into the active python environment. This command is most useful for those - who simply want to run the generator and use a generated client.v -* `make test-protocols` which runs all the protocol tests. It will first (re)install - all necessary components to ensure that the latest is being used. This is most useful - for developers working on the generator and python packages. +TODO: make section -To see what else available, run `make help` or examine the file directly. +To see what targets are available, run `make help` or examine the file directly. ## Security issue notifications diff --git a/codegen/smithy-aws-python-codegen/README.md b/codegen/aws/README.md similarity index 94% rename from codegen/smithy-aws-python-codegen/README.md rename to codegen/aws/README.md index dc20d5741..fe3e94878 100644 --- a/codegen/smithy-aws-python-codegen/README.md +++ b/codegen/aws/README.md @@ -1,6 +1,6 @@ ## Smithy AWS Python Codegen -This package implements AWS-specific code generation plugins to the python generator. +These packages implement AWS-specific code generation plugins to the python generator. Anything that is specific to AWS MUST be implemented here. Examples include most [AWS protocols](https://smithy.io/2.0/aws/protocols/index.html)(*), [SigV4](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_aws-signing.html), diff --git a/codegen/aws/core/build.gradle.kts b/codegen/aws/core/build.gradle.kts new file mode 100644 index 000000000..3a81c5190 --- /dev/null +++ b/codegen/aws/core/build.gradle.kts @@ -0,0 +1,15 @@ +plugins { + id("smithy-python.module-conventions") + id("smithy-python.integ-test-conventions") +} + +description = "This module provides the core aws codegen functionality for Smithy Python" +group = "software.amazon.smithy.python.codegen.aws" + +extra["displayName"] = "Smithy :: Python :: AWS :: Codegen" +extra["moduleName"] = "software.amazon.smithy.python.aws.codegen" + +dependencies { + implementation(project(":core")) + implementation(libs.smithy.aws.traits) +} diff --git a/codegen/smithy-aws-python-codegen/src/main/java/software/amazon/smithy/aws/python/codegen/AwsAuthIntegration.java b/codegen/aws/core/src/main/java/software/amazon/smithy/python/aws/codegen/AwsAuthIntegration.java similarity index 55% rename from codegen/smithy-aws-python-codegen/src/main/java/software/amazon/smithy/aws/python/codegen/AwsAuthIntegration.java rename to codegen/aws/core/src/main/java/software/amazon/smithy/python/aws/codegen/AwsAuthIntegration.java index 93b964b7d..07d0ff0f2 100644 --- a/codegen/smithy-aws-python-codegen/src/main/java/software/amazon/smithy/aws/python/codegen/AwsAuthIntegration.java +++ b/codegen/aws/core/src/main/java/software/amazon/smithy/python/aws/codegen/AwsAuthIntegration.java @@ -2,15 +2,13 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ +package software.amazon.smithy.python.aws.codegen; -package software.amazon.smithy.aws.python.codegen; - -import software.amazon.smithy.python.codegen.integration.PythonIntegration; +import software.amazon.smithy.python.codegen.integrations.PythonIntegration; import software.amazon.smithy.utils.SmithyInternalApi; /** * Adds support for AWS auth traits. */ @SmithyInternalApi -public class AwsAuthIntegration implements PythonIntegration { -} +public class AwsAuthIntegration implements PythonIntegration {} diff --git a/codegen/smithy-aws-python-codegen/src/main/java/software/amazon/smithy/aws/python/codegen/AwsProtocolsIntegration.java b/codegen/aws/core/src/main/java/software/amazon/smithy/python/aws/codegen/AwsProtocolsIntegration.java similarity index 69% rename from codegen/smithy-aws-python-codegen/src/main/java/software/amazon/smithy/aws/python/codegen/AwsProtocolsIntegration.java rename to codegen/aws/core/src/main/java/software/amazon/smithy/python/aws/codegen/AwsProtocolsIntegration.java index a5e858f80..63601dd5d 100644 --- a/codegen/smithy-aws-python-codegen/src/main/java/software/amazon/smithy/aws/python/codegen/AwsProtocolsIntegration.java +++ b/codegen/aws/core/src/main/java/software/amazon/smithy/python/aws/codegen/AwsProtocolsIntegration.java @@ -2,12 +2,11 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.aws.python.codegen; +package software.amazon.smithy.python.aws.codegen; import java.util.List; -import software.amazon.smithy.python.codegen.integration.ProtocolGenerator; -import software.amazon.smithy.python.codegen.integration.PythonIntegration; +import software.amazon.smithy.python.codegen.generators.ProtocolGenerator; +import software.amazon.smithy.python.codegen.integrations.PythonIntegration; import software.amazon.smithy.utils.SmithyInternalApi; /** diff --git a/codegen/aws/core/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integrations.PythonIntegration b/codegen/aws/core/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integrations.PythonIntegration new file mode 100644 index 000000000..5155ed74a --- /dev/null +++ b/codegen/aws/core/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integrations.PythonIntegration @@ -0,0 +1,7 @@ +# +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 +# + +software.amazon.smithy.python.aws.codegen.AwsAuthIntegration +software.amazon.smithy.python.aws.codegen.AwsProtocolsIntegration diff --git a/codegen/build.gradle.kts b/codegen/build.gradle.kts index 2ab6dd214..c8f736a5d 100644 --- a/codegen/build.gradle.kts +++ b/codegen/build.gradle.kts @@ -13,247 +13,7 @@ * permissions and limitations under the License. */ -import com.github.spotbugs.snom.Effort - -plugins { - `java-library` - `maven-publish` - signing - checkstyle - jacoco - id("com.github.spotbugs") version "6.1.5" - id("io.codearte.nexus-staging") version "0.30.0" -} - allprojects { group = "software.amazon.smithy.python" version = "0.1.0" } - -// The root project doesn't produce a JAR. -tasks["jar"].enabled = false - -// Load the Sonatype user/password for use in publishing tasks. -val sonatypeUser: String? by project -val sonatypePassword: String? by project - -/* - * Sonatype Staging Finalization - * ==================================================== - * - * When publishing to Maven Central, we need to close the staging - * repository and release the artifacts after they have been - * validated. This configuration is for the root project because - * it operates at the "group" level. - */ -if (sonatypeUser != null && sonatypePassword != null) { - apply(plugin = "io.codearte.nexus-staging") - - nexusStaging { - packageGroup = "software.amazon" - stagingProfileId = "e789115b6c941" - - username = sonatypeUser - password = sonatypePassword - } -} - -repositories { - mavenLocal() - mavenCentral() -} - -subprojects { - val subproject = this - - /* - * Java - * ==================================================== - */ - if (subproject.name != "smithy-python-codegen-test" && subproject.name != "smithy-python-protocol-test") { - apply(plugin = "java-library") - - java { - toolchain { - languageVersion.set(JavaLanguageVersion.of(17)) - } - } - - tasks.withType { - options.encoding = "UTF-8" - } - - // Use Junit5's test runner. - tasks.withType { - useJUnitPlatform() - } - - // Apply junit 5 and hamcrest test dependencies to all java projects. - dependencies { - testCompileOnly("org.junit.jupiter:junit-jupiter-api:5.11.4") - testImplementation("org.junit.jupiter:junit-jupiter-engine:5.11.4") - testCompileOnly("org.junit.jupiter:junit-jupiter-params:5.11.4") - testCompileOnly("org.hamcrest:hamcrest:3.0") - } - - // Reusable license copySpec - val licenseSpec = copySpec { - from("${project.rootDir}/LICENSE") - from("${project.rootDir}/NOTICE") - } - - // Set up tasks that build source and javadoc jars. - tasks.register("sourcesJar") { - metaInf.with(licenseSpec) - from(sourceSets.main.get().allJava) - archiveClassifier.set("sources") - } - - tasks.register("javadocJar") { - metaInf.with(licenseSpec) - from(tasks.javadoc) - archiveClassifier.set("javadoc") - } - - // Configure jars to include license related info - tasks.jar { - metaInf.with(licenseSpec) - inputs.property("moduleName", subproject.extra["moduleName"]) - manifest { - attributes["Automatic-Module-Name"] = subproject.extra["moduleName"] - } - } - - // Always run javadoc after build. - tasks["build"].finalizedBy(tasks["javadoc"]) - - /* - * Maven - * ==================================================== - */ - apply(plugin = "maven-publish") - apply(plugin = "signing") - - repositories { - mavenLocal() - mavenCentral() - } - - publishing { - repositories { - mavenCentral { - url = uri("https://aws.oss.sonatype.org/service/local/staging/deploy/maven2/") - credentials { - username = sonatypeUser - password = sonatypePassword - } - } - } - - publications { - create("mavenJava") { - from(components["java"]) - - // Ship the source and javadoc jars. - artifact(tasks["sourcesJar"]) - artifact(tasks["javadocJar"]) - - // Include extra information in the POMs. - afterEvaluate { - pom { - name.set(subproject.extra["displayName"].toString()) - description.set(subproject.description) - url.set("https://github.com/awslabs/smithy-python") - licenses { - license { - name.set("Apache License 2.0") - url.set("http://www.apache.org/licenses/LICENSE-2.0.txt") - distribution.set("repo") - } - } - developers { - developer { - id.set("smithy") - name.set("Smithy") - organization.set("Amazon Web Services") - organizationUrl.set("https://aws.amazon.com") - roles.add("developer") - } - } - scm { - url.set("https://github.com/awslabs/smithy-python.git") - } - } - } - } - } - } - - // Don't sign the artifacts if we didn't get a key and password to use. - val signingKey: String? by project - val signingPassword: String? by project - if (signingKey != null && signingPassword != null) { - signing { - useInMemoryPgpKeys(signingKey, signingPassword) - sign(publishing.publications["mavenJava"]) - } - } - - /* - * CheckStyle - * ==================================================== - */ - apply(plugin = "checkstyle") - - tasks["checkstyleTest"].enabled = false - - /* - * Tests - * ==================================================== - * - * Configure the running of tests. - */ - // Log on passed, skipped, and failed test events if the `-Plog-tests` property is set. - if (project.hasProperty("log-tests")) { - tasks.test { - testLogging.events("passed", "skipped", "failed") - } - } - - /* - * Code coverage - * ==================================================== - */ - apply(plugin = "jacoco") - - // Always run the jacoco test report after testing. - tasks["test"].finalizedBy(tasks["jacocoTestReport"]) - - // Configure jacoco to generate an HTML report. - tasks.jacocoTestReport { - reports { - xml.required.set(false) - csv.required.set(false) - html.outputLocation.set(file("$buildDir/reports/jacoco")) - } - } - - /* - * Spotbugs - * ==================================================== - */ - apply(plugin = "com.github.spotbugs") - - // We don't need to lint tests. - tasks["spotbugsTest"].enabled = false - - // Configure the bug filter for spotbugs. - spotbugs { - effort = Effort.MAX - val excludeFile = File("${project.rootDir}/config/spotbugs/filter.xml") - if (excludeFile.exists()) { - excludeFilter.set(excludeFile) - } - } - } -} diff --git a/codegen/buildSrc/build.gradle.kts b/codegen/buildSrc/build.gradle.kts new file mode 100644 index 000000000..1f4fdd38c --- /dev/null +++ b/codegen/buildSrc/build.gradle.kts @@ -0,0 +1,18 @@ +plugins { + `kotlin-dsl` +} + +repositories { + mavenCentral() + gradlePluginPortal() +} + +dependencies { + implementation(libs.test.logger.plugin) + implementation(libs.spotbugs) + implementation(libs.spotless) + implementation(libs.dependency.analysis) + + // https://github.com/gradle/gradle/issues/15383 + implementation(files(libs.javaClass.superclass.protectionDomain.codeSource.location)) +} diff --git a/codegen/buildSrc/gradle.properties b/codegen/buildSrc/gradle.properties new file mode 100644 index 000000000..d2cd2b1f5 --- /dev/null +++ b/codegen/buildSrc/gradle.properties @@ -0,0 +1,2 @@ +org.gradle.parallel=true +org.gradle.jvmargs='-Dfile.encoding=UTF-8' diff --git a/codegen/buildSrc/settings.gradle b/codegen/buildSrc/settings.gradle new file mode 100644 index 000000000..6a22136dd --- /dev/null +++ b/codegen/buildSrc/settings.gradle @@ -0,0 +1,9 @@ + +// Ensure version library is available to buildSrc plugins +dependencyResolutionManagement { + versionCatalogs { + create("libs") { + from(files("../gradle/libs.versions.toml")) + } + } +} diff --git a/codegen/buildSrc/src/main/kotlin/smithy-python.integ-test-conventions.gradle.kts b/codegen/buildSrc/src/main/kotlin/smithy-python.integ-test-conventions.gradle.kts new file mode 100644 index 000000000..ae32faf3a --- /dev/null +++ b/codegen/buildSrc/src/main/kotlin/smithy-python.integ-test-conventions.gradle.kts @@ -0,0 +1,18 @@ +configure { + val main by getting + val test by getting + create("it") { + compileClasspath += main.output + configurations["testRuntimeClasspath"] + configurations["testCompileClasspath"] + runtimeClasspath += output + compileClasspath + test.runtimeClasspath + test.output + } +} + +// Add the integ test task +tasks.register("integ") { + useJUnitPlatform() + testClassesDirs = project.the()["it"].output.classesDirs + classpath = project.the()["it"].runtimeClasspath +} + +// Run integ tests when testing, can be disabled once more testing is added, and we want to separate them. +tasks["test"].finalizedBy("integ") diff --git a/codegen/buildSrc/src/main/kotlin/smithy-python.java-conventions.gradle.kts b/codegen/buildSrc/src/main/kotlin/smithy-python.java-conventions.gradle.kts new file mode 100644 index 000000000..ed30456ad --- /dev/null +++ b/codegen/buildSrc/src/main/kotlin/smithy-python.java-conventions.gradle.kts @@ -0,0 +1,131 @@ +import com.github.spotbugs.snom.Effort +import java.util.regex.Pattern +import org.gradle.api.Project +import org.gradle.kotlin.dsl.the + +plugins { + `java-library` + id("com.adarshr.test-logger") + id("com.github.spotbugs") + id("com.diffplug.spotless") +} + +// Workaround per: https://github.com/gradle/gradle/issues/15383 +val Project.libs get() = the() + +java { + toolchain { + languageVersion = JavaLanguageVersion.of(17) + } +} + +tasks.withType() { + options.encoding = "UTF-8" +} + +tasks.withType() { + options.encoding = "UTF-8" +} + +/* + * Common test configuration + * =============================== + */ +dependencies { + testImplementation(platform(libs.junit.bom)) + testImplementation(libs.junit.jupiter.api) + testRuntimeOnly(libs.junit.jupiter.engine) + testImplementation(libs.junit.jupiter.params) + compileOnly("com.github.spotbugs:spotbugs-annotations:${spotbugs.toolVersion.get()}") + testCompileOnly("com.github.spotbugs:spotbugs-annotations:${spotbugs.toolVersion.get()}") +} + +tasks.withType { + useJUnitPlatform() +} + +testlogger { + showExceptions = true + showStackTraces = true + showFullStackTraces = false + showCauses = true + showSummary = false + showPassed = false + showSkipped = false + showFailed = true + showOnlySlow = false + showStandardStreams = true + showPassedStandardStreams = false + showSkippedStandardStreams = false + showFailedStandardStreams = true + logLevel = LogLevel.WARN +} + +/* + * Formatting + * ================== + * see: https://github.com/diffplug/spotless/blob/main/plugin-gradle/README.md#java + */ +spotless { + java { + // Enforce a common license header on all files + licenseHeaderFile("${project.rootDir}/config/spotless/license-header.txt") + .onlyIfContentMatches("^((?!SKIPLICENSECHECK)[\\s\\S])*\$") + indentWithSpaces() + endWithNewline() + + eclipse().configFile("${project.rootDir}/config/spotless/formatting.xml") + + // Fixes for some strange formatting applied by eclipse: + // see: https://github.com/kamkie/demo-spring-jsf/blob/bcacb9dc90273a5f8d2569470c5bf67b171c7d62/build.gradle.kts#L159 + custom("Lambda fix") { it.replace("} )", "})").replace("} ,", "},") } + custom("Long literal fix") { Pattern.compile("([0-9_]+) [Ll]").matcher(it).replaceAll("\$1L") } + + // Static first, then everything else alphabetically + removeUnusedImports() + importOrder("\\#", "") + + // Ignore generated generated code for formatter check + targetExclude("**/build/**/*.*") + } + + // Formatting for build.gradle.kts files + kotlinGradle { + ktlint() + indentWithSpaces() + trimTrailingWhitespace() + endWithNewline() + } +} + +/* + * Spotbugs + * ==================================================== + * + * Run spotbugs against source files and configure suppressions. + */ +// Configure the spotbugs extension. +spotbugs { + effort = Effort.MAX + excludeFilter = file("${project.rootDir}/config/spotbugs/filter.xml") +} + +// We don't need to lint tests. +tasks.named("spotbugsTest") { + enabled = false +} + +tasks { + spotlessCheck { + dependsOn(tasks.spotlessApply) + } +} + +/* + * Repositories + * ================================ + */ +repositories { + mavenLocal() + mavenCentral() +} diff --git a/codegen/buildSrc/src/main/kotlin/smithy-python.module-conventions.gradle.kts b/codegen/buildSrc/src/main/kotlin/smithy-python.module-conventions.gradle.kts new file mode 100644 index 000000000..f5b0d1225 --- /dev/null +++ b/codegen/buildSrc/src/main/kotlin/smithy-python.module-conventions.gradle.kts @@ -0,0 +1,4 @@ +plugins { + id("smithy-python.java-conventions") + id("smithy-python.publishing-conventions") +} diff --git a/codegen/buildSrc/src/main/kotlin/smithy-python.publishing-conventions.gradle.kts b/codegen/buildSrc/src/main/kotlin/smithy-python.publishing-conventions.gradle.kts new file mode 100644 index 000000000..28af8a608 --- /dev/null +++ b/codegen/buildSrc/src/main/kotlin/smithy-python.publishing-conventions.gradle.kts @@ -0,0 +1,74 @@ +import org.gradle.api.publish.maven.MavenPublication +import org.gradle.kotlin.dsl.extra +import org.gradle.kotlin.dsl.provideDelegate + +plugins { + `maven-publish` + signing +} + +/* + * Staging repository + * ==================================================== + * + * Configure publication to staging repo + */ +publishing { + repositories { + maven { + name = "stagingRepository" + url = rootProject.layout.buildDirectory.dir("staging").get().asFile.toURI() + } + } + // Add license spec to all maven publications + publications { + afterEvaluate { + create("mavenJava") { + from(components["java"]) + + val displayName: String by extra + pom { + name.set(displayName) + description.set(project.description) + url.set("https://github.com/smithy-lang/smithy-python") + licenses { + license { + name.set("Apache License 2.0") + url.set("http://www.apache.org/licenses/LICENSE-2.0.txt") + distribution.set("repo") + } + } + developers { + developer { + id.set("smithy") + name.set("Smithy") + organization.set("Amazon Web Services") + organizationUrl.set("https://aws.amazon.com") + roles.add("developer") + } + } + scm { + url.set("https://github.com/smithy-lang/smithy-python.git") + } + } + } + } + } +} + +signing { + setRequired { + // signing is required only if the artifacts are to be published to a maven repository + gradle.taskGraph.allTasks.any { it is PublishToMavenRepository } + } + + // Don't sign the artifacts if we didn't get a key and password to use. + if (project.hasProperty("signingKey") && project.hasProperty("signingPassword")) { + signing { + useInMemoryPgpKeys( + project.properties["signingKey"].toString(), + project.properties["signingPassword"].toString()) + sign(publishing.publications) + } + } +} diff --git a/codegen/buildSrc/src/main/kotlin/smithy-python.utilities.gradle.kts b/codegen/buildSrc/src/main/kotlin/smithy-python.utilities.gradle.kts new file mode 100644 index 000000000..95bf9ad2b --- /dev/null +++ b/codegen/buildSrc/src/main/kotlin/smithy-python.utilities.gradle.kts @@ -0,0 +1,53 @@ +import org.gradle.api.DefaultTask +import org.gradle.api.provider.Property +import org.gradle.api.tasks.Input +import org.gradle.api.tasks.TaskAction +import org.gradle.api.tasks.options.Option +import org.gradle.kotlin.dsl.invoke +import org.gradle.kotlin.dsl.register + +tasks { + register("analyzeSize") { + group = "reporting" + description = "Analyzes the size of a configuration (default: 'runtimeClasspath')" + } +} + +/** + * A task for analyzing the size of artifacts (most likely the runtime JAR). + * Very useful for seeing the size of dependencies being brought in. + */ +abstract class SizeAnalysisTask : DefaultTask() { + @get:Input + @get:Option( + option = "configuration", + description = "The project configuration to analyze (default: 'runtimeClasspath')") + abstract val configuration: Property + + init { + configuration.convention("runtimeClasspath") + } + + @TaskAction + fun analyze() { + val selectedConfig = project.configurations.getByName(configuration.get()) + + println("\nšŸ“¦ Dependency Size Analysis: '${selectedConfig.name}'") + println("═".repeat(65)) + + selectedConfig + .sortedByDescending { it.length() } + .forEach { dep -> + val size = when { + dep.length() >= 1_048_576 -> "%.2f MB".format(dep.length() / 1_048_576.0) + dep.length() >= 1024 -> "%.2f KB".format(dep.length() / 1024.0) + else -> "${dep.length()} B" + } + println(" * ${dep.name.take(48).padEnd(48)} │ $size") + } + + val totalMb = selectedConfig.sumOf { it.length() } / 1_048_576.0 + println("─".repeat(65)) + println("""šŸ·ļø Total size: %.2f MB""".format(totalMb)) + } +} diff --git a/codegen/config/checkstyle/checkstyle.xml b/codegen/config/checkstyle/checkstyle.xml deleted file mode 100644 index 419a3d1a7..000000000 --- a/codegen/config/checkstyle/checkstyle.xml +++ /dev/null @@ -1,197 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/codegen/config/checkstyle/suppressions.xml b/codegen/config/checkstyle/suppressions.xml deleted file mode 100644 index e1564229e..000000000 --- a/codegen/config/checkstyle/suppressions.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - diff --git a/codegen/config/logging/logging.properties b/codegen/config/logging/logging.properties new file mode 100644 index 000000000..45f684f65 --- /dev/null +++ b/codegen/config/logging/logging.properties @@ -0,0 +1 @@ +.level = WARNING diff --git a/codegen/config/spotless/formatting.xml b/codegen/config/spotless/formatting.xml new file mode 100644 index 000000000..8b22213b7 --- /dev/null +++ b/codegen/config/spotless/formatting.xml @@ -0,0 +1,391 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/codegen/config/spotless/license-header.txt b/codegen/config/spotless/license-header.txt new file mode 100644 index 000000000..35d0f3613 --- /dev/null +++ b/codegen/config/spotless/license-header.txt @@ -0,0 +1,4 @@ +/* + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * SPDX-License-Identifier: Apache-2.0 + */ diff --git a/codegen/core/build.gradle.kts b/codegen/core/build.gradle.kts new file mode 100644 index 000000000..bc8da8191 --- /dev/null +++ b/codegen/core/build.gradle.kts @@ -0,0 +1,18 @@ +plugins { + id("smithy-python.module-conventions") + id("smithy-python.integ-test-conventions") +} + +description = "This module provides the core codegen functionality for Smithy Python" +group = "software.amazon.smithy.python.codegen" + +extra["displayName"] = "Smithy :: Python :: Codegen" +extra["moduleName"] = "software.amazon.smithy.python.codegen" + +dependencies { + api(libs.smithy.codegen) + implementation(libs.smithy.waiters) + implementation(libs.smithy.protocol.test.traits) + // We have this because we're using RestJson1 as a 'generic' protocol. + implementation(libs.smithy.aws.traits) +} diff --git a/codegen/core/src/it/java/software/amazon/smithy/python/codegen/test/PythonCodegenTest.java b/codegen/core/src/it/java/software/amazon/smithy/python/codegen/test/PythonCodegenTest.java new file mode 100644 index 000000000..929aeb602 --- /dev/null +++ b/codegen/core/src/it/java/software/amazon/smithy/python/codegen/test/PythonCodegenTest.java @@ -0,0 +1,42 @@ +/* + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * SPDX-License-Identifier: Apache-2.0 + */ +package software.amazon.smithy.python.codegen.test; + +import java.nio.file.Path; +import org.junit.jupiter.api.Test; +import org.junit.jupiter.api.io.TempDir; +import software.amazon.smithy.build.FileManifest; +import software.amazon.smithy.build.PluginContext; +import software.amazon.smithy.model.Model; +import software.amazon.smithy.model.node.ObjectNode; +import software.amazon.smithy.python.codegen.PythonClientCodegenPlugin; + +/** + * Simple test that executes the Python client codegen plugin. Currently, this is about as much "testing" as + * we can do, aside from the protocol tests. JUnit will set up and tear down a tempdir to house the codegen artifacts. + */ +public class PythonCodegenTest { + + @Test + public void testCodegen(@TempDir Path tempDir) { + // TODO: Move this to its own package once client codegen is in its own package + PythonClientCodegenPlugin plugin = new PythonClientCodegenPlugin(); + Model model = Model.assembler(PythonCodegenTest.class.getClassLoader()) + .discoverModels(PythonCodegenTest.class.getClassLoader()) + .assemble() + .unwrap(); + PluginContext context = PluginContext.builder() + .fileManifest(FileManifest.create(tempDir)) + .settings( + ObjectNode.builder() + .withMember("service", "example.weather#Weather") + .withMember("module", "weather") + .withMember("moduleVersion", "0.0.1") + .build()) + .model(model) + .build(); + plugin.execute(context); + } +} diff --git a/codegen/smithy-python-codegen-test/model/main.smithy b/codegen/core/src/it/resources/META-INF/smithy/main.smithy similarity index 100% rename from codegen/smithy-python-codegen-test/model/main.smithy rename to codegen/core/src/it/resources/META-INF/smithy/main.smithy diff --git a/codegen/core/src/it/resources/META-INF/smithy/manifest b/codegen/core/src/it/resources/META-INF/smithy/manifest new file mode 100644 index 000000000..36913fb59 --- /dev/null +++ b/codegen/core/src/it/resources/META-INF/smithy/manifest @@ -0,0 +1,3 @@ +main.smithy +more-nesting.smithy +nested.smithy diff --git a/codegen/smithy-python-codegen-test/model/more-nesting.smithy b/codegen/core/src/it/resources/META-INF/smithy/more-nesting.smithy similarity index 100% rename from codegen/smithy-python-codegen-test/model/more-nesting.smithy rename to codegen/core/src/it/resources/META-INF/smithy/more-nesting.smithy diff --git a/codegen/smithy-python-codegen-test/model/nested.smithy b/codegen/core/src/it/resources/META-INF/smithy/nested.smithy similarity index 100% rename from codegen/smithy-python-codegen-test/model/nested.smithy rename to codegen/core/src/it/resources/META-INF/smithy/nested.smithy diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ApplicationProtocol.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/ApplicationProtocol.java similarity index 78% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ApplicationProtocol.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/ApplicationProtocol.java index 42a321d3f..b26afa437 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ApplicationProtocol.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/ApplicationProtocol.java @@ -1,18 +1,7 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import software.amazon.smithy.codegen.core.Symbol; @@ -29,8 +18,7 @@ public record ApplicationProtocol( String name, SymbolReference requestType, SymbolReference responseType, - ObjectNode configuration -) { + ObjectNode configuration) { /** * Checks if the protocol is an HTTP based protocol. * @@ -54,8 +42,7 @@ public static ApplicationProtocol createDefaultHttpApplicationProtocol(ObjectNod SymbolReference.builder() .symbol(createHttpSymbol("HTTPResponse")) .build(), - config - ); + config); } /** diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ClientGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/ClientGenerator.java similarity index 82% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ClientGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/ClientGenerator.java index 42c264341..e24305226 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ClientGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/ClientGenerator.java @@ -1,21 +1,9 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; - import java.util.Collection; import java.util.LinkedHashSet; import java.util.Set; @@ -29,17 +17,20 @@ import software.amazon.smithy.model.shapes.Shape; import software.amazon.smithy.model.traits.DocumentationTrait; import software.amazon.smithy.model.traits.StringTrait; -import software.amazon.smithy.python.codegen.integration.PythonIntegration; -import software.amazon.smithy.python.codegen.integration.RuntimeClientPlugin; +import software.amazon.smithy.python.codegen.integrations.PythonIntegration; +import software.amazon.smithy.python.codegen.integrations.RuntimeClientPlugin; import software.amazon.smithy.python.codegen.sections.InitializeHttpAuthParametersSection; import software.amazon.smithy.python.codegen.sections.ResolveEndpointSection; import software.amazon.smithy.python.codegen.sections.ResolveIdentitySection; import software.amazon.smithy.python.codegen.sections.SendRequestSection; import software.amazon.smithy.python.codegen.sections.SignRequestSection; +import software.amazon.smithy.python.codegen.writer.PythonWriter; +import software.amazon.smithy.utils.SmithyInternalApi; /** * Generates the actual client and implements operations. */ +@SmithyInternalApi final class ClientGenerator implements Runnable { private final GenerationContext context; @@ -63,9 +54,9 @@ private void generateService(PythonWriter writer) { writer.addStdlibImport("typing", "TypeVar"); writer.write(""" - Input = TypeVar("Input") - Output = TypeVar("Output") - """); + Input = TypeVar("Input") + Output = TypeVar("Output") + """); writer.openBlock("class $L:", "", serviceSymbol.getName(), () -> { var docs = service.getTrait(DocumentationTrait.class) @@ -129,8 +120,10 @@ private void generateOperationExecutor(PythonWriter writer) { var hasStreaming = hasEventStream(); writer.putContext("hasEventStream", hasStreaming); if (hasStreaming) { - writer.addImports("smithy_core.deserializers", Set.of( - "ShapeDeserializer", "DeserializeableShape")); + writer.addImports("smithy_core.deserializers", + Set.of( + "ShapeDeserializer", + "DeserializeableShape")); writer.addStdlibImport("typing", "Any"); } @@ -166,21 +159,21 @@ def _classify_error( if (context.applicationProtocol().isHttpProtocol()) { writer.addDependency(SmithyPythonDependency.SMITHY_HTTP); writer.write(""" - if not isinstance(error, HasFault) and not context.transport_response: - return RetryErrorInfo(error_type=RetryErrorType.TRANSIENT) + if not isinstance(error, HasFault) and not context.transport_response: + return RetryErrorInfo(error_type=RetryErrorType.TRANSIENT) - if context.transport_response: - if context.transport_response.status in [429, 503]: - retry_after = None - retry_header = context.transport_response.fields["retry-after"] - if retry_header and retry_header.values: - retry_after = float(retry_header.values[0]) - return RetryErrorInfo(error_type=RetryErrorType.THROTTLING, retry_after_hint=retry_after) + if context.transport_response: + if context.transport_response.status in [429, 503]: + retry_after = None + retry_header = context.transport_response.fields["retry-after"] + if retry_header and retry_header.values: + retry_after = float(retry_header.values[0]) + return RetryErrorInfo(error_type=RetryErrorType.THROTTLING, retry_after_hint=retry_after) - if context.transport_response.status >= 500: - return RetryErrorInfo(error_type=RetryErrorType.SERVER_ERROR) + if context.transport_response.status >= 500: + return RetryErrorInfo(error_type=RetryErrorType.SERVER_ERROR) - """); + """); } writer.write(""" @@ -378,7 +371,12 @@ async def _handle_attempt( for interceptor in interceptors: interceptor.read_before_attempt(context) - """, pluginSymbol, transportRequest, transportResponse, errorSymbol, configSymbol, + """, + pluginSymbol, + transportRequest, + transportResponse, + errorSymbol, + configSymbol, writer.consumer(w -> context.protocolGenerator().wrapEventStream(context, w))); boolean supportsAuth = !ServiceIndex.of(context.model()).getAuthSchemes(service).isEmpty(); @@ -386,14 +384,15 @@ async def _handle_attempt( if (context.applicationProtocol().isHttpProtocol() && supportsAuth) { writer.pushState(new InitializeHttpAuthParametersSection()); writer.write(""" - # Step 7b: Invoke service_auth_scheme_resolver.resolve_auth_scheme - auth_parameters: $1T = $1T( - operation=operation_name, - ${2C|} - ) + # Step 7b: Invoke service_auth_scheme_resolver.resolve_auth_scheme + auth_parameters: $1T = $1T( + operation=operation_name, + ${2C|} + ) - """, CodegenUtils.getHttpAuthParamsSymbol(context.settings()), - writer.consumer(this::initializeHttpAuthParameters)); + """, + CodegenUtils.getHttpAuthParamsSymbol(context.settings()), + writer.consumer(this::initializeHttpAuthParameters)); writer.popState(); writer.addDependency(SmithyPythonDependency.SMITHY_CORE); @@ -402,32 +401,32 @@ async def _handle_attempt( writer.addImports("smithy_http.aio.interfaces.auth", Set.of("HTTPSigner", "HTTPAuthOption")); writer.addStdlibImport("typing", "Any"); writer.write(""" - auth_options = config.http_auth_scheme_resolver.resolve_auth_scheme( - auth_parameters=auth_parameters - ) - auth_option: HTTPAuthOption | None = None - for option in auth_options: - if option.scheme_id in config.http_auth_schemes: - auth_option = option + auth_options = config.http_auth_scheme_resolver.resolve_auth_scheme( + auth_parameters=auth_parameters + ) + auth_option: HTTPAuthOption | None = None + for option in auth_options: + if option.scheme_id in config.http_auth_schemes: + auth_option = option - signer: HTTPSigner[Any, Any] | None = None - identity: Identity | None = None + signer: HTTPSigner[Any, Any] | None = None + identity: Identity | None = None - if auth_option: - auth_scheme = config.http_auth_schemes[auth_option.scheme_id] + if auth_option: + auth_scheme = config.http_auth_schemes[auth_option.scheme_id] - # Step 7c: Invoke auth_scheme.identity_resolver - identity_resolver = auth_scheme.identity_resolver(config=config) + # Step 7c: Invoke auth_scheme.identity_resolver + identity_resolver = auth_scheme.identity_resolver(config=config) - # Step 7d: Invoke auth_scheme.signer - signer = auth_scheme.signer + # Step 7d: Invoke auth_scheme.signer + signer = auth_scheme.signer - # Step 7e: Invoke identity_resolver.get_identity - identity = await identity_resolver.get_identity( - identity_properties=auth_option.identity_properties - ) + # Step 7e: Invoke identity_resolver.get_identity + identity = await identity_resolver.get_identity( + identity_properties=auth_option.identity_properties + ) - """); + """); } writer.popState(); @@ -439,33 +438,33 @@ async def _handle_attempt( writer.addImport("smithy_http.endpoints", "StaticEndpointParams"); writer.addImport("smithy_core", "URI"); writer.write(""" - # Step 7f: Invoke endpoint_resolver.resolve_endpoint - if config.endpoint_uri is None: - raise $1T( - "No endpoint_uri found on the operation config." + # Step 7f: Invoke endpoint_resolver.resolve_endpoint + if config.endpoint_uri is None: + raise $1T( + "No endpoint_uri found on the operation config." + ) + + endpoint = await config.endpoint_resolver.resolve_endpoint( + StaticEndpointParams(uri=config.endpoint_uri) ) + if not endpoint.uri.path: + path = "" + elif endpoint.uri.path.endswith("/"): + path = endpoint.uri.path[:-1] + else: + path = endpoint.uri.path + if context.transport_request.destination.path: + path += context.transport_request.destination.path + context._transport_request.destination = URI( + scheme=endpoint.uri.scheme, + host=context.transport_request.destination.host + endpoint.uri.host, + path=path, + port=endpoint.uri.port, + query=context.transport_request.destination.query, + ) + context._transport_request.fields.extend(endpoint.headers) - endpoint = await config.endpoint_resolver.resolve_endpoint( - StaticEndpointParams(uri=config.endpoint_uri) - ) - if not endpoint.uri.path: - path = "" - elif endpoint.uri.path.endswith("/"): - path = endpoint.uri.path[:-1] - else: - path = endpoint.uri.path - if context.transport_request.destination.path: - path += context.transport_request.destination.path - context._transport_request.destination = URI( - scheme=endpoint.uri.scheme, - host=context.transport_request.destination.host + endpoint.uri.host, - path=path, - port=endpoint.uri.port, - query=context.transport_request.destination.query, - ) - context._transport_request.fields.extend(endpoint.headers) - - """, errorSymbol); + """, errorSymbol); } writer.popState(); @@ -483,14 +482,14 @@ async def _handle_attempt( writer.pushState(new SignRequestSection()); if (context.applicationProtocol().isHttpProtocol() && supportsAuth) { writer.write(""" - # Step 7i: sign the request - if auth_option and signer: - context._transport_request = await signer.sign( - http_request=context.transport_request, - identity=identity, - signing_properties=auth_option.signer_properties, - ) - """); + # Step 7i: sign the request + if auth_option and signer: + context._transport_request = await signer.sign( + http_request=context.transport_request, + identity=identity, + signing_properties=auth_option.signer_properties, + ) + """); } writer.popState(); @@ -514,17 +513,17 @@ async def _handle_attempt( writer.addDependency(SmithyPythonDependency.SMITHY_HTTP); writer.addImport("smithy_http.interfaces", "HTTPRequestConfiguration"); writer.write(""" - # Step 7m: Invoke http_client.send - request_config = config.http_request_config or HTTPRequestConfiguration() - context_with_response = cast( - InterceptorContext[Input, None, $1T, $2T], context - ) - context_with_response._transport_response = await config.http_client.send( - request=context_with_response.transport_request, - request_config=request_config, - ) + # Step 7m: Invoke http_client.send + request_config = config.http_request_config or HTTPRequestConfiguration() + context_with_response = cast( + InterceptorContext[Input, None, $1T, $2T], context + ) + context_with_response._transport_response = await config.http_client.send( + request=context_with_response.transport_request, + request_config=request_config, + ) - """, transportRequest, transportResponse); + """, transportRequest, transportResponse); } writer.popState(); @@ -696,28 +695,33 @@ private void generateOperation(PythonWriter writer, OperationShape operation) { var output = context.model().expectShape(operation.getOutputShape()); var outputSymbol = context.symbolProvider().toSymbol(output); - writer.openBlock("async def $L(self, input: $T, plugins: list[$T] | None = None) -> $T:", "", - operationSymbol.getName(), inputSymbol, pluginSymbol, outputSymbol, () -> { - writeSharedOperationInit(writer, operation, input); - - if (context.protocolGenerator() == null) { - writer.write("raise NotImplementedError()"); - } else { - var protocolGenerator = context.protocolGenerator(); - var serSymbol = protocolGenerator.getSerializationFunction(context, operation); - var deserSymbol = protocolGenerator.getDeserializationFunction(context, operation); - writer.write(""" - return await self._execute_operation( - input=input, - plugins=operation_plugins, - serialize=$T, - deserialize=$T, - config=self._config, - operation_name=$S, - ) - """, serSymbol, deserSymbol, operation.getId().getName()); - } - }); + writer.openBlock("async def $L(self, input: $T, plugins: list[$T] | None = None) -> $T:", + "", + operationSymbol.getName(), + inputSymbol, + pluginSymbol, + outputSymbol, + () -> { + writeSharedOperationInit(writer, operation, input); + + if (context.protocolGenerator() == null) { + writer.write("raise NotImplementedError()"); + } else { + var protocolGenerator = context.protocolGenerator(); + var serSymbol = protocolGenerator.getSerializationFunction(context, operation); + var deserSymbol = protocolGenerator.getDeserializationFunction(context, operation); + writer.write(""" + return await self._execute_operation( + input=input, + plugins=operation_plugins, + serialize=$T, + deserialize=$T, + config=self._config, + operation_name=$S, + ) + """, serSymbol, deserSymbol, operation.getId().getName()); + } + }); } private void writeSharedOperationInit(PythonWriter writer, OperationShape operation, Shape input) { @@ -731,13 +735,13 @@ private void writeSharedOperationInit(PythonWriter writer, OperationShape operat .orElse("The operation's input."); writer.write(""" - $L + $L - :param input: $L + :param input: $L - :param plugins: A list of callables that modify the configuration dynamically. - Changes made by these plugins only apply for the duration of the operation - execution and will not affect any other operation invocations.""", docs, inputDocs); + :param plugins: A list of callables that modify the configuration dynamically. + Changes made by these plugins only apply for the duration of the operation + execution and will not affect any other operation invocations.""", docs, inputDocs); }); var defaultPlugins = new LinkedHashSet(); diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/CodegenUtils.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/CodegenUtils.java similarity index 80% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/CodegenUtils.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/CodegenUtils.java index b65bd047b..39379536f 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/CodegenUtils.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/CodegenUtils.java @@ -1,18 +1,7 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import static java.lang.String.format; @@ -45,12 +34,15 @@ import software.amazon.smithy.model.traits.ErrorTrait; import software.amazon.smithy.model.traits.TimestampFormatTrait; import software.amazon.smithy.model.traits.TimestampFormatTrait.Format; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.SetUtils; +import software.amazon.smithy.utils.SmithyInternalApi; import software.amazon.smithy.utils.StringUtils; /** * Utility methods likely to be needed across packages. */ +@SmithyInternalApi public final class CodegenUtils { /** @@ -62,7 +54,9 @@ public final class CodegenUtils { public static final int MAX_PREFERRED_LINE_LENGTH = 88; static final Set ERROR_MESSAGE_MEMBER_NAMES = SetUtils.of( - "errormessage", "error_message", "message"); + "errormessage", + "error_message", + "message"); private static final Logger LOGGER = Logger.getLogger(CodegenUtils.class.getName()); @@ -75,8 +69,8 @@ private CodegenUtils() {} public static Symbol getConfigSymbol(PythonSettings settings) { return Symbol.builder() .name("Config") - .namespace(format("%s.config", settings.moduleName()), ".") - .definitionFile(format("./%s/config.py", settings.moduleName())) + .namespace(String.format("%s.config", settings.moduleName()), ".") + .definitionFile(String.format("./%s/config.py", settings.moduleName())) .build(); } @@ -87,8 +81,8 @@ public static Symbol getConfigSymbol(PythonSettings settings) { public static Symbol getPluginSymbol(PythonSettings settings) { return Symbol.builder() .name("Plugin") - .namespace(format("%s.config", settings.moduleName()), ".") - .definitionFile(format("./%s/config.py", settings.moduleName())) + .namespace(String.format("%s.config", settings.moduleName()), ".") + .definitionFile(String.format("./%s/config.py", settings.moduleName())) .build(); } @@ -106,8 +100,8 @@ public static Symbol getPluginSymbol(PythonSettings settings) { public static Symbol getServiceError(PythonSettings settings) { return Symbol.builder() .name("ServiceError") - .namespace(format("%s.models", settings.moduleName()), ".") - .definitionFile(format("./%s/models.py", settings.moduleName())) + .namespace(String.format("%s.models", settings.moduleName()), ".") + .definitionFile(String.format("./%s/models.py", settings.moduleName())) .build(); } @@ -123,8 +117,8 @@ public static Symbol getServiceError(PythonSettings settings) { public static Symbol getApiError(PythonSettings settings) { return Symbol.builder() .name("ApiError") - .namespace(format("%s.models", settings.moduleName()), ".") - .definitionFile(format("./%s/models.py", settings.moduleName())) + .namespace(String.format("%s.models", settings.moduleName()), ".") + .definitionFile(String.format("./%s/models.py", settings.moduleName())) .build(); } @@ -140,8 +134,8 @@ public static Symbol getApiError(PythonSettings settings) { public static Symbol getUnknownApiError(PythonSettings settings) { return Symbol.builder() .name("UnknownApiError") - .namespace(format("%s.models", settings.moduleName()), ".") - .definitionFile(format("./%s/models.py", settings.moduleName())) + .namespace(String.format("%s.models", settings.moduleName()), ".") + .definitionFile(String.format("./%s/models.py", settings.moduleName())) .build(); } @@ -153,10 +147,10 @@ public static Symbol getUnknownApiError(PythonSettings settings) { */ public static Symbol getHttpAuthParamsSymbol(PythonSettings settings) { return Symbol.builder() - .name("HTTPAuthParams") - .namespace(format("%s.auth", settings.moduleName()), ".") - .definitionFile(format("./%s/auth.py", settings.moduleName())) - .build(); + .name("HTTPAuthParams") + .namespace(String.format("%s.auth", settings.moduleName()), ".") + .definitionFile(String.format("./%s/auth.py", settings.moduleName())) + .build(); } /** @@ -167,10 +161,10 @@ public static Symbol getHttpAuthParamsSymbol(PythonSettings settings) { */ public static Symbol getHttpAuthSchemeResolverSymbol(PythonSettings settings) { return Symbol.builder() - .name("HTTPAuthSchemeResolver") - .namespace(format("%s.auth", settings.moduleName()), ".") - .definitionFile(format("./%s/auth.py", settings.moduleName())) - .build(); + .name("HTTPAuthSchemeResolver") + .namespace(String.format("%s.auth", settings.moduleName()), ".") + .definitionFile(String.format("./%s/auth.py", settings.moduleName())) + .build(); } /** @@ -180,7 +174,7 @@ public static Symbol getHttpAuthSchemeResolverSymbol(PythonSettings settings) { * @param shape The member to check. * @return Returns whether the member is probably the error message. */ - static boolean isErrorMessage(Model model, MemberShape shape) { + public static boolean isErrorMessage(Model model, MemberShape shape) { return ERROR_MESSAGE_MEMBER_NAMES.contains(shape.getMemberName().toLowerCase(Locale.US)) && model.expectShape(shape.getContainer()).hasTrait(ErrorTrait.class); } @@ -195,9 +189,9 @@ static boolean isErrorMessage(Model model, MemberShape shape) { public static String runCommand(String command, Path directory) { String[] finalizedCommand; if (System.getProperty("os.name").toLowerCase().startsWith("windows")) { - finalizedCommand = new String[]{"cmd.exe", "/c", command}; + finalizedCommand = new String[] {"cmd.exe", "/c", command}; } else { - finalizedCommand = new String[]{"sh", "-c", command}; + finalizedCommand = new String[] {"sh", "-c", command}; } ProcessBuilder processBuilder = new ProcessBuilder(finalizedCommand) @@ -210,7 +204,8 @@ public static String runCommand(String command, Path directory) { // Capture output for reporting. try (BufferedReader bufferedReader = new BufferedReader(new InputStreamReader( - process.getInputStream(), Charset.defaultCharset()))) { + process.getInputStream(), + Charset.defaultCharset()))) { String line; while ((line = bufferedReader.readLine()) != null) { LOGGER.finest(line); @@ -224,7 +219,9 @@ public static String runCommand(String command, Path directory) { String joinedOutput = String.join(System.lineSeparator(), output); if (process.exitValue() != 0) { throw new CodegenException(format( - "Command `%s` failed with output:%n%n%s", command, joinedOutput)); + "Command `%s` failed with output:%n%n%s", + command, + joinedOutput)); } return joinedOutput; } catch (InterruptedException | IOException e) { @@ -258,8 +255,7 @@ public static String getDefaultPackageImportName(String packageName) { * @return The list of arrays */ public static List toTuples(Map map) { - return map.entrySet().stream().map((entry) -> - List.of(entry.getKey(), entry.getValue()).toArray()).toList(); + return map.entrySet().stream().map((entry) -> List.of(entry.getKey(), entry.getValue()).toArray()).toList(); } /** @@ -277,10 +273,15 @@ public static String getDatetimeConstructor(PythonWriter writer, ZonedDateTime v writer.addStdlibImport("datetime", "timedelta"); timezone = String.format("timezone(timedelta(seconds=%d))", value.getOffset().getTotalSeconds()); } - return String.format("datetime(%d, %d, %d, %d, %d, %d, %d, %s)", value.get(ChronoField.YEAR), - value.get(ChronoField.MONTH_OF_YEAR), value.get(ChronoField.DAY_OF_MONTH), - value.get(ChronoField.HOUR_OF_DAY), value.get(ChronoField.MINUTE_OF_HOUR), - value.get(ChronoField.SECOND_OF_MINUTE), value.get(ChronoField.MICRO_OF_SECOND), timezone); + return String.format("datetime(%d, %d, %d, %d, %d, %d, %d, %s)", + value.get(ChronoField.YEAR), + value.get(ChronoField.MONTH_OF_YEAR), + value.get(ChronoField.DAY_OF_MONTH), + value.get(ChronoField.HOUR_OF_DAY), + value.get(ChronoField.MINUTE_OF_HOUR), + value.get(ChronoField.SECOND_OF_MINUTE), + value.get(ChronoField.MICRO_OF_SECOND), + timezone); } /** @@ -321,7 +322,7 @@ private static ZonedDateTime parseEpochTime(Node value) { } private static ZonedDateTime parseDateTime(Node value) { - Instant instant = Instant.from(DateTimeFormatter.ISO_INSTANT.parse(value.expectStringNode().getValue())); + Instant instant = Instant.from(DateTimeFormatter.ISO_INSTANT.parse(value.expectStringNode().getValue())); return instant.atZone(ZoneId.of("UTC")); } @@ -340,11 +341,11 @@ private static ZonedDateTime parseHttpDate(Node value) { * @param runnable A runnable which uses the member. */ public static void accessStructureMember( - GenerationContext context, - PythonWriter writer, - String variableName, - MemberShape member, - Runnable runnable + GenerationContext context, + PythonWriter writer, + String variableName, + MemberShape member, + Runnable runnable ) { accessStructureMember(context, writer, variableName, member, true, runnable); } @@ -360,12 +361,12 @@ public static void accessStructureMember( * @param runnable A runnable which uses the member. */ public static void accessStructureMember( - GenerationContext context, - PythonWriter writer, - String variableName, - MemberShape member, - boolean accessFalsey, - Runnable runnable + GenerationContext context, + PythonWriter writer, + String variableName, + MemberShape member, + boolean accessFalsey, + Runnable runnable ) { var shouldDedent = false; var isNullable = NullableIndex.of(context.model()).isMemberNullable(member); diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ConfigProperty.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/ConfigProperty.java similarity index 89% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ConfigProperty.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/ConfigProperty.java index ef94bb504..7a8b1d674 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ConfigProperty.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/ConfigProperty.java @@ -1,23 +1,13 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import java.util.Objects; import java.util.function.Consumer; import software.amazon.smithy.codegen.core.Symbol; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.CodeSection; import software.amazon.smithy.utils.SmithyBuilder; import software.amazon.smithy.utils.SmithyUnstableApi; @@ -100,11 +90,11 @@ public static Builder builder() { @Override public SmithyBuilder toBuilder() { return builder() - .name(name) - .type(type) - .nullable(nullable) - .documentation(documentation) - .initialize(initialize); + .name(name) + .type(type) + .nullable(nullable) + .documentation(documentation) + .initialize(initialize); } /** diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/DerivedProperty.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/DerivedProperty.java similarity index 98% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/DerivedProperty.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/DerivedProperty.java index b9b2d42f7..ac0f581db 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/DerivedProperty.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/DerivedProperty.java @@ -2,13 +2,13 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import java.util.Objects; import java.util.Optional; import software.amazon.smithy.codegen.core.Symbol; import software.amazon.smithy.utils.SmithyBuilder; +import software.amazon.smithy.utils.SmithyInternalApi; import software.amazon.smithy.utils.ToSmithyBuilder; /** @@ -16,6 +16,7 @@ * *

This allows for automatically populating the intermediate config. */ +@SmithyInternalApi public final class DerivedProperty implements ToSmithyBuilder { private final String name; private final Source source; @@ -93,8 +94,8 @@ public Optional sourcePropertyName() { @Override public SmithyBuilder toBuilder() { var builder = builder() - .name(name) - .source(source); + .name(name) + .source(source); initializationFunction().ifPresent(builder::initializationFunction); sourcePropertyName().ifPresent(builder::sourcePropertyName); diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/DirectedPythonCodegen.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/DirectedPythonCodegen.java similarity index 87% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/DirectedPythonCodegen.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/DirectedPythonCodegen.java index fb8a30c43..a52cb082e 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/DirectedPythonCodegen.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/DirectedPythonCodegen.java @@ -1,18 +1,7 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import java.nio.file.Path; @@ -50,10 +39,19 @@ import software.amazon.smithy.model.shapes.ServiceShape; import software.amazon.smithy.model.shapes.Shape; import software.amazon.smithy.model.shapes.ShapeId; +import software.amazon.smithy.python.codegen.generators.ConfigGenerator; +import software.amazon.smithy.python.codegen.generators.EnumGenerator; +import software.amazon.smithy.python.codegen.generators.IntEnumGenerator; import software.amazon.smithy.python.codegen.generators.ListGenerator; import software.amazon.smithy.python.codegen.generators.MapGenerator; -import software.amazon.smithy.python.codegen.integration.ProtocolGenerator; -import software.amazon.smithy.python.codegen.integration.PythonIntegration; +import software.amazon.smithy.python.codegen.generators.ProtocolGenerator; +import software.amazon.smithy.python.codegen.generators.SchemaGenerator; +import software.amazon.smithy.python.codegen.generators.SetupGenerator; +import software.amazon.smithy.python.codegen.generators.StructureGenerator; +import software.amazon.smithy.python.codegen.generators.UnionGenerator; +import software.amazon.smithy.python.codegen.integrations.PythonIntegration; +import software.amazon.smithy.python.codegen.writer.PythonDelegator; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.SmithyUnstableApi; @SmithyUnstableApi @@ -75,10 +73,14 @@ public GenerationContext createContext(CreateContextDirective shapes Stream.concat(index.getOrderedShapes().stream(), index.getRecursiveShapes().stream()) .filter(shapes::contains) .filter(shape -> !shape.isOperationShape() && !shape.isResourceShape() - && !shape.isServiceShape() && !shape.isMemberShape() && !Prelude.isPreludeShape(shape)) + && !shape.isServiceShape() + && !shape.isMemberShape() + && !Prelude.isPreludeShape(shape)) .forEach(schemaGenerator); schemaGenerator.finalizeRecursiveShapes(); } @@ -192,8 +196,7 @@ class $3L($1L): } @Override - public void generateResource(GenerateResourceDirective directive) { - } + public void generateResource(GenerateResourceDirective directive) {} @Override public void generateStructure(GenerateStructureDirective directive) { @@ -202,8 +205,7 @@ public void generateStructure(GenerateStructureDirective directive) { - var serSymbol = directive.context().symbolProvider().toSymbol(directive.shape()) + var serSymbol = directive.context() + .symbolProvider() + .toSymbol(directive.shape()) .expectProperty(SymbolProperties.SERIALIZER); var delegator = directive.context().writerDelegator(); delegator.useFileWriter(serSymbol.getDefinitionFile(), serSymbol.getNamespace(), writer -> { @@ -246,7 +248,9 @@ public void generateList(GenerateListDirective directive) { - var serSymbol = directive.context().symbolProvider().toSymbol(directive.shape()) + var serSymbol = directive.context() + .symbolProvider() + .toSymbol(directive.shape()) .expectProperty(SymbolProperties.SERIALIZER); var delegator = directive.context().writerDelegator(); delegator.useFileWriter(serSymbol.getDefinitionFile(), serSymbol.getNamespace(), writer -> { @@ -276,15 +280,20 @@ public void customizeBeforeIntegrations(CustomizeDirective directive) { - var directories = directive.context().writerDelegator().getWriters().keySet().stream() + var directories = directive.context() + .writerDelegator() + .getWriters() + .keySet() + .stream() .map(Paths::get) .filter(path -> !path.getParent().equals(directive.fileManifest().getBaseDir())) .collect(Collectors.groupingBy(Path::getParent, Collectors.toSet())); for (var entry : directories.entrySet()) { var initPath = entry.getKey().resolve("__init__.py"); if (!entry.getValue().contains(initPath)) { - directive.fileManifest().writeFile(initPath, - "# Code generated by smithy-python-codegen DO NOT EDIT.\n"); + directive.fileManifest() + .writeFile(initPath, + "# Code generated by smithy-python-codegen DO NOT EDIT.\n"); } } } @@ -315,7 +324,8 @@ public void customizeAfterIntegrations(CustomizeDirective supportedAuthSchemes + PythonWriter writer, + Symbol paramsSymbol, + Symbol resolverSymbol, + Map supportedAuthSchemes ) { var resolvedAuthSchemes = ServiceIndex.of(context.model()) - .getEffectiveAuthSchemes(settings.service()).keySet().stream() - .filter(supportedAuthSchemes::containsKey) - .map(supportedAuthSchemes::get) - .toList(); + .getEffectiveAuthSchemes(settings.service()) + .keySet() + .stream() + .filter(supportedAuthSchemes::containsKey) + .map(supportedAuthSchemes::get) + .toList(); writer.pushState(new GenerateHttpAuthSchemeResolverSection(resolvedAuthSchemes)); writer.addDependency(SmithyPythonDependency.SMITHY_CORE); writer.addDependency(SmithyPythonDependency.SMITHY_HTTP); writer.addImport("smithy_http.aio.interfaces.auth", "HTTPAuthOption"); writer.write(""" - class $1L: - def resolve_auth_scheme(self, auth_parameters: $2T) -> list[HTTPAuthOption]: - auth_options: list[HTTPAuthOption] = [] - - ${3C|} - ${4C|} - - """, resolverSymbol.getName(), paramsSymbol, - writer.consumer(w -> writeOperationAuthOptions(w, supportedAuthSchemes)), - writer.consumer(w -> writeAuthOptions(w, resolvedAuthSchemes))); + class $1L: + def resolve_auth_scheme(self, auth_parameters: $2T) -> list[HTTPAuthOption]: + auth_options: list[HTTPAuthOption] = [] + + ${3C|} + ${4C|} + + """, + resolverSymbol.getName(), + paramsSymbol, + writer.consumer(w -> writeOperationAuthOptions(w, supportedAuthSchemes)), + writer.consumer(w -> writeAuthOptions(w, resolvedAuthSchemes))); writer.popState(); } @@ -122,33 +126,35 @@ private void writeOperationAuthOptions(PythonWriter writer, Map writeAuthOptions(w, operationAuthSchemes))); + """, operation.getId().getName(), writer.consumer(w -> writeAuthOptions(w, operationAuthSchemes))); } } private void writeAuthOptions(PythonWriter writer, List authSchemes) { var authOptionInitializers = authSchemes.stream() - .map(scheme -> scheme.getAuthOptionGenerator(context)) - .toList(); + .map(scheme -> scheme.getAuthOptionGenerator(context)) + .toList(); writer.pushState(); writer.putContext("authOptionInitializers", authOptionInitializers); writer.write(""" - ${#authOptionInitializers} - if ((option := ${value:T}(auth_parameters)) is not None): - auth_options.append(option) + ${#authOptionInitializers} + if ((option := ${value:T}(auth_parameters)) is not None): + auth_options.append(option) - ${/authOptionInitializers} - return auth_options - """); + ${/authOptionInitializers} + return auth_options + """); writer.popState(); } } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/HttpProtocolTestGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/HttpProtocolTestGenerator.java similarity index 63% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/HttpProtocolTestGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/HttpProtocolTestGenerator.java index fb231d71f..009b4dd6f 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/HttpProtocolTestGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/HttpProtocolTestGenerator.java @@ -1,18 +1,7 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import java.util.ArrayList; @@ -62,6 +51,7 @@ import software.amazon.smithy.protocoltests.traits.HttpRequestTestsTrait; import software.amazon.smithy.protocoltests.traits.HttpResponseTestCase; import software.amazon.smithy.protocoltests.traits.HttpResponseTestsTrait; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.CaseUtils; import software.amazon.smithy.utils.Pair; import software.amazon.smithy.utils.SimpleParser; @@ -180,107 +170,104 @@ private void generateRequestTest(OperationShape operation, HttpRequestTestCase t String.format("%s_request_%s", testCase.getId(), operation.getId().getName()), testFilter.test(operation, testCase), () -> { - var hostSplit = testCase.getHost().orElse("example.com").split("/", 2); - var host = hostSplit[0]; - var resolvedHost = testCase.getResolvedHost().map(h -> h.split("/", 2)[0]).orElse(host); - String path; - if (hostSplit.length != 1) { - path = hostSplit[1]; - } else { - path = ""; - } - writer.addImport("smithy_core.retries", "SimpleRetryStrategy"); - writeClientBlock(context.symbolProvider().toSymbol(service), testCase, Optional.of(() -> { - writer.write(""" - config = $T( - endpoint_uri="https://$L/$L", - http_client = $T(), - retry_strategy=SimpleRetryStrategy(max_attempts=1), - ) - """, - CodegenUtils.getConfigSymbol(context.settings()), - host, - path, - REQUEST_TEST_ASYNC_HTTP_CLIENT_SYMBOL - ); - })); - - // Generate the input using the expected shape and params - var inputShape = model.expectShape(operation.getInputShape(), StructureShape.class); - writer.write("input_ = $C\n", - (Runnable) () -> testCase.getParams().accept(new ValueNodeVisitor(inputShape)) - ); - - // Execute the command, and catch the expected exception - writer.addImport(SmithyPythonDependency.PYTEST.packageName(), "fail"); - writer.addImport(SmithyPythonDependency.PYTEST.packageName(), "raises"); - writer.addStdlibImport("urllib.parse", "parse_qsl"); - writer.write(""" - try: - await client.$1T(input_) - fail("Expected '$2T' exception to be thrown!") - except $2T as err: - actual = err.request - - assert actual.method == $3S - assert actual.destination.path == $4S - assert actual.destination.host == $5S - - query = actual.destination.query - actual_query_segments: list[str] = query.split("&") if query else [] - expected_query_segments: list[str] = $6J - for expected_query_segment in expected_query_segments: - assert expected_query_segment in actual_query_segments - actual_query_segments.remove(expected_query_segment) - - actual_query_keys: list[str] = [k.lower() for k, v in parse_qsl(query)] - forbidden_query_keys: set[str] = set($7J) - for forbidden_key in forbidden_query_keys: - assert forbidden_key.lower() not in actual_query_keys - - required_query_keys: list[str] = $8J - for required_query_key in required_query_keys: - assert required_query_key.lower() in actual_query_keys - # These are removed because the required list could require more than one - # value. By removing each value after we assert that it's there, we can - # effectively validate that without having to have a more complex comparator. - actual_query_keys.remove(required_query_key) - - expected_headers: list[tuple[str, str]] = [ - ${9C|} - ] - for expected_key, expected_val in expected_headers: - assert expected_val in actual.fields[expected_key].values - - forbidden_headers: set[str] = set($10J) - for forbidden_key in forbidden_headers: - with raises(KeyError): - actual.fields[forbidden_key] - - required_headers: list[str] = $11J - for required_key in required_headers: - # del Fields[required_key] raises KeyError if key does not exist - del actual.fields[required_key] - - ${12C|} - - except Exception as err: - fail(f"Expected '$2L' exception to be thrown, but received {type(err).__name__}: {err}") - """, - context.symbolProvider().toSymbol(operation), - TEST_HTTP_SERVICE_ERR_SYMBOL, - testCase.getMethod(), - testCase.getUri(), - resolvedHost, - testCase.getQueryParams(), - toLowerCase(testCase.getForbidQueryParams()), - toLowerCase(testCase.getRequireQueryParams()), - (Runnable) () -> writeExpectedHeaders(testCase, operation), - toLowerCase(testCase.getForbidHeaders()), - toLowerCase(testCase.getRequireHeaders()), - writer.consumer(w -> writeRequestBodyComparison(testCase, w)) - ); - }); + var hostSplit = testCase.getHost().orElse("example.com").split("/", 2); + var host = hostSplit[0]; + var resolvedHost = testCase.getResolvedHost().map(h -> h.split("/", 2)[0]).orElse(host); + String path; + if (hostSplit.length != 1) { + path = hostSplit[1]; + } else { + path = ""; + } + writer.addImport("smithy_core.retries", "SimpleRetryStrategy"); + writeClientBlock(context.symbolProvider().toSymbol(service), testCase, Optional.of(() -> { + writer.write(""" + config = $T( + endpoint_uri="https://$L/$L", + http_client = $T(), + retry_strategy=SimpleRetryStrategy(max_attempts=1), + ) + """, + CodegenUtils.getConfigSymbol(context.settings()), + host, + path, + REQUEST_TEST_ASYNC_HTTP_CLIENT_SYMBOL); + })); + + // Generate the input using the expected shape and params + var inputShape = model.expectShape(operation.getInputShape(), StructureShape.class); + writer.write("input_ = $C\n", + (Runnable) () -> testCase.getParams().accept(new ValueNodeVisitor(inputShape))); + + // Execute the command, and catch the expected exception + writer.addImport(SmithyPythonDependency.PYTEST.packageName(), "fail"); + writer.addImport(SmithyPythonDependency.PYTEST.packageName(), "raises"); + writer.addStdlibImport("urllib.parse", "parse_qsl"); + writer.write(""" + try: + await client.$1T(input_) + fail("Expected '$2T' exception to be thrown!") + except $2T as err: + actual = err.request + + assert actual.method == $3S + assert actual.destination.path == $4S + assert actual.destination.host == $5S + + query = actual.destination.query + actual_query_segments: list[str] = query.split("&") if query else [] + expected_query_segments: list[str] = $6J + for expected_query_segment in expected_query_segments: + assert expected_query_segment in actual_query_segments + actual_query_segments.remove(expected_query_segment) + + actual_query_keys: list[str] = [k.lower() for k, v in parse_qsl(query)] + forbidden_query_keys: set[str] = set($7J) + for forbidden_key in forbidden_query_keys: + assert forbidden_key.lower() not in actual_query_keys + + required_query_keys: list[str] = $8J + for required_query_key in required_query_keys: + assert required_query_key.lower() in actual_query_keys + # These are removed because the required list could require more than one + # value. By removing each value after we assert that it's there, we can + # effectively validate that without having to have a more complex comparator. + actual_query_keys.remove(required_query_key) + + expected_headers: list[tuple[str, str]] = [ + ${9C|} + ] + for expected_key, expected_val in expected_headers: + assert expected_val in actual.fields[expected_key].values + + forbidden_headers: set[str] = set($10J) + for forbidden_key in forbidden_headers: + with raises(KeyError): + actual.fields[forbidden_key] + + required_headers: list[str] = $11J + for required_key in required_headers: + # del Fields[required_key] raises KeyError if key does not exist + del actual.fields[required_key] + + ${12C|} + + except Exception as err: + fail(f"Expected '$2L' exception to be thrown, but received {type(err).__name__}: {err}") + """, + context.symbolProvider().toSymbol(operation), + TEST_HTTP_SERVICE_ERR_SYMBOL, + testCase.getMethod(), + testCase.getUri(), + resolvedHost, + testCase.getQueryParams(), + toLowerCase(testCase.getForbidQueryParams()), + toLowerCase(testCase.getRequireQueryParams()), + (Runnable) () -> writeExpectedHeaders(testCase, operation), + toLowerCase(testCase.getForbidHeaders()), + toLowerCase(testCase.getRequireHeaders()), + writer.consumer(w -> writeRequestBodyComparison(testCase, w))); + }); } private List toLowerCase(List given) { @@ -288,8 +275,8 @@ private List toLowerCase(List given) { } private void writeExpectedHeaders( - HttpRequestTestCase testCase, - OperationShape operation + HttpRequestTestCase testCase, + OperationShape operation ) { var headerPairs = splitHeaders(testCase, operation); for (Pair pair : headerPairs) { @@ -299,15 +286,15 @@ private void writeExpectedHeaders( // TODO: upstream this to Smithy itself or update the protocol test traits private List> splitHeaders( - HttpRequestTestCase testCase, - OperationShape operation + HttpRequestTestCase testCase, + OperationShape operation ) { // Get a map of headers to binding info for headers that are bound to lists. var listBindings = HttpBindingIndex.of(model) - .getRequestBindings(operation, Location.HEADER) - .stream() - .filter(binding -> model.expectShape(binding.getMember().getTarget()).isListShape()) - .collect(Collectors.toMap(HttpBinding::getLocationName, binding -> binding)); + .getRequestBindings(operation, Location.HEADER) + .stream() + .filter(binding -> model.expectShape(binding.getMember().getTarget()).isListShape()) + .collect(Collectors.toMap(HttpBinding::getLocationName, binding -> binding)); // Go through each of the headers on the protocol test and turn them into key-value tuples. var headerPairs = new ArrayList>(); @@ -328,8 +315,11 @@ private List> splitHeaders( headerPairs.addAll(splitHeader(binding, entry.getKey(), entry.getValue())); } catch (Exception e) { throw new CodegenException( - String.format("Failed to split header in protocol test %s - `%s`: `%s` - %s", - testCase.getId(), entry.getKey(), entry.getValue(), e)); + String.format("Failed to split header in protocol test %s - `%s`: `%s` - %s", + testCase.getId(), + entry.getKey(), + entry.getValue(), + e)); } } @@ -346,7 +336,9 @@ private List> splitHeader(HttpBinding binding, String key, if (listMember.isTimestampShape()) { var httpIndex = HttpBindingIndex.of(model); var format = httpIndex.determineTimestampFormat( - binding.getMember(), binding.getLocation(), Format.HTTP_DATE); + binding.getMember(), + binding.getLocation(), + Format.HTTP_DATE); isHttpDateMember = format == Format.HTTP_DATE; } @@ -415,11 +407,11 @@ private void compareMediaBlob(HttpMessageTestCase testCase, PythonWriter writer) if (contentType.equals("application/json") || contentType.endsWith("+json")) { writer.addStdlibImport("json"); writer.write(""" - actual_body = json.loads(actual_body_content) if actual_body_content else "" - expected_body = json.loads(expected_body_content) - assert actual_body == expected_body + actual_body = json.loads(actual_body_content) if actual_body_content else "" + expected_body = json.loads(expected_body_content) + assert actual_body == expected_body - """); + """); return; } writer.write("assert actual_body_content == expected_body_content\n"); @@ -432,48 +424,45 @@ private void generateResponseTest(OperationShape operation, HttpResponseTestCase String.format("%s_response_%s", testCase.getId(), operation.getId().getName()), testFilter.test(operation, testCase), () -> { - writeClientBlock(context.symbolProvider().toSymbol(service), testCase, Optional.of(() -> { - writer.write(""" - config = $T( - endpoint_uri="https://example.com", - http_client = $T( - status=$L, - headers=$J, - body=b$S, - ), - ) - """, - CodegenUtils.getConfigSymbol(context.settings()), - RESPONSE_TEST_ASYNC_HTTP_CLIENT_SYMBOL, - testCase.getCode(), - CodegenUtils.toTuples(testCase.getHeaders()), - testCase.getBody().filter(body -> !body.isEmpty()).orElse("") - ); - })); - // Create an empty input object to pass - var inputShape = model.expectShape(operation.getInputShape(), StructureShape.class); - var outputShape = model.expectShape(operation.getOutputShape(), StructureShape.class); - writer.write("input_ = $C\n", - (Runnable) () -> (ObjectNode.builder().build()).accept(new ValueNodeVisitor(inputShape)) - ); - - // Execute the command, fail if unexpected exception - writer.addImport(SmithyPythonDependency.PYTEST.packageName(), "fail", "fail"); - writer.write(""" - try: - actual = await client.$T(input_) - except Exception as err: - fail(f"Expected a valid response, but received: {type(err).__name__}: {err}") - else: - expected = $C - - ${C|} - """, - context.symbolProvider().toSymbol(operation), - (Runnable) () -> testCase.getParams().accept(new ValueNodeVisitor(outputShape)), - (Runnable) () -> assertResponseEqual(testCase, operation) - ); - }); + writeClientBlock(context.symbolProvider().toSymbol(service), testCase, Optional.of(() -> { + writer.write(""" + config = $T( + endpoint_uri="https://example.com", + http_client = $T( + status=$L, + headers=$J, + body=b$S, + ), + ) + """, + CodegenUtils.getConfigSymbol(context.settings()), + RESPONSE_TEST_ASYNC_HTTP_CLIENT_SYMBOL, + testCase.getCode(), + CodegenUtils.toTuples(testCase.getHeaders()), + testCase.getBody().filter(body -> !body.isEmpty()).orElse("")); + })); + // Create an empty input object to pass + var inputShape = model.expectShape(operation.getInputShape(), StructureShape.class); + var outputShape = model.expectShape(operation.getOutputShape(), StructureShape.class); + writer.write("input_ = $C\n", + (Runnable) () -> (ObjectNode.builder().build()).accept(new ValueNodeVisitor(inputShape))); + + // Execute the command, fail if unexpected exception + writer.addImport(SmithyPythonDependency.PYTEST.packageName(), "fail", "fail"); + writer.write(""" + try: + actual = await client.$T(input_) + except Exception as err: + fail(f"Expected a valid response, but received: {type(err).__name__}: {err}") + else: + expected = $C + + ${C|} + """, + context.symbolProvider().toSymbol(operation), + (Runnable) () -> testCase.getParams().accept(new ValueNodeVisitor(outputShape)), + (Runnable) () -> assertResponseEqual(testCase, operation)); + }); } // See also: https://smithy.io/2.0/additional-specs/http-protocol-compliance-tests.html#httpresponsetests-trait @@ -486,52 +475,52 @@ private void generateErrorResponseTest( String.format("%s_error_%s", testCase.getId(), operation.getId().getName()), testFilter.test(error, testCase), () -> { - writeClientBlock(context.symbolProvider().toSymbol(service), testCase, Optional.of(() -> { - writer.write(""" - config = $T( - endpoint_uri="https://example.com", - http_client = $T( - status=$L, - headers=$J, - body=b$S, - ), - ) - """, - CodegenUtils.getConfigSymbol(context.settings()), - RESPONSE_TEST_ASYNC_HTTP_CLIENT_SYMBOL, - testCase.getCode(), - CodegenUtils.toTuples(testCase.getHeaders()), - testCase.getBody().orElse("") - ); - })); - // Create an empty input object to pass - var inputShape = model.expectShape(operation.getInputShape(), StructureShape.class); - writer.write("input_ = $C\n", - (Runnable) () -> (Node.objectNode()).accept(new ValueNodeVisitor(inputShape)) - ); - // Execute the command, fail if unexpected exception - writer.addImport(SmithyPythonDependency.PYTEST.packageName(), "fail", "fail"); - writer.write(""" - try: - await client.$1T(input_) - fail("Expected '$2L' exception to be thrown!") - except Exception as err: - if type(err).__name__ != $2S: - fail(f"Expected '$2L' exception to be thrown, but received {type(err).__name__}: {err}") - """, - context.symbolProvider().toSymbol(operation), - error.getId().getName() - ); - // TODO: Correctly assert the status code and other values - }); + writeClientBlock(context.symbolProvider().toSymbol(service), testCase, Optional.of(() -> { + writer.write(""" + config = $T( + endpoint_uri="https://example.com", + http_client = $T( + status=$L, + headers=$J, + body=b$S, + ), + ) + """, + CodegenUtils.getConfigSymbol(context.settings()), + RESPONSE_TEST_ASYNC_HTTP_CLIENT_SYMBOL, + testCase.getCode(), + CodegenUtils.toTuples(testCase.getHeaders()), + testCase.getBody().orElse("")); + })); + // Create an empty input object to pass + var inputShape = model.expectShape(operation.getInputShape(), StructureShape.class); + writer.write("input_ = $C\n", + (Runnable) () -> (Node.objectNode()).accept(new ValueNodeVisitor(inputShape))); + // Execute the command, fail if unexpected exception + writer.addImport(SmithyPythonDependency.PYTEST.packageName(), "fail", "fail"); + writer.write( + """ + try: + await client.$1T(input_) + fail("Expected '$2L' exception to be thrown!") + except Exception as err: + if type(err).__name__ != $2S: + fail(f"Expected '$2L' exception to be thrown, but received {type(err).__name__}: {err}") + """, + context.symbolProvider().toSymbol(operation), + error.getId().getName()); + // TODO: Correctly assert the status code and other values + }); } private void assertResponseEqual(HttpMessageTestCase testCase, Shape operationOrError) { var index = HttpBindingIndex.of(context.model()); var streamBinding = index.getResponseBindings(operationOrError, Location.PAYLOAD) - .stream() - .filter(binding -> binding.getMember().getMemberTrait(context.model(), StreamingTrait.class).isPresent()) - .findAny(); + .stream() + .filter(binding -> binding.getMember() + .getMemberTrait(context.model(), StreamingTrait.class) + .isPresent()) + .findAny(); if (streamBinding.isEmpty()) { writer.write("assert actual == expected\n"); @@ -552,10 +541,10 @@ private void assertResponseEqual(HttpMessageTestCase testCase, Shape operationOr writer.addImport("smithy_core.aio.interfaces", "AsyncByteStream"); writer.addImport("smithy_core.aio.types", "AsyncBytesReader"); writer.write(""" - assert isinstance(actual.$1L, AsyncByteStream) - actual_body_content = await actual.$1L.read() - expected_body_content = await AsyncBytesReader(expected.$1L).read() - """, memberName); + assert isinstance(actual.$1L, AsyncByteStream) + actual_body_content = await actual.$1L.read() + expected_body_content = await AsyncBytesReader(expected.$1L).read() + """, memberName); compareMediaBlob(testCase, writer); continue; } @@ -568,8 +557,7 @@ private void onlyIfProtocolMatches(T testCase, R if (testCase.getProtocol().equals(protocol)) { LOGGER.fine(() -> String.format("Generating protocol test case for %s.%s", service.getId(), - testCase.getId()) - ); + testCase.getId())); runnable.run(); } } @@ -615,65 +603,66 @@ private void writeUtilStubs(Symbol serviceSymbol) { LOGGER.fine(String.format("Writing utility stubs for %s : %s", serviceSymbol.getName(), protocol.getName())); writer.addDependency(SmithyPythonDependency.SMITHY_CORE); writer.addDependency(SmithyPythonDependency.SMITHY_HTTP); - writer.addImports("smithy_http.interfaces", Set.of( - "HTTPRequestConfiguration", "HTTPClientConfiguration")); + writer.addImports("smithy_http.interfaces", + Set.of( + "HTTPRequestConfiguration", + "HTTPClientConfiguration")); writer.addImports("smithy_http.aio.interfaces", Set.of("HTTPRequest", "HTTPResponse")); writer.addImport("smithy_http", "tuples_to_fields"); writer.addImport("smithy_http.aio", "HTTPResponse", "_HTTPResponse"); writer.addImport("smithy_core.aio.utils", "async_list"); writer.write(""" - class $1L($2T): - ""\"A test error that subclasses the service-error for protocol tests.""\" - - def __init__(self, request: HTTPRequest): - self.request = request - - - class $3L: - ""\"An asynchronous HTTP client solely for testing purposes.""\" - - def __init__(self, *, client_config: HTTPClientConfiguration | None = None): - self._client_config = client_config - - async def send( - self, *, request: HTTPRequest, request_config: HTTPRequestConfiguration | None = None - ) -> HTTPResponse: - # Raise the exception with the request object to bypass actual request handling - raise $1T(request) - - - class $4L: - ""\"An asynchronous HTTP client solely for testing purposes.""\" - - def __init__( - self, - *, - client_config: HTTPClientConfiguration | None = None, - status: int = 200, - headers: list[tuple[str, str]] | None = None, - body: bytes = b"", - ): - self._client_config = client_config - self.status = status - self.fields = tuples_to_fields(headers or []) - self.body = body - - async def send( - self, *, request: HTTPRequest, request_config: HTTPRequestConfiguration | None = None - ) -> _HTTPResponse: - # Pre-construct the response from the request and return it - return _HTTPResponse( - status=self.status, - fields=self.fields, - body=async_list([self.body]), - ) - """, - TEST_HTTP_SERVICE_ERR_SYMBOL, - CodegenUtils.getServiceError(context.settings()), - REQUEST_TEST_ASYNC_HTTP_CLIENT_SYMBOL, - RESPONSE_TEST_ASYNC_HTTP_CLIENT_SYMBOL - ); + class $1L($2T): + ""\"A test error that subclasses the service-error for protocol tests.""\" + + def __init__(self, request: HTTPRequest): + self.request = request + + + class $3L: + ""\"An asynchronous HTTP client solely for testing purposes.""\" + + def __init__(self, *, client_config: HTTPClientConfiguration | None = None): + self._client_config = client_config + + async def send( + self, *, request: HTTPRequest, request_config: HTTPRequestConfiguration | None = None + ) -> HTTPResponse: + # Raise the exception with the request object to bypass actual request handling + raise $1T(request) + + + class $4L: + ""\"An asynchronous HTTP client solely for testing purposes.""\" + + def __init__( + self, + *, + client_config: HTTPClientConfiguration | None = None, + status: int = 200, + headers: list[tuple[str, str]] | None = None, + body: bytes = b"", + ): + self._client_config = client_config + self.status = status + self.fields = tuples_to_fields(headers or []) + self.body = body + + async def send( + self, *, request: HTTPRequest, request_config: HTTPRequestConfiguration | None = None + ) -> _HTTPResponse: + # Pre-construct the response from the request and return it + return _HTTPResponse( + status=self.status, + fields=self.fields, + body=async_list([self.body]), + ) + """, + TEST_HTTP_SERVICE_ERR_SYMBOL, + CodegenUtils.getServiceError(context.settings()), + REQUEST_TEST_ASYNC_HTTP_CLIENT_SYMBOL, + RESPONSE_TEST_ASYNC_HTTP_CLIENT_SYMBOL); } /** @@ -776,18 +765,17 @@ public Void stringNode(StringNode node) { } private Void structureShape(StructureShape shape, ObjectNode node) { - writer.openBlock("$T(", ")", + writer.openBlock("$T(", + ")", context.symbolProvider().toSymbol(shape), - () -> structureMemberShapes(shape, node) - ); + () -> structureMemberShapes(shape, node)); return null; } private Void structureMemberShapes(StructureShape container, ObjectNode node) { node.getMembers().forEach((keyNode, valueNode) -> { - var memberShape = container.getMember(keyNode.getValue()).orElseThrow(() -> - new CodegenException("unknown memberShape: " + keyNode.getValue()) - ); + var memberShape = container.getMember(keyNode.getValue()) + .orElseThrow(() -> new CodegenException("unknown memberShape: " + keyNode.getValue())); var targetShape = model.expectShape(memberShape.getTarget()); var formatString = "$L = $C,"; @@ -798,14 +786,14 @@ private Void structureMemberShapes(StructureShape container, ObjectNode node) { writer.write(formatString, context.symbolProvider().toMemberName(memberShape), - (Runnable) () -> valueNode.accept(new ValueNodeVisitor(targetShape)) - ); + (Runnable) () -> valueNode.accept(new ValueNodeVisitor(targetShape))); }); return null; } private Void mapShape(MapShape shape, ObjectNode node) { - writer.openBlock("{", "}", + writer.openBlock("{", + "}", () -> node.getMembers().forEach((keyNode, valueNode) -> { var targetShape = model.expectShape(shape.getValue().getTarget()); @@ -817,22 +805,19 @@ private Void mapShape(MapShape shape, ObjectNode node) { writer.write(formatString, keyNode.getValue(), - (Runnable) () -> valueNode.accept(new ValueNodeVisitor(targetShape)) - ); - }) - ); + (Runnable) () -> valueNode.accept(new ValueNodeVisitor(targetShape))); + })); return null; } private Void documentShape(DocumentShape shape, ObjectNode node) { - writer.openBlock("{", "}", + writer.openBlock("{", + "}", () -> node.getMembers().forEach((keyNode, valueNode) -> { writer.write("$S: $C,", keyNode.getValue(), - (Runnable) () -> valueNode.accept(this) - ); - }) - ); + (Runnable) () -> valueNode.accept(this)); + })); return null; } @@ -851,11 +836,11 @@ private Void unionShape(UnionShape shape, ObjectNode node) { } private Void unionShape(MemberShape memberShape, Shape targetShape, Node node) { - writer.openBlock("$T(", ")", + writer.openBlock("$T(", + ")", context.symbolProvider().toSymbol(memberShape), () -> writer.write("value = $C", - (Runnable) () -> node.accept(new ValueNodeVisitor(targetShape))) - ); + (Runnable) () -> node.accept(new ValueNodeVisitor(targetShape)))); return null; } } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonClientCodegenPlugin.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/PythonClientCodegenPlugin.java similarity index 65% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonClientCodegenPlugin.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/PythonClientCodegenPlugin.java index 45db2a364..567e8efd8 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonClientCodegenPlugin.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/PythonClientCodegenPlugin.java @@ -1,24 +1,14 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import software.amazon.smithy.build.PluginContext; import software.amazon.smithy.build.SmithyBuildPlugin; import software.amazon.smithy.codegen.core.directed.CodegenDirector; -import software.amazon.smithy.python.codegen.integration.PythonIntegration; +import software.amazon.smithy.python.codegen.integrations.PythonIntegration; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.SmithyUnstableApi; /** @@ -33,8 +23,8 @@ public String getName() { @Override public void execute(PluginContext context) { - CodegenDirector runner - = new CodegenDirector<>(); + CodegenDirector runner = + new CodegenDirector<>(); PythonSettings settings = PythonSettings.fromNode(context.getSettings()); runner.settings(settings); diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonDependency.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/PythonDependency.java similarity index 76% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonDependency.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/PythonDependency.java index 2e0fb9fa3..89f016b9e 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonDependency.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/PythonDependency.java @@ -1,18 +1,7 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import java.util.Collections; @@ -26,8 +15,11 @@ */ @SmithyUnstableApi public record PythonDependency( - String packageName, String version, Type type, boolean isLink, List optionalDependencies -) implements SymbolDependencyContainer { + String packageName, + String version, + Type type, + boolean isLink, + List optionalDependencies) implements SymbolDependencyContainer { public PythonDependency( String packageName, diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonSettings.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/PythonSettings.java similarity index 88% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonSettings.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/PythonSettings.java index ec7645fbe..f152f2d9c 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonSettings.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/PythonSettings.java @@ -1,18 +1,7 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import java.util.Arrays; @@ -41,8 +30,7 @@ public record PythonSettings( ShapeId service, String moduleName, String moduleVersion, - String moduleDescription - ) implements ToSmithyBuilder { + String moduleDescription) implements ToSmithyBuilder { private static final String SERVICE = "service"; private static final String MODULE_NAME = "module"; @@ -67,8 +55,7 @@ public PythonSettings(Builder builder) { builder.moduleVersion, StringUtils.isBlank(builder.moduleDescription) ? builder.moduleName + " client" - : builder.moduleDescription - ); + : builder.moduleDescription); } /** diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SmithyPythonDependency.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/SmithyPythonDependency.java similarity index 77% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SmithyPythonDependency.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/SmithyPythonDependency.java index 26a34ca17..a09293113 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SmithyPythonDependency.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/SmithyPythonDependency.java @@ -1,18 +1,7 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import java.util.List; @@ -36,8 +25,7 @@ public final class SmithyPythonDependency { // You'll need to locally install this before we publish "==0.0.1", Type.DEPENDENCY, - false - ); + false); /** * The core smithy-python python package. @@ -49,8 +37,7 @@ public final class SmithyPythonDependency { // You'll need to locally install this before we publish "==0.0.1", Type.DEPENDENCY, - false - ); + false); /** * The core smithy-json python package. @@ -59,8 +46,7 @@ public final class SmithyPythonDependency { "smithy_json", "==0.0.1", Type.DEPENDENCY, - false - ); + false); /** * Core interfaces for event streams. @@ -69,8 +55,7 @@ public final class SmithyPythonDependency { "smithy_event_stream", "==0.0.1", Type.DEPENDENCY, - false - ); + false); /** * EventStream implementations for application/vnd.amazon.eventstream. @@ -79,8 +64,7 @@ public final class SmithyPythonDependency { "aws_event_stream", "==0.0.1", Type.DEPENDENCY, - false - ); + false); /** * testing framework used in generated functional tests. @@ -89,18 +73,16 @@ public final class SmithyPythonDependency { "pytest", ">=7.2.0,<8.0.0", Type.TEST_DEPENDENCY, - false - ); + false); /** * testing framework used in generated functional tests. */ public static final PythonDependency PYTEST_ASYNCIO = new PythonDependency( - "pytest-asyncio", - ">=0.20.3,<0.21.0", - Type.TEST_DEPENDENCY, - false - ); + "pytest-asyncio", + ">=0.20.3,<0.21.0", + Type.TEST_DEPENDENCY, + false); private SmithyPythonDependency() {} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SymbolProperties.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/SymbolProperties.java similarity index 99% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SymbolProperties.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/SymbolProperties.java index 31bfb7975..46862aa72 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SymbolProperties.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/SymbolProperties.java @@ -2,7 +2,6 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import java.util.List; diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SymbolVisitor.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/SymbolVisitor.java similarity index 82% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SymbolVisitor.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/SymbolVisitor.java index b57dc131d..4adc041e7 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SymbolVisitor.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/SymbolVisitor.java @@ -1,18 +1,7 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen; import static java.lang.String.format; @@ -58,6 +47,7 @@ import software.amazon.smithy.model.traits.StreamingTrait; import software.amazon.smithy.utils.CaseUtils; import software.amazon.smithy.utils.MediaType; +import software.amazon.smithy.utils.SmithyInternalApi; import software.amazon.smithy.utils.StringUtils; /** @@ -69,7 +59,8 @@ *

{@see {@link SymbolProperties}} for various additional properties that * may be attached to symbols. */ -final class SymbolVisitor implements SymbolProvider, ShapeVisitor { +@SmithyInternalApi +public final class SymbolVisitor implements SymbolProvider, ShapeVisitor { private static final Logger LOGGER = Logger.getLogger(SymbolVisitor.class.getName()); private static final String SHAPES_FILE = "models"; @@ -88,28 +79,28 @@ final class SymbolVisitor implements SymbolProvider, ShapeVisitor { // Load reserved words from new-line delimited files. var reservedClassNames = new ReservedWordsBuilder() - .loadWords(SymbolVisitor.class.getResource("reserved-class-names.txt"), this::escapeWord) - .build(); + .loadWords(SymbolVisitor.class.getResource("reserved-class-names.txt"), this::escapeWord) + .build(); var reservedMemberNamesBuilder = new ReservedWordsBuilder() - .loadWords(SymbolVisitor.class.getResource("reserved-member-names.txt"), this::escapeWord); + .loadWords(SymbolVisitor.class.getResource("reserved-member-names.txt"), this::escapeWord); escaper = ReservedWordSymbolProvider.builder() - .nameReservedWords(reservedClassNames) - .memberReservedWords(reservedMemberNamesBuilder.build()) - // Only escape words when the symbol has a definition file to - // prevent escaping intentional references to built-in types. - .escapePredicate((shape, symbol) -> !StringUtils.isEmpty(symbol.getDefinitionFile())) - .buildEscaper(); + .nameReservedWords(reservedClassNames) + .memberReservedWords(reservedMemberNamesBuilder.build()) + // Only escape words when the symbol has a definition file to + // prevent escaping intentional references to built-in types. + .escapePredicate((shape, symbol) -> !StringUtils.isEmpty(symbol.getDefinitionFile())) + .buildEscaper(); // Reserved words that only apply to error members. ReservedWords reservedErrorMembers = reservedMemberNamesBuilder - .put("code", "code_") - .build(); + .put("code", "code_") + .build(); errorMemberEscaper = ReservedWordSymbolProvider.builder() - .memberReservedWords(reservedErrorMembers) - .escapePredicate((shape, symbol) -> !StringUtils.isEmpty(symbol.getDefinitionFile())) - .buildEscaper(); + .memberReservedWords(reservedErrorMembers) + .escapePredicate((shape, symbol) -> !StringUtils.isEmpty(symbol.getDefinitionFile())) + .buildEscaper(); } private String escapeWord(String word) { @@ -125,7 +116,7 @@ public Symbol toSymbol(Shape shape) { @Override public String toMemberName(MemberShape shape) { - if (CodegenUtils.isErrorMessage(model, shape)) { + if (CodegenUtils.isErrorMessage(model, shape)) { return "message"; } @@ -187,13 +178,21 @@ public Symbol listShape(ListShape shape) { var builder = createSymbolBuilder(shape, "list[" + type + "]") .addReference(reference); - builder.putProperty(SymbolProperties.SERIALIZER, createGeneratedSymbolBuilder( - shape, "_serialize_" + CaseUtils.toSnakeCase(shape.getId().getName()), SHAPES_FILE, false) - .build()); - - builder.putProperty(SymbolProperties.DESERIALIZER, createGeneratedSymbolBuilder( - shape, "_deserialize_" + CaseUtils.toSnakeCase(shape.getId().getName()), SHAPES_FILE, false) - .build()); + builder.putProperty(SymbolProperties.SERIALIZER, + createGeneratedSymbolBuilder( + shape, + "_serialize_" + CaseUtils.toSnakeCase(shape.getId().getName()), + SHAPES_FILE, + false) + .build()); + + builder.putProperty(SymbolProperties.DESERIALIZER, + createGeneratedSymbolBuilder( + shape, + "_deserialize_" + CaseUtils.toSnakeCase(shape.getId().getName()), + SHAPES_FILE, + false) + .build()); return builder.build(); } @@ -206,13 +205,21 @@ public Symbol mapShape(MapShape shape) { var builder = createSymbolBuilder(shape, "dict[str, " + type + "]") .addReference(reference); - builder.putProperty(SymbolProperties.SERIALIZER, createGeneratedSymbolBuilder( - shape, "_serialize_" + CaseUtils.toSnakeCase(shape.getId().getName()), SHAPES_FILE, false) - .build()); - - builder.putProperty(SymbolProperties.DESERIALIZER, createGeneratedSymbolBuilder( - shape, "_deserialize_" + CaseUtils.toSnakeCase(shape.getId().getName()), SHAPES_FILE, false) - .build()); + builder.putProperty(SymbolProperties.SERIALIZER, + createGeneratedSymbolBuilder( + shape, + "_serialize_" + CaseUtils.toSnakeCase(shape.getId().getName()), + SHAPES_FILE, + false) + .build()); + + builder.putProperty(SymbolProperties.DESERIALIZER, + createGeneratedSymbolBuilder( + shape, + "_deserialize_" + CaseUtils.toSnakeCase(shape.getId().getName()), + SHAPES_FILE, + false) + .build()); return builder.build(); } @@ -342,9 +349,13 @@ public Symbol unionShape(UnionShape shape) { var builder = createGeneratedSymbolBuilder(shape, name, SHAPES_FILE) .putProperty(SymbolProperties.UNION_UNKNOWN, unknownSymbol); - builder.putProperty(SymbolProperties.DESERIALIZER, createGeneratedSymbolBuilder( - shape, "_" + name + "Deserializer", SHAPES_FILE, false) - .build()); + builder.putProperty(SymbolProperties.DESERIALIZER, + createGeneratedSymbolBuilder( + shape, + "_" + name + "Deserializer", + SHAPES_FILE, + false) + .build()); return builder.build(); } @@ -387,8 +398,8 @@ private SymbolReference createSchemaSymbol(Shape shape) { .addDependency(SmithyPythonDependency.SMITHY_CORE); } else { schemaSymbolBuilder - .namespace(format("%s.%s", settings.moduleName(), SCHEMAS_FILE.replace('/', '.')), ".") - .definitionFile(format("./%s/%s.py", settings.moduleName(), SCHEMAS_FILE)); + .namespace(String.format("%s.%s", settings.moduleName(), SCHEMAS_FILE.replace('/', '.')), ".") + .definitionFile(String.format("./%s/%s.py", settings.moduleName(), SCHEMAS_FILE)); } var schemaSymbol = schemaSymbolBuilder.build(); return SymbolReference.builder() @@ -407,8 +418,8 @@ private Symbol.Builder createGeneratedSymbolBuilder( String file, boolean includeSchema ) { - var namespace = format("%s.%s", settings.moduleName(), file.replace('/', '.')); - var filename = format("./%s/%s.py", settings.moduleName(), file); + var namespace = String.format("%s.%s", settings.moduleName(), file.replace('/', '.')); + var filename = String.format("./%s/%s.py", settings.moduleName(), file); return createSymbolBuilder(shape, typeName, includeSchema) .namespace(namespace, ".") .definitionFile(filename); diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ConfigGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/ConfigGenerator.java similarity index 54% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ConfigGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/ConfigGenerator.java index 8f847e1c7..fb01926d8 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ConfigGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/ConfigGenerator.java @@ -1,19 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen; +package software.amazon.smithy.python.codegen.generators; import java.util.ArrayList; import java.util.Arrays; @@ -28,101 +17,108 @@ import software.amazon.smithy.model.node.ArrayNode; import software.amazon.smithy.model.node.StringNode; import software.amazon.smithy.model.shapes.OperationShape; -import software.amazon.smithy.python.codegen.integration.PythonIntegration; -import software.amazon.smithy.python.codegen.integration.RuntimeClientPlugin; +import software.amazon.smithy.python.codegen.CodegenUtils; +import software.amazon.smithy.python.codegen.ConfigProperty; +import software.amazon.smithy.python.codegen.GenerationContext; +import software.amazon.smithy.python.codegen.PythonSettings; +import software.amazon.smithy.python.codegen.SmithyPythonDependency; +import software.amazon.smithy.python.codegen.SymbolProperties; +import software.amazon.smithy.python.codegen.integrations.PythonIntegration; +import software.amazon.smithy.python.codegen.integrations.RuntimeClientPlugin; import software.amazon.smithy.python.codegen.sections.ConfigSection; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.CodeInterceptor; +import software.amazon.smithy.utils.SmithyInternalApi; /** * Generates the client's config object. */ -final class ConfigGenerator implements Runnable { +@SmithyInternalApi +public final class ConfigGenerator implements Runnable { // This list contains any properties that should unconditionally be added to every // config object. This should be as minimal as possible, and importantly should // not contain any HTTP related config since Smithy is transport agnostic. private static final List BASE_PROPERTIES = Arrays.asList( - ConfigProperty.builder() - .name("interceptors") - .type(Symbol.builder() - .name("list[_ServiceInterceptor]") - .build()) - .documentation( - "The list of interceptors, which are hooks that are called during the execution of a request.") - .nullable(false) - .initialize(writer -> writer.write("self.interceptors = interceptors or []")) - .build(), - ConfigProperty.builder() - .name("retry_strategy") - .type(Symbol.builder() - .name("RetryStrategy") - .namespace("smithy_core.interfaces.retries", ".") - .addDependency(SmithyPythonDependency.SMITHY_CORE) - .build()) - .documentation("The retry strategy for issuing retry tokens and computing retry delays.") - .nullable(false) - .initialize(writer -> { - writer.addDependency(SmithyPythonDependency.SMITHY_CORE); - writer.addImport("smithy_core.retries", "SimpleRetryStrategy"); - writer.write("self.retry_strategy = retry_strategy or SimpleRetryStrategy()"); - }) - .build() - ); + ConfigProperty.builder() + .name("interceptors") + .type(Symbol.builder() + .name("list[_ServiceInterceptor]") + .build()) + .documentation( + "The list of interceptors, which are hooks that are called during the execution of a request.") + .nullable(false) + .initialize(writer -> writer.write("self.interceptors = interceptors or []")) + .build(), + ConfigProperty.builder() + .name("retry_strategy") + .type(Symbol.builder() + .name("RetryStrategy") + .namespace("smithy_core.interfaces.retries", ".") + .addDependency(SmithyPythonDependency.SMITHY_CORE) + .build()) + .documentation("The retry strategy for issuing retry tokens and computing retry delays.") + .nullable(false) + .initialize(writer -> { + writer.addDependency(SmithyPythonDependency.SMITHY_CORE); + writer.addImport("smithy_core.retries", "SimpleRetryStrategy"); + writer.write("self.retry_strategy = retry_strategy or SimpleRetryStrategy()"); + }) + .build()); // This list contains any properties that must be added to any http-based // service client, except for the http client itself. private static final List HTTP_PROPERTIES = Arrays.asList( - ConfigProperty.builder() - .name("http_request_config") - .type(Symbol.builder() - .name("HTTPRequestConfiguration") - .namespace("smithy_http.interfaces", ".") - .addDependency(SmithyPythonDependency.SMITHY_HTTP) - .build()) - .documentation("Configuration for individual HTTP requests.") - .build(), - ConfigProperty.builder() - .name("endpoint_resolver") - .type(Symbol.builder() - .name("EndpointResolver[Any]") - .addReference(Symbol.builder() - .name("Any") - .namespace("typing", ".") - .putProperty(SymbolProperties.STDLIB, true) - .build()) - .addReference(Symbol.builder() - .name("EndpointResolver") - .namespace("smithy_http.aio.interfaces", ".") - .addDependency(SmithyPythonDependency.SMITHY_HTTP) - .build()) - .build()) - .documentation(""" - The endpoint resolver used to resolve the final endpoint per-operation based on the \ - configuration.""") - .nullable(false) - .initialize(writer -> { - writer.addImport("smithy_http.aio.endpoints", "StaticEndpointResolver"); - writer.write("self.endpoint_resolver = endpoint_resolver or StaticEndpointResolver()"); - }) - .build(), - ConfigProperty.builder() - .name("endpoint_uri") - .type(Symbol.builder() - .name("str | URI") - .addReference(Symbol.builder() - .name("URI") - .namespace("smithy_core.interfaces", ".") - .addDependency(SmithyPythonDependency.SMITHY_CORE) - .build()) - .build()) - .documentation("A static URI to route requests to.") - .build() - ); + ConfigProperty.builder() + .name("http_request_config") + .type(Symbol.builder() + .name("HTTPRequestConfiguration") + .namespace("smithy_http.interfaces", ".") + .addDependency(SmithyPythonDependency.SMITHY_HTTP) + .build()) + .documentation("Configuration for individual HTTP requests.") + .build(), + ConfigProperty.builder() + .name("endpoint_resolver") + .type(Symbol.builder() + .name("EndpointResolver[Any]") + .addReference(Symbol.builder() + .name("Any") + .namespace("typing", ".") + .putProperty(SymbolProperties.STDLIB, true) + .build()) + .addReference(Symbol.builder() + .name("EndpointResolver") + .namespace("smithy_http.aio.interfaces", ".") + .addDependency(SmithyPythonDependency.SMITHY_HTTP) + .build()) + .build()) + .documentation(""" + The endpoint resolver used to resolve the final endpoint per-operation based on the \ + configuration.""") + .nullable(false) + .initialize(writer -> { + writer.addImport("smithy_http.aio.endpoints", "StaticEndpointResolver"); + writer.write("self.endpoint_resolver = endpoint_resolver or StaticEndpointResolver()"); + }) + .build(), + ConfigProperty.builder() + .name("endpoint_uri") + .type(Symbol.builder() + .name("str | URI") + .addReference(Symbol.builder() + .name("URI") + .namespace("smithy_core.interfaces", ".") + .addDependency(SmithyPythonDependency.SMITHY_CORE) + .build()) + .build()) + .documentation("A static URI to route requests to.") + .build()); private final PythonSettings settings; private final GenerationContext context; - ConfigGenerator(PythonSettings settings, GenerationContext context) { + public ConfigGenerator(PythonSettings settings, GenerationContext context) { this.context = context; this.settings = settings; } @@ -141,19 +137,19 @@ private static List getHttpProperties(GenerationContext context) if (usesHttp2(context)) { clientBuilder - .initialize(writer -> { - writer.addDependency(SmithyPythonDependency.SMITHY_HTTP.withOptionalDependencies("awscrt")); - writer.addImport("smithy_http.aio.crt", "AWSCRTHTTPClient"); - writer.write("self.http_client = http_client or AWSCRTHTTPClient()"); - }); + .initialize(writer -> { + writer.addDependency(SmithyPythonDependency.SMITHY_HTTP.withOptionalDependencies("awscrt")); + writer.addImport("smithy_http.aio.crt", "AWSCRTHTTPClient"); + writer.write("self.http_client = http_client or AWSCRTHTTPClient()"); + }); } else { clientBuilder - .initialize(writer -> { - writer.addDependency(SmithyPythonDependency.SMITHY_HTTP.withOptionalDependencies("aiohttp")); - writer.addImport("smithy_http.aio.aiohttp", "AIOHTTPClient"); - writer.write("self.http_client = http_client or AIOHTTPClient()"); - }); + .initialize(writer -> { + writer.addDependency(SmithyPythonDependency.SMITHY_HTTP.withOptionalDependencies("aiohttp")); + writer.addImport("smithy_http.aio.aiohttp", "AIOHTTPClient"); + writer.write("self.http_client = http_client or AIOHTTPClient()"); + }); } properties.add(clientBuilder.build()); @@ -166,7 +162,9 @@ private static boolean usesHttp2(GenerationContext context) { var httpVersions = configuration.getArrayMember("http") .orElse(ArrayNode.arrayNode()) .getElementsAs(StringNode.class) - .stream().map(node -> node.getValue().toLowerCase(Locale.ENGLISH)).toList(); + .stream() + .map(node -> node.getValue().toLowerCase(Locale.ENGLISH)) + .toList(); // An explicit http2 configuration if (httpVersions.contains("h2")) { @@ -187,34 +185,34 @@ private static boolean usesHttp2(GenerationContext context) { private static List getHttpAuthProperties(GenerationContext context) { return List.of( - ConfigProperty.builder() - .name("http_auth_schemes") - .type(Symbol.builder() - .name("dict[str, HTTPAuthScheme[Any, Any, Any, Any]]") - .addReference(Symbol.builder() - .name("HTTPAuthScheme") - .namespace("smithy_http.aio.interfaces.auth", ".") - .addDependency(SmithyPythonDependency.SMITHY_HTTP) - .build()) - .addReference(Symbol.builder() - .name("Any") - .namespace("typing", ".") - .putProperty(SymbolProperties.STDLIB, true) - .build()) - .build()) - .documentation("A map of http auth scheme ids to http auth schemes.") - .nullable(false) - .initialize(writer -> writeDefaultHttpAuthSchemes(context, writer)) - .build(), - ConfigProperty.builder() - .name("http_auth_scheme_resolver") - .type(CodegenUtils.getHttpAuthSchemeResolverSymbol(context.settings())) - .documentation("An http auth scheme resolver that determines the auth scheme for each operation.") - .nullable(false) - .initialize(writer -> writer.write( - "self.http_auth_scheme_resolver = http_auth_scheme_resolver or HTTPAuthSchemeResolver()")) - .build() - ); + ConfigProperty.builder() + .name("http_auth_schemes") + .type(Symbol.builder() + .name("dict[str, HTTPAuthScheme[Any, Any, Any, Any]]") + .addReference(Symbol.builder() + .name("HTTPAuthScheme") + .namespace("smithy_http.aio.interfaces.auth", ".") + .addDependency(SmithyPythonDependency.SMITHY_HTTP) + .build()) + .addReference(Symbol.builder() + .name("Any") + .namespace("typing", ".") + .putProperty(SymbolProperties.STDLIB, true) + .build()) + .build()) + .documentation("A map of http auth scheme ids to http auth schemes.") + .nullable(false) + .initialize(writer -> writeDefaultHttpAuthSchemes(context, writer)) + .build(), + ConfigProperty.builder() + .name("http_auth_scheme_resolver") + .type(CodegenUtils.getHttpAuthSchemeResolverSymbol(context.settings())) + .documentation( + "An http auth scheme resolver that determines the auth scheme for each operation.") + .nullable(false) + .initialize(writer -> writer.write( + "self.http_auth_scheme_resolver = http_auth_scheme_resolver or HTTPAuthSchemeResolver()")) + .build()); } private static void writeDefaultHttpAuthSchemes(GenerationContext context, PythonWriter writer) { @@ -233,12 +231,12 @@ private static void writeDefaultHttpAuthSchemes(GenerationContext context, Pytho writer.pushState(); writer.putContext("authSchemes", supportedAuthSchemes); writer.write(""" - self.http_auth_schemes = http_auth_schemes or { - ${#authSchemes} - ${key:S}: ${value:T}(), - ${/authSchemes} - } - """); + self.http_auth_schemes = http_auth_schemes or { + ${#authSchemes} + ${key:S}: ${value:T}(), + ${/authSchemes} + } + """); writer.popState(); } @@ -325,35 +323,37 @@ private void generateConfig(GenerationContext context, PythonWriter writer) { writer.pushState(new ConfigSection(finalProperties)); writer.addStdlibImport("dataclasses", "dataclass"); writer.write(""" - @dataclass(init=False) - class $L: - \"""Configuration for $L.\""" - - ${C|} + @dataclass(init=False) + class $L: + \"""Configuration for $L.\""" - def __init__( - self, - *, ${C|} - ): - \"""Constructor. - ${C|} - \""" - ${C|} - """, symbol.getName(), context.settings().service().getName(), - writer.consumer(w -> writePropertyDeclarations(w, finalProperties)), - writer.consumer(w -> writeInitParams(w, finalProperties)), - writer.consumer(w -> documentProperties(w, finalProperties)), - writer.consumer(w -> initializeProperties(w, finalProperties))); + def __init__( + self, + *, + ${C|} + ): + \"""Constructor. + + ${C|} + \""" + ${C|} + """, + symbol.getName(), + context.settings().service().getName(), + writer.consumer(w -> writePropertyDeclarations(w, finalProperties)), + writer.consumer(w -> writeInitParams(w, finalProperties)), + writer.consumer(w -> documentProperties(w, finalProperties)), + writer.consumer(w -> initializeProperties(w, finalProperties))); writer.popState(); } private void writePropertyDeclarations(PythonWriter writer, Collection properties) { for (ConfigProperty property : properties) { var formatString = property.isNullable() - ? "$L: $T | None" - : "$L: $T"; + ? "$L: $T | None" + : "$L: $T"; writer.write(formatString, property.name(), property.type()); } } @@ -401,15 +401,15 @@ public void write(PythonWriter writer, String previousText, ConfigSection sectio // Note that this is indented to keep it at the proper indentation level. writer.write(""" - def set_http_auth_scheme(self, scheme: HTTPAuthScheme[Any, Any, Any, Any]) -> None: - \"""Sets the implementation of an auth scheme. + def set_http_auth_scheme(self, scheme: HTTPAuthScheme[Any, Any, Any, Any]) -> None: + \"""Sets the implementation of an auth scheme. - Using this method ensures the correct key is used. + Using this method ensures the correct key is used. - :param scheme: The auth scheme to add. - \""" - self.http_auth_schemes[scheme.scheme_id] = scheme - """); + :param scheme: The auth scheme to add. + \""" + self.http_auth_schemes[scheme.scheme_id] = scheme + """); } } } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/EnumGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/EnumGenerator.java similarity index 69% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/EnumGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/EnumGenerator.java index 8b1606053..8f0d2f804 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/EnumGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/EnumGenerator.java @@ -1,33 +1,26 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen; +package software.amazon.smithy.python.codegen.generators; import software.amazon.smithy.model.shapes.EnumShape; import software.amazon.smithy.model.shapes.MemberShape; import software.amazon.smithy.model.traits.DocumentationTrait; import software.amazon.smithy.model.traits.EnumValueTrait; +import software.amazon.smithy.python.codegen.GenerationContext; +import software.amazon.smithy.python.codegen.SymbolProperties; +import software.amazon.smithy.utils.SmithyInternalApi; /** * Renders enums. */ -final class EnumGenerator implements Runnable { +@SmithyInternalApi +public final class EnumGenerator implements Runnable { private final EnumShape shape; private final GenerationContext context; - EnumGenerator(GenerationContext context, EnumShape enumShape) { + public EnumGenerator(GenerationContext context, EnumShape enumShape) { this.context = context; this.shape = enumShape; } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/IntEnumGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/IntEnumGenerator.java similarity index 68% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/IntEnumGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/IntEnumGenerator.java index ecd5859c1..7fbb6bb5d 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/IntEnumGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/IntEnumGenerator.java @@ -1,30 +1,24 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen; +package software.amazon.smithy.python.codegen.generators; import software.amazon.smithy.codegen.core.directed.GenerateIntEnumDirective; import software.amazon.smithy.model.shapes.MemberShape; import software.amazon.smithy.model.traits.DocumentationTrait; import software.amazon.smithy.model.traits.EnumValueTrait; +import software.amazon.smithy.python.codegen.GenerationContext; +import software.amazon.smithy.python.codegen.PythonSettings; +import software.amazon.smithy.python.codegen.SymbolProperties; +import software.amazon.smithy.utils.SmithyInternalApi; -final class IntEnumGenerator implements Runnable { +@SmithyInternalApi +public final class IntEnumGenerator implements Runnable { private final GenerateIntEnumDirective directive; - IntEnumGenerator(GenerateIntEnumDirective directive) { + public IntEnumGenerator(GenerateIntEnumDirective directive) { this.directive = directive; } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/ListGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/ListGenerator.java similarity index 89% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/ListGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/ListGenerator.java index 5630be77c..91f60c38f 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/ListGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/ListGenerator.java @@ -2,14 +2,13 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen.generators; import software.amazon.smithy.model.shapes.ListShape; import software.amazon.smithy.model.traits.SparseTrait; import software.amazon.smithy.python.codegen.GenerationContext; -import software.amazon.smithy.python.codegen.PythonWriter; import software.amazon.smithy.python.codegen.SymbolProperties; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.SmithyInternalApi; /** @@ -57,7 +56,9 @@ private void generateSerializer() { ${3C|} ${/sparse} - """, serializerSymbol.getName(), listSymbol, + """, + serializerSymbol.getName(), + listSymbol, writer.consumer(w -> memberTarget.accept( new MemberSerializerGenerator(context, w, shape.getMember(), "ls")))); writer.popState(); @@ -73,8 +74,8 @@ private void generateDeserializer() { writer.addImport("smithy_core.schemas", "Schema"); var sparse = shape.hasTrait(SparseTrait.class); writer.putContext("sparse", sparse); - writer.putContext("includeSchema", sparse || ( - !memberTarget.isUnionShape() && !memberTarget.isStructureShape())); + writer.putContext("includeSchema", + sparse || (!memberTarget.isUnionShape() && !memberTarget.isStructureShape())); writer.write(""" def $1L(deserializer: ShapeDeserializer, schema: Schema) -> $2T: result: $2T = [] @@ -89,10 +90,11 @@ def _read_value(d: ShapeDeserializer): result.append(${3C|}) deserializer.read_list(schema, _read_value) return result - """, deserializerSymbol.getName(), listSymbol, + """, + deserializerSymbol.getName(), + listSymbol, writer.consumer(w -> memberTarget.accept( - new MemberDeserializerGenerator(context, w, shape.getMember(), "d") - ))); + new MemberDeserializerGenerator(context, w, shape.getMember(), "d")))); writer.popState(); } } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/MapGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/MapGenerator.java similarity index 90% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/MapGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/MapGenerator.java index 13111b783..853ee722a 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/MapGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/MapGenerator.java @@ -2,14 +2,13 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen.generators; import software.amazon.smithy.model.shapes.MapShape; import software.amazon.smithy.model.traits.SparseTrait; import software.amazon.smithy.python.codegen.GenerationContext; -import software.amazon.smithy.python.codegen.PythonWriter; import software.amazon.smithy.python.codegen.SymbolProperties; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.SmithyInternalApi; /** @@ -60,7 +59,9 @@ private void generateSerializer() { m.entry(k, lambda vs: ${3C|}) ${/sparse} - """, serializerSymbol.getName(), mapSymbol, + """, + serializerSymbol.getName(), + mapSymbol, writer.consumer(w -> valueTarget.accept( new MemberSerializerGenerator(context, w, shape.getValue(), "vs")))); writer.popState(); @@ -76,8 +77,7 @@ private void generateDeserializer() { writer.addImport("smithy_core.schemas", "Schema"); var sparse = shape.hasTrait(SparseTrait.class); writer.putContext("sparse", sparse); - writer.putContext("includeSchema", sparse || ( - !valueTarget.isUnionShape() && !valueTarget.isStructureShape())); + writer.putContext("includeSchema", sparse || (!valueTarget.isUnionShape() && !valueTarget.isStructureShape())); writer.write(""" def $1L(deserializer: ShapeDeserializer, schema: Schema) -> $2T: result: $2T = {} @@ -90,10 +90,11 @@ def _read_value(k: str, d: ShapeDeserializer): result[k] = ${3C|} deserializer.read_map(schema, _read_value) return result - """, deserializerSymbol.getName(), listSymbol, + """, + deserializerSymbol.getName(), + listSymbol, writer.consumer(w -> valueTarget.accept( - new MemberDeserializerGenerator(context, w, shape.getValue(), "d") - ))); + new MemberDeserializerGenerator(context, w, shape.getValue(), "d")))); writer.popState(); } } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/MemberDeserializerGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/MemberDeserializerGenerator.java similarity index 93% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/MemberDeserializerGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/MemberDeserializerGenerator.java index ccc8d3970..35c1cf592 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/MemberDeserializerGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/MemberDeserializerGenerator.java @@ -2,7 +2,6 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen.generators; import java.util.Locale; @@ -30,12 +29,14 @@ import software.amazon.smithy.model.shapes.TimestampShape; import software.amazon.smithy.model.shapes.UnionShape; import software.amazon.smithy.python.codegen.GenerationContext; -import software.amazon.smithy.python.codegen.PythonWriter; import software.amazon.smithy.python.codegen.SymbolProperties; +import software.amazon.smithy.python.codegen.writer.PythonWriter; +import software.amazon.smithy.utils.SmithyInternalApi; /** * Generates calls to shape serializers for member shapes. */ +@SmithyInternalApi public class MemberDeserializerGenerator extends ShapeVisitor.DataShapeVisitor { private final GenerationContext context; @@ -82,8 +83,7 @@ private void writeDeserializer(String shapeTypeName) { writer.write( "${deserializer:L}.read_$L(${C|})", shapeTypeName, - writer.consumer(w -> writeSchema()) - ); + writer.consumer(w -> writeSchema())); //writer.popState(); } @@ -207,10 +207,12 @@ public Void mapShape(MapShape shape) { private void deserializerSymbolShape(Shape shape) { pushMemberState(); - var deserializerSymbol = context.symbolProvider().toSymbol(shape) + var deserializerSymbol = context.symbolProvider() + .toSymbol(shape) .expectProperty(SymbolProperties.DESERIALIZER); writer.write("$T(${deserializer:L}, ${C|})", - deserializerSymbol, writer.consumer(w -> writeSchema())); + deserializerSymbol, + writer.consumer(w -> writeSchema())); //writer.popState(); } @@ -224,7 +226,8 @@ public Void structureShape(StructureShape shape) { @Override public Void unionShape(UnionShape shape) { pushMemberState(); - var deserializerSymbol = context.symbolProvider().toSymbol(shape) + var deserializerSymbol = context.symbolProvider() + .toSymbol(shape) .expectProperty(SymbolProperties.DESERIALIZER); writer.write("$T().deserialize(${deserializer:L})", deserializerSymbol); //writer.popState(); diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/MemberSerializerGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/MemberSerializerGenerator.java similarity index 94% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/MemberSerializerGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/MemberSerializerGenerator.java index ee3be623a..25bc523ff 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/generators/MemberSerializerGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/MemberSerializerGenerator.java @@ -2,7 +2,6 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen.generators; import java.util.Locale; @@ -31,8 +30,8 @@ import software.amazon.smithy.model.shapes.TimestampShape; import software.amazon.smithy.model.shapes.UnionShape; import software.amazon.smithy.python.codegen.GenerationContext; -import software.amazon.smithy.python.codegen.PythonWriter; import software.amazon.smithy.python.codegen.SymbolProperties; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.SmithyInternalApi; /** @@ -205,10 +204,12 @@ public Void timestampShape(TimestampShape shape) { @Override public Void listShape(ListShape shape) { pushMemberState(); - var serializerSymbol = context.symbolProvider().toSymbol(shape) + var serializerSymbol = context.symbolProvider() + .toSymbol(shape) .expectProperty(SymbolProperties.SERIALIZER); writer.write("$T(${serializer:L}, ${C|}, ${property:L})", - serializerSymbol, writer.consumer(w -> writeSchema())); + serializerSymbol, + writer.consumer(w -> writeSchema())); writer.popState(); return null; } @@ -216,10 +217,12 @@ public Void listShape(ListShape shape) { @Override public Void mapShape(MapShape shape) { pushMemberState(); - var serializerSymbol = context.symbolProvider().toSymbol(shape) + var serializerSymbol = context.symbolProvider() + .toSymbol(shape) .expectProperty(SymbolProperties.SERIALIZER); writer.write("$T(${serializer:L}, ${C|}, ${property:L})", - serializerSymbol, writer.consumer(w -> writeSchema())); + serializerSymbol, + writer.consumer(w -> writeSchema())); writer.popState(); return null; } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/ProtocolGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/ProtocolGenerator.java similarity index 87% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/ProtocolGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/ProtocolGenerator.java index e6ab93e37..664c08c14 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/ProtocolGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/ProtocolGenerator.java @@ -1,19 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen.integration; +package software.amazon.smithy.python.codegen.generators; import static java.lang.String.format; @@ -22,7 +11,7 @@ import software.amazon.smithy.model.shapes.ToShapeId; import software.amazon.smithy.python.codegen.ApplicationProtocol; import software.amazon.smithy.python.codegen.GenerationContext; -import software.amazon.smithy.python.codegen.PythonWriter; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.CaseUtils; import software.amazon.smithy.utils.SmithyUnstableApi; @@ -57,7 +46,6 @@ default String getName() { */ ApplicationProtocol getApplicationProtocol(GenerationContext context); - /** * Generates the name of a serializer function for shapes of a service that is not protocol-specific. * @@ -123,10 +111,10 @@ default Symbol getDeserializationFunction(GenerationContext context, ToShapeId s default Symbol getErrorDeserializationFunction(GenerationContext context, ToShapeId shapeId) { var name = context.settings().service(context.model()).getContextualName(shapeId); return Symbol.builder() - .name("_deserialize_error_" + CaseUtils.toSnakeCase(name)) - .namespace(format("%s.deserialize", context.settings().moduleName()), "") - .definitionFile(format("./%s/deserialize.py", context.settings().moduleName())) - .build(); + .name("_deserialize_error_" + CaseUtils.toSnakeCase(name)) + .namespace(format("%s.deserialize", context.settings().moduleName()), "") + .definitionFile(format("./%s/deserialize.py", context.settings().moduleName())) + .build(); } /** @@ -134,8 +122,7 @@ default Symbol getErrorDeserializationFunction(GenerationContext context, ToShap * * @param context Serde context. */ - default void generateSharedSerializerComponents(GenerationContext context) { - } + default void generateSharedSerializerComponents(GenerationContext context) {} /** * Generates the code used to serialize the shapes of a service @@ -150,8 +137,7 @@ default void generateSharedSerializerComponents(GenerationContext context) { * * @param context Serde context. */ - default void generateSharedDeserializerComponents(GenerationContext context) { - } + default void generateSharedDeserializerComponents(GenerationContext context) {} /** * Generates the code used to deserialize the shapes of a service @@ -166,8 +152,7 @@ default void generateSharedDeserializerComponents(GenerationContext context) { * * @param context Generation context */ - default void generateProtocolTests(GenerationContext context) { - } + default void generateProtocolTests(GenerationContext context) {} /** * Generates the code to wrap an operation output into an event stream. @@ -187,6 +172,5 @@ default void generateProtocolTests(GenerationContext context) { * @param context Generation context. * @param writer The writer to write to. */ - default void wrapEventStream(GenerationContext context, PythonWriter writer) { - } + default void wrapEventStream(GenerationContext context, PythonWriter writer) {} } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SchemaGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/SchemaGenerator.java similarity index 86% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SchemaGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/SchemaGenerator.java index 8ff44ccad..413cf5e0f 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SchemaGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/SchemaGenerator.java @@ -2,8 +2,7 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen; +package software.amazon.smithy.python.codegen.generators; import java.util.HashMap; import java.util.HashSet; @@ -23,6 +22,10 @@ import software.amazon.smithy.model.traits.EnumTrait; import software.amazon.smithy.model.traits.UnitTypeTrait; import software.amazon.smithy.model.traits.synthetic.SyntheticEnumTrait; +import software.amazon.smithy.python.codegen.GenerationContext; +import software.amazon.smithy.python.codegen.SmithyPythonDependency; +import software.amazon.smithy.python.codegen.SymbolProperties; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.CaseUtils; import software.amazon.smithy.utils.SmithyUnstableApi; @@ -32,14 +35,15 @@ *

Schemas are essentially a reduced, runtime-available model. */ @SmithyUnstableApi -final class SchemaGenerator implements Consumer { +public final class SchemaGenerator implements Consumer { private static final Logger LOGGER = Logger.getLogger(SchemaGenerator.class.getName()); // Filter out traits that would overly bloat the definition, which are already part of the // class, such as documentation. private static final Set DEFAULT_TRAIT_FILTER = Set.of( - DocumentationTrait.ID, EnumTrait.ID, SyntheticEnumTrait.ID - ); + DocumentationTrait.ID, + EnumTrait.ID, + SyntheticEnumTrait.ID); private static final Symbol UNIT_SYMBOL = Symbol.builder() .name("UNIT") @@ -51,15 +55,18 @@ final class SchemaGenerator implements Consumer { private final Set generatedShapes = new HashSet<>(); private final Map deferredMembers = new HashMap<>(); - SchemaGenerator(GenerationContext context) { + public SchemaGenerator(GenerationContext context) { this.context = context; } @Override public void accept(Shape shape) { var symbol = context.symbolProvider().toSymbol(shape).expectProperty(SymbolProperties.SCHEMA).getSymbol(); - context.writerDelegator().useFileWriter( - symbol.getDefinitionFile(), symbol.getNamespace(), writer -> writeShapeSchema(writer, shape)); + context.writerDelegator() + .useFileWriter( + symbol.getDefinitionFile(), + symbol.getNamespace(), + writer -> writeShapeSchema(writer, shape)); generatedShapes.add(shape.getId()); } @@ -87,14 +94,18 @@ private void writeShapeSchema(PythonWriter writer, Shape shape) { ${/hasTraits} ${C|} ) - """, symbol.getName(), shape.getId(), + """, + symbol.getName(), + shape.getId(), writer.consumer(w -> writeTraits(w, traits)), writer.consumer(w -> writeSchemaMembers(w, shape))); writer.popState(); } private Map> filterTraits(Shape shape) { - return shape.getAllTraits().entrySet().stream() + return shape.getAllTraits() + .entrySet() + .stream() .filter(t -> !DEFAULT_TRAIT_FILTER.contains(t.getKey())) .collect(Collectors.toMap(Map.Entry::getKey, e -> { var value = e.getValue().toNode(); @@ -154,7 +165,10 @@ private void writeSchemaMembers(PythonWriter writer, Shape shape) { ], ${/hasTraits} }, - """, member.getMemberName(), targetSchemaSymbol, index, + """, + member.getMemberName(), + targetSchemaSymbol, + index, writer.consumer(w -> writeTraits(w, traits))); index++; @@ -205,8 +219,12 @@ private void finalizeRecursiveShapes(PythonWriter writer) { ${/hasTraits} ) - """, container, member.getMemberName(), target, - writer.consumer(w -> writeTraits(w, traits)), entry.getValue()); + """, + container, + member.getMemberName(), + target, + writer.consumer(w -> writeTraits(w, traits)), + entry.getValue()); writer.popState(); } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SetupGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/SetupGenerator.java similarity index 89% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SetupGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/SetupGenerator.java index eb014f0c3..16cfc70bb 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/SetupGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/SetupGenerator.java @@ -1,19 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen; +package software.amazon.smithy.python.codegen.generators; import java.util.Collection; import java.util.Collections; @@ -25,19 +14,25 @@ import software.amazon.smithy.model.traits.DocumentationTrait; import software.amazon.smithy.model.traits.StringTrait; import software.amazon.smithy.model.traits.TitleTrait; -import software.amazon.smithy.python.codegen.PythonDependency.Type; +import software.amazon.smithy.python.codegen.GenerationContext; +import software.amazon.smithy.python.codegen.PythonDependency; +import software.amazon.smithy.python.codegen.PythonSettings; +import software.amazon.smithy.python.codegen.SymbolProperties; import software.amazon.smithy.python.codegen.sections.PyprojectSection; import software.amazon.smithy.python.codegen.sections.ReadmeSection; +import software.amazon.smithy.python.codegen.writer.PythonWriter; +import software.amazon.smithy.utils.SmithyInternalApi; import software.amazon.smithy.utils.StringUtils; /** * Generates package setup configuration files. */ -final class SetupGenerator { +@SmithyInternalApi +public final class SetupGenerator { private SetupGenerator() {} - static void generateSetup( + public static void generateSetup( PythonSettings settings, GenerationContext context ) { @@ -91,11 +86,11 @@ private static void writePyproject( ] """, settings.moduleName(), settings.moduleVersion(), settings.moduleDescription()); - Optional.ofNullable(dependencies.get(Type.DEPENDENCY.getType())).ifPresent(deps -> { + Optional.ofNullable(dependencies.get(PythonDependency.Type.DEPENDENCY.getType())).ifPresent(deps -> { writer.openBlock("dependencies = [", "]", () -> writeDependencyList(writer, deps.values())); }); - Optional.ofNullable(dependencies.get(Type.TEST_DEPENDENCY.getType())).ifPresent(deps -> { + Optional.ofNullable(dependencies.get(PythonDependency.Type.TEST_DEPENDENCY.getType())).ifPresent(deps -> { writer.write("[project.optional-dependencies]"); writer.openBlock("tests = [", "]", () -> writeDependencyList(writer, deps.values())); }); @@ -137,7 +132,8 @@ private static void writeDependencyList(PythonWriter writer, Collection recursiveShapes + Set recursiveShapes ) { this.context = context; this.model = context.model(); @@ -78,7 +71,7 @@ final class StructureGenerator implements Runnable { var required = new ArrayList(); var optional = new ArrayList(); var index = NullableIndex.of(context.model()); - for (MemberShape member: shape.members()) { + for (MemberShape member : shape.members()) { if (index.isMemberNullable(member) || member.hasTrait(DefaultTrait.class)) { optional.add(member); } else { @@ -117,7 +110,8 @@ class $L: ${C|} - """, symbol.getName(), + """, + symbol.getName(), writer.consumer(w -> writeClassDocs(false)), writer.consumer(w -> writeProperties()), writer.consumer(w -> generateSerializeMethod()), @@ -150,7 +144,11 @@ class $1L($2T): ${8C|} - """, symbol.getName(), apiError, code, fault, + """, + symbol.getName(), + apiError, + code, + fault, writer.consumer(w -> writeClassDocs(true)), writer.consumer(w -> writeProperties()), writer.consumer(w -> generateSerializeMethod()), @@ -173,7 +171,8 @@ private void writeProperties() { $L: ${quote:L}$T${quote:L}\ ${?sensitive} = field(repr=False)${/sensitive} """, - memberName, symbolProvider.toSymbol(member)); + memberName, + symbolProvider.toSymbol(member)); writer.popState(); } @@ -339,9 +338,9 @@ def serialize(self, serializer: ShapeSerializer): if (isNullable(member)) { var gen = new MemberSerializerGenerator(context, writer, member, "serializer"); writer.write(""" - if self.${propertyName:L} is not None: - ${C|} - """, + if self.${propertyName:L} is not None: + ${C|} + """, writer.consumer(w -> target.accept(gen))); } else { target.accept(new MemberSerializerGenerator(context, writer, member, "serializer")); @@ -358,13 +357,15 @@ private List filterMembers() { if (shape.hasTrait(InputTrait.class)) { var operation = operationIndex.getInputBindings(shape).iterator().next(); var bindings = httpIndex.getRequestBindings(operation); - return shape.members().stream() + return shape.members() + .stream() .filter(member -> filterMember(member, bindings)) .toList(); } else if (shape.hasTrait(OutputTrait.class)) { var operation = operationIndex.getOutputBindings(shape).iterator().next(); var bindings = httpIndex.getResponseBindings(operation); - return shape.members().stream() + return shape.members() + .stream() .filter(member -> filterMember(member, bindings)) .toList(); } @@ -432,9 +433,11 @@ private void deserializeMembers(Collection members) { writer.write(""" case $L: kwargs[$S] = ${C|} - """, index++, symbolProvider.toMemberName(member), writer.consumer(w -> - target.accept(new MemberDeserializerGenerator(context, writer, member, "de")) - )); + """, + index++, + symbolProvider.toMemberName(member), + writer.consumer( + w -> target.accept(new MemberDeserializerGenerator(context, writer, member, "de")))); } } } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/UnionGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/UnionGenerator.java similarity index 88% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/UnionGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/UnionGenerator.java index eba7c85f7..7996375d0 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/UnionGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/generators/UnionGenerator.java @@ -1,19 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen; +package software.amazon.smithy.python.codegen.generators; import java.util.ArrayList; import java.util.Set; @@ -24,13 +13,16 @@ import software.amazon.smithy.model.shapes.UnionShape; import software.amazon.smithy.model.traits.DocumentationTrait; import software.amazon.smithy.model.traits.StringTrait; -import software.amazon.smithy.python.codegen.generators.MemberDeserializerGenerator; -import software.amazon.smithy.python.codegen.generators.MemberSerializerGenerator; +import software.amazon.smithy.python.codegen.GenerationContext; +import software.amazon.smithy.python.codegen.SymbolProperties; +import software.amazon.smithy.python.codegen.writer.PythonWriter; +import software.amazon.smithy.utils.SmithyInternalApi; /** * Renders unions. */ -final class UnionGenerator implements Runnable { +@SmithyInternalApi +public final class UnionGenerator implements Runnable { private final GenerationContext context; private final Model model; @@ -39,11 +31,11 @@ final class UnionGenerator implements Runnable { private final UnionShape shape; private final Set recursiveShapes; - UnionGenerator( + public UnionGenerator( GenerationContext context, PythonWriter writer, UnionShape shape, - Set recursiveShapes + Set recursiveShapes ) { this.context = context; this.model = context.model(); @@ -90,7 +82,8 @@ def deserialize(cls, deserializer: ShapeDeserializer) -> Self: """, memberSymbol.getName(), writer.consumer(w -> member.getMemberTrait(model, DocumentationTrait.class) - .map(StringTrait::getValue).ifPresent(w::writeDocs)), + .map(StringTrait::getValue) + .ifPresent(w::writeDocs)), targetSymbol, schemaSymbol, writer.consumer(w -> target.accept( diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/AuthScheme.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/AuthScheme.java similarity index 97% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/AuthScheme.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/AuthScheme.java index a09875de9..6b2371f2b 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/AuthScheme.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/AuthScheme.java @@ -2,8 +2,7 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen.integration; +package software.amazon.smithy.python.codegen.integrations; import java.util.Collections; import java.util.List; diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/DocumentMemberDeserVisitor.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/DocumentMemberDeserVisitor.java similarity index 90% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/DocumentMemberDeserVisitor.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/DocumentMemberDeserVisitor.java index bd880be62..e63a475fb 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/DocumentMemberDeserVisitor.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/DocumentMemberDeserVisitor.java @@ -1,19 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen.integration; +package software.amazon.smithy.python.codegen.integrations; import java.util.Optional; import software.amazon.smithy.codegen.core.CodegenException; @@ -44,8 +33,8 @@ import software.amazon.smithy.model.shapes.UnionShape; import software.amazon.smithy.model.traits.TimestampFormatTrait.Format; import software.amazon.smithy.python.codegen.GenerationContext; -import software.amazon.smithy.python.codegen.PythonWriter; import software.amazon.smithy.python.codegen.SmithyPythonDependency; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.SmithyUnstableApi; /** @@ -83,10 +72,10 @@ public class DocumentMemberDeserVisitor implements ShapeVisitor { * of a TimestampFormat trait. */ public DocumentMemberDeserVisitor( - GenerationContext context, - PythonWriter writer, - String dataSource, - Format defaultTimestampFormat + GenerationContext context, + PythonWriter writer, + String dataSource, + Format defaultTimestampFormat ) { this(context, writer, null, dataSource, defaultTimestampFormat); } @@ -104,11 +93,11 @@ public DocumentMemberDeserVisitor( * of a TimestampFormat trait. */ public DocumentMemberDeserVisitor( - GenerationContext context, - PythonWriter writer, - MemberShape member, - String dataSource, - Format defaultTimestampFormat + GenerationContext context, + PythonWriter writer, + MemberShape member, + String dataSource, + Format defaultTimestampFormat ) { this.context = context; this.writer = writer; @@ -274,8 +263,9 @@ public String timestampShape(TimestampShape shape) { var member = memberShape().get(); if (!shape.getId().equals(member.getTarget())) { throw new CodegenException( - String.format("Encountered timestamp shape %s that was not the target of member shape %s", - shape.getId(), member.getId())); + String.format("Encountered timestamp shape %s that was not the target of member shape %s", + shape.getId(), + member.getId())); } format = httpIndex.determineTimestampFormat(member, Location.DOCUMENT, defaultTimestampFormat); } diff --git a/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/HttpApiKeyAuth.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/HttpApiKeyAuth.java new file mode 100644 index 000000000..f8034d0ab --- /dev/null +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/HttpApiKeyAuth.java @@ -0,0 +1,142 @@ +/* + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * SPDX-License-Identifier: Apache-2.0 + */ +package software.amazon.smithy.python.codegen.integrations; + +import java.util.List; +import software.amazon.smithy.codegen.core.Symbol; +import software.amazon.smithy.model.shapes.ShapeId; +import software.amazon.smithy.model.traits.HttpApiKeyAuthTrait; +import software.amazon.smithy.python.codegen.ApplicationProtocol; +import software.amazon.smithy.python.codegen.CodegenUtils; +import software.amazon.smithy.python.codegen.ConfigProperty; +import software.amazon.smithy.python.codegen.GenerationContext; +import software.amazon.smithy.python.codegen.SmithyPythonDependency; +import software.amazon.smithy.utils.SmithyInternalApi; + +/** + * Adds support for the http api key auth. + * {@see https://smithy.io/2.0/spec/authentication-traits.html#smithy-api-httpapikeyauth-trait} + */ +@SmithyInternalApi +public final class HttpApiKeyAuth implements PythonIntegration { + private static final String OPTION_GENERATOR_NAME = "_generate_api_key_option"; + + @Override + public List getClientPlugins() { + return List.of( + RuntimeClientPlugin.builder() + .servicePredicate((model, service) -> service.hasTrait(HttpApiKeyAuthTrait.class)) + .addConfigProperty(ConfigProperty.builder() + .name("api_key_identity_resolver") + .documentation("Resolves the API key. Required for operations that use API key auth.") + .type(Symbol.builder() + .name("IdentityResolver[ApiKeyIdentity, IdentityProperties]") + .addReference(Symbol.builder() + .addDependency(SmithyPythonDependency.SMITHY_CORE) + .name("IdentityResolver") + .namespace("smithy_core.aio.interfaces.identity", ".") + .build()) + .addReference(Symbol.builder() + .addDependency(SmithyPythonDependency.SMITHY_HTTP) + .name("ApiKeyIdentity") + .namespace("smithy_http.aio.identity.apikey", ".") + .build()) + .addReference(Symbol.builder() + .addDependency(SmithyPythonDependency.SMITHY_CORE) + .name("IdentityProperties") + .namespace("smithy_core.interfaces.identity", ".") + .build()) + .build()) + .nullable(true) + .build()) + .authScheme(new ApiKeyAuthScheme()) + .build()); + } + + @Override + public void customize(GenerationContext context) { + if (!hasApiKeyAuth(context)) { + return; + } + var trait = context.settings().service(context.model()).expectTrait(HttpApiKeyAuthTrait.class); + var params = CodegenUtils.getHttpAuthParamsSymbol(context.settings()); + var resolver = CodegenUtils.getHttpAuthSchemeResolverSymbol(context.settings()); + + // Add a function that generates the http auth option for api key auth. + // This needs to be generated because there's modeled parameters that + // must be accounted for. + context.writerDelegator().useFileWriter(resolver.getDefinitionFile(), resolver.getNamespace(), writer -> { + writer.addDependency(SmithyPythonDependency.SMITHY_CORE); + writer.addDependency(SmithyPythonDependency.SMITHY_HTTP); + writer.addImport("smithy_http.aio.interfaces.auth", "HTTPAuthOption"); + writer.addImport("smithy_http.aio.auth.apikey", "ApiKeyLocation"); + writer.pushState(); + + // Push the scheme into the context to allow for conditionally adding + // it to the properties dict. + writer.putContext("scheme", trait.getScheme().orElse(null)); + writer.write(""" + def $1L(auth_params: $2T) -> HTTPAuthOption | None: + return HTTPAuthOption( + scheme_id=$3S, + identity_properties={}, + signer_properties={ + "name": $4S, + "location": ApiKeyLocation($5S), + ${?scheme} + "scheme": ${scheme:S}, + ${/scheme} + } + ) + """, + OPTION_GENERATOR_NAME, + params, + HttpApiKeyAuthTrait.ID.toString(), + trait.getName(), + trait.getIn().toString()); + writer.popState(); + }); + } + + private boolean hasApiKeyAuth(GenerationContext context) { + var service = context.settings().service(context.model()); + return service.hasTrait(HttpApiKeyAuthTrait.class); + } + + /** + * The AuthScheme representing api key auth. + */ + private static final class ApiKeyAuthScheme implements AuthScheme { + + @Override + public ShapeId getAuthTrait() { + return HttpApiKeyAuthTrait.ID; + } + + @Override + public ApplicationProtocol getApplicationProtocol() { + return ApplicationProtocol.createDefaultHttpApplicationProtocol(); + } + + @Override + public Symbol getAuthOptionGenerator(GenerationContext context) { + var resolver = CodegenUtils.getHttpAuthSchemeResolverSymbol(context.settings()); + return Symbol.builder() + .name(OPTION_GENERATOR_NAME) + .namespace(resolver.getNamespace(), ".") + .definitionFile(resolver.getDefinitionFile()) + .build(); + } + + @Override + public Symbol getAuthSchemeSymbol(GenerationContext context) { + return Symbol.builder() + .name("ApiKeyAuthScheme") + .namespace("smithy_http.aio.auth.apikey", ".") + .addDependency(SmithyPythonDependency.SMITHY_HTTP) + .build(); + } + } +} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/HttpBindingProtocolGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/HttpBindingProtocolGenerator.java similarity index 80% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/HttpBindingProtocolGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/HttpBindingProtocolGenerator.java index b34d45a68..8042663b9 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/HttpBindingProtocolGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/HttpBindingProtocolGenerator.java @@ -1,20 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen.integration; - +package software.amazon.smithy.python.codegen.integrations; import static java.lang.String.format; import static software.amazon.smithy.model.knowledge.HttpBinding.Location.DOCUMENT; @@ -25,8 +13,8 @@ import static software.amazon.smithy.model.knowledge.HttpBinding.Location.QUERY; import static software.amazon.smithy.model.knowledge.HttpBinding.Location.QUERY_PARAMS; import static software.amazon.smithy.model.traits.TimestampFormatTrait.Format; -import static software.amazon.smithy.python.codegen.integration.HttpProtocolGeneratorUtils.generateErrorDispatcher; -import static software.amazon.smithy.python.codegen.integration.HttpProtocolGeneratorUtils.getOutputShape; +import static software.amazon.smithy.python.codegen.integrations.HttpProtocolGeneratorUtils.generateErrorDispatcher; +import static software.amazon.smithy.python.codegen.integrations.HttpProtocolGeneratorUtils.getOutputShape; import java.util.ArrayList; import java.util.List; @@ -70,8 +58,9 @@ import software.amazon.smithy.python.codegen.ApplicationProtocol; import software.amazon.smithy.python.codegen.CodegenUtils; import software.amazon.smithy.python.codegen.GenerationContext; -import software.amazon.smithy.python.codegen.PythonWriter; import software.amazon.smithy.python.codegen.SmithyPythonDependency; +import software.amazon.smithy.python.codegen.generators.ProtocolGenerator; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.CodeSection; import software.amazon.smithy.utils.SmithyUnstableApi; import software.amazon.smithy.utils.StringUtils; @@ -131,10 +120,14 @@ public void generateRequestSerializers(GenerationContext context) { delegator.useFileWriter(serFunction.getDefinitionFile(), serFunction.getNamespace(), writer -> { writer.pushState(new RequestSerializerSection(operation)); writer.write(""" - async def $L(input: $T, config: $T) -> $T: - ${C|} - """, serFunction.getName(), inputSymbol, configSymbol, transportRequest, - writer.consumer(w -> generateRequestSerializer(context, operation, w))); + async def $L(input: $T, config: $T) -> $T: + ${C|} + """, + serFunction.getName(), + inputSymbol, + configSymbol, + transportRequest, + writer.consumer(w -> generateRequestSerializer(context, operation, w))); writer.popState(); }); } @@ -157,9 +150,9 @@ public void generateRequestSerializers(GenerationContext context) { * */ private void generateRequestSerializer( - GenerationContext context, - OperationShape operation, - PythonWriter writer + GenerationContext context, + OperationShape operation, + PythonWriter writer ) { var httpTrait = operation.expectTrait(HttpTrait.class); var bindingIndex = HttpBindingIndex.of(context.model()); @@ -174,18 +167,18 @@ private void generateRequestSerializer( writer.addImport("smithy_core", "URI", "_URI"); writer.write(""" - return _HTTPRequest( - destination=_URI( - host="", - path=path, - scheme="https", - query=query, - ), - method=$S, - fields=headers, - body=body, - ) - """, httpTrait.getMethod()); + return _HTTPRequest( + destination=_URI( + host="", + path=path, + scheme="https", + query=query, + ), + method=$S, + fields=headers, + body=body, + ) + """, httpTrait.getMethod()); } /** @@ -200,28 +193,28 @@ public record RequestSerializerSection(OperationShape operation) implements Code * and protocol-specific standard headers. */ private void serializeHeaders( - GenerationContext context, - PythonWriter writer, - OperationShape operation + GenerationContext context, + PythonWriter writer, + OperationShape operation ) { writer.pushState(new SerializeFieldsSection(operation)); writer.addDependency(SmithyPythonDependency.SMITHY_HTTP); writer.addImports("smithy_http", Set.of("Field", "Fields")); writer.write(""" - headers = Fields( - [ - ${C|} - ${C|} - ${C|} - ] - ) - - """, - writer.consumer(w -> writeContentType(context, w, operation)), - writer.consumer(w -> writeContentLength(context, w, operation)), - writer.consumer(w -> writeDefaultHeaders(context, w, operation))); - serializeIndividualHeaders(context, writer, operation); - serializePrefixHeaders(context, writer, operation); + headers = Fields( + [ + ${C|} + ${C|} + ${C|} + ] + ) + + """, + writer.consumer(w -> writeContentType(context, w, operation)), + writer.consumer(w -> writeContentLength(context, w, operation)), + writer.consumer(w -> writeDefaultHeaders(context, w, operation))); + serializeIndividualHeaders(context, writer, operation); + serializePrefixHeaders(context, writer, operation); writer.popState(); } @@ -242,7 +235,8 @@ private void writeContentType(GenerationContext context, PythonWriter writer, Op optionalContentType = Optional.of(getDocumentContentType()); } optionalContentType.ifPresent(contentType -> writer.write( - "Field(name=\"Content-Type\", values=[$S]),", contentType)); + "Field(name=\"Content-Type\", values=[$S]),", + contentType)); } private void writeContentLength(GenerationContext context, PythonWriter writer, OperationShape operation) { @@ -262,8 +256,10 @@ private void writeContentLength(GenerationContext context, PythonWriter writer, // If there is nothing bound to the body, there's no need to add a length. var hasBodyBindings = HttpBindingIndex.of(context.model()) - .getRequestBindings(operation).values().stream() - .anyMatch(binding -> binding.getLocation() == PAYLOAD || binding.getLocation() == DOCUMENT); + .getRequestBindings(operation) + .values() + .stream() + .anyMatch(binding -> binding.getLocation() == PAYLOAD || binding.getLocation() == DOCUMENT); if (hasBodyBindings) { writer.write("Field(name=\"Content-Length\", values=[str(content_length)]),"); @@ -295,8 +291,7 @@ private boolean requiresLength(GenerationContext context, OperationShape operati * @param writer The writer to write to. * @param operation The operation whose input is being generated. */ - protected void writeDefaultHeaders(GenerationContext context, PythonWriter writer, OperationShape operation) { - } + protected void writeDefaultHeaders(GenerationContext context, PythonWriter writer, OperationShape operation) {} /** * Serialize headers that are bound with the httpHeader trait, where a single @@ -322,23 +317,32 @@ private void serializeIndividualHeaders(GenerationContext context, PythonWriter var listMember = target.asListShape().get().getMember(); var listTarget = context.model().expectShape(listMember.getTarget()); var inputValue = listTarget.accept(new HttpMemberSerVisitor( - context, writer, binding.getLocation(), "e", listMember, - getDocumentTimestampFormat())); + context, + writer, + binding.getLocation(), + "e", + listMember, + getDocumentTimestampFormat())); var trailer = listTarget.isStringShape() ? " if e" : ""; writer.addDependency(SmithyPythonDependency.SMITHY_HTTP); writer.addImport("smithy_http", "tuples_to_fields"); writer.write(""" - headers.extend(tuples_to_fields(($S, $L) for e in input.$L$L)) - """, binding.getLocationName(), inputValue, pythonName, trailer); + headers.extend(tuples_to_fields(($S, $L) for e in input.$L$L)) + """, binding.getLocationName(), inputValue, pythonName, trailer); } else { var dataSource = "input." + pythonName; var inputValue = target.accept(new HttpMemberSerVisitor( - context, writer, binding.getLocation(), dataSource, binding.getMember(), - getDocumentTimestampFormat())); + context, + writer, + binding.getLocation(), + dataSource, + binding.getMember(), + getDocumentTimestampFormat())); writer.write( - "headers.extend(Fields([Field(name=$S, values=[$L])]))", - binding.getLocationName(), inputValue); + "headers.extend(Fields([Field(name=$S, values=[$L])]))", + binding.getLocationName(), + inputValue); } }); } @@ -360,16 +364,19 @@ private void serializePrefixHeaders(GenerationContext context, PythonWriter writ var target = context.model().expectShape(binding.getMember().getTarget(), MapShape.class); var valueTarget = context.model().expectShape(target.getValue().getTarget()); var inputValue = valueTarget.accept(new HttpMemberSerVisitor( - context, writer, binding.getLocation(), "v", target.getValue(), - getDocumentTimestampFormat())); + context, + writer, + binding.getLocation(), + "v", + target.getValue(), + getDocumentTimestampFormat())); writer.addDependency(SmithyPythonDependency.SMITHY_HTTP); writer.addImport("smithy_http", "tuples_to_fields"); writer.write(""" - headers.extend( - tuples_to_fields((f'$L{k}', $L) for k, v in input.$L.items() if v) - ) - """, binding.getLocationName( - ), inputValue, pythonName); + headers.extend( + tuples_to_fields((f'$L{k}', $L) for k, v in input.$L.items() if v) + ) + """, binding.getLocationName(), inputValue, pythonName); }); } @@ -389,18 +396,19 @@ public record SerializeFieldsSection(OperationShape operation) implements CodeSe * Serializes the path, including resolving any path bindings. */ private void serializePath( - GenerationContext context, - PythonWriter writer, - OperationShape operation, - HttpBindingIndex bindingIndex + GenerationContext context, + PythonWriter writer, + OperationShape operation, + HttpBindingIndex bindingIndex ) { writer.pushState(new SerializePathSection(operation)); // Get a map of member name to label bindings. The URI pattern we fetch uses the member name // for the content of label segments, so this lets us look up the extra info we need for those. // see: https://smithy.io/2.0/spec/http-bindings.html#httplabel-trait - var labelBindings = bindingIndex.getRequestBindings(operation, LABEL).stream() - .collect(Collectors.toMap(HttpBinding::getMemberName, httpBinding -> httpBinding)); + var labelBindings = bindingIndex.getRequestBindings(operation, LABEL) + .stream() + .collect(Collectors.toMap(HttpBinding::getMemberName, httpBinding -> httpBinding)); // Build up a format string that will produce the path. We could have used an f-string, but they end up // taking a ton of space and aren't easily formatted. Using .format results in something that is much @@ -417,9 +425,9 @@ private void serializePath( // Note that we've not actually started writing the format string out yet, which // is why we can just write out these guard clauses here. writer.write(""" - if not input.$1L: - raise $2T("$1L must not be empty.") - """, memberName, CodegenUtils.getServiceError(context.settings())); + if not input.$1L: + raise $2T("$1L must not be empty.") + """, memberName, CodegenUtils.getServiceError(context.settings())); // We're creating an f-string, so here we just put the contents inside some brackets to allow // for string interpolation. @@ -455,8 +463,12 @@ private void serializePath( var dataSource = "input." + memberName; var target = context.model().expectShape(httpBinding.getMember().getTarget()); var inputValue = target.accept(new HttpMemberSerVisitor( - context, writer, httpBinding.getLocation(), dataSource, httpBinding.getMember(), - getDocumentTimestampFormat())); + context, + writer, + httpBinding.getLocation(), + dataSource, + httpBinding.getMember(), + getDocumentTimestampFormat())); writer.write("$1L=urlquote($3L$2L),", memberName, urlSafe, inputValue); } }); @@ -478,10 +490,10 @@ public record SerializePathSection(OperationShape operation) implements CodeSect * Serializes the query in the form of a list of tuples. */ private void serializeQuery( - GenerationContext context, - PythonWriter writer, - OperationShape operation, - HttpBindingIndex bindingIndex + GenerationContext context, + PythonWriter writer, + OperationShape operation, + HttpBindingIndex bindingIndex ) { writer.pushState(new SerializeQuerySection(operation)); var httpTrait = operation.expectTrait(HttpTrait.class); @@ -491,14 +503,14 @@ private void serializeQuery( writer.addDependency(SmithyPythonDependency.SMITHY_HTTP); writer.addImport("smithy_http.utils", "join_query_params"); writer.write(""" - query_params: list[tuple[str, str | None]] = [] - ${C|} - ${C|} - query = join_query_params(params=query_params, prefix=query) + query_params: list[tuple[str, str | None]] = [] + ${C|} + ${C|} + query = join_query_params(params=query_params, prefix=query) - """, - writer.consumer(w -> serializeIndividualQueryParams(context, w, operation, bindingIndex)), - writer.consumer(w -> serializeQueryParamsMap(context, w, operation, bindingIndex))); + """, + writer.consumer(w -> serializeIndividualQueryParams(context, w, operation, bindingIndex)), + writer.consumer(w -> serializeQueryParamsMap(context, w, operation, bindingIndex))); } writer.popState(); @@ -506,8 +518,10 @@ private void serializeQuery( private boolean hasQueryBindings(GenerationContext context, OperationShape operation) { return HttpBindingIndex.of(context.model()) - .getRequestBindings(operation).values().stream() - .anyMatch(binding -> binding.getLocation() == QUERY || binding.getLocation() == QUERY_PARAMS); + .getRequestBindings(operation) + .values() + .stream() + .anyMatch(binding -> binding.getLocation() == QUERY || binding.getLocation() == QUERY_PARAMS); } // The http trait can add static query literals as part of its 'uri' property. @@ -529,7 +543,8 @@ private void writeStaticQuerySegment(PythonWriter writer, UriPattern uri) { writer.writeInline("{urlquote($S, safe=\"\")}", entry.getKey()); } else { writer.writeInline("{urlquote($S, safe=\"\")}={urlquote($S, safe=\"\")}", - entry.getKey(), entry.getValue()); + entry.getKey(), + entry.getValue()); } } @@ -543,10 +558,10 @@ private void writeStaticQuerySegment(PythonWriter writer, UriPattern uri) { *

{@see https://smithy.io/2.0/spec/http-bindings.html#httpquery-trait} */ private void serializeIndividualQueryParams( - GenerationContext context, - PythonWriter writer, - OperationShape operation, - HttpBindingIndex bindingIndex + GenerationContext context, + PythonWriter writer, + OperationShape operation, + HttpBindingIndex bindingIndex ) { var queryBindings = bindingIndex.getRequestBindings(operation, QUERY); for (HttpBinding binding : queryBindings) { @@ -559,14 +574,24 @@ private void serializeIndividualQueryParams( var listMember = target.asListShape().get().getMember(); var listTarget = context.model().expectShape(listMember.getTarget()); var memberSerializer = listTarget.accept(new HttpMemberSerVisitor( - context, writer, QUERY, "e", listMember, - getDocumentTimestampFormat())); + context, + writer, + QUERY, + "e", + listMember, + getDocumentTimestampFormat())); writer.write("query_params.extend(($S, $L) for e in input.$L)", - locationName, memberSerializer, memberName); + locationName, + memberSerializer, + memberName); } else { var memberSerializer = target.accept(new HttpMemberSerVisitor( - context, writer, QUERY, "input." + memberName, binding.getMember(), - getDocumentTimestampFormat())); + context, + writer, + QUERY, + "input." + memberName, + binding.getMember(), + getDocumentTimestampFormat())); writer.write("query_params.append(($S, $L))", locationName, memberSerializer); } }); @@ -581,10 +606,10 @@ private void serializeIndividualQueryParams( *

{@see https://smithy.io/2.0/spec/http-bindings.html#httpqueryparams-trait} */ private void serializeQueryParamsMap( - GenerationContext context, - PythonWriter writer, - OperationShape operation, - HttpBindingIndex bindingIndex + GenerationContext context, + PythonWriter writer, + OperationShape operation, + HttpBindingIndex bindingIndex ) { var queryMapBindings = bindingIndex.getRequestBindings(operation, QUERY_PARAMS); for (HttpBinding binding : queryMapBindings) { @@ -597,16 +622,26 @@ private void serializeQueryParamsMap( var listMember = mapTarget.asListShape().get().getMember(); var listMemberTarget = context.model().expectShape(listMember.getTarget()); var memberSerializer = listMemberTarget.accept(new HttpMemberSerVisitor( - context, writer, QUERY, "v", listMember, - getDocumentTimestampFormat())); + context, + writer, + QUERY, + "v", + listMember, + getDocumentTimestampFormat())); writer.write("query_params.extend((k, $1L) for k in input.$2L for v in input.$2L[k])", - memberSerializer, memberName); + memberSerializer, + memberName); } else { var memberSerializer = mapTarget.accept(new HttpMemberSerVisitor( - context, writer, QUERY, "v", mapShape.getValue(), - getDocumentTimestampFormat())); + context, + writer, + QUERY, + "v", + mapShape.getValue(), + getDocumentTimestampFormat())); writer.write("query_params.extend((k, $L) for k, v in input.$L.items())", - memberSerializer, memberName); + memberSerializer, + memberName); } }); } @@ -629,10 +664,10 @@ public record SerializeQuerySection(OperationShape operation) implements CodeSec * protocol, so this delegates out to implementors. */ private void serializeBody( - GenerationContext context, - PythonWriter writer, - OperationShape operation, - HttpBindingIndex bindingIndex + GenerationContext context, + PythonWriter writer, + OperationShape operation, + HttpBindingIndex bindingIndex ) { writer.pushState(new SerializeBodySection(operation)); writer.addDependency(SmithyPythonDependency.SMITHY_CORE); @@ -705,10 +740,10 @@ public record SerializeBodySection(OperationShape operation) implements CodeSect * @param documentBindings The bindings to place in the document. */ protected abstract void serializeDocumentBody( - GenerationContext context, - PythonWriter writer, - OperationShape operation, - List documentBindings + GenerationContext context, + PythonWriter writer, + OperationShape operation, + List documentBindings ); /** @@ -720,8 +755,8 @@ protected abstract void serializeDocumentBody( * @param shapes The shapes to generate deserialization for. */ protected abstract void generateDocumentBodyShapeSerializers( - GenerationContext context, - Set shapes + GenerationContext context, + Set shapes ); /** @@ -749,10 +784,10 @@ protected abstract void generateDocumentBodyShapeSerializers( * @param payloadBinding The payload binding to serialize. */ protected abstract void serializePayloadBody( - GenerationContext context, - PythonWriter writer, - OperationShape operation, - HttpBinding payloadBinding + GenerationContext context, + PythonWriter writer, + OperationShape operation, + HttpBinding payloadBinding ); @Override @@ -786,8 +821,8 @@ public void generateResponseDeserializers(GenerationContext context) { * */ private void generateOperationResponseDeserializer( - GenerationContext context, - OperationShape operation + GenerationContext context, + OperationShape operation ) { var delegator = context.writerDelegator(); var deserFunction = getDeserializationFunction(context, operation); @@ -807,17 +842,22 @@ private void generateOperationResponseDeserializer( // occurred if the status is 300+. // see: https://smithy.io/2.0/spec/http-bindings.html#http-trait writer.write(""" - async def $L(http_response: $T, config: $T) -> $T: - if http_response.status != $L and http_response.status >= 300: - raise await $T(http_response, config) + async def $L(http_response: $T, config: $T) -> $T: + if http_response.status != $L and http_response.status >= 300: + raise await $T(http_response, config) - kwargs: dict[str, Any] = {} + kwargs: dict[str, Any] = {} - ${C|} + ${C|} - """, deserFunction.getName(), transportResponse, configSymbol, - outputSymbol, httpTrait.getCode(), errorFunction, - writer.consumer(w -> generateHttpResponseDeserializer(context, writer, operation))); + """, + deserFunction.getName(), + transportResponse, + configSymbol, + outputSymbol, + httpTrait.getCode(), + errorFunction, + writer.consumer(w -> generateHttpResponseDeserializer(context, writer, operation))); writer.popState(); }); @@ -843,18 +883,22 @@ private void generateErrorResponseDeserializer(GenerationContext context, Struct writer.addStdlibImport("typing", "Any"); writer.addImport("smithy_core.documents", "DocumentValue"); writer.write(""" - async def $L( - http_response: $T, - config: $T, - parsed_body: dict[str, DocumentValue] | None, - default_message: str, - ) -> $T: - kwargs: dict[str, Any] = {"message": default_message} + async def $L( + http_response: $T, + config: $T, + parsed_body: dict[str, DocumentValue] | None, + default_message: str, + ) -> $T: + kwargs: dict[str, Any] = {"message": default_message} - ${C|} + ${C|} - """, deserFunction.getName(), transportResponse, configSymbol, errorSymbol, - writer.consumer(w -> generateHttpResponseDeserializer(context, writer, error))); + """, + deserFunction.getName(), + transportResponse, + configSymbol, + errorSymbol, + writer.consumer(w -> generateHttpResponseDeserializer(context, writer, error))); writer.popState(); }); } @@ -867,27 +911,27 @@ private void generateErrorResponseDeserializer(GenerationContext context, Struct public record ErrorDeserializerSection(StructureShape error) implements CodeSection {} private void generateHttpResponseDeserializer( - GenerationContext context, - PythonWriter writer, - Shape operationOrError + GenerationContext context, + PythonWriter writer, + Shape operationOrError ) { var bindingIndex = HttpBindingIndex.of(context.model()); var outputShape = getOutputShape(context, operationOrError); var outputSymbol = context.symbolProvider().toSymbol(outputShape); writer.write(""" - ${C|} + ${C|} - ${C|} + ${C|} - ${C|} + ${C|} - return $T(**kwargs) - """, - writer.consumer(w -> deserializeBody(context, w, operationOrError, bindingIndex)), - writer.consumer(w -> deserializeHeaders(context, w, operationOrError, bindingIndex)), - writer.consumer(w -> deserializeStatusCode(context, w, operationOrError, bindingIndex)), - outputSymbol); + return $T(**kwargs) + """, + writer.consumer(w -> deserializeBody(context, w, operationOrError, bindingIndex)), + writer.consumer(w -> deserializeHeaders(context, w, operationOrError, bindingIndex)), + writer.consumer(w -> deserializeStatusCode(context, w, operationOrError, bindingIndex)), + outputSymbol); } /** @@ -911,16 +955,16 @@ protected String getErrorCode(StructureShape error) { * @param canReadResponseBody If the http response body can be parsed by the delegator. */ protected abstract void resolveErrorCodeAndMessage( - GenerationContext context, - PythonWriter writer, - Boolean canReadResponseBody + GenerationContext context, + PythonWriter writer, + Boolean canReadResponseBody ); private void deserializeHeaders( - GenerationContext context, - PythonWriter writer, - Shape operationOrError, - HttpBindingIndex bindingIndex + GenerationContext context, + PythonWriter writer, + Shape operationOrError, + HttpBindingIndex bindingIndex ) { writer.pushState(new DeserializeFieldsSection(operationOrError)); var individualBindings = bindingIndex.getResponseBindings(operationOrError, HEADER); @@ -928,15 +972,14 @@ private void deserializeHeaders( if (!individualBindings.isEmpty() || !prefixBindings.isEmpty()) { writer.write(""" - for fld in http_response.fields: - for key, value in fld.as_tuples(): - _key_lowercase = key.lower() - ${C|} - ${C|} - """, - writer.consumer(w -> deserializeIndividualHeaders(context, w, individualBindings)), - writer.consumer(w -> deserializePrefixHeaders(context, w, prefixBindings)) - ); + for fld in http_response.fields: + for key, value in fld.as_tuples(): + _key_lowercase = key.lower() + ${C|} + ${C|} + """, + writer.consumer(w -> deserializeIndividualHeaders(context, w, individualBindings)), + writer.consumer(w -> deserializePrefixHeaders(context, w, prefixBindings))); } writer.popState(); @@ -948,9 +991,9 @@ private void deserializeHeaders( *

{@see https://smithy.io/2.0/spec/http-bindings.html#httpheader-trait} */ private void deserializeIndividualHeaders( - GenerationContext context, - PythonWriter writer, - List bindings + GenerationContext context, + PythonWriter writer, + List bindings ) { if (bindings.isEmpty()) { return; @@ -963,28 +1006,31 @@ private void deserializeIndividualHeaders( var memberName = context.symbolProvider().toMemberName(binding.getMember()); var locationName = binding.getLocationName().toLowerCase(Locale.US); var deserVisitor = new HttpMemberDeserVisitor( - context, writer, binding.getLocation(), "value", binding.getMember(), - getDocumentTimestampFormat() - ); + context, + writer, + binding.getLocation(), + "value", + binding.getMember(), + getDocumentTimestampFormat()); var targetHandler = target.accept(deserVisitor); if (target.isListShape()) { // A header list can be a comma-delimited single entry, a set of entries with // the same header key, or a combination of the two. writer.write(""" - case $1S: - _$2L = $3L - if $2S not in kwargs: - kwargs[$2S] = _$2L - else: - kwargs[$2S].extend(_$2L) - - """, locationName, memberName, targetHandler); + case $1S: + _$2L = $3L + if $2S not in kwargs: + kwargs[$2S] = _$2L + else: + kwargs[$2S].extend(_$2L) + + """, locationName, memberName, targetHandler); } else { writer.write(""" - case $1S: - kwargs[$2S] = $3L + case $1S: + kwargs[$2S] = $3L - """, locationName, memberName, targetHandler); + """, locationName, memberName, targetHandler); } } @@ -1004,9 +1050,9 @@ private void deserializeIndividualHeaders( *

{@see https://smithy.io/2.0/spec/http-bindings.html#httpprefixheaders-trait} */ private void deserializePrefixHeaders( - GenerationContext context, - PythonWriter writer, - List bindings + GenerationContext context, + PythonWriter writer, + List bindings ) { for (HttpBinding binding : bindings) { var bindingTarget = context.model().expectShape(binding.getMember().getTarget()).asMapShape().get(); @@ -1014,17 +1060,20 @@ private void deserializePrefixHeaders( var memberName = context.symbolProvider().toMemberName(binding.getMember()); var locationName = binding.getLocationName().toLowerCase(Locale.US); var deserVisitor = new HttpMemberDeserVisitor( - context, writer, binding.getLocation(), "value", bindingTarget.getValue(), - getDocumentTimestampFormat() - ); + context, + writer, + binding.getLocation(), + "value", + bindingTarget.getValue(), + getDocumentTimestampFormat()); // Prefix headers can only be maps of string to string, and they can't be sparse. writer.write(""" - if _key_lowercase.startswith($1S): - if $2S not in kwargs: - kwargs[$2S] = {} - kwargs[$2S][key[$3L:]] = $4L + if _key_lowercase.startswith($1S): + if $2S not in kwargs: + kwargs[$2S] = {} + kwargs[$2S][key[$3L:]] = $4L - """, locationName, memberName, locationName.length(), mapTarget.accept(deserVisitor)); + """, locationName, memberName, locationName.length(), mapTarget.accept(deserVisitor)); } } @@ -1044,10 +1093,10 @@ public record DeserializeFieldsSection(Shape operationOrError) implements CodeSe *

{@see https://smithy.io/2.0/spec/http-bindings.html#httpresponsecode-trait} */ private void deserializeStatusCode( - GenerationContext context, - PythonWriter writer, - Shape operationOrError, - HttpBindingIndex bindingIndex + GenerationContext context, + PythonWriter writer, + Shape operationOrError, + HttpBindingIndex bindingIndex ) { writer.pushState(new DeserializeStatusCodeSection(operationOrError)); var statusBinding = bindingIndex.getResponseBindings(operationOrError, Location.RESPONSE_CODE); @@ -1066,10 +1115,10 @@ private void deserializeStatusCode( public record DeserializeStatusCodeSection(Shape operationOrError) implements CodeSection {} private void deserializeBody( - GenerationContext context, - PythonWriter writer, - Shape operationOrError, - HttpBindingIndex bindingIndex + GenerationContext context, + PythonWriter writer, + Shape operationOrError, + HttpBindingIndex bindingIndex ) { // Any member that isn't explicitly bound to some part of the http // request is bound to the document, where "document" refers to a @@ -1127,13 +1176,12 @@ public record DeserializeBodySection(Shape operationOrError) implements CodeSect * @param documentBindings The bindings to read from the document. */ protected abstract void deserializeDocumentBody( - GenerationContext context, - PythonWriter writer, - Shape operationOrError, - List documentBindings + GenerationContext context, + PythonWriter writer, + Shape operationOrError, + List documentBindings ); - /** * Generates deserialization functions for shapes in the given set. * @@ -1143,8 +1191,8 @@ protected abstract void deserializeDocumentBody( * @param shapes The shapes to generate deserialization for. */ protected abstract void generateDocumentBodyShapeDeserializers( - GenerationContext context, - Set shapes + GenerationContext context, + Set shapes ); /** @@ -1158,10 +1206,10 @@ protected abstract void generateDocumentBodyShapeDeserializers( * @param payloadBinding The payload binding to deserialize. */ protected abstract void deserializePayloadBody( - GenerationContext context, - PythonWriter writer, - Shape operationOrError, - HttpBinding payloadBinding + GenerationContext context, + PythonWriter writer, + Shape operationOrError, + HttpBinding payloadBinding ); /** @@ -1187,12 +1235,12 @@ private static class HttpMemberSerVisitor extends ShapeVisitor.Default { * @param defaultTimestampFormat The default timestamp format to use. */ HttpMemberSerVisitor( - GenerationContext context, - PythonWriter writer, - Location bindingType, - String dataSource, - MemberShape member, - Format defaultTimestampFormat + GenerationContext context, + PythonWriter writer, + Location bindingType, + String dataSource, + MemberShape member, + Format defaultTimestampFormat ) { this.context = context; this.writer = writer; @@ -1206,8 +1254,12 @@ private static class HttpMemberSerVisitor extends ShapeVisitor.Default { protected String getDefault(Shape shape) { var protocolName = context.protocolGenerator().getName(); throw new CodegenException(String.format( - "Unsupported %s binding of %s to %s in %s using the %s protocol", - bindingType, member.getMemberName(), shape.getType(), member.getContainer(), protocolName)); + "Unsupported %s binding of %s to %s in %s using the %s protocol", + bindingType, + member.getMemberName(), + shape.getType(), + member.getContainer(), + protocolName)); } @Override @@ -1303,7 +1355,11 @@ public String timestampShape(TimestampShape shape) { }; var result = HttpProtocolGeneratorUtils.getTimestampInputParam( - context, writer, dataSource, member, format); + context, + writer, + dataSource, + member, + format); if (format == Format.EPOCH_SECONDS) { result = format("str(%s)", result); } @@ -1336,12 +1392,12 @@ private static class HttpMemberDeserVisitor extends ShapeVisitor.Default * @param defaultTimestampFormat The default timestamp format to use. */ HttpMemberDeserVisitor( - GenerationContext context, - PythonWriter writer, - Location bindingType, - String dataSource, - MemberShape member, - Format defaultTimestampFormat + GenerationContext context, + PythonWriter writer, + Location bindingType, + String dataSource, + MemberShape member, + Format defaultTimestampFormat ) { this.context = context; this.writer = writer; @@ -1355,8 +1411,12 @@ private static class HttpMemberDeserVisitor extends ShapeVisitor.Default protected String getDefault(Shape shape) { var protocolName = context.protocolGenerator().getName(); throw new CodegenException(String.format( - "Unsupported %s binding of %s to %s in %s using the %s protocol", - bindingType, member.getMemberName(), shape.getType(), member.getContainer(), protocolName)); + "Unsupported %s binding of %s to %s in %s using the %s protocol", + bindingType, + member.getMemberName(), + shape.getType(), + member.getContainer(), + protocolName)); } @Override @@ -1453,7 +1513,7 @@ public String bigDecimalShape(BigDecimalShape shape) { public String stringShape(StringShape shape) { if ((bindingType == HEADER || bindingType == PREFIX_HEADERS) && shape.hasTrait(MediaTypeTrait.ID)) { writer.addStdlibImport("base64", "b64decode"); - return "b64decode(" + dataSource + ").decode('utf-8')"; + return "b64decode(" + dataSource + ").decode('utf-8')"; } return dataSource; @@ -1490,7 +1550,12 @@ public String listShape(ListShape shape) { } var targetDeserVisitor = new HttpMemberDeserVisitor( - context, writer, bindingType, "e.strip()", shape.getMember(), defaultTimestampFormat); + context, + writer, + bindingType, + "e.strip()", + shape.getMember(), + defaultTimestampFormat); return String.format("[%s for e in %s]", collectionTarget.accept(targetDeserVisitor), split); } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/HttpProtocolGeneratorUtils.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/HttpProtocolGeneratorUtils.java similarity index 82% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/HttpProtocolGeneratorUtils.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/HttpProtocolGeneratorUtils.java index 64cc2cbc7..2f95918c6 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/HttpProtocolGeneratorUtils.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/HttpProtocolGeneratorUtils.java @@ -1,19 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen.integration; +package software.amazon.smithy.python.codegen.integrations; import static java.lang.String.format; @@ -29,8 +18,8 @@ import software.amazon.smithy.model.traits.TimestampFormatTrait.Format; import software.amazon.smithy.python.codegen.CodegenUtils; import software.amazon.smithy.python.codegen.GenerationContext; -import software.amazon.smithy.python.codegen.PythonWriter; import software.amazon.smithy.python.codegen.SmithyPythonDependency; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.CodeSection; import software.amazon.smithy.utils.SmithyUnstableApi; import software.amazon.smithy.utils.TriConsumer; @@ -43,11 +32,9 @@ public final class HttpProtocolGeneratorUtils { // Shape is an error on an operation shape that has the httpPayload trait applied to it // See: https://smithy.io/2.0/spec/selectors.html for more information on selectors private static final Selector PAYLOAD_ERROR_SELECTOR = Selector.parse( - "operation -[error]-> structure :test(> member :test([trait|httpPayload]))" - ); + "operation -[error]-> structure :test(> member :test([trait|httpPayload]))"); - private HttpProtocolGeneratorUtils() { - } + private HttpProtocolGeneratorUtils() {} /** * Given a format and a source of data, generate an input value provider for the @@ -63,11 +50,11 @@ private HttpProtocolGeneratorUtils() { * @return Returns a value or expression of the input timestamp. */ public static String getTimestampInputParam( - GenerationContext context, - PythonWriter writer, - String dataSource, - Shape shape, - Format format + GenerationContext context, + PythonWriter writer, + String dataSource, + Shape shape, + Format format ) { writer.addImport("smithy_core.utils", "ensure_utc"); var result = "ensure_utc(" + dataSource + ")"; @@ -101,10 +88,10 @@ public static String getTimestampInputParam( * @return Returns a value or expression of the output timestamp. */ public static String getTimestampOutputParam( - PythonWriter writer, - String dataSource, - Shape shape, - Format format + PythonWriter writer, + String dataSource, + Shape shape, + Format format ) { writer.addDependency(SmithyPythonDependency.SMITHY_CORE); writer.addImport("smithy_core.utils", "expect_type"); @@ -140,10 +127,10 @@ public static String getTimestampOutputParam( * body to {@literal parsed_body}. */ public static void generateErrorDispatcher( - GenerationContext context, - OperationShape operation, - Function errorShapeToCode, - TriConsumer errorMessageCodeGenerator + GenerationContext context, + OperationShape operation, + Function errorShapeToCode, + TriConsumer errorMessageCodeGenerator ) { var configSymbol = CodegenUtils.getConfigSymbol(context.settings()); var transportResponse = context.applicationProtocol().responseType(); @@ -163,7 +150,12 @@ public static void generateErrorDispatcher( case _: return $5T(message) - """, errorDispatcher.getName(), transportResponse, configSymbol, apiError, unknownApiError, + """, + errorDispatcher.getName(), + transportResponse, + configSymbol, + apiError, + unknownApiError, writer.consumer(w -> errorMessageCodeGenerator.accept(context, w, canReadResponseBody)), writer.consumer(w -> errorCases(context, w, operation, errorShapeToCode))); writer.popState(); @@ -181,15 +173,15 @@ public static void generateErrorDispatcher( */ private static boolean canReadResponseBody(OperationShape operationShape, Model model) { return PAYLOAD_ERROR_SELECTOR.shapes(model) - .map(Shape::getId) - .noneMatch(shapeId -> operationShape.getErrors().contains(shapeId)); + .map(Shape::getId) + .noneMatch(shapeId -> operationShape.getErrors().contains(shapeId)); } private static void errorCases( - GenerationContext context, - PythonWriter writer, - OperationShape operation, - Function errorShapeToCode + GenerationContext context, + PythonWriter writer, + OperationShape operation, + Function errorShapeToCode ) { var errorIds = operation.getErrors(context.settings().service(context.model())); for (ShapeId errorId : errorIds) { @@ -197,9 +189,9 @@ private static void errorCases( var code = errorShapeToCode.apply(error).toLowerCase(Locale.US); var deserFunction = context.protocolGenerator().getErrorDeserializationFunction(context, errorId); writer.write(""" - case $S: - return await $T(http_response, config, parsed_body, message) - """, code, deserFunction); + case $S: + return await $T(http_response, config, parsed_body, message) + """, code, deserFunction); } } @@ -228,8 +220,7 @@ public static Shape getOutputShape(GenerationContext context, Shape operationOrE * @param errorMessageCodeGenerator A consumer that generates code to extract the error message and code. */ public record ErrorDispatcherSection( - OperationShape operation, - Function errorShapeToCode, - TriConsumer errorMessageCodeGenerator - ) implements CodeSection {} + OperationShape operation, + Function errorShapeToCode, + TriConsumer errorMessageCodeGenerator) implements CodeSection {} } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/PythonIntegration.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/PythonIntegration.java similarity index 66% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/PythonIntegration.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/PythonIntegration.java index c9ddeb186..a23cf237a 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/PythonIntegration.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/PythonIntegration.java @@ -1,26 +1,16 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen.integration; +package software.amazon.smithy.python.codegen.integrations; import java.util.Collections; import java.util.List; import software.amazon.smithy.codegen.core.SmithyIntegration; import software.amazon.smithy.python.codegen.GenerationContext; import software.amazon.smithy.python.codegen.PythonSettings; -import software.amazon.smithy.python.codegen.PythonWriter; +import software.amazon.smithy.python.codegen.generators.ProtocolGenerator; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.SmithyUnstableApi; /** diff --git a/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/RestJsonIntegration.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/RestJsonIntegration.java new file mode 100644 index 000000000..defb630fe --- /dev/null +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/RestJsonIntegration.java @@ -0,0 +1,20 @@ +/* + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * SPDX-License-Identifier: Apache-2.0 + */ +package software.amazon.smithy.python.codegen.integrations; + +import java.util.List; +import software.amazon.smithy.python.codegen.generators.ProtocolGenerator; +import software.amazon.smithy.utils.SmithyInternalApi; + +/** + * Integration that registers {@link RestJsonProtocolGenerator}. + */ +@SmithyInternalApi +public final class RestJsonIntegration implements PythonIntegration { + @Override + public List getProtocolGenerators() { + return List.of(new RestJsonProtocolGenerator()); + } +} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/RestJsonProtocolGenerator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/RestJsonProtocolGenerator.java similarity index 80% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/RestJsonProtocolGenerator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/RestJsonProtocolGenerator.java index 066c7a76e..7e3165105 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/RestJsonProtocolGenerator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/RestJsonProtocolGenerator.java @@ -1,19 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen.integration; +package software.amazon.smithy.python.codegen.integrations; import java.util.List; import java.util.Set; @@ -33,9 +22,9 @@ import software.amazon.smithy.python.codegen.CodegenUtils; import software.amazon.smithy.python.codegen.GenerationContext; import software.amazon.smithy.python.codegen.HttpProtocolTestGenerator; -import software.amazon.smithy.python.codegen.PythonWriter; import software.amazon.smithy.python.codegen.SmithyPythonDependency; import software.amazon.smithy.python.codegen.SymbolProperties; +import software.amazon.smithy.python.codegen.writer.PythonWriter; import software.amazon.smithy.utils.SmithyUnstableApi; /** @@ -50,43 +39,42 @@ public class RestJsonProtocolGenerator extends HttpBindingProtocolGenerator { private static final Set TESTS_TO_SKIP = Set.of( - // These two tests essentially try to assert nan == nan, - // which is never true. We should update the generator to - // make specific assertions for these. - "RestJsonSupportsNaNFloatHeaderOutputs", - "RestJsonSupportsNaNFloatInputs", - - // This requires support of idempotency autofill - "RestJsonQueryIdempotencyTokenAutoFill", - - // This requires support of the httpChecksumRequired trait - "RestJsonHttpChecksumRequired", - - // These require support of the endpoint trait - "RestJsonEndpointTraitWithHostLabel", - "RestJsonEndpointTrait", - - // TODO: support the request compression trait - // https://smithy.io/2.0/spec/behavior-traits.html#smithy-api-requestcompression-trait - "SDKAppliedContentEncoding_restJson1", - "SDKAppendedGzipAfterProvidedEncoding_restJson1", - - // TODO: update union deserialization to ignore `__type` for JSON protocols - "RestJsonDeserializeIgnoreType", - - // These tests do need to be fixed, but they're being disabled right now - // since the way protocols work is changing. - "RestJsonClientPopulatesDefaultValuesInInput", - "RestJsonClientSkipsTopLevelDefaultValuesInInput", - "RestJsonClientUsesExplicitlyProvidedMemberValuesOverDefaults", - "RestJsonClientIgnoresNonTopLevelDefaultsOnMembersWithClientOptional", - "RestJsonClientPopulatesDefaultsValuesWhenMissingInResponse", - "RestJsonClientIgnoresDefaultValuesIfMemberValuesArePresentInResponse", - "RestJsonClientPopulatesNestedDefaultsWhenMissingInResponseBody", - "RestJsonHttpPrefixEmptyHeaders", - "RestJsonNullAndEmptyHeaders", - "HttpPrefixEmptyHeaders" - ); + // These two tests essentially try to assert nan == nan, + // which is never true. We should update the generator to + // make specific assertions for these. + "RestJsonSupportsNaNFloatHeaderOutputs", + "RestJsonSupportsNaNFloatInputs", + + // This requires support of idempotency autofill + "RestJsonQueryIdempotencyTokenAutoFill", + + // This requires support of the httpChecksumRequired trait + "RestJsonHttpChecksumRequired", + + // These require support of the endpoint trait + "RestJsonEndpointTraitWithHostLabel", + "RestJsonEndpointTrait", + + // TODO: support the request compression trait + // https://smithy.io/2.0/spec/behavior-traits.html#smithy-api-requestcompression-trait + "SDKAppliedContentEncoding_restJson1", + "SDKAppendedGzipAfterProvidedEncoding_restJson1", + + // TODO: update union deserialization to ignore `__type` for JSON protocols + "RestJsonDeserializeIgnoreType", + + // These tests do need to be fixed, but they're being disabled right now + // since the way protocols work is changing. + "RestJsonClientPopulatesDefaultValuesInInput", + "RestJsonClientSkipsTopLevelDefaultValuesInInput", + "RestJsonClientUsesExplicitlyProvidedMemberValuesOverDefaults", + "RestJsonClientIgnoresNonTopLevelDefaultsOnMembersWithClientOptional", + "RestJsonClientPopulatesDefaultsValuesWhenMissingInResponse", + "RestJsonClientIgnoresDefaultValuesIfMemberValuesArePresentInResponse", + "RestJsonClientPopulatesNestedDefaultsWhenMissingInResponseBody", + "RestJsonHttpPrefixEmptyHeaders", + "RestJsonNullAndEmptyHeaders", + "HttpPrefixEmptyHeaders"); @Override public ShapeId getProtocol() { @@ -120,8 +108,10 @@ protected String getDocumentContentType() { public void generateProtocolTests(GenerationContext context) { context.writerDelegator().useFileWriter("./tests/test_protocol.py", "tests.test_protocol", writer -> { new HttpProtocolTestGenerator( - context, getProtocol(), writer, (shape, testCase) -> filterTests(testCase) - ).run(); + context, + getProtocol(), + writer, + (shape, testCase) -> filterTests(testCase)).run(); }); } @@ -131,10 +121,10 @@ private boolean filterTests(HttpMessageTestCase testCase) { @Override protected void serializeDocumentBody( - GenerationContext context, - PythonWriter writer, - OperationShape operation, - List documentBindings + GenerationContext context, + PythonWriter writer, + OperationShape operation, + List documentBindings ) { writer.addDependency(SmithyPythonDependency.SMITHY_JSON); writer.addImport("smithy_json", "JSONCodec"); @@ -168,10 +158,10 @@ protected void serializeDocumentBody( @Override protected void serializePayloadBody( - GenerationContext context, - PythonWriter writer, - OperationShape operation, - HttpBinding payloadBinding + GenerationContext context, + PythonWriter writer, + OperationShape operation, + HttpBinding payloadBinding ) { var target = context.model().expectShape(payloadBinding.getMember().getTarget()); var dataSource = "input." + context.symbolProvider().toMemberName(payloadBinding.getMember()); @@ -201,11 +191,11 @@ protected void serializePayloadBody( // we can't assume that the source is seekable or safe to read more than once. writer.addImport("smithy_core.aio.types", "SeekableAsyncBytesReader"); writer.write(""" - body = SeekableAsyncBytesReader($L) - await body.seek(0, 2) - content_length = body.tell() - await body.seek(0, 0) - """, dataSource); + body = SeekableAsyncBytesReader($L) + await body.seek(0, 2) + content_length = body.tell() + await body.seek(0, 0) + """, dataSource); } else { writer.addStdlibImport("typing", "AsyncIterator"); writer.addImport("smithy_core.aio.types", "AsyncBytesReader"); @@ -213,11 +203,11 @@ protected void serializePayloadBody( // a bytes iterator and pyright isn't quite as clever about narrowing the union as // mypy is in this case. writer.write(""" - if isinstance($1L, AsyncIterator): - body = $1L # type: ignore - else: - body = AsyncBytesReader($1L) - """, dataSource); + if isinstance($1L, AsyncIterator): + body = $1L # type: ignore + else: + body = AsyncBytesReader($1L) + """, dataSource); } }); return; @@ -248,10 +238,10 @@ protected void serializePayloadBody( }); if (target.isStructureShape()) { writer.write(""" - else: - content_length = 2 - body = SeekableAsyncBytesReader(b'{}') - """); + else: + content_length = 2 + body = SeekableAsyncBytesReader(b'{}') + """); } } @@ -267,10 +257,10 @@ protected void generateDocumentBodyShapeSerializers(GenerationContext context, S @Override protected void deserializeDocumentBody( - GenerationContext context, - PythonWriter writer, - Shape operationOrError, - List documentBindings + GenerationContext context, + PythonWriter writer, + Shape operationOrError, + List documentBindings ) { writer.addDependency(SmithyPythonDependency.SMITHY_JSON); writer.addDependency(SmithyPythonDependency.SMITHY_CORE); @@ -308,8 +298,8 @@ protected void deserializeDocumentBody( @Override protected void generateDocumentBodyShapeDeserializers( - GenerationContext context, - Set shapes + GenerationContext context, + Set shapes ) { // No longer needed now that JSONCodec is handling it } @@ -385,9 +375,10 @@ protected void deserializePayloadBody( } @Override - protected void resolveErrorCodeAndMessage(GenerationContext context, - PythonWriter writer, - Boolean canReadResponseBody + protected void resolveErrorCodeAndMessage( + GenerationContext context, + PythonWriter writer, + Boolean canReadResponseBody ) { writer.addDependency(SmithyPythonDependency.SMITHY_HTTP); writer.addImport("smithy_http.aio.restjson", "parse_rest_json_error_info"); @@ -403,8 +394,11 @@ public void wrapEventStream(GenerationContext context, PythonWriter writer) { writer.addDependency(SmithyPythonDependency.SMITHY_JSON); writer.addDependency(SmithyPythonDependency.AWS_EVENT_STREAM); writer.addDependency(SmithyPythonDependency.SMITHY_CORE); - writer.addImports("aws_event_stream.aio", Set.of( - "AWSDuplexEventStream", "AWSInputEventStream", "AWSOutputEventStream")); + writer.addImports("aws_event_stream.aio", + Set.of( + "AWSDuplexEventStream", + "AWSInputEventStream", + "AWSOutputEventStream")); writer.addImport("smithy_json", "JSONCodec"); writer.addImport("smithy_core.aio.types", "AsyncBytesReader"); writer.addImport("smithy_core.types", "TimestampFormat"); diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/RuntimeClientPlugin.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/RuntimeClientPlugin.java similarity index 93% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/RuntimeClientPlugin.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/RuntimeClientPlugin.java index 7471b0f54..88ac5ec4f 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/RuntimeClientPlugin.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/integrations/RuntimeClientPlugin.java @@ -1,19 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen.integration; +package software.amazon.smithy.python.codegen.integrations; import java.util.ArrayList; import java.util.Collections; @@ -141,9 +130,9 @@ public static Builder builder() { @Override public SmithyBuilder toBuilder() { var builder = builder() - .pythonPlugin(pythonPlugin) - .authScheme(authScheme) - .configProperties(configProperties); + .pythonPlugin(pythonPlugin) + .authScheme(authScheme) + .configProperties(configProperties); if (operationPredicate == OPERATION_ALWAYS_FALSE) { builder.servicePredicate(servicePredicate); @@ -164,8 +153,7 @@ public static final class Builder implements SmithyBuilder private SymbolReference pythonPlugin = null; private AuthScheme authScheme = null; - Builder() { - } + Builder() {} @Override public RuntimeClientPlugin build() { diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ConfigSection.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ConfigSection.java similarity index 84% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ConfigSection.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ConfigSection.java index efcae8d38..13ae6110d 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ConfigSection.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ConfigSection.java @@ -2,17 +2,17 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen.sections; import java.util.List; import software.amazon.smithy.python.codegen.ConfigProperty; import software.amazon.smithy.utils.CodeSection; +import software.amazon.smithy.utils.SmithyInternalApi; /** * Section that contains the entire generated config object. * * @param properties The list of properties that need to be present on the config. */ -public record ConfigSection(List properties) implements CodeSection { -} +@SmithyInternalApi +public record ConfigSection(List properties) implements CodeSection {} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthParametersSection.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthParametersSection.java similarity index 83% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthParametersSection.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthParametersSection.java index 18075c247..ffde1115a 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthParametersSection.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthParametersSection.java @@ -2,12 +2,12 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen.sections; import java.util.Map; import software.amazon.smithy.codegen.core.Symbol; import software.amazon.smithy.utils.CodeSection; +import software.amazon.smithy.utils.SmithyInternalApi; /** * A section that controls generating the HttpAuthParameters class. @@ -15,5 +15,5 @@ * @param properties A map of property names to types for properties that must * be present on the parameters object. */ -public record GenerateHttpAuthParametersSection(Map properties) implements CodeSection { -} +@SmithyInternalApi +public record GenerateHttpAuthParametersSection(Map properties) implements CodeSection {} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthSchemeResolverSection.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthSchemeResolverSection.java similarity index 71% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthSchemeResolverSection.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthSchemeResolverSection.java index 80e7d6497..c9c50ef4c 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthSchemeResolverSection.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/GenerateHttpAuthSchemeResolverSection.java @@ -2,17 +2,17 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen.sections; import java.util.List; -import software.amazon.smithy.python.codegen.integration.AuthScheme; +import software.amazon.smithy.python.codegen.integrations.AuthScheme; import software.amazon.smithy.utils.CodeSection; +import software.amazon.smithy.utils.SmithyInternalApi; /** * A code section that controls generating the entire auth scheme resolver. * * @param authSchemes A list of supported auth schemes discovered on the path. */ -public record GenerateHttpAuthSchemeResolverSection(List authSchemes) implements CodeSection { -} +@SmithyInternalApi +public record GenerateHttpAuthSchemeResolverSection(List authSchemes) implements CodeSection {} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/InitializeHttpAuthParametersSection.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/InitializeHttpAuthParametersSection.java similarity index 80% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/InitializeHttpAuthParametersSection.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/InitializeHttpAuthParametersSection.java index 42eb5b8d5..946a1680a 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/InitializeHttpAuthParametersSection.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/InitializeHttpAuthParametersSection.java @@ -2,13 +2,13 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen.sections; import software.amazon.smithy.utils.CodeSection; +import software.amazon.smithy.utils.SmithyInternalApi; /** * A section that controls writing out the auth scheme parameters. */ -public record InitializeHttpAuthParametersSection() implements CodeSection { -} +@SmithyInternalApi +public record InitializeHttpAuthParametersSection() implements CodeSection {} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/PyprojectSection.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/PyprojectSection.java similarity index 63% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/PyprojectSection.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/PyprojectSection.java index 74586e316..a88493ae6 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/PyprojectSection.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/PyprojectSection.java @@ -1,18 +1,7 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen.sections; import java.util.Map; @@ -32,5 +21,4 @@ * This contains all the dependencies for the generated client. */ @SmithyUnstableApi -public record PyprojectSection(Map> dependencies) implements CodeSection { -} +public record PyprojectSection(Map> dependencies) implements CodeSection {} diff --git a/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ReadmeSection.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ReadmeSection.java new file mode 100644 index 000000000..cbc370941 --- /dev/null +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ReadmeSection.java @@ -0,0 +1,17 @@ +/* + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * SPDX-License-Identifier: Apache-2.0 + */ +package software.amazon.smithy.python.codegen.sections; + +import software.amazon.smithy.utils.CodeSection; +import software.amazon.smithy.utils.SmithyUnstableApi; + +/** + * This section controls the entire generated README.md + * + *

An integration may want to use this if they want to programmatically + * overwrite the generated README. + */ +@SmithyUnstableApi +public record ReadmeSection() implements CodeSection {} diff --git a/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveEndpointSection.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveEndpointSection.java new file mode 100644 index 000000000..ced96ff86 --- /dev/null +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveEndpointSection.java @@ -0,0 +1,17 @@ +/* + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * SPDX-License-Identifier: Apache-2.0 + */ +package software.amazon.smithy.python.codegen.sections; + +import software.amazon.smithy.utils.CodeSection; +import software.amazon.smithy.utils.SmithyUnstableApi; + +/** + * This section resolves the service's endpoint and adds it to the transport + * request, if necessary. + * + *

This is implemented by default only for HTTP protocols. + */ +@SmithyUnstableApi +public record ResolveEndpointSection() implements CodeSection {} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveIdentitySection.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveIdentitySection.java similarity index 68% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveIdentitySection.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveIdentitySection.java index 1c9df5061..bc0df2cda 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveIdentitySection.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveIdentitySection.java @@ -2,13 +2,13 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen.sections; import software.amazon.smithy.utils.CodeSection; +import software.amazon.smithy.utils.SmithyInternalApi; /** * A section responsible for resolving the caller's identity. */ -public record ResolveIdentitySection() implements CodeSection { -} +@SmithyInternalApi +public record ResolveIdentitySection() implements CodeSection {} diff --git a/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/SendRequestSection.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/SendRequestSection.java new file mode 100644 index 000000000..9a0bf269e --- /dev/null +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/SendRequestSection.java @@ -0,0 +1,16 @@ +/* + * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. + * SPDX-License-Identifier: Apache-2.0 + */ +package software.amazon.smithy.python.codegen.sections; + +import software.amazon.smithy.utils.CodeSection; +import software.amazon.smithy.utils.SmithyUnstableApi; + +/** + * This section is responsible for sending the client's request to the service. + * + *

This is implemented by default only for HTTP protocols. + */ +@SmithyUnstableApi +public record SendRequestSection() implements CodeSection {} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/SignRequestSection.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/SignRequestSection.java similarity index 68% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/SignRequestSection.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/SignRequestSection.java index 9fdebbf01..b443596dc 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/SignRequestSection.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/sections/SignRequestSection.java @@ -2,13 +2,13 @@ * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0 */ - package software.amazon.smithy.python.codegen.sections; import software.amazon.smithy.utils.CodeSection; +import software.amazon.smithy.utils.SmithyInternalApi; /** * A section responsible for signing requests before sending them. */ -public record SignRequestSection() implements CodeSection { -} +@SmithyInternalApi +public record SignRequestSection() implements CodeSection {} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ImportDeclarations.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/writer/ImportDeclarations.java similarity index 90% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ImportDeclarations.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/writer/ImportDeclarations.java index daafdba52..799b64912 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/ImportDeclarations.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/writer/ImportDeclarations.java @@ -1,19 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen; +package software.amazon.smithy.python.codegen.writer; import java.util.Iterator; import java.util.Map; @@ -21,6 +10,9 @@ import software.amazon.smithy.codegen.core.CodegenException; import software.amazon.smithy.codegen.core.ImportContainer; import software.amazon.smithy.codegen.core.Symbol; +import software.amazon.smithy.python.codegen.CodegenUtils; +import software.amazon.smithy.python.codegen.PythonSettings; +import software.amazon.smithy.python.codegen.SymbolProperties; import software.amazon.smithy.utils.SmithyInternalApi; import software.amazon.smithy.utils.StringUtils; @@ -28,7 +20,7 @@ * Internal class used for aggregating imports of a file. */ @SmithyInternalApi -final class ImportDeclarations implements ImportContainer { +public final class ImportDeclarations implements ImportContainer { private static final String MODULE_IMPORT_TEMPLATE = "import %s%n"; private final Map> stdlibImports = new TreeMap<>(); @@ -54,7 +46,7 @@ public void importSymbol(Symbol symbol, String alias) { } } - ImportDeclarations addImport(String namespace, String name, String alias) { + public ImportDeclarations addImport(String namespace, String name, String alias) { var isTestModule = this.localNamespace.startsWith("tests"); if (namespace.startsWith(settings.moduleName())) { // if the module is for tests, we shouldn't relativize the imports @@ -127,7 +119,7 @@ public String toString() { } private void formatImportList(StringBuilder builder, Map> importMap) { - for (Map.Entry> namespaceEntry: importMap.entrySet()) { + for (Map.Entry> namespaceEntry : importMap.entrySet()) { if (namespaceEntry.getValue().remove("") != null) { builder.append(formatModuleImport(namespaceEntry.getKey())); } diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonDelegator.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/writer/PythonDelegator.java similarity index 66% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonDelegator.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/writer/PythonDelegator.java index dd9f327d0..0e6f5c7ca 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonDelegator.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/writer/PythonDelegator.java @@ -1,19 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen; +package software.amazon.smithy.python.codegen.writer; import software.amazon.smithy.build.FileManifest; import software.amazon.smithy.codegen.core.Symbol; @@ -21,13 +10,17 @@ import software.amazon.smithy.codegen.core.WriterDelegator; import software.amazon.smithy.model.shapes.MemberShape; import software.amazon.smithy.model.shapes.Shape; +import software.amazon.smithy.python.codegen.PythonSettings; +import software.amazon.smithy.python.codegen.SymbolProperties; +import software.amazon.smithy.utils.SmithyInternalApi; /** * Manages writers for Python files. */ -final class PythonDelegator extends WriterDelegator { +@SmithyInternalApi +public final class PythonDelegator extends WriterDelegator { - PythonDelegator( + public PythonDelegator( FileManifest fileManifest, SymbolProvider symbolProvider, PythonSettings settings @@ -35,8 +28,7 @@ final class PythonDelegator extends WriterDelegator { super( fileManifest, new EnumSymbolProviderWrapper(symbolProvider), - new PythonWriter.PythonWriterFactory(settings) - ); + new PythonWriter.PythonWriterFactory(settings)); } private static final class EnumSymbolProviderWrapper implements SymbolProvider { diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonWriter.java b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/writer/PythonWriter.java similarity index 96% rename from codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonWriter.java rename to codegen/core/src/main/java/software/amazon/smithy/python/codegen/writer/PythonWriter.java index 95d1fbc05..c9e598500 100644 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/PythonWriter.java +++ b/codegen/core/src/main/java/software/amazon/smithy/python/codegen/writer/PythonWriter.java @@ -1,19 +1,8 @@ /* * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. + * SPDX-License-Identifier: Apache-2.0 */ - -package software.amazon.smithy.python.codegen; +package software.amazon.smithy.python.codegen.writer; import java.util.Map; import java.util.Optional; @@ -33,6 +22,9 @@ import software.amazon.smithy.model.node.ObjectNode; import software.amazon.smithy.model.node.StringNode; import software.amazon.smithy.model.shapes.Shape; +import software.amazon.smithy.python.codegen.CodegenUtils; +import software.amazon.smithy.python.codegen.PythonSettings; +import software.amazon.smithy.python.codegen.SymbolProperties; import software.amazon.smithy.utils.SmithyUnstableApi; import software.amazon.smithy.utils.StringUtils; @@ -179,7 +171,6 @@ public PythonWriter writeComment(String comment) { return openComment(() -> write(formatDocs(comment.replace("\n", " ")))); } - /** * Imports a module from the standard library without an alias. * diff --git a/codegen/smithy-python-codegen/src/main/resources/META-INF/services/software.amazon.smithy.build.SmithyBuildPlugin b/codegen/core/src/main/resources/META-INF/services/software.amazon.smithy.build.SmithyBuildPlugin similarity index 100% rename from codegen/smithy-python-codegen/src/main/resources/META-INF/services/software.amazon.smithy.build.SmithyBuildPlugin rename to codegen/core/src/main/resources/META-INF/services/software.amazon.smithy.build.SmithyBuildPlugin diff --git a/codegen/core/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integrations.PythonIntegration b/codegen/core/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integrations.PythonIntegration new file mode 100644 index 000000000..e8dc8f92c --- /dev/null +++ b/codegen/core/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integrations.PythonIntegration @@ -0,0 +1,7 @@ +# +# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 +# + +software.amazon.smithy.python.codegen.integrations.RestJsonIntegration +software.amazon.smithy.python.codegen.integrations.HttpApiKeyAuth diff --git a/codegen/smithy-python-codegen/src/main/resources/software/amazon/smithy/python/codegen/reserved-class-names.txt b/codegen/core/src/main/resources/software/amazon/smithy/python/codegen/reserved-class-names.txt similarity index 100% rename from codegen/smithy-python-codegen/src/main/resources/software/amazon/smithy/python/codegen/reserved-class-names.txt rename to codegen/core/src/main/resources/software/amazon/smithy/python/codegen/reserved-class-names.txt diff --git a/codegen/smithy-python-codegen/src/main/resources/software/amazon/smithy/python/codegen/reserved-member-names.txt b/codegen/core/src/main/resources/software/amazon/smithy/python/codegen/reserved-member-names.txt similarity index 100% rename from codegen/smithy-python-codegen/src/main/resources/software/amazon/smithy/python/codegen/reserved-member-names.txt rename to codegen/core/src/main/resources/software/amazon/smithy/python/codegen/reserved-member-names.txt diff --git a/codegen/gradle/libs.versions.toml b/codegen/gradle/libs.versions.toml new file mode 100644 index 000000000..9a7270687 --- /dev/null +++ b/codegen/gradle/libs.versions.toml @@ -0,0 +1,32 @@ +[versions] +junit5 = "5.11.4" +smithy = "1.54.0" +test-logger-plugin = "4.0.0" +spotbugs = "6.0.22" +spotless = "6.25.0" +smithy-gradle-plugins = "1.2.0" +dep-analysis = "2.8.2" + +[libraries] +smithy-model = { module = "software.amazon.smithy:smithy-model", version.ref = "smithy" } +smithy-codegen = { module = "software.amazon.smithy:smithy-codegen-core", version.ref = "smithy" } +smithy-aws-traits = { module = "software.amazon.smithy:smithy-aws-traits", version.ref = "smithy" } +smithy-aws-protocol-tests = { module = "software.amazon.smithy:smithy-aws-protocol-tests", version.ref = "smithy" } +smithy-protocol-test-traits = { module = "software.amazon.smithy:smithy-protocol-test-traits", version.ref = "smithy"} +smithy-waiters = { module = "software.amazon.smithy:smithy-waiters", version.ref = "smithy" } + +# Test dependencies +junit-bom = { module = "org.junit:junit-bom", version.ref = "junit5" } +junit-jupiter-api = { module = "org.junit.jupiter:junit-jupiter-api", version.ref = "junit5" } +junit-jupiter-engine = { module = "org.junit.jupiter:junit-jupiter-engine", version.ref = "junit5" } +junit-jupiter-params = { module = "org.junit.jupiter:junit-jupiter-params", version.ref = "junit5" } + +# plugin artifacts for buildsrc plugins +test-logger-plugin = { module = "com.adarshr:gradle-test-logger-plugin", version.ref = "test-logger-plugin" } +spotbugs = { module = "com.github.spotbugs.snom:spotbugs-gradle-plugin", version.ref = "spotbugs" } +spotless = { module = "com.diffplug.spotless:spotless-plugin-gradle", version.ref = "spotless" } +dependency-analysis = { module = "com.autonomousapps:dependency-analysis-gradle-plugin", version.ref = "dep-analysis" } + +[plugins] +smithy-gradle-base = { id = "software.amazon.smithy.gradle.smithy-base", version.ref = "smithy-gradle-plugins" } +smithy-gradle-jar = { id = "software.amazon.smithy.gradle.smithy-jar", version.ref = "smithy-gradle-plugins" } diff --git a/codegen/smithy-python-protocol-test/README.md b/codegen/protocol-test/README.md similarity index 100% rename from codegen/smithy-python-protocol-test/README.md rename to codegen/protocol-test/README.md diff --git a/codegen/smithy-python-protocol-test/build.gradle.kts b/codegen/protocol-test/build.gradle.kts similarity index 73% rename from codegen/smithy-python-protocol-test/build.gradle.kts rename to codegen/protocol-test/build.gradle.kts index 6ccf1b490..5c470b9c4 100644 --- a/codegen/smithy-python-protocol-test/build.gradle.kts +++ b/codegen/protocol-test/build.gradle.kts @@ -13,12 +13,14 @@ * permissions and limitations under the License. */ +description = "Smithy framework errors for Smithy Java" extra["displayName"] = "Smithy :: Python :: Protocol :: Test" extra["moduleName"] = "software.amazon.smithy.python.protocol.test" +// TODO: Create a smithy-python protocol convention plugin once we have a better idea of what it looks like plugins { java - id("software.amazon.smithy.gradle.smithy-base") + alias(libs.plugins.smithy.gradle.base) } repositories { @@ -27,6 +29,6 @@ repositories { } dependencies { - implementation(project(":smithy-python-codegen")) - implementation("software.amazon.smithy:smithy-aws-protocol-tests:1.54.0") + implementation(project(":core")) + implementation(libs.smithy.aws.protocol.tests) } diff --git a/codegen/smithy-python-protocol-test/smithy-build.json b/codegen/protocol-test/smithy-build.json similarity index 100% rename from codegen/smithy-python-protocol-test/smithy-build.json rename to codegen/protocol-test/smithy-build.json diff --git a/codegen/settings.gradle.kts b/codegen/settings.gradle.kts index ab75cdc51..6591b98d4 100644 --- a/codegen/settings.gradle.kts +++ b/codegen/settings.gradle.kts @@ -14,18 +14,6 @@ */ rootProject.name = "smithy-python" -include(":smithy-python-codegen") -include(":smithy-aws-python-codegen") -include(":smithy-python-codegen-test") -include(":smithy-python-protocol-test") - -pluginManagement { - repositories { - mavenLocal() - gradlePluginPortal() - } - val smithyGradleVersion: String by settings - plugins { - id("software.amazon.smithy.gradle.smithy-base").version("1.1.0") - } -} +include(":core") +include(":protocol-test") +include(":aws:core") diff --git a/codegen/smithy-aws-python-codegen/build.gradle.kts b/codegen/smithy-aws-python-codegen/build.gradle.kts deleted file mode 100644 index 89fa2c36e..000000000 --- a/codegen/smithy-aws-python-codegen/build.gradle.kts +++ /dev/null @@ -1,13 +0,0 @@ -/* - * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * SPDX-License-Identifier: Apache-2.0 - */ - -description = "Generates AWS Python code from Smithy models" -extra["displayName"] = "Smithy :: AWS :: Python :: Codegen" -extra["moduleName"] = "software.amazon.smithy.aws.python.codegen" - -dependencies { - implementation(project(":smithy-python-codegen")) - implementation("software.amazon.smithy:smithy-aws-traits:1.54.0") -} diff --git a/codegen/smithy-aws-python-codegen/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integration.PythonIntegration b/codegen/smithy-aws-python-codegen/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integration.PythonIntegration deleted file mode 100644 index 9743a30a0..000000000 --- a/codegen/smithy-aws-python-codegen/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integration.PythonIntegration +++ /dev/null @@ -1,7 +0,0 @@ -# -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 -# - -software.amazon.smithy.aws.python.codegen.AwsAuthIntegration -software.amazon.smithy.aws.python.codegen.AwsProtocolsIntegration diff --git a/codegen/smithy-python-codegen-test/README.md b/codegen/smithy-python-codegen-test/README.md deleted file mode 100644 index 7c185be5c..000000000 --- a/codegen/smithy-python-codegen-test/README.md +++ /dev/null @@ -1,22 +0,0 @@ -## Smithy Python Codegen Test - -This package is a handwritten Smithy package that generates a python client. The -shapes in this package are intended to exercise as many parts of the generator as -possible to ensure they generate valid code that passes mypy checks. For -example, there are cases that ensure that we're properly escaping shape names that -would collide with built-in types (e.g. a shape called `Exception` would collide with -the builtin of the same name if it weren't escaped). - -This package does not contain any actual unit tests. Mypy passing and python not -failing to parse the output is the intended test. For actual unit tests, see the -[`smithy-python-protocol-test` package -](https://github.com/awslabs/smithy-python/tree/develop/codegen/smithy-python-protocol-test). - -### When should I change this package? - -Any time an issue is discovered where the code generator generates invalid code -from a valid model. A similar shape should then be added to this package's Smithy -model. That shape then MUST be connected to the service, for example by adding it to -the output of an operation already attached to the service. If the shape isn't -connected in this way, it will be stripped from the model before code generation and -therefore will not be generated. diff --git a/codegen/smithy-python-codegen-test/build.gradle.kts b/codegen/smithy-python-codegen-test/build.gradle.kts deleted file mode 100644 index 59b93bf7a..000000000 --- a/codegen/smithy-python-codegen-test/build.gradle.kts +++ /dev/null @@ -1,33 +0,0 @@ -/* - * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. - */ - -extra["displayName"] = "Smithy :: Python :: Codegen :: Test" -extra["moduleName"] = "software.amazon.smithy.python.codegen.test" - -plugins { - java - id("software.amazon.smithy.gradle.smithy-base") -} - -repositories { - mavenLocal() - mavenCentral() -} - -dependencies { - implementation(project(":smithy-python-codegen")) - implementation("software.amazon.smithy:smithy-waiters:1.54.0") - implementation("software.amazon.smithy:smithy-protocol-test-traits:1.54.0") -} diff --git a/codegen/smithy-python-codegen-test/smithy-build.json b/codegen/smithy-python-codegen-test/smithy-build.json deleted file mode 100644 index 6249eaf5e..000000000 --- a/codegen/smithy-python-codegen-test/smithy-build.json +++ /dev/null @@ -1,10 +0,0 @@ -{ - "version": "1.0", - "plugins": { - "python-client-codegen": { - "service": "example.weather#Weather", - "module": "weather", - "moduleVersion": "0.0.1" - } - } -} diff --git a/codegen/smithy-python-codegen/README.md b/codegen/smithy-python-codegen/README.md deleted file mode 100644 index 67738a2a9..000000000 --- a/codegen/smithy-python-codegen/README.md +++ /dev/null @@ -1,23 +0,0 @@ -## Smithy Python Codegen - -This package implements generic Smithy Python client generation. This includes, but is -not limited to, the following capabilities: - -* Generating Python data types from Smithy shapes. -* Generating fully functional clients for Smithy services. -* Generating serializers and deserializers for generic protocols. -* Providing interfaces for implementing protocols and customizing of all code - generation. - -This package MUST NOT include any components that are only applicable to a particular -organization. For example, [SigV4 -](https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_aws-signing.html) -(an AWS HTTP authorization mechanism) support MUST NOT be implemented in this package -since it isn't generally applicable outside of AWS. - -### When should I change this package? - -Any time one of the above capabilities needs to change. For example, if the plugin -mechanism for the code generator is missing some features then [`PythonIntegration` -](https://github.com/awslabs/smithy-python/blob/develop/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/PythonIntegration.java) -likely needs to be changed. diff --git a/codegen/smithy-python-codegen/build.gradle.kts b/codegen/smithy-python-codegen/build.gradle.kts deleted file mode 100644 index fdefb9436..000000000 --- a/codegen/smithy-python-codegen/build.gradle.kts +++ /dev/null @@ -1,26 +0,0 @@ -/* - * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. - */ - -description = "Generates Python code from Smithy models" -extra["displayName"] = "Smithy :: Python :: Codegen" -extra["moduleName"] = "software.amazon.smithy.python.codegen" - -dependencies { - api("software.amazon.smithy:smithy-codegen-core:1.54.0") - implementation("software.amazon.smithy:smithy-waiters:1.54.0") - implementation("software.amazon.smithy:smithy-protocol-test-traits:1.54.0") - // We have this because we're using RestJson1 as a 'generic' protocol. - implementation("software.amazon.smithy:smithy-aws-traits:1.54.0") -} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/HttpApiKeyAuth.java b/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/HttpApiKeyAuth.java deleted file mode 100644 index 2ccd59e08..000000000 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/HttpApiKeyAuth.java +++ /dev/null @@ -1,138 +0,0 @@ -/* - * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * SPDX-License-Identifier: Apache-2.0 - */ - -package software.amazon.smithy.python.codegen.integration; - -import java.util.List; -import software.amazon.smithy.codegen.core.Symbol; -import software.amazon.smithy.model.shapes.ShapeId; -import software.amazon.smithy.model.traits.HttpApiKeyAuthTrait; -import software.amazon.smithy.python.codegen.ApplicationProtocol; -import software.amazon.smithy.python.codegen.CodegenUtils; -import software.amazon.smithy.python.codegen.ConfigProperty; -import software.amazon.smithy.python.codegen.GenerationContext; -import software.amazon.smithy.python.codegen.SmithyPythonDependency; - -/** - * Adds support for the http api key auth. - * {@see https://smithy.io/2.0/spec/authentication-traits.html#smithy-api-httpapikeyauth-trait} - */ -public final class HttpApiKeyAuth implements PythonIntegration { - private static final String OPTION_GENERATOR_NAME = "_generate_api_key_option"; - - @Override - public List getClientPlugins() { - return List.of( - RuntimeClientPlugin.builder() - .servicePredicate((model, service) -> service.hasTrait(HttpApiKeyAuthTrait.class)) - .addConfigProperty(ConfigProperty.builder() - .name("api_key_identity_resolver") - .documentation("Resolves the API key. Required for operations that use API key auth.") - .type(Symbol.builder() - .name("IdentityResolver[ApiKeyIdentity, IdentityProperties]") - .addReference(Symbol.builder() - .addDependency(SmithyPythonDependency.SMITHY_CORE) - .name("IdentityResolver") - .namespace("smithy_core.aio.interfaces.identity", ".") - .build()) - .addReference(Symbol.builder() - .addDependency(SmithyPythonDependency.SMITHY_HTTP) - .name("ApiKeyIdentity") - .namespace("smithy_http.aio.identity.apikey", ".") - .build()) - .addReference(Symbol.builder() - .addDependency(SmithyPythonDependency.SMITHY_CORE) - .name("IdentityProperties") - .namespace("smithy_core.interfaces.identity", ".") - .build()) - .build()) - .nullable(true) - .build()) - .authScheme(new ApiKeyAuthScheme()) - .build() - ); - } - - @Override - public void customize(GenerationContext context) { - if (!hasApiKeyAuth(context)) { - return; - } - var trait = context.settings().service(context.model()).expectTrait(HttpApiKeyAuthTrait.class); - var params = CodegenUtils.getHttpAuthParamsSymbol(context.settings()); - var resolver = CodegenUtils.getHttpAuthSchemeResolverSymbol(context.settings()); - - // Add a function that generates the http auth option for api key auth. - // This needs to be generated because there's modeled parameters that - // must be accounted for. - context.writerDelegator().useFileWriter(resolver.getDefinitionFile(), resolver.getNamespace(), writer -> { - writer.addDependency(SmithyPythonDependency.SMITHY_CORE); - writer.addDependency(SmithyPythonDependency.SMITHY_HTTP); - writer.addImport("smithy_http.aio.interfaces.auth", "HTTPAuthOption"); - writer.addImport("smithy_http.aio.auth.apikey", "ApiKeyLocation"); - writer.pushState(); - - // Push the scheme into the context to allow for conditionally adding - // it to the properties dict. - writer.putContext("scheme", trait.getScheme().orElse(null)); - writer.write(""" - def $1L(auth_params: $2T) -> HTTPAuthOption | None: - return HTTPAuthOption( - scheme_id=$3S, - identity_properties={}, - signer_properties={ - "name": $4S, - "location": ApiKeyLocation($5S), - ${?scheme} - "scheme": ${scheme:S}, - ${/scheme} - } - ) - """, OPTION_GENERATOR_NAME, params, HttpApiKeyAuthTrait.ID.toString(), - trait.getName(), trait.getIn().toString()); - writer.popState(); - }); - } - - private boolean hasApiKeyAuth(GenerationContext context) { - var service = context.settings().service(context.model()); - return service.hasTrait(HttpApiKeyAuthTrait.class); - } - - /** - * The AuthScheme representing api key auth. - */ - private static final class ApiKeyAuthScheme implements AuthScheme { - - @Override - public ShapeId getAuthTrait() { - return HttpApiKeyAuthTrait.ID; - } - - @Override - public ApplicationProtocol getApplicationProtocol() { - return ApplicationProtocol.createDefaultHttpApplicationProtocol(); - } - - @Override - public Symbol getAuthOptionGenerator(GenerationContext context) { - var resolver = CodegenUtils.getHttpAuthSchemeResolverSymbol(context.settings()); - return Symbol.builder() - .name(OPTION_GENERATOR_NAME) - .namespace(resolver.getNamespace(), ".") - .definitionFile(resolver.getDefinitionFile()) - .build(); - } - - @Override - public Symbol getAuthSchemeSymbol(GenerationContext context) { - return Symbol.builder() - .name("ApiKeyAuthScheme") - .namespace("smithy_http.aio.auth.apikey", ".") - .addDependency(SmithyPythonDependency.SMITHY_HTTP) - .build(); - } - } -} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/RestJsonIntegration.java b/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/RestJsonIntegration.java deleted file mode 100644 index 762156a72..000000000 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/integration/RestJsonIntegration.java +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. - */ - -package software.amazon.smithy.python.codegen.integration; - -import java.util.List; -import software.amazon.smithy.utils.SmithyInternalApi; - -/** - * Integration that registers {@link RestJsonProtocolGenerator}. - */ -@SmithyInternalApi -public final class RestJsonIntegration implements PythonIntegration { - @Override - public List getProtocolGenerators() { - return List.of(new RestJsonProtocolGenerator()); - } -} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ReadmeSection.java b/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ReadmeSection.java deleted file mode 100644 index fba45db5f..000000000 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ReadmeSection.java +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. - */ - -package software.amazon.smithy.python.codegen.sections; - - -import software.amazon.smithy.utils.CodeSection; -import software.amazon.smithy.utils.SmithyUnstableApi; - -/** - * This section controls the entire generated README.md - * - *

An integration may want to use this if they want to programmatically - * overwrite the generated README. - */ -@SmithyUnstableApi -public record ReadmeSection() implements CodeSection { -} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveEndpointSection.java b/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveEndpointSection.java deleted file mode 100644 index 2d55abeb4..000000000 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/ResolveEndpointSection.java +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. - */ - -package software.amazon.smithy.python.codegen.sections; - -import software.amazon.smithy.utils.CodeSection; -import software.amazon.smithy.utils.SmithyUnstableApi; - -/** - * This section resolves the service's endpoint and adds it to the transport - * request, if necessary. - * - *

This is implemented by default only for HTTP protocols. - */ -@SmithyUnstableApi -public record ResolveEndpointSection() implements CodeSection { -} diff --git a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/SendRequestSection.java b/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/SendRequestSection.java deleted file mode 100644 index c9da498dc..000000000 --- a/codegen/smithy-python-codegen/src/main/java/software/amazon/smithy/python/codegen/sections/SendRequestSection.java +++ /dev/null @@ -1,28 +0,0 @@ -/* - * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. - * - * Licensed under the Apache License, Version 2.0 (the "License"). - * You may not use this file except in compliance with the License. - * A copy of the License is located at - * - * http://aws.amazon.com/apache2.0 - * - * or in the "license" file accompanying this file. This file is distributed - * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either - * express or implied. See the License for the specific language governing - * permissions and limitations under the License. - */ - -package software.amazon.smithy.python.codegen.sections; - -import software.amazon.smithy.utils.CodeSection; -import software.amazon.smithy.utils.SmithyUnstableApi; - -/** - * This section is responsible for sending the client's request to the service. - * - *

This is implemented by default only for HTTP protocols. - */ -@SmithyUnstableApi -public record SendRequestSection() implements CodeSection { -} diff --git a/codegen/smithy-python-codegen/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integration.PythonIntegration b/codegen/smithy-python-codegen/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integration.PythonIntegration deleted file mode 100644 index 10665fde4..000000000 --- a/codegen/smithy-python-codegen/src/main/resources/META-INF/services/software.amazon.smithy.python.codegen.integration.PythonIntegration +++ /dev/null @@ -1,7 +0,0 @@ -# -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 -# - -software.amazon.smithy.python.codegen.integration.RestJsonIntegration -software.amazon.smithy.python.codegen.integration.HttpApiKeyAuth diff --git a/get-pants b/get-pants deleted file mode 100755 index cae178edd..000000000 --- a/get-pants +++ /dev/null @@ -1,221 +0,0 @@ -#!/usr/bin/env bash -# Copyright 2023 Pants project contributors (see CONTRIBUTORS.md). -# Licensed under the Apache License, Version 2.0 (see LICENSE). - -set -euo pipefail - -COLOR_RED="\x1b[31m" -COLOR_GREEN="\x1b[32m" -COLOR_YELLOW="\x1b[33m" -COLOR_RESET="\x1b[0m" - -function log() { - echo -e "$@" 1>&2 -} - -function die() { - (($# > 0)) && log "${COLOR_RED}$*${COLOR_RESET}" - exit 1 -} - -function green() { - (($# > 0)) && log "${COLOR_GREEN}$*${COLOR_RESET}" -} - -function warn() { - (($# > 0)) && log "${COLOR_YELLOW}$*${COLOR_RESET}" -} - -function check_cmd() { - local cmd="$1" - command -v "$cmd" > /dev/null || die "This script requires the ${cmd} binary to be on the PATH." -} - -help_url="https://www.pantsbuild.org/docs/getting-help" - -_GC=() - -function gc() { - if (($# > 0)); then - check_cmd rm - _GC+=("$@") - else - rm -rf "${_GC[@]}" - fi -} - -trap gc EXIT - -check_cmd uname - -function calculate_os() { - local os - - os="$(uname -s)" - if [[ "${os}" =~ [Ll]inux ]]; then - echo linux - elif [[ "${os}" =~ [Dd]arwin ]]; then - echo macos - elif [[ "${os}" =~ [Ww]in|[Mm][Ii][Nn][Gg] ]]; then - # Powershell reports something like: Windows_NT - # Git bash reports something like: MINGW64_NT-10.0-22621 - echo windows - else - die "Pants is not supported on this operating system (${os}). Please reach out to us at ${help_url} for help." - fi -} - -OS="$(calculate_os)" - -check_cmd basename -if [[ "${OS}" == "windows" ]]; then - check_cmd pwsh -else - check_cmd curl -fi - -function fetch() { - local url="$1" - local dest_dir="$2" - - local dest - dest="${dest_dir}/$(basename "${url}")" - - if [[ "${OS}" == "windows" ]]; then - pwsh -c "Invoke-WebRequest -OutFile $dest -Uri $url" - else - curl --proto '=https' --tlsv1.2 -sSfL -o "${dest}" "${url}" - fi -} - -if [[ "${OS}" == "macos" ]]; then - check_cmd shasum -else - check_cmd sha256sum -fi - -function sha256() { - if [[ "${OS}" == "macos" ]]; then - shasum --algorithm 256 "$@" - else - sha256sum "$@" - fi -} - -check_cmd mktemp - -function install_from_url() { - local url="$1" - local dest="$2" - - local workdir - workdir="$(mktemp -d)" - gc "${workdir}" - - fetch "${url}.sha256" "${workdir}" - fetch "${url}" "${workdir}" - ( - cd "${workdir}" - sha256 -c --status ./*.sha256 || - die "Download from ${url} did not match the fingerprint at ${url}.sha256" - ) - rm "${workdir}/"*.sha256 - if [[ "${OS}" == "macos" ]]; then - mkdir -p "$(dirname "${dest}")" - install -m 755 "${workdir}/"* "${dest}" - else - install -D -m 755 "${workdir}/"* "${dest}" - fi -} - -function calculate_arch() { - local arch - - arch="$(uname -m)" - if [[ "${arch}" =~ x86[_-]64 ]]; then - echo x86_64 - elif [[ "${arch}" =~ arm64|aarch64 ]]; then - echo aarch64 - else - die "Pants is not supported for this chip architecture (${arch}). Please reach out to us at ${help_url} for help." - fi -} - -check_cmd cat - -function usage() { - cat << EOF -Usage: $0 - -Installs the pants launcher binary. - -You only need to run this once on a machine when you do not have "pants" -available to run yet. - -The pants binary takes care of managing and running the underlying -Pants version configured in "pants.toml" in the surrounding Pants-using -project. - -Once installed, if you want to update your "pants" launcher binary, use -"SCIE_BOOT=update pants" to get the latest release or -"SCIE_BOOT=update pants --help" to learn more options. - --h | --help: Print this help message. - --d | --bin-dir: - The directory to install the scie-pants binary in, "~/.local/bin" by default. - --b | --base-name: - The name to use for the scie-pants binary, "pants" by default. - --V | --version: - The version of the scie-pants binary to install, the latest version by default. - The available versions can be seen at: - https://github.com/pantsbuild/scie-pants/releases - -EOF -} - -bin_dir="${HOME}/.local/bin" -base_name="pants" -version="latest/download" -while (($# > 0)); do - case "$1" in - --help | -h) - usage - exit 0 - ;; - --bin-dir | -d) - bin_dir="$2" - shift - ;; - --base-name | -b) - base_name="$2" - shift - ;; - --version | -V) - version="download/v$2" - shift - ;; - *) - usage - die "Unexpected argument $1\n" - ;; - esac - shift -done - -ARCH="$(calculate_arch)" -URL="https://github.com/pantsbuild/scie-pants/releases/${version}/scie-pants-${OS}-${ARCH}" -dest="${bin_dir}/${base_name}" - -log "Downloading and installing the pants launcher ..." -install_from_url "${URL}" "${dest}" -green "Installed the pants launcher from ${URL} to ${dest}" -if ! command -v "${base_name}" > /dev/null; then - warn "${dest} is not on the PATH." - log "You'll either need to invoke ${dest} explicitly or else add ${bin_dir} to your shell's PATH." -fi - -green "\nRunning \`pants\` in a Pants-enabled repo will use the version of Pants configured for that repo." -green "In a repo not yet Pants-enabled, it will prompt you to set up Pants for that repo." diff --git a/python-packages/aws-event-stream/NOTICE b/packages/aws-event-stream/NOTICE similarity index 100% rename from python-packages/aws-event-stream/NOTICE rename to packages/aws-event-stream/NOTICE diff --git a/python-packages/aws-event-stream/README.md b/packages/aws-event-stream/README.md similarity index 100% rename from python-packages/aws-event-stream/README.md rename to packages/aws-event-stream/README.md diff --git a/packages/aws-event-stream/pyproject.toml b/packages/aws-event-stream/pyproject.toml new file mode 100644 index 000000000..82c4cf1cf --- /dev/null +++ b/packages/aws-event-stream/pyproject.toml @@ -0,0 +1,19 @@ +[project] +name = "aws-event-stream" +version = "0.1.0" +description = "Core Smithy components for AWS services and protocols." +readme = "README.md" +requires-python = ">=3.12" +dependencies = [ + "smithy-core", + "smithy-event-stream", +] + +[build-system] +requires = ["hatchling"] +build-backend = "hatchling.build" + +[tool.hatch.build] +exclude = [ + "tests", +] diff --git a/python-packages/aws-event-stream/aws_event_stream/BUILD b/packages/aws-event-stream/src/aws_event_stream/BUILD similarity index 100% rename from python-packages/aws-event-stream/aws_event_stream/BUILD rename to packages/aws-event-stream/src/aws_event_stream/BUILD diff --git a/python-packages/aws-event-stream/aws_event_stream/__init__.py b/packages/aws-event-stream/src/aws_event_stream/__init__.py similarity index 100% rename from python-packages/aws-event-stream/aws_event_stream/__init__.py rename to packages/aws-event-stream/src/aws_event_stream/__init__.py diff --git a/python-packages/aws-event-stream/aws_event_stream/_private/__init__.py b/packages/aws-event-stream/src/aws_event_stream/_private/__init__.py similarity index 100% rename from python-packages/aws-event-stream/aws_event_stream/_private/__init__.py rename to packages/aws-event-stream/src/aws_event_stream/_private/__init__.py diff --git a/python-packages/aws-event-stream/aws_event_stream/_private/deserializers.py b/packages/aws-event-stream/src/aws_event_stream/_private/deserializers.py similarity index 100% rename from python-packages/aws-event-stream/aws_event_stream/_private/deserializers.py rename to packages/aws-event-stream/src/aws_event_stream/_private/deserializers.py diff --git a/python-packages/aws-event-stream/aws_event_stream/_private/serializers.py b/packages/aws-event-stream/src/aws_event_stream/_private/serializers.py similarity index 99% rename from python-packages/aws-event-stream/aws_event_stream/_private/serializers.py rename to packages/aws-event-stream/src/aws_event_stream/_private/serializers.py index ae8ddac56..a84d0a726 100644 --- a/python-packages/aws-event-stream/aws_event_stream/_private/serializers.py +++ b/packages/aws-event-stream/src/aws_event_stream/_private/serializers.py @@ -159,7 +159,6 @@ def _get_payload_media_type(self, schema: Schema, default: str) -> str: class EventHeaderSerializer(SpecificShapeSerializer): - def __init__(self, encoder: EventHeaderEncoder) -> None: self._encoder = encoder diff --git a/python-packages/aws-event-stream/aws_event_stream/_private/traits.py b/packages/aws-event-stream/src/aws_event_stream/_private/traits.py similarity index 100% rename from python-packages/aws-event-stream/aws_event_stream/_private/traits.py rename to packages/aws-event-stream/src/aws_event_stream/_private/traits.py diff --git a/python-packages/aws-event-stream/aws_event_stream/aio/__init__.py b/packages/aws-event-stream/src/aws_event_stream/aio/__init__.py similarity index 99% rename from python-packages/aws-event-stream/aws_event_stream/aio/__init__.py rename to packages/aws-event-stream/src/aws_event_stream/aio/__init__.py index b019e004e..5057ea688 100644 --- a/python-packages/aws-event-stream/aws_event_stream/aio/__init__.py +++ b/packages/aws-event-stream/src/aws_event_stream/aio/__init__.py @@ -22,7 +22,9 @@ class AWSDuplexEventStream[ - I: SerializeableShape, O: DeserializeableShape, R: DeserializeableShape + I: SerializeableShape, + O: DeserializeableShape, + R: DeserializeableShape, ](DuplexEventStream[I, O, R]): """A duplex event stream using the application/vnd.amazon.eventstream format.""" diff --git a/python-packages/aws-event-stream/aws_event_stream/events.py b/packages/aws-event-stream/src/aws_event_stream/events.py similarity index 100% rename from python-packages/aws-event-stream/aws_event_stream/events.py rename to packages/aws-event-stream/src/aws_event_stream/events.py diff --git a/python-packages/aws-event-stream/aws_event_stream/exceptions.py b/packages/aws-event-stream/src/aws_event_stream/exceptions.py similarity index 100% rename from python-packages/aws-event-stream/aws_event_stream/exceptions.py rename to packages/aws-event-stream/src/aws_event_stream/exceptions.py diff --git a/python-packages/aws-event-stream/aws_event_stream/py.typed b/packages/aws-event-stream/src/aws_event_stream/py.typed similarity index 100% rename from python-packages/aws-event-stream/aws_event_stream/py.typed rename to packages/aws-event-stream/src/aws_event_stream/py.typed diff --git a/python-packages/aws-event-stream/tests/py.typed b/packages/aws-event-stream/tests/py.typed similarity index 100% rename from python-packages/aws-event-stream/tests/py.typed rename to packages/aws-event-stream/tests/py.typed diff --git a/python-packages/aws-event-stream/tests/unit/_private/__init__.py b/packages/aws-event-stream/tests/unit/_private/__init__.py similarity index 98% rename from python-packages/aws-event-stream/tests/unit/_private/__init__.py rename to packages/aws-event-stream/tests/unit/_private/__init__.py index 150f2344b..6eb258f2a 100644 --- a/python-packages/aws-event-stream/tests/unit/_private/__init__.py +++ b/packages/aws-event-stream/tests/unit/_private/__init__.py @@ -335,9 +335,7 @@ def serialize(self, serializer: ShapeSerializer): serializer.write_struct(SCHEMA_EVENT_STREAM, self) def serialize_members(self, serializer: ShapeSerializer): - serializer.write_struct( - SCHEMA_EVENT_STREAM.members["blobPayload"], self.value - ) + serializer.write_struct(SCHEMA_EVENT_STREAM.members["blobPayload"], self.value) @dataclass @@ -393,7 +391,13 @@ def serialize_members(self, serializer: ShapeSerializer): raise SmithyException("Unknown union variants may not be serialized.") -type EventStream = EventStreamMessageEvent | EventStreamPayloadEvent | EventStreamBlobPayloadEvent | EventStreamErrorEvent | EventStreamUnknownEvent +type EventStream = ( + EventStreamMessageEvent + | EventStreamPayloadEvent + | EventStreamBlobPayloadEvent + | EventStreamErrorEvent + | EventStreamUnknownEvent +) class EventStreamDeserializer: diff --git a/python-packages/aws-event-stream/tests/unit/_private/test_deserializers.py b/packages/aws-event-stream/tests/unit/_private/test_deserializers.py similarity index 100% rename from python-packages/aws-event-stream/tests/unit/_private/test_deserializers.py rename to packages/aws-event-stream/tests/unit/_private/test_deserializers.py diff --git a/python-packages/aws-event-stream/tests/unit/_private/test_serializers.py b/packages/aws-event-stream/tests/unit/_private/test_serializers.py similarity index 100% rename from python-packages/aws-event-stream/tests/unit/_private/test_serializers.py rename to packages/aws-event-stream/tests/unit/_private/test_serializers.py diff --git a/python-packages/aws-event-stream/tests/unit/test_events.py b/packages/aws-event-stream/tests/unit/test_events.py similarity index 98% rename from python-packages/aws-event-stream/tests/unit/test_events.py rename to packages/aws-event-stream/tests/unit/test_events.py index 97f97a276..5223676a7 100644 --- a/python-packages/aws-event-stream/tests/unit/test_events.py +++ b/packages/aws-event-stream/tests/unit/test_events.py @@ -37,7 +37,7 @@ b"\x00\x00\x00\x10" # total length b"\x00\x00\x00\x00" # headers length b"\x05\xc2\x48\xeb" # prelude crc - b"\x7D\x98\xc8\xff" # message crc + b"\x7d\x98\xc8\xff" # message crc ), Event( prelude=EventPrelude( @@ -407,7 +407,7 @@ CORRUPTED_HEADERS_LENGTH = ( ( b"\x00\x00\x00\x3d" # total length - b"\xFF\x00\x01\x02" # headers length + b"\xff\x00\x01\x02" # headers length b"\x07\xfd\x83\x96" # prelude crc b"\x0ccontent-type\x07\x00\x10application/json" # headers b"{'foo':'bar'}" # payload @@ -443,7 +443,7 @@ ( b"\x00\x00\x00\x1d" # total length b"\x00\x00\x00\x00" # headers length - b"\xfd\x52\x8c\x5A" # prelude crc + b"\xfd\x52\x8c\x5a" # prelude crc b"{'foo':'bar'\x8d" # payload b"\xc3\x65\x39\x36" # message crc ), @@ -464,11 +464,11 @@ INVALID_HEADERS_LENGTH = ( ( b"\x00\x00\x00\x3d" # total length - b"\xFF\x00\x01\x02" # headers length + b"\xff\x00\x01\x02" # headers length b"\x15\x83\xf5\xc2" # prelude crc b"\x0ccontent-type\x07\x00\x10application/json" # headers b"{'foo':'bar'}" # payload - b"\x2F\x37\x7f\x5d" # message crc + b"\x2f\x37\x7f\x5d" # message crc ), InvalidHeadersLength, ) diff --git a/python-packages/smithy-aws-core/NOTICE b/packages/smithy-aws-core/NOTICE similarity index 100% rename from python-packages/smithy-aws-core/NOTICE rename to packages/smithy-aws-core/NOTICE diff --git a/python-packages/smithy-aws-core/README.md b/packages/smithy-aws-core/README.md similarity index 100% rename from python-packages/smithy-aws-core/README.md rename to packages/smithy-aws-core/README.md diff --git a/packages/smithy-aws-core/pyproject.toml b/packages/smithy-aws-core/pyproject.toml new file mode 100644 index 000000000..1d628f474 --- /dev/null +++ b/packages/smithy-aws-core/pyproject.toml @@ -0,0 +1,18 @@ +[project] +name = "smithy-aws-core" +version = "0.1.0" +description = "Core Smithy components for AWS services and protocols." +readme = "README.md" +requires-python = ">=3.12" +dependencies = [ + "smithy-core", +] + +[build-system] +requires = ["hatchling"] +build-backend = "hatchling.build" + +[tool.hatch.build] +exclude = [ + "tests", +] diff --git a/python-packages/smithy-aws-core/smithy_aws_core/__init__.py b/packages/smithy-aws-core/src/smithy_aws_core/__init__.py similarity index 95% rename from python-packages/smithy-aws-core/smithy_aws_core/__init__.py rename to packages/smithy-aws-core/src/smithy_aws_core/__init__.py index 9a8a05063..654905217 100644 --- a/python-packages/smithy-aws-core/smithy_aws_core/__init__.py +++ b/packages/smithy-aws-core/src/smithy_aws_core/__init__.py @@ -10,6 +10,3 @@ # distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF # ANY KIND, either express or implied. See the License for the specific # language governing permissions and limitations under the License. - - -__version__ = "0.0.1" diff --git a/python-packages/smithy-aws-core/smithy_aws_core/identity.py b/packages/smithy-aws-core/src/smithy_aws_core/identity.py similarity index 100% rename from python-packages/smithy-aws-core/smithy_aws_core/identity.py rename to packages/smithy-aws-core/src/smithy_aws_core/identity.py diff --git a/python-packages/smithy-aws-core/smithy_aws_core/interfaces/__init__.py b/packages/smithy-aws-core/src/smithy_aws_core/interfaces/__init__.py similarity index 100% rename from python-packages/smithy-aws-core/smithy_aws_core/interfaces/__init__.py rename to packages/smithy-aws-core/src/smithy_aws_core/interfaces/__init__.py diff --git a/python-packages/smithy-aws-core/smithy_aws_core/py.typed b/packages/smithy-aws-core/src/smithy_aws_core/py.typed similarity index 100% rename from python-packages/smithy-aws-core/smithy_aws_core/py.typed rename to packages/smithy-aws-core/src/smithy_aws_core/py.typed diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/LICENSE b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/LICENSE similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/LICENSE rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/LICENSE diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/NOTICE b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/NOTICE similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/NOTICE rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/NOTICE diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-key-duplicate/get-header-key-duplicate.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-multiline/get-header-value-multiline.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-order/get-header-value-order.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-header-value-trim/get-header-value-trim.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-unreserved/get-unreserved.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-utf8/get-utf8.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-empty-query-key/get-vanilla-empty-query-key.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-encoded/get-vanilla-query-order-encoded.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key-case/get-vanilla-query-order-key-case.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-key/get-vanilla-query-order-key.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-order-value/get-vanilla-query-order-value.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query-unreserved/get-vanilla-query-unreserved.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-query/get-vanilla-query.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-utf8-query/get-vanilla-utf8-query.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla-with-session-token/get-vanilla-with-session-token.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/get-vanilla/get-vanilla.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative-relative/get-relative-relative.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-relative/get-relative.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-dot-slash/get-slash-dot-slash.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash-pointless-dot/get-slash-pointless-dot.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slash/get-slash.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-slashes/get-slashes.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-space/get-space.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/get-special-character/get-special-character.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/normalize-path.txt b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/normalize-path.txt similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/normalize-path.txt rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/normalize-path/normalize-path.txt diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-case/post-header-key-case.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-key-sort/post-header-key-sort.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-header-value-case/post-header-value-case.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-after/post-sts-header-after.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/post-sts-header-before/post-sts-header-before.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/readme.txt b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/readme.txt similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/readme.txt rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-sts-token/readme.txt diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-empty-query-value/post-vanilla-empty-query-value.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla-query/post-vanilla-query.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-vanilla/post-vanilla.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded-parameters/post-x-www-form-urlencoded-parameters.sts diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.authz b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.authz similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.authz rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.authz diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.creq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.creq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.creq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.creq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.req b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.req similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.req rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.req diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.sreq b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.sreq similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.sreq rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.sreq diff --git a/python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.sts b/packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.sts similarity index 100% rename from python-packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.sts rename to packages/smithy-aws-core/tests/unit/auth/aws4_testsuite/post-x-www-form-urlencoded/post-x-www-form-urlencoded.sts diff --git a/python-packages/smithy-core/NOTICE b/packages/smithy-core/NOTICE similarity index 100% rename from python-packages/smithy-core/NOTICE rename to packages/smithy-core/NOTICE diff --git a/python-packages/smithy-core/README.md b/packages/smithy-core/README.md similarity index 100% rename from python-packages/smithy-core/README.md rename to packages/smithy-core/README.md diff --git a/packages/smithy-core/pyproject.toml b/packages/smithy-core/pyproject.toml new file mode 100644 index 000000000..91d867d73 --- /dev/null +++ b/packages/smithy-core/pyproject.toml @@ -0,0 +1,21 @@ +[project] +name = "smithy_core" +version = "0.1.0" +description = "Core components for implementing Smithy tooling in Python." +readme = "README.md" +requires-python = ">=3.12" +dependencies = [] + +[dependency-groups] +dev = [ + "freezegun>=1.5.1", +] + +[build-system] +requires = ["hatchling"] +build-backend = "hatchling.build" + +[tool.hatch.build] +exclude = [ + "tests", +] diff --git a/python-packages/smithy-core/smithy_core/__init__.py b/packages/smithy-core/src/smithy_core/__init__.py similarity index 100% rename from python-packages/smithy-core/smithy_core/__init__.py rename to packages/smithy-core/src/smithy_core/__init__.py diff --git a/python-packages/aws-event-stream/tests/__init__.py b/packages/smithy-core/src/smithy_core/aio/__init__.py similarity index 100% rename from python-packages/aws-event-stream/tests/__init__.py rename to packages/smithy-core/src/smithy_core/aio/__init__.py diff --git a/python-packages/smithy-core/smithy_core/aio/interfaces/__init__.py b/packages/smithy-core/src/smithy_core/aio/interfaces/__init__.py similarity index 100% rename from python-packages/smithy-core/smithy_core/aio/interfaces/__init__.py rename to packages/smithy-core/src/smithy_core/aio/interfaces/__init__.py diff --git a/python-packages/smithy-core/smithy_core/aio/interfaces/identity.py b/packages/smithy-core/src/smithy_core/aio/interfaces/identity.py similarity index 100% rename from python-packages/smithy-core/smithy_core/aio/interfaces/identity.py rename to packages/smithy-core/src/smithy_core/aio/interfaces/identity.py diff --git a/python-packages/smithy-core/smithy_core/aio/types.py b/packages/smithy-core/src/smithy_core/aio/types.py similarity index 98% rename from python-packages/smithy-core/smithy_core/aio/types.py rename to packages/smithy-core/src/smithy_core/aio/types.py index a6625f07a..51a63bbc4 100644 --- a/python-packages/smithy-core/smithy_core/aio/types.py +++ b/packages/smithy-core/src/smithy_core/aio/types.py @@ -46,14 +46,14 @@ async def read(self, size: int = -1) -> bytes: if self._closed or not self._data: raise ValueError("I/O operation on closed file.") - if isinstance(self._data, BytesReader) and not iscoroutinefunction( + if isinstance(self._data, BytesReader) and not iscoroutinefunction( # type: ignore - TODO(pyright) self._data.read ): # Python's runtime_checkable can't actually tell the difference between # sync and async, so we have to check ourselves. return self._data.read(size) - if isinstance(self._data, AsyncByteStream): + if isinstance(self._data, AsyncByteStream): # type: ignore - TODO(pyright) return await self._data.read(size) return await self._read_from_iterable( @@ -135,7 +135,7 @@ def __init__(self, data: StreamingBlob): if isinstance(data, bytes | bytearray): self._buffer = BytesIO(data) self._data_source = None - elif isinstance(data, AsyncByteStream) and iscoroutinefunction(data.read): + elif isinstance(data, AsyncByteStream) and iscoroutinefunction(data.read): # type: ignore - TODO(pyright) # Note that we need that iscoroutine check because python won't actually check # whether or not the read function is async. self._buffer = BytesIO() @@ -321,7 +321,6 @@ async def write(self, data: bytes) -> None: # Acquire a lock on the data buffer, releasing it automatically when the # block exits. async with self._data_condition: - # Wait for the number of chunks in the buffer to be less than the # specified maximum. This also releases the lock until that condition # is met. @@ -407,7 +406,6 @@ async def __anext__(self) -> bytes: # Acquire a lock on the data buffer, releasing it automatically when the # block exits. async with self._data_condition: - # Wait for the stream to be closed or for the data buffer to be non-empty. # This also releases the lock until that condition is met. await self._data_condition.wait_for( diff --git a/python-packages/smithy-core/smithy_core/aio/utils.py b/packages/smithy-core/src/smithy_core/aio/utils.py similarity index 100% rename from python-packages/smithy-core/smithy_core/aio/utils.py rename to packages/smithy-core/src/smithy_core/aio/utils.py diff --git a/python-packages/smithy-core/smithy_core/codecs.py b/packages/smithy-core/src/smithy_core/codecs.py similarity index 94% rename from python-packages/smithy-core/smithy_core/codecs.py rename to packages/smithy-core/src/smithy_core/codecs.py index f3fd4d0eb..bb79fd535 100644 --- a/python-packages/smithy-core/smithy_core/codecs.py +++ b/packages/smithy-core/src/smithy_core/codecs.py @@ -50,9 +50,9 @@ def serialize(self, shape: "SerializeableShape") -> bytes: stream.seek(0) return stream.read() - def deserialize[ - S: DeserializeableShape - ](self, source: bytes | BytesReader, shape: type[S]) -> S: + def deserialize[S: DeserializeableShape]( + self, source: bytes | BytesReader, shape: type[S] + ) -> S: """Deserialize bytes into a shape. :param source: The bytes to deserialize. diff --git a/python-packages/smithy-core/smithy_core/deserializers.py b/packages/smithy-core/src/smithy_core/deserializers.py similarity index 100% rename from python-packages/smithy-core/smithy_core/deserializers.py rename to packages/smithy-core/src/smithy_core/deserializers.py diff --git a/python-packages/smithy-core/smithy_core/documents.py b/packages/smithy-core/src/smithy_core/documents.py similarity index 100% rename from python-packages/smithy-core/smithy_core/documents.py rename to packages/smithy-core/src/smithy_core/documents.py diff --git a/python-packages/smithy-core/smithy_core/exceptions.py b/packages/smithy-core/src/smithy_core/exceptions.py similarity index 100% rename from python-packages/smithy-core/smithy_core/exceptions.py rename to packages/smithy-core/src/smithy_core/exceptions.py diff --git a/python-packages/smithy-core/smithy_core/identity.py b/packages/smithy-core/src/smithy_core/identity.py similarity index 100% rename from python-packages/smithy-core/smithy_core/identity.py rename to packages/smithy-core/src/smithy_core/identity.py diff --git a/python-packages/smithy-core/smithy_core/interceptors.py b/packages/smithy-core/src/smithy_core/interceptors.py similarity index 100% rename from python-packages/smithy-core/smithy_core/interceptors.py rename to packages/smithy-core/src/smithy_core/interceptors.py diff --git a/python-packages/smithy-core/smithy_core/interfaces/__init__.py b/packages/smithy-core/src/smithy_core/interfaces/__init__.py similarity index 100% rename from python-packages/smithy-core/smithy_core/interfaces/__init__.py rename to packages/smithy-core/src/smithy_core/interfaces/__init__.py diff --git a/python-packages/smithy-core/smithy_core/interfaces/exceptions.py b/packages/smithy-core/src/smithy_core/interfaces/exceptions.py similarity index 100% rename from python-packages/smithy-core/smithy_core/interfaces/exceptions.py rename to packages/smithy-core/src/smithy_core/interfaces/exceptions.py diff --git a/python-packages/smithy-core/smithy_core/interfaces/identity.py b/packages/smithy-core/src/smithy_core/interfaces/identity.py similarity index 100% rename from python-packages/smithy-core/smithy_core/interfaces/identity.py rename to packages/smithy-core/src/smithy_core/interfaces/identity.py diff --git a/python-packages/smithy-core/smithy_core/interfaces/retries.py b/packages/smithy-core/src/smithy_core/interfaces/retries.py similarity index 100% rename from python-packages/smithy-core/smithy_core/interfaces/retries.py rename to packages/smithy-core/src/smithy_core/interfaces/retries.py diff --git a/python-packages/smithy-core/smithy_core/prelude.py b/packages/smithy-core/src/smithy_core/prelude.py similarity index 100% rename from python-packages/smithy-core/smithy_core/prelude.py rename to packages/smithy-core/src/smithy_core/prelude.py diff --git a/python-packages/smithy-core/smithy_core/py.typed b/packages/smithy-core/src/smithy_core/py.typed similarity index 100% rename from python-packages/smithy-core/smithy_core/py.typed rename to packages/smithy-core/src/smithy_core/py.typed diff --git a/python-packages/smithy-core/smithy_core/retries.py b/packages/smithy-core/src/smithy_core/retries.py similarity index 100% rename from python-packages/smithy-core/smithy_core/retries.py rename to packages/smithy-core/src/smithy_core/retries.py diff --git a/python-packages/smithy-core/smithy_core/rfc3986.py b/packages/smithy-core/src/smithy_core/rfc3986.py similarity index 99% rename from python-packages/smithy-core/smithy_core/rfc3986.py rename to packages/smithy-core/src/smithy_core/rfc3986.py index c33f4b51c..2cee4792d 100644 --- a/python-packages/smithy-core/smithy_core/rfc3986.py +++ b/packages/smithy-core/src/smithy_core/rfc3986.py @@ -16,6 +16,7 @@ https://github.com/python-hyper/rfc3986/blob/main/src/rfc3986/abnf_regexp.py https://github.com/python-hyper/rfc3986/blob/main/src/rfc3986/misc.py """ + import re # ######################### diff --git a/python-packages/smithy-core/smithy_core/schemas.py b/packages/smithy-core/src/smithy_core/schemas.py similarity index 99% rename from python-packages/smithy-core/smithy_core/schemas.py rename to packages/smithy-core/src/smithy_core/schemas.py index 2b4909d50..0e725d129 100644 --- a/python-packages/smithy-core/smithy_core/schemas.py +++ b/packages/smithy-core/src/smithy_core/schemas.py @@ -162,10 +162,10 @@ def collection( def member( cls, id: ShapeID, - target: Self, + target: "Schema", index: int, member_traits: list["Trait"] | None = None, - ) -> Self: + ) -> "Schema": """Create a schema for a member shape. Member schemas are largely copies of the schemas they target to make it easier diff --git a/python-packages/smithy-core/smithy_core/serializers.py b/packages/smithy-core/src/smithy_core/serializers.py similarity index 100% rename from python-packages/smithy-core/smithy_core/serializers.py rename to packages/smithy-core/src/smithy_core/serializers.py diff --git a/python-packages/smithy-core/smithy_core/shapes.py b/packages/smithy-core/src/smithy_core/shapes.py similarity index 100% rename from python-packages/smithy-core/smithy_core/shapes.py rename to packages/smithy-core/src/smithy_core/shapes.py diff --git a/python-packages/smithy-core/smithy_core/traits.py b/packages/smithy-core/src/smithy_core/traits.py similarity index 100% rename from python-packages/smithy-core/smithy_core/traits.py rename to packages/smithy-core/src/smithy_core/traits.py diff --git a/python-packages/smithy-core/smithy_core/types.py b/packages/smithy-core/src/smithy_core/types.py similarity index 100% rename from python-packages/smithy-core/smithy_core/types.py rename to packages/smithy-core/src/smithy_core/types.py diff --git a/python-packages/smithy-core/smithy_core/utils.py b/packages/smithy-core/src/smithy_core/utils.py similarity index 100% rename from python-packages/smithy-core/smithy_core/utils.py rename to packages/smithy-core/src/smithy_core/utils.py diff --git a/python-packages/aws-event-stream/tests/unit/__init__.py b/packages/smithy-core/tests/__init__.py similarity index 100% rename from python-packages/aws-event-stream/tests/unit/__init__.py rename to packages/smithy-core/tests/__init__.py diff --git a/python-packages/smithy-core/tests/py.typed b/packages/smithy-core/tests/py.typed similarity index 100% rename from python-packages/smithy-core/tests/py.typed rename to packages/smithy-core/tests/py.typed diff --git a/python-packages/smithy-core/smithy_core/aio/__init__.py b/packages/smithy-core/tests/unit/__init__.py similarity index 100% rename from python-packages/smithy-core/smithy_core/aio/__init__.py rename to packages/smithy-core/tests/unit/__init__.py diff --git a/python-packages/smithy-core/tests/__init__.py b/packages/smithy-core/tests/unit/aio/__init__.py similarity index 100% rename from python-packages/smithy-core/tests/__init__.py rename to packages/smithy-core/tests/unit/aio/__init__.py diff --git a/python-packages/smithy-core/tests/unit/aio/test_types.py b/packages/smithy-core/tests/unit/aio/test_types.py similarity index 99% rename from python-packages/smithy-core/tests/unit/aio/test_types.py rename to packages/smithy-core/tests/unit/aio/test_types.py index 85b987660..b62f3a4b3 100644 --- a/python-packages/smithy-core/tests/unit/aio/test_types.py +++ b/packages/smithy-core/tests/unit/aio/test_types.py @@ -485,7 +485,6 @@ async def test_aexit_flushes() -> None: # Use the provider in a context manager. When this exits, it should flush # and close the provider. async with provider: - # Write some data to the provider. await provider.write(b"foo") diff --git a/python-packages/smithy-core/tests/unit/test_documents.py b/packages/smithy-core/tests/unit/test_documents.py similarity index 99% rename from python-packages/smithy-core/tests/unit/test_documents.py rename to packages/smithy-core/tests/unit/test_documents.py index 5733f17d1..3afea0fe9 100644 --- a/python-packages/smithy-core/tests/unit/test_documents.py +++ b/packages/smithy-core/tests/unit/test_documents.py @@ -855,7 +855,9 @@ def test_document_serializer(given: Any, expected: Document): if v is None: map_serializer.entry(k, lambda vs: vs.write_null(member_schema)) else: - map_serializer.entry(k, lambda vs: vs.write_string(member_schema, v)) # type: ignore + map_serializer.entry( + k, lambda vs: vs.write_string(member_schema, v) + ) # type: ignore case DocumentSerdeShape(): given.serialize(serializer) case _: diff --git a/python-packages/smithy-core/tests/unit/test_identity.py b/packages/smithy-core/tests/unit/test_identity.py similarity index 100% rename from python-packages/smithy-core/tests/unit/test_identity.py rename to packages/smithy-core/tests/unit/test_identity.py diff --git a/python-packages/smithy-core/tests/unit/test_retries.py b/packages/smithy-core/tests/unit/test_retries.py similarity index 100% rename from python-packages/smithy-core/tests/unit/test_retries.py rename to packages/smithy-core/tests/unit/test_retries.py diff --git a/python-packages/smithy-core/tests/unit/test_schemas.py b/packages/smithy-core/tests/unit/test_schemas.py similarity index 100% rename from python-packages/smithy-core/tests/unit/test_schemas.py rename to packages/smithy-core/tests/unit/test_schemas.py diff --git a/python-packages/smithy-core/tests/unit/test_shapes.py b/packages/smithy-core/tests/unit/test_shapes.py similarity index 100% rename from python-packages/smithy-core/tests/unit/test_shapes.py rename to packages/smithy-core/tests/unit/test_shapes.py diff --git a/python-packages/smithy-core/tests/unit/test_types.py b/packages/smithy-core/tests/unit/test_types.py similarity index 100% rename from python-packages/smithy-core/tests/unit/test_types.py rename to packages/smithy-core/tests/unit/test_types.py diff --git a/python-packages/smithy-core/tests/unit/test_uri.py b/packages/smithy-core/tests/unit/test_uri.py similarity index 100% rename from python-packages/smithy-core/tests/unit/test_uri.py rename to packages/smithy-core/tests/unit/test_uri.py diff --git a/python-packages/smithy-core/tests/unit/test_utils.py b/packages/smithy-core/tests/unit/test_utils.py similarity index 100% rename from python-packages/smithy-core/tests/unit/test_utils.py rename to packages/smithy-core/tests/unit/test_utils.py diff --git a/python-packages/smithy-event-stream/NOTICE b/packages/smithy-event-stream/NOTICE similarity index 100% rename from python-packages/smithy-event-stream/NOTICE rename to packages/smithy-event-stream/NOTICE diff --git a/python-packages/smithy-event-stream/README.md b/packages/smithy-event-stream/README.md similarity index 100% rename from python-packages/smithy-event-stream/README.md rename to packages/smithy-event-stream/README.md diff --git a/packages/smithy-event-stream/pyproject.toml b/packages/smithy-event-stream/pyproject.toml new file mode 100644 index 000000000..b4a0c5f6d --- /dev/null +++ b/packages/smithy-event-stream/pyproject.toml @@ -0,0 +1,18 @@ +[project] +name = "smithy-event-stream" +version = "0.1.0" +description = "Smithy event stream interfaces and core components." +readme = "README.md" +requires-python = ">=3.12" +dependencies = [ + "smithy-core", +] + +[build-system] +requires = ["hatchling"] +build-backend = "hatchling.build" + +[tool.hatch.build] +exclude = [ + "tests", +] diff --git a/python-packages/smithy-event-stream/smithy_event_stream/BUILD b/packages/smithy-event-stream/src/smithy_event_stream/BUILD similarity index 100% rename from python-packages/smithy-event-stream/smithy_event_stream/BUILD rename to packages/smithy-event-stream/src/smithy_event_stream/BUILD diff --git a/python-packages/smithy-core/tests/unit/__init__.py b/packages/smithy-event-stream/src/smithy_event_stream/__init__.py similarity index 100% rename from python-packages/smithy-core/tests/unit/__init__.py rename to packages/smithy-event-stream/src/smithy_event_stream/__init__.py diff --git a/python-packages/smithy-event-stream/smithy_event_stream/__init__.py b/packages/smithy-event-stream/src/smithy_event_stream/aio/__init__.py similarity index 100% rename from python-packages/smithy-event-stream/smithy_event_stream/__init__.py rename to packages/smithy-event-stream/src/smithy_event_stream/aio/__init__.py diff --git a/python-packages/smithy-event-stream/smithy_event_stream/aio/interfaces.py b/packages/smithy-event-stream/src/smithy_event_stream/aio/interfaces.py similarity index 95% rename from python-packages/smithy-event-stream/smithy_event_stream/aio/interfaces.py rename to packages/smithy-event-stream/src/smithy_event_stream/aio/interfaces.py index a38468d0b..2c5c4a547 100644 --- a/python-packages/smithy-event-stream/smithy_event_stream/aio/interfaces.py +++ b/packages/smithy-event-stream/src/smithy_event_stream/aio/interfaces.py @@ -82,7 +82,9 @@ async def main(): input = StreamMessagesInput(chat_room="aws-python-sdk", username="hunter7") async with client.stream_messages(input=input) as stream: - stream.input_stream.send(MessageStreamMessage("Chat logger starting up.")) + stream.input_stream.send( + MessageStreamMessage("Chat logger starting up.") + ) response_task = asyncio.create_task(handle_output(stream)) stream.input_stream.send(MessageStreamMessage("Chat logger active.")) await response_handler @@ -97,7 +99,9 @@ async def handle_output(stream: EventStream) -> None: return case _: stream.input_stream.send( - MessageStreamMessage("Unknown message type received. Shutting down.") + MessageStreamMessage( + "Unknown message type received. Shutting down." + ) ) return """ @@ -193,7 +197,9 @@ async def main(): input = PublishMessagesInput(chat_room="aws-python-sdk", username="hunter7") async with client.publish_messages(input=input) as stream: - stream.input_stream.send(MessageStreamMessage("High severity ticket alert!")) + stream.input_stream.send( + MessageStreamMessage("High severity ticket alert!") + ) await stream.await_output() """ diff --git a/python-packages/smithy-event-stream/smithy_event_stream/py.typed b/packages/smithy-event-stream/src/smithy_event_stream/py.typed similarity index 100% rename from python-packages/smithy-event-stream/smithy_event_stream/py.typed rename to packages/smithy-event-stream/src/smithy_event_stream/py.typed diff --git a/python-packages/smithy-event-stream/tests/py.typed b/packages/smithy-event-stream/tests/py.typed similarity index 100% rename from python-packages/smithy-event-stream/tests/py.typed rename to packages/smithy-event-stream/tests/py.typed diff --git a/python-packages/smithy-http/NOTICE b/packages/smithy-http/NOTICE similarity index 100% rename from python-packages/smithy-http/NOTICE rename to packages/smithy-http/NOTICE diff --git a/python-packages/smithy-http/README.md b/packages/smithy-http/README.md similarity index 100% rename from python-packages/smithy-http/README.md rename to packages/smithy-http/README.md diff --git a/packages/smithy-http/pyproject.toml b/packages/smithy-http/pyproject.toml new file mode 100644 index 000000000..26400ab3e --- /dev/null +++ b/packages/smithy-http/pyproject.toml @@ -0,0 +1,26 @@ +[project] +name = "smithy_http" +version = "0.1.0" +description = "HTTP components for Smithy tooling." +readme = "README.md" +requires-python = ">=3.12" +dependencies = [ + "smithy-core", +] + +[project.optional-dependencies] +awscrt = [ + "awscrt>=0.23.10", +] +aiohttp = [ + "aiohttp>=3.11.12", +] + +[build-system] +requires = ["hatchling"] +build-backend = "hatchling.build" + +[tool.hatch.build] +exclude = [ + "tests", +] diff --git a/python-packages/smithy-http/smithy_http/__init__.py b/packages/smithy-http/src/smithy_http/__init__.py similarity index 98% rename from python-packages/smithy-http/smithy_http/__init__.py rename to packages/smithy-http/src/smithy_http/__init__.py index eb222d05c..90869db71 100644 --- a/python-packages/smithy-http/smithy_http/__init__.py +++ b/packages/smithy-http/src/smithy_http/__init__.py @@ -113,7 +113,7 @@ def __init__( f"{', '.join(non_unique_names)}." ) init_tuples = zip(init_field_names, init_fields) - self.entries: OrderedDict[str, interfaces.Field] = OrderedDict(init_tuples) + self.entries: dict[str, interfaces.Field] = OrderedDict(init_tuples) self.encoding: str = encoding def set_field(self, field: interfaces.Field) -> None: diff --git a/python-packages/smithy-http/smithy_http/aio/__init__.py b/packages/smithy-http/src/smithy_http/aio/__init__.py similarity index 100% rename from python-packages/smithy-http/smithy_http/aio/__init__.py rename to packages/smithy-http/src/smithy_http/aio/__init__.py diff --git a/python-packages/smithy-http/smithy_http/aio/aiohttp.py b/packages/smithy-http/src/smithy_http/aio/aiohttp.py similarity index 100% rename from python-packages/smithy-http/smithy_http/aio/aiohttp.py rename to packages/smithy-http/src/smithy_http/aio/aiohttp.py diff --git a/python-packages/smithy-core/tests/unit/aio/__init__.py b/packages/smithy-http/src/smithy_http/aio/auth/__init__.py similarity index 100% rename from python-packages/smithy-core/tests/unit/aio/__init__.py rename to packages/smithy-http/src/smithy_http/aio/auth/__init__.py diff --git a/python-packages/smithy-http/smithy_http/aio/auth/apikey.py b/packages/smithy-http/src/smithy_http/aio/auth/apikey.py similarity index 100% rename from python-packages/smithy-http/smithy_http/aio/auth/apikey.py rename to packages/smithy-http/src/smithy_http/aio/auth/apikey.py diff --git a/python-packages/smithy-http/smithy_http/aio/crt.py b/packages/smithy-http/src/smithy_http/aio/crt.py similarity index 100% rename from python-packages/smithy-http/smithy_http/aio/crt.py rename to packages/smithy-http/src/smithy_http/aio/crt.py diff --git a/python-packages/smithy-http/smithy_http/aio/endpoints.py b/packages/smithy-http/src/smithy_http/aio/endpoints.py similarity index 100% rename from python-packages/smithy-http/smithy_http/aio/endpoints.py rename to packages/smithy-http/src/smithy_http/aio/endpoints.py diff --git a/python-packages/smithy-http/smithy_http/aio/auth/__init__.py b/packages/smithy-http/src/smithy_http/aio/identity/__init__.py similarity index 100% rename from python-packages/smithy-http/smithy_http/aio/auth/__init__.py rename to packages/smithy-http/src/smithy_http/aio/identity/__init__.py diff --git a/python-packages/smithy-http/smithy_http/aio/identity/apikey.py b/packages/smithy-http/src/smithy_http/aio/identity/apikey.py similarity index 100% rename from python-packages/smithy-http/smithy_http/aio/identity/apikey.py rename to packages/smithy-http/src/smithy_http/aio/identity/apikey.py diff --git a/python-packages/smithy-http/smithy_http/aio/interfaces/__init__.py b/packages/smithy-http/src/smithy_http/aio/interfaces/__init__.py similarity index 100% rename from python-packages/smithy-http/smithy_http/aio/interfaces/__init__.py rename to packages/smithy-http/src/smithy_http/aio/interfaces/__init__.py diff --git a/python-packages/smithy-http/smithy_http/aio/interfaces/auth.py b/packages/smithy-http/src/smithy_http/aio/interfaces/auth.py similarity index 100% rename from python-packages/smithy-http/smithy_http/aio/interfaces/auth.py rename to packages/smithy-http/src/smithy_http/aio/interfaces/auth.py diff --git a/python-packages/smithy-http/smithy_http/aio/restjson.py b/packages/smithy-http/src/smithy_http/aio/restjson.py similarity index 100% rename from python-packages/smithy-http/smithy_http/aio/restjson.py rename to packages/smithy-http/src/smithy_http/aio/restjson.py diff --git a/python-packages/smithy-http/smithy_http/endpoints.py b/packages/smithy-http/src/smithy_http/endpoints.py similarity index 100% rename from python-packages/smithy-http/smithy_http/endpoints.py rename to packages/smithy-http/src/smithy_http/endpoints.py diff --git a/python-packages/smithy-http/smithy_http/exceptions.py b/packages/smithy-http/src/smithy_http/exceptions.py similarity index 100% rename from python-packages/smithy-http/smithy_http/exceptions.py rename to packages/smithy-http/src/smithy_http/exceptions.py diff --git a/python-packages/smithy-http/smithy_http/interfaces/__init__.py b/packages/smithy-http/src/smithy_http/interfaces/__init__.py similarity index 99% rename from python-packages/smithy-http/smithy_http/interfaces/__init__.py rename to packages/smithy-http/src/smithy_http/interfaces/__init__.py index 0ad35ccdd..0c3ac3cc0 100644 --- a/python-packages/smithy-http/smithy_http/interfaces/__init__.py +++ b/packages/smithy-http/src/smithy_http/interfaces/__init__.py @@ -72,7 +72,7 @@ class Fields(Protocol): # Entries are keyed off the name of a provided Field entries: dict[str, Field] - encoding: str | None = "utf-8" + encoding: str = "utf-8" def set_field(self, field: Field) -> None: """Alias for __setitem__ to utilize the field.name for the entry key.""" diff --git a/python-packages/smithy-http/smithy_http/py.typed b/packages/smithy-http/src/smithy_http/py.typed similarity index 100% rename from python-packages/smithy-http/smithy_http/py.typed rename to packages/smithy-http/src/smithy_http/py.typed diff --git a/python-packages/smithy-http/smithy_http/restjson.py b/packages/smithy-http/src/smithy_http/restjson.py similarity index 100% rename from python-packages/smithy-http/smithy_http/restjson.py rename to packages/smithy-http/src/smithy_http/restjson.py diff --git a/python-packages/smithy-http/smithy_http/utils.py b/packages/smithy-http/src/smithy_http/utils.py similarity index 100% rename from python-packages/smithy-http/smithy_http/utils.py rename to packages/smithy-http/src/smithy_http/utils.py diff --git a/python-packages/smithy-http/tests/integration/aio/conftest.py b/packages/smithy-http/tests/integration/aio/conftest.py similarity index 92% rename from python-packages/smithy-http/tests/integration/aio/conftest.py rename to packages/smithy-http/tests/integration/aio/conftest.py index a0e4ebf9a..c0c66b642 100644 --- a/python-packages/smithy-http/tests/integration/aio/conftest.py +++ b/packages/smithy-http/tests/integration/aio/conftest.py @@ -17,9 +17,10 @@ def sample_request() -> HTTPRequest: Field(name="user-agent", values=["smithy-python-test"]), ] ) + b: list[bytes] = [] return HTTPRequest( method="GET", destination=URI(host="aws.amazon.com"), fields=headers, - body=async_list([]), + body=async_list(b), ) diff --git a/python-packages/smithy-http/tests/integration/aio/test_aiohttp.py b/packages/smithy-http/tests/integration/aio/test_aiohttp.py similarity index 100% rename from python-packages/smithy-http/tests/integration/aio/test_aiohttp.py rename to packages/smithy-http/tests/integration/aio/test_aiohttp.py diff --git a/python-packages/smithy-http/tests/integration/aio/test_crt.py b/packages/smithy-http/tests/integration/aio/test_crt.py similarity index 100% rename from python-packages/smithy-http/tests/integration/aio/test_crt.py rename to packages/smithy-http/tests/integration/aio/test_crt.py diff --git a/python-packages/smithy-http/tests/py.typed b/packages/smithy-http/tests/py.typed similarity index 100% rename from python-packages/smithy-http/tests/py.typed rename to packages/smithy-http/tests/py.typed diff --git a/python-packages/smithy-http/tests/unit/aio/auth/test_apikey.py b/packages/smithy-http/tests/unit/aio/auth/test_apikey.py similarity index 100% rename from python-packages/smithy-http/tests/unit/aio/auth/test_apikey.py rename to packages/smithy-http/tests/unit/aio/auth/test_apikey.py diff --git a/python-packages/smithy-http/tests/unit/aio/identity/test_apikey.py b/packages/smithy-http/tests/unit/aio/identity/test_apikey.py similarity index 100% rename from python-packages/smithy-http/tests/unit/aio/identity/test_apikey.py rename to packages/smithy-http/tests/unit/aio/identity/test_apikey.py diff --git a/python-packages/smithy-http/tests/unit/aio/test_crt.py b/packages/smithy-http/tests/unit/aio/test_crt.py similarity index 100% rename from python-packages/smithy-http/tests/unit/aio/test_crt.py rename to packages/smithy-http/tests/unit/aio/test_crt.py diff --git a/python-packages/smithy-http/tests/unit/aio/test_endpoints.py b/packages/smithy-http/tests/unit/aio/test_endpoints.py similarity index 100% rename from python-packages/smithy-http/tests/unit/aio/test_endpoints.py rename to packages/smithy-http/tests/unit/aio/test_endpoints.py diff --git a/python-packages/smithy-http/tests/unit/aio/test_http.py b/packages/smithy-http/tests/unit/aio/test_http.py similarity index 100% rename from python-packages/smithy-http/tests/unit/aio/test_http.py rename to packages/smithy-http/tests/unit/aio/test_http.py diff --git a/python-packages/smithy-http/tests/unit/aio/test_restjson.py b/packages/smithy-http/tests/unit/aio/test_restjson.py similarity index 100% rename from python-packages/smithy-http/tests/unit/aio/test_restjson.py rename to packages/smithy-http/tests/unit/aio/test_restjson.py diff --git a/python-packages/smithy-http/tests/unit/test_fields.py b/packages/smithy-http/tests/unit/test_fields.py similarity index 100% rename from python-packages/smithy-http/tests/unit/test_fields.py rename to packages/smithy-http/tests/unit/test_fields.py diff --git a/python-packages/smithy-http/tests/unit/test_utils.py b/packages/smithy-http/tests/unit/test_utils.py similarity index 100% rename from python-packages/smithy-http/tests/unit/test_utils.py rename to packages/smithy-http/tests/unit/test_utils.py diff --git a/python-packages/smithy-json/NOTICE b/packages/smithy-json/NOTICE similarity index 100% rename from python-packages/smithy-json/NOTICE rename to packages/smithy-json/NOTICE diff --git a/python-packages/smithy-json/README.md b/packages/smithy-json/README.md similarity index 100% rename from python-packages/smithy-json/README.md rename to packages/smithy-json/README.md diff --git a/packages/smithy-json/pyproject.toml b/packages/smithy-json/pyproject.toml new file mode 100644 index 000000000..3f7c971b3 --- /dev/null +++ b/packages/smithy-json/pyproject.toml @@ -0,0 +1,19 @@ +[project] +name = "smithy-json" +version = "0.1.0" +description = "JSON serialization and deserialization support for Smithy tooling." +readme = "README.md" +requires-python = ">=3.12" +dependencies = [ + "ijson>=3.3.0", + "smithy-core", +] + +[build-system] +requires = ["hatchling"] +build-backend = "hatchling.build" + +[tool.hatch.build] +exclude = [ + "tests", +] diff --git a/python-packages/smithy-aws-core/smithy_aws_core/BUILD b/packages/smithy-json/src/smithy_json/BUILD similarity index 100% rename from python-packages/smithy-aws-core/smithy_aws_core/BUILD rename to packages/smithy-json/src/smithy_json/BUILD diff --git a/python-packages/smithy-json/smithy_json/__init__.py b/packages/smithy-json/src/smithy_json/__init__.py similarity index 99% rename from python-packages/smithy-json/smithy_json/__init__.py rename to packages/smithy-json/src/smithy_json/__init__.py index 9261c9290..11d7494f7 100644 --- a/python-packages/smithy-json/smithy_json/__init__.py +++ b/packages/smithy-json/src/smithy_json/__init__.py @@ -1,7 +1,5 @@ # Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. # SPDX-License-Identifier: Apache-2.0 -__version__ = "0.0.1" - from io import BytesIO from smithy_core.codecs import Codec diff --git a/python-packages/smithy-json/smithy_json/_private/__init__.py b/packages/smithy-json/src/smithy_json/_private/__init__.py similarity index 100% rename from python-packages/smithy-json/smithy_json/_private/__init__.py rename to packages/smithy-json/src/smithy_json/_private/__init__.py diff --git a/python-packages/smithy-json/smithy_json/_private/deserializers.py b/packages/smithy-json/src/smithy_json/_private/deserializers.py similarity index 100% rename from python-packages/smithy-json/smithy_json/_private/deserializers.py rename to packages/smithy-json/src/smithy_json/_private/deserializers.py diff --git a/python-packages/smithy-json/smithy_json/_private/documents.py b/packages/smithy-json/src/smithy_json/_private/documents.py similarity index 100% rename from python-packages/smithy-json/smithy_json/_private/documents.py rename to packages/smithy-json/src/smithy_json/_private/documents.py diff --git a/python-packages/smithy-json/smithy_json/_private/serializers.py b/packages/smithy-json/src/smithy_json/_private/serializers.py similarity index 100% rename from python-packages/smithy-json/smithy_json/_private/serializers.py rename to packages/smithy-json/src/smithy_json/_private/serializers.py diff --git a/python-packages/smithy-json/smithy_json/_private/traits.py b/packages/smithy-json/src/smithy_json/_private/traits.py similarity index 100% rename from python-packages/smithy-json/smithy_json/_private/traits.py rename to packages/smithy-json/src/smithy_json/_private/traits.py diff --git a/python-packages/smithy-json/smithy_json/py.typed b/packages/smithy-json/src/smithy_json/py.typed similarity index 100% rename from python-packages/smithy-json/smithy_json/py.typed rename to packages/smithy-json/src/smithy_json/py.typed diff --git a/python-packages/smithy-json/tests/unit/__init__.py b/packages/smithy-json/tests/unit/__init__.py similarity index 100% rename from python-packages/smithy-json/tests/unit/__init__.py rename to packages/smithy-json/tests/unit/__init__.py diff --git a/python-packages/smithy-json/tests/unit/test_deserializers.py b/packages/smithy-json/tests/unit/test_deserializers.py similarity index 100% rename from python-packages/smithy-json/tests/unit/test_deserializers.py rename to packages/smithy-json/tests/unit/test_deserializers.py diff --git a/python-packages/smithy-json/tests/unit/test_serializers.py b/packages/smithy-json/tests/unit/test_serializers.py similarity index 93% rename from python-packages/smithy-json/tests/unit/test_serializers.py rename to packages/smithy-json/tests/unit/test_serializers.py index 4c2ebccc2..567474687 100644 --- a/python-packages/smithy-json/tests/unit/test_serializers.py +++ b/packages/smithy-json/tests/unit/test_serializers.py @@ -65,7 +65,9 @@ def test_json_serializer(given: Any, expected: bytes) -> None: if v is None: map_serializer.entry(k, lambda vs: vs.write_null(member_schema)) else: - map_serializer.entry(k, lambda vs: vs.write_string(member_schema, v)) # type: ignore + map_serializer.entry( + k, lambda vs: vs.write_string(member_schema, v) + ) # type: ignore case SerdeShape(): given.serialize(serializer) case _: diff --git a/pants.ci.toml b/pants.ci.toml deleted file mode 100644 index fcff515a7..000000000 --- a/pants.ci.toml +++ /dev/null @@ -1,14 +0,0 @@ -[GLOBAL] -colors = true - -[stats] -log = true - -[test] -use_coverage = true - -[coverage-py] -report = ["xml", "html"] - -[pytest] -args = ["-vv", "--no-header"] diff --git a/pants.toml b/pants.toml deleted file mode 100644 index c9f3e6e9c..000000000 --- a/pants.toml +++ /dev/null @@ -1,78 +0,0 @@ -[GLOBAL] -pants_version = "2.19.0" - -backend_packages = [ - "pants.backend.python", - "pants.backend.python.lint.black", - "pants.backend.python.lint.isort", - "pants.backend.python.lint.flake8", - "pants.backend.experimental.python.typecheck.pyright", - "pants.backend.python.lint.pyupgrade", - "pants.backend.python.lint.docformatter", - "pants.backend.python.lint.bandit", -] - -[source] -root_patterns = [ - "python-packages/*" -] - -[python] -interpreter_constraints = [">=3.12"] -pip_version = "latest" -enable_resolves = true -resolves = { python-default = "python-default.lock" } -default_resolve = "python-default" - -[pytest] -install_from_resolve = "python-default" -requirements = [ - "pytest-asyncio", - "pytest-cov", -] -args = ['-v'] - -[test] -output = "all" -use_coverage = true - -[black] -install_from_resolve = "python-default" -args = ["-t py312"] -interpreter_constraints = [">=3.12"] - -[coverage-py] -install_from_resolve = "python-default" -interpreter_constraints = [">=3.12"] -report = [ - "xml", - "html" -] - -[pyright] -interpreter_constraints = [">=3.12"] - -[flake8] -install_from_resolve = "python-default" -args = "--extend-ignore=W503" - -[pyupgrade] -install_from_resolve = "python-default" -args = ["--py312-plus"] -interpreter_constraints = [">=3.12"] - -[docformatter] -install_from_resolve = "python-default" -args = ["--wrap-summaries 88", "--wrap-descriptions 88"] -interpreter_constraints = [">=3.12"] - -[bandit] -install_from_resolve = "python-default" -args = ["-x tests"] - -[isort] -install_from_resolve = "python-default" -interpreter_constraints = [">=3.12"] - -[anonymous-telemetry] -enabled = false diff --git a/pyproject.toml b/pyproject.toml index 445370513..6bdb5f1b1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,3 +1,61 @@ +[project] +name = "smithy-python" +version = "0.1.0" +description = "Add your description here" +readme = "README.md" +requires-python = ">=3.12" +dependencies = [] + +[dependency-groups] +dev = [ + "black>=25.1.0", + "docformatter>=1.7.5", + "pyright>=1.1.394", + "pytest>=8.3.4", + "pytest-asyncio>=0.25.3", + "pytest-cov>=6.0.0", + "ruff>=0.9.7", +] + +[tool.uv] +package = false + +[tool.uv.workspace] +members = ["packages/*"] + +[tool.uv.sources] +smithy_core = { workspace = true } +smithy_event_stream = { workspace = true } +smithy_http = { workspace = true } +smithy_json = { workspace = true } +smithy_aws_core = { workspace = true } +aws_event_stream = { workspace = true } + [tool.pyright] typeCheckingMode = "strict" -pythonVersion = "3.12" + +[tool.pytest.ini_options] +asyncio_mode = "auto" # makes pytest run async tests without having to be marked with the @pytest.mark.asyncio decorator +addopts = [ "--import-mode=importlib", "--cov", "--cov-report=term-missing" ] + +[tool.docformatter] +recursive = true +black = true + +[tool.ruff] +target-version = "py312" + +[tool.ruff.lint] +# candidates: C4, DTZ, EM, INP, ISC, PERF, PIE, RUF, SIM118, SIM401, SLOT +# perhaps in the future: N, PYI, TC, TID +# probably not, a lot of work: DOC, D, PL, TRY + +# TODO: I, T, UP +select = [ "ASYNC", "E1", "E4", "E7", "E9", "F", "FURB", "G", "LOG", "S" ] +exclude = [ "packages/smithy-core/src/smithy_core/rfc3986.py" ] + +[tool.ruff.lint.per-file-ignores] +"**/{tests}/*" = ["S"] + +[tool.ruff.format] +docstring-code-format = true diff --git a/python-default.lock b/python-default.lock deleted file mode 100644 index bd56eb46f..000000000 --- a/python-default.lock +++ /dev/null @@ -1,1539 +0,0 @@ -// This lockfile was autogenerated by Pants. To regenerate, run: -// -// ./pants generate-lockfiles --resolve=python-default -// -// --- BEGIN PANTS LOCKFILE METADATA: DO NOT EDIT OR REMOVE --- -// { -// "version": 3, -// "valid_for_interpreter_constraints": [ -// "CPython>=3.12" -// ], -// "generated_with_requirements": [ -// "aiohttp<3.11.0,>=3.8.6", -// "awscrt<1.0,>=0.15", -// "bandit<1.8.0", -// "black<=24.8.0", -// "docformatter<1.7.6", -// "flake8<=7.1.1", -// "freezegun<1.6.0", -// "ijson==3.2.3", -// "isort<5.14.0", -// "pyright==1.1.379", -// "pytest-asyncio<0.25.0", -// "pytest-cov<=5.0.0", -// "pytest<=8.3.2", -// "pyupgrade<3.18.0" -// ], -// "manylinux": "manylinux2014", -// "requirement_constraints": [], -// "only_binary": [], -// "no_binary": [] -// } -// --- END PANTS LOCKFILE METADATA --- - -{ - "allow_builds": true, - "allow_prereleases": false, - "allow_wheels": true, - "build_isolation": true, - "constraints": [], - "locked_resolves": [ - { - "locked_requirements": [ - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "7ce92076e249169a13c2f49320d1967425eaf1f407522d707d59cac7628d62bd", - "url": "https://files.pythonhosted.org/packages/18/b6/58ea188899950d759a837f9a58b2aee1d1a380ea4d6211ce9b1823748851/aiohappyeyeballs-2.4.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "55a1714f084e63d49639800f95716da97a1f173d46a16dfcfda0016abb93b6b2", - "url": "https://files.pythonhosted.org/packages/2d/f7/22bba300a16fd1cad99da1a23793fe43963ee326d012fdf852d0b4035955/aiohappyeyeballs-2.4.0.tar.gz" - } - ], - "project_name": "aiohappyeyeballs", - "requires_dists": [], - "requires_python": ">=3.8", - "version": "2.4.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "4f1c9866ccf48a6df2b06823e6ae80573529f2af3a0992ec4fe75b1a510df8a6", - "url": "https://files.pythonhosted.org/packages/fe/c2/f7eed4d602f3f224600d03ab2e1a7734999b0901b1c49b94dc5891340433/aiohttp-3.10.5-cp312-cp312-musllinux_1_2_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "de7a5299827253023c55ea549444e058c0eb496931fa05d693b95140a947cb73", - "url": "https://files.pythonhosted.org/packages/0a/32/c10118f0ad50e4093227234f71fd0abec6982c29367f65f32ee74ed652c4/aiohttp-3.10.5-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl" - }, - { - "algorithm": "sha256", - "hash": "3a1c32a19ee6bbde02f1cb189e13a71b321256cc1d431196a9f824050b160d5a", - "url": "https://files.pythonhosted.org/packages/12/29/68d090551f2b58ce76c2b436ced8dd2dfd32115d41299bf0b0c308a5483c/aiohttp-3.10.5-cp312-cp312-macosx_10_9_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "8ba01ebc6175e1e6b7275c907a3a36be48a2d487549b656aa90c8a910d9f3178", - "url": "https://files.pythonhosted.org/packages/1a/52/a25c0334a1845eb4967dff279151b67ca32a948145a5812ed660ed900868/aiohttp-3.10.5-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl" - }, - { - "algorithm": "sha256", - "hash": "b1c43eb1ab7cbf411b8e387dc169acb31f0ca0d8c09ba63f9eac67829585b44f", - "url": "https://files.pythonhosted.org/packages/64/74/0f1ddaa5f0caba1d946f0dd0c31f5744116e4a029beec454ec3726d3311f/aiohttp-3.10.5-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "44b324a6b8376a23e6ba25d368726ee3bc281e6ab306db80b5819999c737d820", - "url": "https://files.pythonhosted.org/packages/7e/5d/99c71f8e5c8b64295be421b4c42d472766b263a1fe32e91b64bf77005bf2/aiohttp-3.10.5-cp312-cp312-musllinux_1_2_i686.whl" - }, - { - "algorithm": "sha256", - "hash": "0d277cfb304118079e7044aad0b76685d30ecb86f83a0711fc5fb257ffe832ca", - "url": "https://files.pythonhosted.org/packages/8f/2c/76d2377dd947f52fbe8afb19b18a3b816d66c7966755c04030f93b1f7b2d/aiohttp-3.10.5-cp312-cp312-musllinux_1_2_ppc64le.whl" - }, - { - "algorithm": "sha256", - "hash": "61645818edd40cc6f455b851277a21bf420ce347baa0b86eaa41d51ef58ba23d", - "url": "https://files.pythonhosted.org/packages/8f/f7/971f88b4cdcaaa4622925ba7d86de47b48ec02a9040a143514b382f78da4/aiohttp-3.10.5-cp312-cp312-macosx_11_0_arm64.whl" - }, - { - "algorithm": "sha256", - "hash": "8eaf44ccbc4e35762683078b72bf293f476561d8b68ec8a64f98cf32811c323e", - "url": "https://files.pythonhosted.org/packages/96/3d/33c1d8efc2d8ec36bff9a8eca2df9fdf8a45269c6e24a88e74f2aa4f16bd/aiohttp-3.10.5-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl" - }, - { - "algorithm": "sha256", - "hash": "4790f0e15f00058f7599dab2b206d3049d7ac464dc2e5eae0e93fa18aee9e7bf", - "url": "https://files.pythonhosted.org/packages/c6/c9/77e3d648d97c03a42acfe843d03e97be3c5ef1b4d9de52e5bd2d28eed8e7/aiohttp-3.10.5-cp312-cp312-musllinux_1_2_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "f071854b47d39591ce9a17981c46790acb30518e2f83dfca8db2dfa091178691", - "url": "https://files.pythonhosted.org/packages/ca/28/ca549838018140b92a19001a8628578b0f2a3b38c16826212cc6f706e6d4/aiohttp-3.10.5.tar.gz" - }, - { - "algorithm": "sha256", - "hash": "305be5ff2081fa1d283a76113b8df7a14c10d75602a38d9f012935df20731487", - "url": "https://files.pythonhosted.org/packages/d9/1c/74f9dad4a2fc4107e73456896283d915937f48177b99867b63381fadac6e/aiohttp-3.10.5-cp312-cp312-macosx_10_9_universal2.whl" - }, - { - "algorithm": "sha256", - "hash": "6c225286f2b13bab5987425558baa5cbdb2bc925b2998038fa028245ef421e75", - "url": "https://files.pythonhosted.org/packages/f1/5a/fe3742efdce551667b2ddf1158b27c5b8eb1edc13d5e14e996e52e301025/aiohttp-3.10.5-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "54d9ddea424cd19d3ff6128601a4a4d23d54a421f9b4c0fff740505813739a91", - "url": "https://files.pythonhosted.org/packages/fd/e6/3d9d935cc705d57ed524d82ec5d6b678a53ac1552720ae41282caa273584/aiohttp-3.10.5-cp312-cp312-musllinux_1_2_s390x.whl" - } - ], - "project_name": "aiohttp", - "requires_dists": [ - "Brotli; platform_python_implementation == \"CPython\" and extra == \"speedups\"", - "aiodns>=3.2.0; (sys_platform == \"linux\" or sys_platform == \"darwin\") and extra == \"speedups\"", - "aiohappyeyeballs>=2.3.0", - "aiosignal>=1.1.2", - "async-timeout<5.0,>=4.0; python_version < \"3.11\"", - "attrs>=17.3.0", - "brotlicffi; platform_python_implementation != \"CPython\" and extra == \"speedups\"", - "frozenlist>=1.1.1", - "multidict<7.0,>=4.5", - "yarl<2.0,>=1.0" - ], - "requires_python": ">=3.8", - "version": "3.10.5" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "f8376fb07dd1e86a584e4fcdec80b36b7f81aac666ebc724e2c090300dd83b17", - "url": "https://files.pythonhosted.org/packages/76/ac/a7305707cb852b7e16ff80eaf5692309bde30e2b1100a1fcacdc8f731d97/aiosignal-1.3.1-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "54cd96e15e1649b75d6c87526a6ff0b6c1b0dd3459f43d9ca11d48c339b68cfc", - "url": "https://files.pythonhosted.org/packages/ae/67/0952ed97a9793b4958e5736f6d2b346b414a2cd63e82d05940032f45b32f/aiosignal-1.3.1.tar.gz" - } - ], - "project_name": "aiosignal", - "requires_dists": [ - "frozenlist>=1.1.0" - ], - "requires_python": ">=3.7", - "version": "1.3.1" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "81921eb96de3191c8258c199618104dd27ac608d9366f5e35d011eae1867ede2", - "url": "https://files.pythonhosted.org/packages/6a/21/5b6702a7f963e95456c0de2d495f67bf5fd62840ac655dc451586d23d39a/attrs-24.2.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "5cfb1b9148b5b086569baec03f20d7b6bf3bcacc9a42bebf87ffaaca362f6346", - "url": "https://files.pythonhosted.org/packages/fc/0f/aafca9af9315aee06a89ffde799a10a582fe8de76c563ee80bbcdc08b3fb/attrs-24.2.0.tar.gz" - } - ], - "project_name": "attrs", - "requires_dists": [ - "cloudpickle; platform_python_implementation == \"CPython\" and extra == \"benchmark\"", - "cloudpickle; platform_python_implementation == \"CPython\" and extra == \"cov\"", - "cloudpickle; platform_python_implementation == \"CPython\" and extra == \"dev\"", - "cloudpickle; platform_python_implementation == \"CPython\" and extra == \"tests\"", - "cogapp; extra == \"docs\"", - "coverage[toml]>=5.3; extra == \"cov\"", - "furo; extra == \"docs\"", - "hypothesis; extra == \"benchmark\"", - "hypothesis; extra == \"cov\"", - "hypothesis; extra == \"dev\"", - "hypothesis; extra == \"tests\"", - "importlib-metadata; python_version < \"3.8\"", - "mypy>=1.11.1; (platform_python_implementation == \"CPython\" and python_version >= \"3.9\") and extra == \"benchmark\"", - "mypy>=1.11.1; (platform_python_implementation == \"CPython\" and python_version >= \"3.9\") and extra == \"cov\"", - "mypy>=1.11.1; (platform_python_implementation == \"CPython\" and python_version >= \"3.9\") and extra == \"dev\"", - "mypy>=1.11.1; (platform_python_implementation == \"CPython\" and python_version >= \"3.9\") and extra == \"tests\"", - "mypy>=1.11.1; (platform_python_implementation == \"CPython\" and python_version >= \"3.9\") and extra == \"tests-mypy\"", - "myst-parser; extra == \"docs\"", - "pre-commit; extra == \"dev\"", - "pympler; extra == \"benchmark\"", - "pympler; extra == \"cov\"", - "pympler; extra == \"dev\"", - "pympler; extra == \"tests\"", - "pytest-codspeed; extra == \"benchmark\"", - "pytest-mypy-plugins; (platform_python_implementation == \"CPython\" and python_version >= \"3.9\" and python_version < \"3.13\") and extra == \"benchmark\"", - "pytest-mypy-plugins; (platform_python_implementation == \"CPython\" and python_version >= \"3.9\" and python_version < \"3.13\") and extra == \"cov\"", - "pytest-mypy-plugins; (platform_python_implementation == \"CPython\" and python_version >= \"3.9\" and python_version < \"3.13\") and extra == \"dev\"", - "pytest-mypy-plugins; (platform_python_implementation == \"CPython\" and python_version >= \"3.9\" and python_version < \"3.13\") and extra == \"tests\"", - "pytest-mypy-plugins; (platform_python_implementation == \"CPython\" and python_version >= \"3.9\" and python_version < \"3.13\") and extra == \"tests-mypy\"", - "pytest-xdist[psutil]; extra == \"benchmark\"", - "pytest-xdist[psutil]; extra == \"cov\"", - "pytest-xdist[psutil]; extra == \"dev\"", - "pytest-xdist[psutil]; extra == \"tests\"", - "pytest>=4.3.0; extra == \"benchmark\"", - "pytest>=4.3.0; extra == \"cov\"", - "pytest>=4.3.0; extra == \"dev\"", - "pytest>=4.3.0; extra == \"tests\"", - "sphinx-notfound-page; extra == \"docs\"", - "sphinx; extra == \"docs\"", - "sphinxcontrib-towncrier; extra == \"docs\"", - "towncrier<24.7; extra == \"docs\"" - ], - "requires_python": ">=3.7", - "version": "24.2.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "c9ceef0f824b0cc96b90f025a54a79960f42a48d8af75ce7cd965a7c27f8df47", - "url": "https://files.pythonhosted.org/packages/c2/0f/17a2fa38336cc2709f1cfb0967dfddb0b960ee39f8843bba66eec62845c9/awscrt-0.21.2-cp311-abi3-musllinux_1_1_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "381f8f6912f31bef15394b3d6ece0a38edfeed3da98e8c207a01399b278b9dc2", - "url": "https://files.pythonhosted.org/packages/5f/d0/d53cf6ec85855e41ff816d2656a6261d755c447108757bf60bfc263dd1e2/awscrt-0.21.2-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "37ace28d0d7a91f90862dd2994872a15962b7b4f1376e0b7b01a821954611507", - "url": "https://files.pythonhosted.org/packages/7f/74/7789c268de69be3f6179abdba36a5e7c079997a8de73aea13e70a98d4494/awscrt-0.21.2.tar.gz" - }, - { - "algorithm": "sha256", - "hash": "085c03407681ae571db23dabeae77d0e28f3382237facf0816e30619ed815ae5", - "url": "https://files.pythonhosted.org/packages/bd/9c/93ae9ceb894e635fc3a4fb41f2757536e17893b4ba77e8363242fd087b14/awscrt-0.21.2-cp311-abi3-musllinux_1_1_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "29914013d02c0d4ab4a863f4b86fb7cfac43e216948446dc5b3437bea0250c30", - "url": "https://files.pythonhosted.org/packages/db/8b/f21afa2d2327d93bd4af61878b5c9f381b1329cadade1f5c79fb8b78095f/awscrt-0.21.2-cp311-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "5599b82fff266ff5443018e02ec9a6f695a75c8773c14047a6d6c7f5efaa5525", - "url": "https://files.pythonhosted.org/packages/e3/88/dba84bc524d837708f9a98ee1becefe4b87afb6c5f82278bcabc85102d46/awscrt-0.21.2-cp311-abi3-macosx_10_9_universal2.whl" - } - ], - "project_name": "awscrt", - "requires_dists": [], - "requires_python": ">=3.7", - "version": "0.21.2" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "52077cb339000f337fb25f7e045995c4ad01511e716e5daac37014b9752de8ec", - "url": "https://files.pythonhosted.org/packages/5b/a3/05820b7ce584a1fa01d887ec5e3274bee9f9e02a53aa63de3cb1a5ad7d24/bandit-1.7.9-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "7c395a436743018f7be0a4cbb0a4ea9b902b6d87264ddecf8cfdc73b4f78ff61", - "url": "https://files.pythonhosted.org/packages/1c/a4/ee391b0f046a6d8919eef246aed7c39849e299cc2e50d918b54add397de6/bandit-1.7.9.tar.gz" - } - ], - "project_name": "bandit", - "requires_dists": [ - "GitPython>=3.1.30; extra == \"baseline\"", - "PyYAML; extra == \"yaml\"", - "PyYAML>=5.3.1", - "beautifulsoup4>=4.8.0; extra == \"test\"", - "colorama>=0.3.9; platform_system == \"Windows\"", - "coverage>=4.5.4; extra == \"test\"", - "fixtures>=3.0.0; extra == \"test\"", - "flake8>=4.0.0; extra == \"test\"", - "jschema-to-python>=1.2.3; extra == \"sarif\"", - "pylint==1.9.4; extra == \"test\"", - "rich", - "sarif-om>=1.0.4; extra == \"sarif\"", - "stestr>=2.5.0; extra == \"test\"", - "stevedore>=1.20.0", - "testscenarios>=0.5.0; extra == \"test\"", - "testtools>=2.3.0; extra == \"test\"", - "tomli>=1.1.0; python_version < \"3.11\" and extra == \"toml\"" - ], - "requires_python": ">=3.8", - "version": "1.7.9" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "972085c618ee94f402da1af548a4f218c754ea7e5dc70acb168bfaca4c2542ed", - "url": "https://files.pythonhosted.org/packages/27/1e/83fa8a787180e1632c3d831f7e58994d7aaf23a0961320d21e84f922f919/black-24.8.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "2500945420b6784c38b9ee885af039f5e7471ef284ab03fa35ecdde4688cd83f", - "url": "https://files.pythonhosted.org/packages/04/b0/46fb0d4e00372f4a86a6f8efa3cb193c9f64863615e39010b1477e010578/black-24.8.0.tar.gz" - }, - { - "algorithm": "sha256", - "hash": "649f6d84ccbae73ab767e206772cc2d7a393a001070a4c814a546afd0d423aed", - "url": "https://files.pythonhosted.org/packages/41/77/8d9ce42673e5cb9988f6df73c1c5c1d4e9e788053cccd7f5fb14ef100982/black-24.8.0-cp312-cp312-macosx_11_0_arm64.whl" - }, - { - "algorithm": "sha256", - "hash": "7c046c1d1eeb7aea9335da62472481d3bbf3fd986e093cffd35f4385c94ae368", - "url": "https://files.pythonhosted.org/packages/a2/a8/05fb14195cfef32b7c8d4585a44b7499c2a4b205e1662c427b941ed87054/black-24.8.0-cp312-cp312-macosx_10_9_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "2b59b250fdba5f9a9cd9d0ece6e6d993d91ce877d121d161e4698af3eb9c1018", - "url": "https://files.pythonhosted.org/packages/cc/94/eff1ddad2ce1d3cc26c162b3693043c6b6b575f538f602f26fe846dfdc75/black-24.8.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl" - } - ], - "project_name": "black", - "requires_dists": [ - "aiohttp!=3.9.0,>=3.7.4; (sys_platform == \"win32\" and implementation_name == \"pypy\") and extra == \"d\"", - "aiohttp>=3.7.4; (sys_platform != \"win32\" or implementation_name != \"pypy\") and extra == \"d\"", - "click>=8.0.0", - "colorama>=0.4.3; extra == \"colorama\"", - "ipython>=7.8.0; extra == \"jupyter\"", - "mypy-extensions>=0.4.3", - "packaging>=22.0", - "pathspec>=0.9.0", - "platformdirs>=2", - "tokenize-rt>=3.2.0; extra == \"jupyter\"", - "tomli>=1.1.0; python_version < \"3.11\"", - "typing-extensions>=4.0.1; python_version < \"3.11\"", - "uvloop>=0.15.2; extra == \"uvloop\"" - ], - "requires_python": ">=3.8", - "version": "24.8.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "3e4d1f6587322d2788836a99c69062fbb091331ec940e02d12d179c1d53e25fc", - "url": "https://files.pythonhosted.org/packages/28/76/e6222113b83e3622caa4bb41032d0b1bf785250607392e1b778aca0b8a7d/charset_normalizer-3.3.2-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "b4a23f61ce87adf89be746c8a8974fe1c823c891d8f86eb218bb957c924bb143", - "url": "https://files.pythonhosted.org/packages/24/9d/2e3ef673dfd5be0154b20363c5cdcc5606f35666544381bee15af3778239/charset_normalizer-3.3.2-cp312-cp312-musllinux_1_1_s390x.whl" - }, - { - "algorithm": "sha256", - "hash": "ddbb2551d7e0102e7252db79ba445cdab71b26640817ab1e3e3648dad515003b", - "url": "https://files.pythonhosted.org/packages/2e/7d/2259318c202f3d17f3fe6438149b3b9e706d1070fe3fcbb28049730bb25c/charset_normalizer-3.3.2-cp312-cp312-macosx_10_9_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "55086ee1064215781fff39a1af09518bc9255b50d6333f2e4c74ca09fac6a8f6", - "url": "https://files.pythonhosted.org/packages/3a/52/9f9d17c3b54dc238de384c4cb5a2ef0e27985b42a0e5cc8e8a31d918d48d/charset_normalizer-3.3.2-cp312-cp312-macosx_11_0_arm64.whl" - }, - { - "algorithm": "sha256", - "hash": "7ed9e526742851e8d5cc9e6cf41427dfc6068d4f5a3bb03659444b4cabf6bc26", - "url": "https://files.pythonhosted.org/packages/45/59/3d27019d3b447a88fe7e7d004a1e04be220227760264cc41b405e863891b/charset_normalizer-3.3.2-cp312-cp312-musllinux_1_1_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "efcb3f6676480691518c177e3b465bcddf57cea040302f9f4e6e191af91174d4", - "url": "https://files.pythonhosted.org/packages/5b/ae/ce2c12fcac59cb3860b2e2d76dc405253a4475436b1861d95fe75bdea520/charset_normalizer-3.3.2-cp312-cp312-musllinux_1_1_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "f30c3cb33b24454a82faecaf01b19c18562b1e89558fb6c56de4d9118a032fd5", - "url": "https://files.pythonhosted.org/packages/63/09/c1bc53dab74b1816a00d8d030de5bf98f724c52c1635e07681d312f20be8/charset-normalizer-3.3.2.tar.gz" - }, - { - "algorithm": "sha256", - "hash": "8d756e44e94489e49571086ef83b2bb8ce311e730092d2c34ca8f7d925cb20aa", - "url": "https://files.pythonhosted.org/packages/72/1a/641d5c9f59e6af4c7b53da463d07600a695b9824e20849cb6eea8a627761/charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl" - }, - { - "algorithm": "sha256", - "hash": "8bdb58ff7ba23002a4c5808d608e4e6c687175724f54a5dade5fa8c67b604e4d", - "url": "https://files.pythonhosted.org/packages/7b/ef/5eb105530b4da8ae37d506ccfa25057961b7b63d581def6f99165ea89c7e/charset_normalizer-3.3.2-cp312-cp312-musllinux_1_1_i686.whl" - }, - { - "algorithm": "sha256", - "hash": "a10af20b82360ab00827f916a6058451b723b4e65030c5a18577c8b2de5b3389", - "url": "https://files.pythonhosted.org/packages/91/33/749df346e93d7a30cdcb90cbfdd41a06026317bfbfb62cd68307c1a3c543/charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl" - }, - { - "algorithm": "sha256", - "hash": "8f4a014bc36d3c57402e2977dada34f9c12300af536839dc38c0beab8878f38a", - "url": "https://files.pythonhosted.org/packages/99/b0/9c365f6d79a9f0f3c379ddb40a256a67aa69c59609608fe7feb6235896e1/charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "6b3251890fff30ee142c44144871185dbe13b11bab478a88887a639655be1068", - "url": "https://files.pythonhosted.org/packages/a2/51/e5023f937d7f307c948ed3e5c29c4b7a3e42ed2ee0b8cdf8f3a706089bf0/charset_normalizer-3.3.2-cp312-cp312-musllinux_1_1_ppc64le.whl" - }, - { - "algorithm": "sha256", - "hash": "0b2b64d2bb6d3fb9112bafa732def486049e63de9618b5843bcdd081d8144cd8", - "url": "https://files.pythonhosted.org/packages/d1/b2/fcedc8255ec42afee97f9e6f0145c734bbe104aac28300214593eb326f1d/charset_normalizer-3.3.2-cp312-cp312-macosx_10_9_universal2.whl" - }, - { - "algorithm": "sha256", - "hash": "6ac7ffc7ad6d040517be39eb591cac5ff87416c2537df6ba3cba3bae290c0fed", - "url": "https://files.pythonhosted.org/packages/df/3e/a06b18788ca2eb6695c9b22325b6fde7dde0f1d1838b1792a0076f58fe9d/charset_normalizer-3.3.2-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl" - }, - { - "algorithm": "sha256", - "hash": "90d558489962fd4918143277a773316e56c72da56ec7aa3dc3dbbe20fdfed15b", - "url": "https://files.pythonhosted.org/packages/ee/fb/14d30eb4956408ee3ae09ad34299131fb383c47df355ddb428a7331cfa1e/charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl" - } - ], - "project_name": "charset-normalizer", - "requires_dists": [], - "requires_python": ">=3.7.0", - "version": "3.3.2" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "ae74fb96c20a0277a1d615f1e4d73c8414f5a98db8b799a7931d1582f3390c28", - "url": "https://files.pythonhosted.org/packages/00/2e/d53fa4befbf2cfa713304affc7ca780ce4fc1fd8710527771b58311a3229/click-8.1.7-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "ca9853ad459e787e2192211578cc907e7594e294c7ccc834310722b41b9ca6de", - "url": "https://files.pythonhosted.org/packages/96/d3/f04c7bfcf5c1862a2a5b845c6b2b360488cf47af55dfa79c98f6a6bf98b5/click-8.1.7.tar.gz" - } - ], - "project_name": "click", - "requires_dists": [ - "colorama; platform_system == \"Windows\"", - "importlib-metadata; python_version < \"3.8\"" - ], - "requires_python": ">=3.7", - "version": "8.1.7" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "c3c02d12f837d9683e5ab2f3d9844dc57655b92c74e286c262e0fc54213c216d", - "url": "https://files.pythonhosted.org/packages/86/74/1dc7a20969725e917b1e07fe71a955eb34bc606b938316bcc799f228374b/coverage-7.6.1-cp312-cp312-musllinux_1_2_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "07e2ca0ad381b91350c0ed49d52699b625aab2b44b65e1b4e02fa9df0e92ad2d", - "url": "https://files.pythonhosted.org/packages/0f/ef/94043e478201ffa85b8ae2d2c79b4081e5a1b73438aafafccf3e9bafb6b5/coverage-7.6.1-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl" - }, - { - "algorithm": "sha256", - "hash": "c44fee9975f04b33331cb8eb272827111efc8930cfd582e0320613263ca849ca", - "url": "https://files.pythonhosted.org/packages/1f/0f/c890339dd605f3ebc269543247bdd43b703cce6825b5ed42ff5f2d6122c7/coverage-7.6.1-cp312-cp312-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "95cae0efeb032af8458fc27d191f85d1717b1d4e49f7cb226cf526ff28179778", - "url": "https://files.pythonhosted.org/packages/7e/d4/300fc921dff243cd518c7db3a4c614b7e4b2431b0d1145c1e274fd99bd70/coverage-7.6.1-cp312-cp312-macosx_10_9_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "260933720fdcd75340e7dbe9060655aff3af1f0c5d20f46b57f262ab6c86a5e8", - "url": "https://files.pythonhosted.org/packages/92/8f/2ead05e735022d1a7f3a0a683ac7f737de14850395a826192f0288703472/coverage-7.6.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "877abb17e6339d96bf08e7a622d05095e72b71f8afd8a9fefc82cf30ed944163", - "url": "https://files.pythonhosted.org/packages/d1/04/7fd7b39ec7372a04efb0f70c70e35857a99b6a9188b5205efb4c77d6a57a/coverage-7.6.1-cp312-cp312-musllinux_1_2_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "5621a9175cf9d0b0c84c2ef2b12e9f5f5071357c4d2ea6ca1cf01814f45d2391", - "url": "https://files.pythonhosted.org/packages/e1/ab/6bf00de5327ecb8db205f9ae596885417a31535eeda6e7b99463108782e1/coverage-7.6.1-cp312-cp312-macosx_11_0_arm64.whl" - }, - { - "algorithm": "sha256", - "hash": "3e0cadcf6733c09154b461f1ca72d5416635e5e4ec4e536192180d34ec160f8a", - "url": "https://files.pythonhosted.org/packages/ed/bf/73ce346a9d32a09cf369f14d2a06651329c984e106f5992c89579d25b27e/coverage-7.6.1-cp312-cp312-musllinux_1_2_i686.whl" - }, - { - "algorithm": "sha256", - "hash": "953510dfb7b12ab69d20135a0662397f077c59b1e6379a768e97c59d852ee51d", - "url": "https://files.pythonhosted.org/packages/f7/08/7e37f82e4d1aead42a7443ff06a1e406aabf7302c4f00a546e4b320b994c/coverage-7.6.1.tar.gz" - } - ], - "project_name": "coverage", - "requires_dists": [ - "tomli; python_full_version <= \"3.11.0a6\" and extra == \"toml\"" - ], - "requires_python": ">=3.8", - "version": "7.6.1" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "a24f5545ed1f30af00d106f5d85dc2fce4959295687c24c8f39f5263afaf9186", - "url": "https://files.pythonhosted.org/packages/8b/95/568a2fca29df365b82012b09b64964a05f4f20ac83c2137b262f3fa3188f/docformatter-1.7.5-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "ffed3da0daffa2e77f80ccba4f0e50bfa2755e1c10e130102571c890a61b246e", - "url": "https://files.pythonhosted.org/packages/f4/44/aba2c40cf796121b35835ea8c00bc5d93f2f70730eca53b36b8bbbfaefe1/docformatter-1.7.5.tar.gz" - } - ], - "project_name": "docformatter", - "requires_dists": [ - "charset_normalizer<4.0.0,>=3.0.0", - "tomli<3.0.0,>=2.0.0; python_version < \"3.11\" and extra == \"tomli\"", - "untokenize<0.2.0,>=0.1.1" - ], - "requires_python": "<4.0,>=3.7", - "version": "1.7.5" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "597477df7860daa5aa0fdd84bf5208a043ab96b8e96ab708770ae0364dd03213", - "url": "https://files.pythonhosted.org/packages/d9/42/65004373ac4617464f35ed15931b30d764f53cdd30cc78d5aea349c8c050/flake8-7.1.1-py2.py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "049d058491e228e03e67b390f311bbf88fce2dbaa8fa673e7aea87b7198b8d38", - "url": "https://files.pythonhosted.org/packages/37/72/e8d66150c4fcace3c0a450466aa3480506ba2cae7b61e100a2613afc3907/flake8-7.1.1.tar.gz" - } - ], - "project_name": "flake8", - "requires_dists": [ - "mccabe<0.8.0,>=0.7.0", - "pycodestyle<2.13.0,>=2.12.0", - "pyflakes<3.3.0,>=3.2.0" - ], - "requires_python": ">=3.8.1", - "version": "7.1.1" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "bf111d7138a8abe55ab48a71755673dbaa4ab87f4cff5634a4442dfec34c15f1", - "url": "https://files.pythonhosted.org/packages/51/0b/0d7fee5919bccc1fdc1c2a7528b98f65c6f69b223a3fd8f809918c142c36/freezegun-1.5.1-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "b29dedfcda6d5e8e083ce71b2b542753ad48cfec44037b3fc79702e2980a89e9", - "url": "https://files.pythonhosted.org/packages/2c/ef/722b8d71ddf4d48f25f6d78aa2533d505bf3eec000a7cacb8ccc8de61f2f/freezegun-1.5.1.tar.gz" - } - ], - "project_name": "freezegun", - "requires_dists": [ - "python-dateutil>=2.7" - ], - "requires_python": ">=3.7", - "version": "1.5.1" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "04ced3e6a46b4cfffe20f9ae482818e34eba9b5fb0ce4056e4cc9b6e212d09b7", - "url": "https://files.pythonhosted.org/packages/83/10/466fe96dae1bff622021ee687f68e5524d6392b0a2f80d05001cd3a451ba/frozenlist-1.4.1-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "9acbb16f06fe7f52f441bb6f413ebae6c37baa6ef9edd49cdd567216da8600cd", - "url": "https://files.pythonhosted.org/packages/0b/f2/b8158a0f06faefec33f4dff6345a575c18095a44e52d4f10c678c137d0e0/frozenlist-1.4.1-cp312-cp312-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "dd9b1baec094d91bf36ec729445f7769d0d0cf6b64d04d86e45baf89e2b9059b", - "url": "https://files.pythonhosted.org/packages/37/ff/a613e58452b60166507d731812f3be253eb1229808e59980f0405d1eafbf/frozenlist-1.4.1-cp312-cp312-musllinux_1_1_ppc64le.whl" - }, - { - "algorithm": "sha256", - "hash": "c9c92be9fd329ac801cc420e08452b70e7aeab94ea4233a4804f0915c14eba9b", - "url": "https://files.pythonhosted.org/packages/3f/ab/c543c13824a615955f57e082c8a5ee122d2d5368e80084f2834e6f4feced/frozenlist-1.4.1-cp312-cp312-macosx_11_0_arm64.whl" - }, - { - "algorithm": "sha256", - "hash": "cc7b01b3754ea68a62bd77ce6020afaffb44a590c2289089289363472d13aedb", - "url": "https://files.pythonhosted.org/packages/46/03/69eb64642ca8c05f30aa5931d6c55e50b43d0cd13256fdd01510a1f85221/frozenlist-1.4.1-cp312-cp312-macosx_10_9_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "3e0153a805a98f5ada7e09826255ba99fb4f7524bb81bf6b47fb702666484ae1", - "url": "https://files.pythonhosted.org/packages/4c/f9/8894c05dc927af2a09663bdf31914d4fb5501653f240a5bbaf1e88cab1d3/frozenlist-1.4.1-cp312-cp312-musllinux_1_1_i686.whl" - }, - { - "algorithm": "sha256", - "hash": "ba60bb19387e13597fb059f32cd4d59445d7b18b69a745b8f8e5db0346f33480", - "url": "https://files.pythonhosted.org/packages/54/72/716a955521b97a25d48315c6c3653f981041ce7a17ff79f701298195bca3/frozenlist-1.4.1-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl" - }, - { - "algorithm": "sha256", - "hash": "8aefbba5f69d42246543407ed2461db31006b0f76c4e32dfd6f42215a2c41d09", - "url": "https://files.pythonhosted.org/packages/65/d8/934c08103637567084568e4d5b4219c1016c60b4d29353b1a5b3587827d6/frozenlist-1.4.1-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl" - }, - { - "algorithm": "sha256", - "hash": "780d3a35680ced9ce682fbcf4cb9c2bad3136eeff760ab33707b71db84664e3a", - "url": "https://files.pythonhosted.org/packages/70/bb/d3b98d83ec6ef88f9bd63d77104a305d68a146fd63a683569ea44c3085f6/frozenlist-1.4.1-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl" - }, - { - "algorithm": "sha256", - "hash": "5667ed53d68d91920defdf4035d1cdaa3c3121dc0b113255124bcfada1cfa1b8", - "url": "https://files.pythonhosted.org/packages/a5/c2/e42ad54bae8bcffee22d1e12a8ee6c7717f7d5b5019261a8c861854f4776/frozenlist-1.4.1-cp312-cp312-musllinux_1_1_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "5c3894db91f5a489fc8fa6a9991820f368f0b3cbdb9cd8849547ccfab3392d86", - "url": "https://files.pythonhosted.org/packages/a9/b8/438cfd92be2a124da8259b13409224d9b19ef8f5a5b2507174fc7e7ea18f/frozenlist-1.4.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "1979bc0aeb89b33b588c51c54ab0161791149f2461ea7c7c946d95d5f93b56ae", - "url": "https://files.pythonhosted.org/packages/b4/db/4cf37556a735bcdb2582f2c3fa286aefde2322f92d3141e087b8aeb27177/frozenlist-1.4.1-cp312-cp312-macosx_10_9_universal2.whl" - }, - { - "algorithm": "sha256", - "hash": "1a4471094e146b6790f61b98616ab8e44f72661879cc63fa1049d13ef711e71e", - "url": "https://files.pythonhosted.org/packages/cc/6e/0091d785187f4c2020d5245796d04213f2261ad097e0c1cf35c44317d517/frozenlist-1.4.1-cp312-cp312-musllinux_1_1_s390x.whl" - }, - { - "algorithm": "sha256", - "hash": "c037a86e8513059a2613aaba4d817bb90b9d9b6b69aace3ce9c877e8c8ed402b", - "url": "https://files.pythonhosted.org/packages/cf/3d/2102257e7acad73efc4a0c306ad3953f68c504c16982bbdfee3ad75d8085/frozenlist-1.4.1.tar.gz" - }, - { - "algorithm": "sha256", - "hash": "23b701e65c7b36e4bf15546a89279bd4d8675faabc287d06bbcfac7d3c33e1e6", - "url": "https://files.pythonhosted.org/packages/ea/a2/20882c251e61be653764038ece62029bfb34bd5b842724fff32a5b7a2894/frozenlist-1.4.1-cp312-cp312-musllinux_1_1_aarch64.whl" - } - ], - "project_name": "frozenlist", - "requires_dists": [], - "requires_python": ">=3.8", - "version": "1.4.1" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "050b4e5baadcd44d760cedbd2b8e639f2ff89bbc7a5730fcc662954303377aac", - "url": "https://files.pythonhosted.org/packages/22/7e/d71db821f177828df9dea8c42ac46473366f191be53080e552e628aad991/idna-3.8-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "d838c2c0ed6fced7693d5e8ab8e734d5f8fda53a039c0164afb0b82e771e3603", - "url": "https://files.pythonhosted.org/packages/e8/ac/e349c5e6d4543326c6883ee9491e3921e0d07b55fdf3cce184b40d63e72a/idna-3.8.tar.gz" - } - ], - "project_name": "idna", - "requires_dists": [], - "requires_python": ">=3.6", - "version": "3.8" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "105c314fd624e81ed20f925271ec506523b8dd236589ab6c0208b8707d652a0e", - "url": "https://files.pythonhosted.org/packages/4f/a4/ba9b4450846e93e675bf915f3eed9724ee3ba1991e3295109377525688ee/ijson-3.2.3-cp312-cp312-musllinux_1_1_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "c075a547de32f265a5dd139ab2035900fef6653951628862e5cdce0d101af557", - "url": "https://files.pythonhosted.org/packages/11/af/c990c00e5585b36213cb47b773785d20e99a8850458c1e2698973b0e4c78/ijson-3.2.3-cp312-cp312-macosx_10_9_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "10294e9bf89cb713da05bc4790bdff616610432db561964827074898e174f917", - "url": "https://files.pythonhosted.org/packages/20/58/acdd87bd1b926fa2348a7f2ee5e1e7e2c9b808db78342317fc2474c87516/ijson-3.2.3.tar.gz" - }, - { - "algorithm": "sha256", - "hash": "457f8a5fc559478ac6b06b6d37ebacb4811f8c5156e997f0d87d708b0d8ab2ae", - "url": "https://files.pythonhosted.org/packages/31/78/430e11f91d40b97b08a105e057d1c93a487e6c96361967e01aac45445d61/ijson-3.2.3-cp312-cp312-macosx_11_0_arm64.whl" - }, - { - "algorithm": "sha256", - "hash": "bdd0dc5da4f9dc6d12ab6e8e0c57d8b41d3c8f9ceed31a99dae7b2baf9ea769a", - "url": "https://files.pythonhosted.org/packages/4a/9c/7a6eccc0403378d34c497b59b5c71cca4b1f63e12ba2ab459b6c3a793ae0/ijson-3.2.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "c6beb80df19713e39e68dc5c337b5c76d36ccf69c30b79034634e5e4c14d6904", - "url": "https://files.pythonhosted.org/packages/59/67/94d24cc4afde3fa8654f6a19b67cd4e9b6dffc24ef09be281e896b1e39ba/ijson-3.2.3-cp312-cp312-musllinux_1_1_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "9788f0c915351f41f0e69ec2618b81ebfcf9f13d9d67c6d404c7f5afda3e4afb", - "url": "https://files.pythonhosted.org/packages/6f/a2/c273d70946658bdca0de537617f276c497a0708f97054c2acadcc0acc3bc/ijson-3.2.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "a2973ce57afb142d96f35a14e9cfec08308ef178a2c76b8b5e1e98f3960438bf", - "url": "https://files.pythonhosted.org/packages/71/7c/5c56fff0643cfdd15492d90b560464c3c44745c3a4e4b54cdd980fe31447/ijson-3.2.3-cp312-cp312-musllinux_1_1_i686.whl" - }, - { - "algorithm": "sha256", - "hash": "055b71bbc37af5c3c5861afe789e15211d2d3d06ac51ee5a647adf4def19c0ea", - "url": "https://files.pythonhosted.org/packages/82/a8/0e389a7e097a28ba18ee9238de957550414007b58e67522b00cb85ff951e/ijson-3.2.3-cp312-cp312-macosx_10_9_universal2.whl" - }, - { - "algorithm": "sha256", - "hash": "fa234ab7a6a33ed51494d9d2197fb96296f9217ecae57f5551a55589091e7853", - "url": "https://files.pythonhosted.org/packages/bb/ff/2c59cbf961b90dd56471cdb8c30a75b7513ee32b19a1490f165cb40b4321/ijson-3.2.3-cp312-cp312-manylinux_2_17_i686.manylinux2014_i686.whl" - } - ], - "project_name": "ijson", - "requires_dists": [], - "requires_python": null, - "version": "3.2.3" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "b6a85871a79d2e3b22d2d1b94ac2824226a63c6b741c88f7ae975f18b6778374", - "url": "https://files.pythonhosted.org/packages/ef/a6/62565a6e1cf69e10f5727360368e451d4b7f58beeac6173dc9db836a5b46/iniconfig-2.0.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "2d91e135bf72d31a410b17c16da610a82cb55f6b0477d1a902134b24a455b8b3", - "url": "https://files.pythonhosted.org/packages/d7/4b/cbd8e699e64a6f16ca3a8220661b5f83792b3017d0f79807cb8708d33913/iniconfig-2.0.0.tar.gz" - } - ], - "project_name": "iniconfig", - "requires_dists": [], - "requires_python": ">=3.7", - "version": "2.0.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "8ca5e72a8d85860d5a3fa69b8745237f2939afe12dbf656afbcb47fe72d947a6", - "url": "https://files.pythonhosted.org/packages/d1/b3/8def84f539e7d2289a02f0524b944b15d7c75dab7628bedf1c4f0992029c/isort-5.13.2-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "48fdfcb9face5d58a4f6dde2e72a1fb8dcaf8ab26f95ab49fab84c2ddefb0109", - "url": "https://files.pythonhosted.org/packages/87/f9/c1eb8635a24e87ade2efce21e3ce8cd6b8630bb685ddc9cdaca1349b2eb5/isort-5.13.2.tar.gz" - } - ], - "project_name": "isort", - "requires_dists": [ - "colorama>=0.4.6; extra == \"colors\"" - ], - "requires_python": ">=3.8.0", - "version": "5.13.2" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "355216845c60bd96232cd8d8c40e8f9765cc86f46880e43a8fd22dc1a1a8cab1", - "url": "https://files.pythonhosted.org/packages/42/d7/1ec15b46af6af88f19b8e5ffea08fa375d433c998b8a7639e76935c14f1f/markdown_it_py-3.0.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "e3f60a94fa066dc52ec76661e37c851cb232d92f9886b15cb560aaada2df8feb", - "url": "https://files.pythonhosted.org/packages/38/71/3b932df36c1a044d397a1f92d1cf91ee0a503d91e470cbd670aa66b07ed0/markdown-it-py-3.0.0.tar.gz" - } - ], - "project_name": "markdown-it-py", - "requires_dists": [ - "commonmark~=0.9; extra == \"compare\"", - "coverage; extra == \"testing\"", - "gprof2dot; extra == \"profiling\"", - "jupyter_sphinx; extra == \"rtd\"", - "linkify-it-py<3,>=1; extra == \"linkify\"", - "markdown~=3.4; extra == \"compare\"", - "mdit-py-plugins; extra == \"plugins\"", - "mdit-py-plugins; extra == \"rtd\"", - "mdurl~=0.1", - "mistletoe~=1.0; extra == \"compare\"", - "mistune~=2.0; extra == \"compare\"", - "myst-parser; extra == \"rtd\"", - "panflute~=2.3; extra == \"compare\"", - "pre-commit~=3.0; extra == \"code-style\"", - "psutil; extra == \"benchmarking\"", - "pytest-benchmark; extra == \"benchmarking\"", - "pytest-cov; extra == \"testing\"", - "pytest-regressions; extra == \"testing\"", - "pytest; extra == \"benchmarking\"", - "pytest; extra == \"testing\"", - "pyyaml; extra == \"rtd\"", - "sphinx-copybutton; extra == \"rtd\"", - "sphinx-design; extra == \"rtd\"", - "sphinx; extra == \"rtd\"", - "sphinx_book_theme; extra == \"rtd\"" - ], - "requires_python": ">=3.8", - "version": "3.0.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "6c2d30ab6be0e4a46919781807b4f0d834ebdd6c6e3dca0bda5a15f863427b6e", - "url": "https://files.pythonhosted.org/packages/27/1a/1f68f9ba0c207934b35b86a8ca3aad8395a3d6dd7921c0686e23853ff5a9/mccabe-0.7.0-py2.py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "348e0240c33b60bbdf4e523192ef919f28cb2c3d7d5c7794f74009290f236325", - "url": "https://files.pythonhosted.org/packages/e7/ff/0ffefdcac38932a54d2b5eed4e0ba8a408f215002cd178ad1df0f2806ff8/mccabe-0.7.0.tar.gz" - } - ], - "project_name": "mccabe", - "requires_dists": [], - "requires_python": ">=3.6", - "version": "0.7.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "84008a41e51615a49fc9966191ff91509e3c40b939176e643fd50a5c2196b8f8", - "url": "https://files.pythonhosted.org/packages/b3/38/89ba8ad64ae25be8de66a6d463314cf1eb366222074cfda9ee839c56a4b4/mdurl-0.1.2-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "bb413d29f5eea38f31dd4754dd7377d4465116fb207585f97bf925588687c1ba", - "url": "https://files.pythonhosted.org/packages/d6/54/cfe61301667036ec958cb99bd3efefba235e65cdeb9c84d24a8293ba1d90/mdurl-0.1.2.tar.gz" - } - ], - "project_name": "mdurl", - "requires_dists": [], - "requires_python": ">=3.7", - "version": "0.1.2" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "0d63c74e3d7ab26de115c49bffc92cc77ed23395303d496eae515d4204a625e7", - "url": "https://files.pythonhosted.org/packages/fa/a2/17e1e23c6be0a916219c5292f509360c345b5fa6beeb50d743203c27532c/multidict-6.0.5-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "79660376075cfd4b2c80f295528aa6beb2058fd289f4c9252f986751a4cd0496", - "url": "https://files.pythonhosted.org/packages/0c/08/bb47f886457e2259aefc10044e45c8a1b62f0c27228557e17775869d0341/multidict-6.0.5-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl" - }, - { - "algorithm": "sha256", - "hash": "d84a5c3a5f7ce6db1f999fb9438f686bc2e09d38143f2d93d8406ed2dd6b9226", - "url": "https://files.pythonhosted.org/packages/24/1f/af976383b0b772dd351210af5b60ff9927e3abb2f4a103e93da19a957da0/multidict-6.0.5-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "14c2976aa9038c2629efa2c148022ed5eb4cb939e15ec7aace7ca932f48f9ba6", - "url": "https://files.pythonhosted.org/packages/3c/29/3dd36cf6b9c5abba8b97bba84eb499a168ba59c3faec8829327b3887d123/multidict-6.0.5-cp312-cp312-musllinux_1_1_s390x.whl" - }, - { - "algorithm": "sha256", - "hash": "fb616be3538599e797a2017cccca78e354c767165e8858ab5116813146041a24", - "url": "https://files.pythonhosted.org/packages/45/7c/06926bb91752c52abca3edbfefac1ea90d9d1bc00c84d0658c137589b920/multidict-6.0.5-cp312-cp312-musllinux_1_1_ppc64le.whl" - }, - { - "algorithm": "sha256", - "hash": "ceb3b7e6a0135e092de86110c5a74e46bda4bd4fbfeeb3a3bcec79c0f861e450", - "url": "https://files.pythonhosted.org/packages/4e/4e/3815190e73e6ef101b5681c174c541bf972a1b064e926e56eea78d06e858/multidict-6.0.5-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "92d16a3e275e38293623ebf639c471d3e03bb20b8ebb845237e0d3664914caef", - "url": "https://files.pythonhosted.org/packages/5e/e8/ad6ee74b1a2050d3bc78f566dabcc14c8bf89cbe87eecec866c011479815/multidict-6.0.5-cp312-cp312-musllinux_1_1_i686.whl" - }, - { - "algorithm": "sha256", - "hash": "435a0984199d81ca178b9ae2c26ec3d49692d20ee29bc4c11a2a8d4514c67eda", - "url": "https://files.pythonhosted.org/packages/60/47/9a0f43470c70bbf6e148311f78ef5a3d4996b0226b6d295bdd50fdcfe387/multidict-6.0.5-cp312-cp312-musllinux_1_1_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "51d035609b86722963404f711db441cf7134f1889107fb171a970c9701f92e1e", - "url": "https://files.pythonhosted.org/packages/90/9c/7fda9c0defa09538c97b1f195394be82a1f53238536f70b32eb5399dfd4e/multidict-6.0.5-cp312-cp312-macosx_10_9_universal2.whl" - }, - { - "algorithm": "sha256", - "hash": "2ffc42c922dbfddb4a4c3b438eb056828719f07608af27d163191cb3e3aa6cc5", - "url": "https://files.pythonhosted.org/packages/9c/18/9565f32c19d186168731e859692dfbc0e98f66a1dcf9e14d69c02a78b75a/multidict-6.0.5-cp312-cp312-macosx_11_0_arm64.whl" - }, - { - "algorithm": "sha256", - "hash": "cbebcd5bcaf1eaf302617c114aa67569dd3f090dd0ce8ba9e35e9985b41ac35b", - "url": "https://files.pythonhosted.org/packages/be/21/d6ca80dd1b9b2c5605ff7475699a8ff5dc6ea958cd71fb2ff234afc13d79/multidict-6.0.5-cp312-cp312-macosx_10_9_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "79a6d2ba910adb2cbafc95dad936f8b9386e77c84c35bc0add315b856d7c3abb", - "url": "https://files.pythonhosted.org/packages/d0/bf/2a1d667acf11231cdf0b97a6cd9f30e7a5cf847037b5cf6da44884284bd0/multidict-6.0.5-cp312-cp312-musllinux_1_1_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "e4428b29611e989719874670fd152b6625500ad6c686d464e99f5aaeeaca175a", - "url": "https://files.pythonhosted.org/packages/d5/2f/952f79b5f0795cf4e34852fc5cf4dfda6166f63c06c798361215b69c131d/multidict-6.0.5-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl" - }, - { - "algorithm": "sha256", - "hash": "f7e301075edaf50500f0b341543c41194d8df3ae5caf4702f2095f3ca73dd8da", - "url": "https://files.pythonhosted.org/packages/f9/79/722ca999a3a09a63b35aac12ec27dfa8e5bb3a38b0f857f7a1a209a88836/multidict-6.0.5.tar.gz" - }, - { - "algorithm": "sha256", - "hash": "76c0de87358b192de7ea9649beb392f107dcad9ad27276324c24c91774ca5271", - "url": "https://files.pythonhosted.org/packages/fc/b1/b0a7744be00b0f5045c7ed4e4a6b8ee6bde4672b2c620474712299df5979/multidict-6.0.5-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl" - } - ], - "project_name": "multidict", - "requires_dists": [], - "requires_python": ">=3.7", - "version": "6.0.5" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "4392f6c0eb8a5668a69e23d168ffa70f0be9ccfd32b5cc2d26a34ae5b844552d", - "url": "https://files.pythonhosted.org/packages/2a/e2/5d3f6ada4297caebe1a2add3b126fe800c96f56dbe5d1988a2cbe0b267aa/mypy_extensions-1.0.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "75dbf8955dc00442a438fc4d0666508a9a97b6bd41aa2f0ffe9d2f2725af0782", - "url": "https://files.pythonhosted.org/packages/98/a4/1ab47638b92648243faf97a5aeb6ea83059cc3624972ab6b8d2316078d3f/mypy_extensions-1.0.0.tar.gz" - } - ], - "project_name": "mypy-extensions", - "requires_dists": [], - "requires_python": ">=3.5", - "version": "1.0.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "ba11c9782d29c27c70ffbdda2d7415098754709be8a7056d79a737cd901155c9", - "url": "https://files.pythonhosted.org/packages/d2/1d/1b658dbd2b9fa9c4c9f32accbfc0205d532c8c6194dc0f2a4c0428e7128a/nodeenv-1.9.1-py2.py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "6ec12890a2dab7946721edbfbcd91f3319c6ccc9aec47be7c7e6b7011ee6645f", - "url": "https://files.pythonhosted.org/packages/43/16/fc88b08840de0e0a72a2f9d8c6bae36be573e475a6326ae854bcc549fc45/nodeenv-1.9.1.tar.gz" - } - ], - "project_name": "nodeenv", - "requires_dists": [], - "requires_python": "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,>=2.7", - "version": "1.9.1" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "5b8f2217dbdbd2f7f384c41c628544e6d52f2d0f53c6d0c3ea61aa5d1d7ff124", - "url": "https://files.pythonhosted.org/packages/08/aa/cc0199a5f0ad350994d660967a8efb233fe0416e4639146c089643407ce6/packaging-24.1-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "026ed72c8ed3fcce5bf8950572258698927fd1dbda10a5e981cdf0ac37f4f002", - "url": "https://files.pythonhosted.org/packages/51/65/50db4dda066951078f0a96cf12f4b9ada6e4b811516bf0262c0f4f7064d4/packaging-24.1.tar.gz" - } - ], - "project_name": "packaging", - "requires_dists": [], - "requires_python": ">=3.8", - "version": "24.1" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "a0d503e138a4c123b27490a4f7beda6a01c6f288df0e4a8b79c7eb0dc7b4cc08", - "url": "https://files.pythonhosted.org/packages/cc/20/ff623b09d963f88bfde16306a54e12ee5ea43e9b597108672ff3a408aad6/pathspec-0.12.1-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "a482d51503a1ab33b1c67a6c3813a26953dbdc71c31dacaef9a838c4e29f5712", - "url": "https://files.pythonhosted.org/packages/ca/bc/f35b8446f4531a7cb215605d100cd88b7ac6f44ab3fc94870c120ab3adbf/pathspec-0.12.1.tar.gz" - } - ], - "project_name": "pathspec", - "requires_dists": [], - "requires_python": ">=3.8", - "version": "0.12.1" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "a776ae228892d8013649c0aeccbb3d5f99ee15e005a4cbb7e61d55a067b28a2a", - "url": "https://files.pythonhosted.org/packages/1d/44/6a65ecd630393d47ad3e7d5354768cb7f9a10b3a0eb2cd8c6f52b28211ee/pbr-6.1.0-py2.py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "788183e382e3d1d7707db08978239965e8b9e4e5ed42669bf4758186734d5f24", - "url": "https://files.pythonhosted.org/packages/b2/35/80cf8f6a4f34017a7fe28242dc45161a1baa55c41563c354d8147e8358b2/pbr-6.1.0.tar.gz" - } - ], - "project_name": "pbr", - "requires_dists": [], - "requires_python": ">=2.6", - "version": "6.1.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "2d7a1657e36a80ea911db832a8a6ece5ee53d8de21edd5cc5879af6530b1bfee", - "url": "https://files.pythonhosted.org/packages/68/13/2aa1f0e1364feb2c9ef45302f387ac0bd81484e9c9a4c5688a322fbdfd08/platformdirs-4.2.2-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "38b7b51f512eed9e84a22788b4bce1de17c0adb134d6becb09836e37d8654cd3", - "url": "https://files.pythonhosted.org/packages/f5/52/0763d1d976d5c262df53ddda8d8d4719eedf9594d046f117c25a27261a19/platformdirs-4.2.2.tar.gz" - } - ], - "project_name": "platformdirs", - "requires_dists": [ - "appdirs==1.4.4; extra == \"test\"", - "covdefaults>=2.3; extra == \"test\"", - "furo>=2023.9.10; extra == \"docs\"", - "mypy>=1.8; extra == \"type\"", - "proselint>=0.13; extra == \"docs\"", - "pytest-cov>=4.1; extra == \"test\"", - "pytest-mock>=3.12; extra == \"test\"", - "pytest>=7.4.3; extra == \"test\"", - "sphinx-autodoc-typehints>=1.25.2; extra == \"docs\"", - "sphinx>=7.2.6; extra == \"docs\"" - ], - "requires_python": ">=3.8", - "version": "4.2.2" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "44e1ad92c8ca002de6377e165f3e0f1be63266ab4d554740532335b9d75ea669", - "url": "https://files.pythonhosted.org/packages/88/5f/e351af9a41f866ac3f1fac4ca0613908d9a41741cfcf2228f4ad853b697d/pluggy-1.5.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "2cffa88e94fdc978c4c574f15f9e59b7f4201d439195c3715ca9e2486f1d0cf1", - "url": "https://files.pythonhosted.org/packages/96/2d/02d4312c973c6050a18b314a5ad0b3210edb65a906f868e31c111dede4a6/pluggy-1.5.0.tar.gz" - } - ], - "project_name": "pluggy", - "requires_dists": [ - "pre-commit; extra == \"dev\"", - "pytest-benchmark; extra == \"testing\"", - "pytest; extra == \"testing\"", - "tox; extra == \"dev\"" - ], - "requires_python": ">=3.8", - "version": "1.5.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "46f0fb92069a7c28ab7bb558f05bfc0110dac69a0cd23c61ea0040283a9d78b3", - "url": "https://files.pythonhosted.org/packages/3a/d8/a211b3f85e99a0daa2ddec96c949cac6824bd305b040571b82a03dd62636/pycodestyle-2.12.1-py2.py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "6838eae08bbce4f6accd5d5572075c63626a15ee3e6f842df996bf62f6d73521", - "url": "https://files.pythonhosted.org/packages/43/aa/210b2c9aedd8c1cbeea31a50e42050ad56187754b34eb214c46709445801/pycodestyle-2.12.1.tar.gz" - } - ], - "project_name": "pycodestyle", - "requires_dists": [], - "requires_python": ">=3.8", - "version": "2.12.1" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "84b5be138a2dfbb40689ca07e2152deb896a65c3a3e24c251c5c62489568074a", - "url": "https://files.pythonhosted.org/packages/d4/d7/f1b7db88d8e4417c5d47adad627a93547f44bdc9028372dbd2313f34a855/pyflakes-3.2.0-py2.py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "1c61603ff154621fb2a9172037d84dca3500def8c8b630657d1701f026f8af3f", - "url": "https://files.pythonhosted.org/packages/57/f9/669d8c9c86613c9d568757c7f5824bd3197d7b1c6c27553bc5618a27cce2/pyflakes-3.2.0.tar.gz" - } - ], - "project_name": "pyflakes", - "requires_dists": [], - "requires_python": ">=3.8", - "version": "3.2.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "b8e6aca0523f3ab76fee51799c488e38782ac06eafcf95e7ba832985c8e7b13a", - "url": "https://files.pythonhosted.org/packages/f7/3f/01c8b82017c199075f8f788d0d906b9ffbbc5a47dc9918a945e13d5a2bda/pygments-2.18.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "786ff802f32e91311bff3889f6e9a86e81505fe99f2735bb6d60ae0c5004f199", - "url": "https://files.pythonhosted.org/packages/8e/62/8336eff65bcbc8e4cb5d05b55faf041285951b6e80f33e2bff2024788f31/pygments-2.18.0.tar.gz" - } - ], - "project_name": "pygments", - "requires_dists": [ - "colorama>=0.4.6; extra == \"windows-terminal\"" - ], - "requires_python": ">=3.8", - "version": "2.18.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "01954811ac71db8646f50de1577576dc275ffb891a9e7324350e676cf6df323f", - "url": "https://files.pythonhosted.org/packages/1e/4b/98bb2d6eb98ca35fa5fe90d787c3181310ed153c996af3a7f158487b9a87/pyright-1.1.379-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "6f426cb6443786fa966b930c23ad1941c8cb9fe672e4589daea8d80bb34193ea", - "url": "https://files.pythonhosted.org/packages/14/62/fd6f13c417087b8e941c3d7cbc37fcf5ec62b6ae7031837194c0926cb704/pyright-1.1.379.tar.gz" - } - ], - "project_name": "pyright", - "requires_dists": [ - "nodeenv>=1.6.0", - "twine>=3.4.1; extra == \"all\"", - "twine>=3.4.1; extra == \"dev\"", - "typing-extensions>=3.7; python_version < \"3.8\"" - ], - "requires_python": ">=3.7", - "version": "1.1.379" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "4ba08f9ae7dcf84ded419494d229b48d0903ea6407b030eaec46df5e6a73bba5", - "url": "https://files.pythonhosted.org/packages/0f/f9/cf155cf32ca7d6fa3601bc4c5dd19086af4b320b706919d48a4c79081cf9/pytest-8.3.2-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "c132345d12ce551242c87269de812483f5bcc87cdbb4722e48487ba194f9fdce", - "url": "https://files.pythonhosted.org/packages/b4/8c/9862305bdcd6020bc7b45b1b5e7397a6caf1a33d3025b9a003b39075ffb2/pytest-8.3.2.tar.gz" - } - ], - "project_name": "pytest", - "requires_dists": [ - "argcomplete; extra == \"dev\"", - "attrs>=19.2; extra == \"dev\"", - "colorama; sys_platform == \"win32\"", - "exceptiongroup>=1.0.0rc8; python_version < \"3.11\"", - "hypothesis>=3.56; extra == \"dev\"", - "iniconfig", - "mock; extra == \"dev\"", - "packaging", - "pluggy<2,>=1.5", - "pygments>=2.7.2; extra == \"dev\"", - "requests; extra == \"dev\"", - "setuptools; extra == \"dev\"", - "tomli>=1; python_version < \"3.11\"", - "xmlschema; extra == \"dev\"" - ], - "requires_python": ">=3.8", - "version": "8.3.2" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "a811296ed596b69bf0b6f3dc40f83bcaf341b155a269052d82efa2b25ac7037b", - "url": "https://files.pythonhosted.org/packages/96/31/6607dab48616902f76885dfcf62c08d929796fc3b2d2318faf9fd54dbed9/pytest_asyncio-0.24.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "d081d828e576d85f875399194281e92bf8a68d60d72d1a2faf2feddb6c46b276", - "url": "https://files.pythonhosted.org/packages/52/6d/c6cf50ce320cf8611df7a1254d86233b3df7cc07f9b5f5cbcb82e08aa534/pytest_asyncio-0.24.0.tar.gz" - } - ], - "project_name": "pytest-asyncio", - "requires_dists": [ - "coverage>=6.2; extra == \"testing\"", - "hypothesis>=5.7.1; extra == \"testing\"", - "pytest<9,>=8.2", - "sphinx-rtd-theme>=1.0; extra == \"docs\"", - "sphinx>=5.3; extra == \"docs\"" - ], - "requires_python": ">=3.8", - "version": "0.24.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "4f0764a1219df53214206bf1feea4633c3b558a2925c8b59f144f682861ce652", - "url": "https://files.pythonhosted.org/packages/78/3a/af5b4fa5961d9a1e6237b530eb87dd04aea6eb83da09d2a4073d81b54ccf/pytest_cov-5.0.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "5837b58e9f6ebd335b0f8060eecce69b662415b16dc503883a02f45dfeb14857", - "url": "https://files.pythonhosted.org/packages/74/67/00efc8d11b630c56f15f4ad9c7f9223f1e5ec275aaae3fa9118c6a223ad2/pytest-cov-5.0.0.tar.gz" - } - ], - "project_name": "pytest-cov", - "requires_dists": [ - "coverage[toml]>=5.2.1", - "fields; extra == \"testing\"", - "hunter; extra == \"testing\"", - "process-tests; extra == \"testing\"", - "pytest-xdist; extra == \"testing\"", - "pytest>=4.6", - "virtualenv; extra == \"testing\"" - ], - "requires_python": ">=3.8", - "version": "5.0.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "a8b2bc7bffae282281c8140a97d3aa9c14da0b136dfe83f850eea9a5f7470427", - "url": "https://files.pythonhosted.org/packages/ec/57/56b9bcc3c9c6a792fcbaf139543cee77261f3651ca9da0c93f5c1221264b/python_dateutil-2.9.0.post0-py2.py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "37dd54208da7e1cd875388217d5e00ebd4179249f90fb72437e91a35459a0ad3", - "url": "https://files.pythonhosted.org/packages/66/c0/0c8b6ad9f17a802ee498c46e004a0eb49bc148f2fd230864601a86dcf6db/python-dateutil-2.9.0.post0.tar.gz" - } - ], - "project_name": "python-dateutil", - "requires_dists": [ - "six>=1.5" - ], - "requires_python": "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7", - "version": "2.9.0.post0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "cbc8f67a61d3f4e7ca9c2ef57b9aae67f023d3780ce30c99fccec78401723754", - "url": "https://files.pythonhosted.org/packages/2c/a6/97092b45591e35945ea9714a8f77bfdf7058bd311e61bb47763174067f4f/pyupgrade-3.17.0-py2.py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "d5dd1dcaf9a016c31508bb9d3d09fd335d736578092f91df52bb26ac30c37919", - "url": "https://files.pythonhosted.org/packages/7a/79/15cd93e47b5d670f0e32a540eb3f11bac4b5800cf1f796590eb448c6a768/pyupgrade-3.17.0.tar.gz" - } - ], - "project_name": "pyupgrade", - "requires_dists": [ - "tokenize-rt>=5.2.0" - ], - "requires_python": ">=3.9", - "version": "3.17.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "8b9c7197f7cb2738065c481a0461e50ad02f18c78cd75775628afb4d7137fb3b", - "url": "https://files.pythonhosted.org/packages/c9/1f/4f998c900485e5c0ef43838363ba4a9723ac0ad73a9dc42068b12aaba4e4/PyYAML-6.0.2-cp312-cp312-musllinux_1_1_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "d584d9ec91ad65861cc08d42e834324ef890a082e591037abe114850ff7bbc3e", - "url": "https://files.pythonhosted.org/packages/54/ed/79a089b6be93607fa5cdaedf301d7dfb23af5f25c398d5ead2525b063e17/pyyaml-6.0.2.tar.gz" - }, - { - "algorithm": "sha256", - "hash": "c70c95198c015b85feafc136515252a261a84561b7b1d51e3384e0655ddf25ab", - "url": "https://files.pythonhosted.org/packages/86/0c/c581167fc46d6d6d7ddcfb8c843a4de25bdd27e4466938109ca68492292c/PyYAML-6.0.2-cp312-cp312-macosx_10_9_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "9b22676e8097e9e22e36d6b7bda33190d0d400f345f23d4065d48f4ca7ae0425", - "url": "https://files.pythonhosted.org/packages/95/0f/b8938f1cbd09739c6da569d172531567dbcc9789e0029aa070856f123984/PyYAML-6.0.2-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl" - }, - { - "algorithm": "sha256", - "hash": "ce826d6ef20b1bc864f0a68340c8b3287705cae2f8b4b1d932177dcc76721725", - "url": "https://files.pythonhosted.org/packages/a8/0c/38374f5bb272c051e2a69281d71cba6fdb983413e6758b84482905e29a5d/PyYAML-6.0.2-cp312-cp312-macosx_11_0_arm64.whl" - }, - { - "algorithm": "sha256", - "hash": "80bab7bfc629882493af4aa31a4cfa43a4c57c83813253626916b8c7ada83476", - "url": "https://files.pythonhosted.org/packages/b9/2b/614b4752f2e127db5cc206abc23a8c19678e92b23c3db30fc86ab731d3bd/PyYAML-6.0.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "1f71ea527786de97d1a0cc0eacd1defc0985dcf6b3f17bb77dcfc8c34bec4dc5", - "url": "https://files.pythonhosted.org/packages/c3/93/9916574aa8c00aa06bbac729972eb1071d002b8e158bd0e83a3b9a20a1f7/PyYAML-6.0.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "0833f8694549e586547b576dcfaba4a6b55b9e96098b36cdc7ebefe667dfed48", - "url": "https://files.pythonhosted.org/packages/d4/00/dd137d5bcc7efea1836d6264f049359861cf548469d18da90cd8216cf05f/PyYAML-6.0.2-cp312-cp312-musllinux_1_1_aarch64.whl" - } - ], - "project_name": "pyyaml", - "requires_dists": [], - "requires_python": ">=3.8", - "version": "6.0.2" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "2e85306a063b9492dffc86278197a60cbece75bcb766022f3436f567cae11bdc", - "url": "https://files.pythonhosted.org/packages/c7/d9/c2a126eeae791e90ea099d05cb0515feea3688474b978343f3cdcfe04523/rich-13.8.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "a5ac1f1cd448ade0d59cc3356f7db7a7ccda2c8cbae9c7a90c28ff463d3e91f4", - "url": "https://files.pythonhosted.org/packages/cf/60/5959113cae0ce512cf246a6871c623117330105a0d5f59b4e26138f2c9cc/rich-13.8.0.tar.gz" - } - ], - "project_name": "rich", - "requires_dists": [ - "ipywidgets<9,>=7.5.1; extra == \"jupyter\"", - "markdown-it-py>=2.2.0", - "pygments<3.0.0,>=2.13.0", - "typing-extensions<5.0,>=4.0.0; python_version < \"3.9\"" - ], - "requires_python": ">=3.7.0", - "version": "13.8.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254", - "url": "https://files.pythonhosted.org/packages/d9/5a/e7c31adbe875f2abbb91bd84cf2dc52d792b5a01506781dbcf25c91daf11/six-1.16.0-py2.py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926", - "url": "https://files.pythonhosted.org/packages/71/39/171f1c67cd00715f190ba0b100d606d440a28c93c7714febeca8b79af85e/six-1.16.0.tar.gz" - } - ], - "project_name": "six", - "requires_dists": [], - "requires_python": "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7", - "version": "1.16.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "1efd34ca08f474dad08d9b19e934a22c68bb6fe416926479ba29e5013bcc8f78", - "url": "https://files.pythonhosted.org/packages/ec/50/70762bdb23f6c2b746b90661f461d33c4913a22a46bb5265b10947e85ffb/stevedore-5.3.0-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "9a64265f4060312828151c204efbe9b7a9852a0d9228756344dbc7e4023e375a", - "url": "https://files.pythonhosted.org/packages/c4/59/f8aefa21020054f553bf7e3b405caec7f8d1f432d9cb47e34aaa244d8d03/stevedore-5.3.0.tar.gz" - } - ], - "project_name": "stevedore", - "requires_dists": [ - "pbr>=2.0.0" - ], - "requires_python": ">=3.8", - "version": "5.3.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "d4ff7ded2873512938b4f8cbb98c9b07118f01d30ac585a30d7a88353ca36d22", - "url": "https://files.pythonhosted.org/packages/5c/c2/44486862562c6902778ccf88001ad5ea3f8da5c030c638cac8be72f65b40/tokenize_rt-6.0.0-py2.py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "b9711bdfc51210211137499b5e355d3de5ec88a85d2025c520cbb921b5194367", - "url": "https://files.pythonhosted.org/packages/7d/09/6257dabdeab5097d72c5d874f29b33cd667ec411af6667922d84f85b79b5/tokenize_rt-6.0.0.tar.gz" - } - ], - "project_name": "tokenize-rt", - "requires_dists": [], - "requires_python": ">=3.8", - "version": "6.0.0" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "3865dbbbb8efb4bb5eaa72f1be7f3e0be00ea8b7f125c69cbd1f5fda926f37a2", - "url": "https://files.pythonhosted.org/packages/f7/46/e7cea8159199096e1df52da20a57a6665da80c37fb8aeb848a3e47442c32/untokenize-0.1.1.tar.gz" - } - ], - "project_name": "untokenize", - "requires_dists": [], - "requires_python": null, - "version": "0.1.1" - }, - { - "artifacts": [ - { - "algorithm": "sha256", - "hash": "c6f6c87665a9e18a635f0545ea541d9640617832af2317d4f5ad389686b4ed3d", - "url": "https://files.pythonhosted.org/packages/a0/20/ae694bcd16b49e83a9f943ebc2f0a90c9ca6bb09846e99a7bda30e1773d9/yarl-1.9.11-py3-none-any.whl" - }, - { - "algorithm": "sha256", - "hash": "f568d70b7187f4002b6b500c0996c37674a25ce44b20716faebe5fdb8bd356e7", - "url": "https://files.pythonhosted.org/packages/04/99/161a2365a804dfec9e5ff5c44c6c09c64ba87bcf979b915a54a5a4a37d9e/yarl-1.9.11-cp312-cp312-musllinux_1_2_i686.whl" - }, - { - "algorithm": "sha256", - "hash": "c7548a90cb72b67652e2cd6ae80e2683ee08fde663104528ac7df12d8ef271d2", - "url": "https://files.pythonhosted.org/packages/1e/87/6d71456eabebf614e0cac4387c27116a0bff9decf00a70c362fe7db9394e/yarl-1.9.11.tar.gz" - }, - { - "algorithm": "sha256", - "hash": "e4a8c3dedd081cca134a21179aebe58b6e426e8d1e0202da9d1cafa56e01af3c", - "url": "https://files.pythonhosted.org/packages/2c/b5/a2ca969c82583fc7d2073d3f6461f67c0e7fc8cd4aec5175c8cc7847eab4/yarl-1.9.11-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "0b2a8e5eb18181060197e3d5db7e78f818432725c0759bc1e5a9d603d9246389", - "url": "https://files.pythonhosted.org/packages/33/49/0f3d021ca989640d173495846a6832eb124e53a2ce4ed64b9036a4e1683c/yarl-1.9.11-cp312-cp312-musllinux_1_2_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "2d1c81c3b92bef0c1c180048e43a5a85754a61b4f69d6f84df8e4bd615bef25d", - "url": "https://files.pythonhosted.org/packages/39/da/ab9ee8f9de9cae329b4a3f3c115acd18138cca1a2fb78ec10c20f9f114b5/yarl-1.9.11-cp312-cp312-musllinux_1_2_s390x.whl" - }, - { - "algorithm": "sha256", - "hash": "63a5dc2866791236779d99d7a422611d22bb3a3d50935bafa4e017ea13e51469", - "url": "https://files.pythonhosted.org/packages/67/9e/86f55c8f70868203ab9cdb168e1821a64a13d9a0e35e5e077152c121b534/yarl-1.9.11-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl" - }, - { - "algorithm": "sha256", - "hash": "c335342d482e66254ae94b1231b1532790afb754f89e2e0c646f7f19d09740aa", - "url": "https://files.pythonhosted.org/packages/77/d1/eb10e0ce4f91cc82e19a775341b5d8b06e249f6decbd24267d9009c68a2a/yarl-1.9.11-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl" - }, - { - "algorithm": "sha256", - "hash": "5c23f6dc3d7126b4c64b80aa186ac2bb65ab104a8372c4454e462fb074197bc6", - "url": "https://files.pythonhosted.org/packages/7c/80/e027f7c1f51a6eb178657937cceffb175716d18929f054982debb5db9101/yarl-1.9.11-cp312-cp312-macosx_11_0_arm64.whl" - }, - { - "algorithm": "sha256", - "hash": "b8f847cc092c2b85d22e527f91ea83a6cf51533e727e2461557a47a859f96734", - "url": "https://files.pythonhosted.org/packages/88/aa/ffea918291c455305475b7850b2cf970f5a80e6dfbcde9b94a5eacdfe8ec/yarl-1.9.11-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl" - }, - { - "algorithm": "sha256", - "hash": "ff64f575d71eacb5a4d6f0696bfe991993d979423ea2241f23ab19ff63f0f9d1", - "url": "https://files.pythonhosted.org/packages/8c/fc/20e7083cc89e5856d59483692e41d623bd9bd1c158d2fb543ee3f6c05535/yarl-1.9.11-cp312-cp312-macosx_10_9_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "735b285ea46ca7e86ad261a462a071d0968aade44e1a3ea2b7d4f3d63b5aab12", - "url": "https://files.pythonhosted.org/packages/91/dc/f389be705187434423ad70bae78a55243fb16a07e4b80d8d97c5fb821fe0/yarl-1.9.11-cp312-cp312-musllinux_1_2_ppc64le.whl" - }, - { - "algorithm": "sha256", - "hash": "614fa50fd0db41b79f426939a413d216cdc7bab8d8c8a25844798d286a999c5a", - "url": "https://files.pythonhosted.org/packages/ba/ce/cb879750a618b977bc2dd57dae79f7173626a35294a2911c3749f5618f93/yarl-1.9.11-cp312-cp312-macosx_10_9_universal2.whl" - }, - { - "algorithm": "sha256", - "hash": "8d6e1c1562b53bd26efd38e886fc13863b8d904d559426777990171020c478a9", - "url": "https://files.pythonhosted.org/packages/c9/42/cad7ffe2469282b91b84ebc8cfc79bfbd0c7cce182fa0da445d6980c25dc/yarl-1.9.11-cp312-cp312-musllinux_1_2_x86_64.whl" - }, - { - "algorithm": "sha256", - "hash": "504d19320c92532cabc3495fb7ed6bb599f3c2bfb45fed432049bf4693dbd6d0", - "url": "https://files.pythonhosted.org/packages/e4/92/724d7eb7b8dca0ae97a9054ba41742e6599d4c94e1e090e29ae3d54aaf7c/yarl-1.9.11-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl" - } - ], - "project_name": "yarl", - "requires_dists": [ - "idna>=2.0", - "multidict>=4.0" - ], - "requires_python": ">=3.8", - "version": "1.9.11" - } - ], - "platform_tag": null - } - ], - "path_mappings": {}, - "pex_version": "2.1.148", - "pip_version": "23.2", - "prefer_older_binary": false, - "requirements": [ - "aiohttp<3.11.0,>=3.8.6", - "awscrt<1.0,>=0.15", - "bandit<1.8.0", - "black<=24.8.0", - "docformatter<1.7.6", - "flake8<=7.1.1", - "freezegun<1.6.0", - "ijson==3.2.3", - "isort<5.14.0", - "pyright==1.1.379", - "pytest-asyncio<0.25.0", - "pytest-cov<=5.0.0", - "pytest<=8.3.2", - "pyupgrade<3.18.0" - ], - "requires_python": [ - ">=3.12" - ], - "resolver_version": "pip-2020-resolver", - "style": "universal", - "target_systems": [ - "linux", - "mac" - ], - "transitive": true, - "use_pep517": null -} diff --git a/python-packages/aws-event-stream/BUILD b/python-packages/aws-event-stream/BUILD deleted file mode 100644 index a0ad1e14f..000000000 --- a/python-packages/aws-event-stream/BUILD +++ /dev/null @@ -1,28 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 - -resource(name="pyproject", source="pyproject.toml") -resource(name="readme", source="README.md") -resource(name="notice", source="NOTICE") - -python_distribution( - name="dist", - dependencies=[ - ":pyproject", - ":readme", - ":notice", - "python-packages/aws-event-stream/aws_event_stream:source", - ], - provides=python_artifact( - name="aws_event_stream", - version="0.0.1", - ), -) - -# We shouldn't need this, but pants will assume that smithy_core is an external -# dependency since it's in pyproject.toml and there's no way to exclude it, so -# for now we need to duplicate things. -python_requirements( - name="requirements", - source="requirements.txt", -) diff --git a/python-packages/aws-event-stream/MANIFEST.in b/python-packages/aws-event-stream/MANIFEST.in deleted file mode 100644 index bcd0f28ac..000000000 --- a/python-packages/aws-event-stream/MANIFEST.in +++ /dev/null @@ -1 +0,0 @@ -include aws_event_stream/py.typed diff --git a/python-packages/aws-event-stream/pyproject.toml b/python-packages/aws-event-stream/pyproject.toml deleted file mode 100644 index 37a651614..000000000 --- a/python-packages/aws-event-stream/pyproject.toml +++ /dev/null @@ -1,50 +0,0 @@ -[build-system] -requires = ["setuptools", "setuptools-scm", "wheel"] -build-backend = "setuptools.build_meta" - -[project] -name = "aws_event_stream" -version = "0.0.1" -description = "AWS event stream library for Smithy defined services in Python." -readme = "README.md" -authors = [{name = "Amazon Web Services"}] -keywords = ["aws", "python", "sdk", "amazon", "smithy", "codegen", "http"] -requires-python = ">=3.12" -license = {text = "Apache License 2.0"} -classifiers = [ - "Development Status :: 2 - Pre-Alpha", - "Intended Audience :: Developers", - "Intended Audience :: System Administrators", - "Natural Language :: English", - "License :: OSI Approved :: Apache Software License", - "Operating System :: OS Independent", - "Programming Language :: Python", - "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.12", - "Programming Language :: Python :: Implementation :: CPython", - "Topic :: Software Development :: Libraries" -] -dependencies=[ - "smithy_core==0.0.1", - "smithy_event_stream==0.0.1", -] - -[project.urls] -source = "https://github.com/awslabs/smithy-python/tree/develop/python-packages/aws-event-stream" -changelog = "https://github.com/awslabs/smithy-python/blob/develop/CHANGES.md" - -[tool.setuptools] -license-files = ["NOTICE"] -include-package-data = true - -[tool.setuptools.packages.find] -exclude=["tests*", "codegen", "designs"] - -[tool.isort] -profile = "black" -honor_noqa = true -src_paths = ["aws_event_stream", "tests"] - -[tool.pytest.ini_options] -asyncio_mode = "auto" diff --git a/python-packages/aws-event-stream/requirements.txt b/python-packages/aws-event-stream/requirements.txt deleted file mode 100644 index baedc420a..000000000 --- a/python-packages/aws-event-stream/requirements.txt +++ /dev/null @@ -1,3 +0,0 @@ -# We shouldn't need this, but pants will assume that smithy_core is an external -# dependency since it's in pyproject.toml and there's no way to exclude it, so -# for now we need to duplicate things. diff --git a/python-packages/aws-event-stream/tests/BUILD b/python-packages/aws-event-stream/tests/BUILD deleted file mode 100644 index b80471f73..000000000 --- a/python-packages/aws-event-stream/tests/BUILD +++ /dev/null @@ -1,20 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 - -python_test_utils( - name="test_utils", - sources=[ - "**/conftest.py", # pytest's conftest.py file - ], -) - -resource(name="pytyped", source="py.typed") - -python_tests( - name="tests", - dependencies=[":test_utils", ":pytyped"], - sources=[ - "**/test_*.py", - "**/tests.py", - ], -) diff --git a/python-packages/smithy-aws-core/BUILD b/python-packages/smithy-aws-core/BUILD deleted file mode 100644 index 28ddf85f4..000000000 --- a/python-packages/smithy-aws-core/BUILD +++ /dev/null @@ -1,18 +0,0 @@ -resource(name="pyproject", source="pyproject.toml") -resource(name="readme", source="README.md") -resource(name="notice", source="NOTICE") - -python_distribution( - name="dist", - dependencies=[ - ":pyproject", - ":readme", - ":notice", - "python-packages/smithy-aws-core/smithy_aws_core:source", - "python-packages/smithy-core:dist", - ], - provides=python_artifact( - name="smithy_aws_core", - version="0.0.1", - ), -) diff --git a/python-packages/smithy-aws-core/MANIFEST.in b/python-packages/smithy-aws-core/MANIFEST.in deleted file mode 100644 index dd024fbac..000000000 --- a/python-packages/smithy-aws-core/MANIFEST.in +++ /dev/null @@ -1 +0,0 @@ -include smithy_aws_core/py.typed diff --git a/python-packages/smithy-aws-core/pyproject.toml b/python-packages/smithy-aws-core/pyproject.toml deleted file mode 100644 index 48dd5170e..000000000 --- a/python-packages/smithy-aws-core/pyproject.toml +++ /dev/null @@ -1,46 +0,0 @@ -[build-system] -requires = ["setuptools", "setuptools-scm", "wheel"] -build-backend = "setuptools.build_meta" - -[project] -name = "smithy_aws_core" -version = "0.0.1" -description = "Core libraries for Smithy defined AWS services in Python." -readme = "README.md" -authors = [{name = "Amazon Web Services"}] -keywords = ["aws", "python", "sdk", "amazon", "smithy", "codegen"] -requires-python = ">=3.12" -license = {text = "Apache License 2.0"} -classifiers = [ - "Development Status :: 2 - Pre-Alpha", - "Intended Audience :: Developers", - "Intended Audience :: System Administrators", - "Natural Language :: English", - "License :: OSI Approved :: Apache Software License", - "Operating System :: OS Independent", - "Programming Language :: Python", - "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.12", - "Programming Language :: Python :: Implementation :: CPython", - "Topic :: Software Development :: Libraries" -] -dependencies = [ - "smithy_core==0.0.1" -] - -[project.urls] -source = "https://github.com/awslabs/smithy-python/tree/develop/python-packages/smithy-aws-core" -changelog = "https://github.com/awslabs/smithy-python/blob/develop/CHANGES.md" - -[tool.setuptools] -license-files = ["NOTICE"] -include-package-data = true - -[tool.setuptools.packages.find] -exclude=["tests*", "codegen", "designs"] - -[tool.isort] -profile = "black" -honor_noqa = true -src_paths = ["smithy_aws_core", "tests"] diff --git a/python-packages/smithy-aws-core/requirements-dev.txt b/python-packages/smithy-aws-core/requirements-dev.txt deleted file mode 100644 index e69de29bb..000000000 diff --git a/python-packages/smithy-aws-core/tests/__init__.py b/python-packages/smithy-aws-core/tests/__init__.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/python-packages/smithy-aws-core/tests/functional/__init__.py b/python-packages/smithy-aws-core/tests/functional/__init__.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/python-packages/smithy-aws-core/tests/integration/__init__.py b/python-packages/smithy-aws-core/tests/integration/__init__.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/python-packages/smithy-aws-core/tests/unit/BUILD b/python-packages/smithy-aws-core/tests/unit/BUILD deleted file mode 100644 index 57341b135..000000000 --- a/python-packages/smithy-aws-core/tests/unit/BUILD +++ /dev/null @@ -1,3 +0,0 @@ -python_tests( - name="tests", -) diff --git a/python-packages/smithy-aws-core/tests/unit/__init__.py b/python-packages/smithy-aws-core/tests/unit/__init__.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/python-packages/smithy-core/BUILD b/python-packages/smithy-core/BUILD deleted file mode 100644 index 11c39706e..000000000 --- a/python-packages/smithy-core/BUILD +++ /dev/null @@ -1,20 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 - -resource(name="pyproject", source="pyproject.toml") -resource(name="readme", source="README.md") -resource(name="notice", source="NOTICE") - -python_distribution( - name="dist", - dependencies=[ - ":pyproject", - ":readme", - ":notice", - "python-packages/smithy-core/smithy_core:source", - ], - provides=python_artifact( - name="smithy_core", - version="0.0.1", - ), -) diff --git a/python-packages/smithy-core/MANIFEST.in b/python-packages/smithy-core/MANIFEST.in deleted file mode 100644 index f8c7a4991..000000000 --- a/python-packages/smithy-core/MANIFEST.in +++ /dev/null @@ -1 +0,0 @@ -include smithy_core/py.typed diff --git a/python-packages/smithy-core/pyproject.toml b/python-packages/smithy-core/pyproject.toml deleted file mode 100644 index 1de37fe62..000000000 --- a/python-packages/smithy-core/pyproject.toml +++ /dev/null @@ -1,47 +0,0 @@ -[build-system] -requires = ["setuptools", "setuptools-scm", "wheel"] -build-backend = "setuptools.build_meta" - -[project] -name = "smithy_core" -version = "0.0.1" -description = "Core library for Smithy defined services in Python." -readme = "README.md" -authors = [{name = "Amazon Web Services"}] -keywords = ["aws", "python", "sdk", "amazon", "smithy", "codegen"] -requires-python = ">=3.12" -license = {text = "Apache License 2.0"} -classifiers = [ - "Development Status :: 2 - Pre-Alpha", - "Intended Audience :: Developers", - "Intended Audience :: System Administrators", - "Natural Language :: English", - "License :: OSI Approved :: Apache Software License", - "Operating System :: OS Independent", - "Programming Language :: Python", - "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.12", - "Programming Language :: Python :: Implementation :: CPython", - "Topic :: Software Development :: Libraries" -] -dependencies = [] - -[project.urls] -source = "https://github.com/awslabs/smithy-python/tree/develop/python-packages/smithy-core" -changelog = "https://github.com/awslabs/smithy-python/blob/develop/CHANGES.md" - -[tool.setuptools] -license-files = ["NOTICE"] -include-package-data = true - -[tool.setuptools.packages.find] -exclude=["tests*", "codegen", "designs"] - -[tool.isort] -profile = "black" -honor_noqa = true -src_paths = ["smithy_core", "tests"] - -[tool.pytest.ini_options] -asyncio_mode = "auto" diff --git a/python-packages/smithy-core/smithy_core/BUILD b/python-packages/smithy-core/smithy_core/BUILD deleted file mode 100644 index ecd6a7749..000000000 --- a/python-packages/smithy-core/smithy_core/BUILD +++ /dev/null @@ -1,10 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 - -resource(name="pytyped", source="py.typed") - -python_sources( - name="source", - dependencies=[":pytyped"], - sources=["**/*.py"], -) diff --git a/python-packages/smithy-core/tests/BUILD b/python-packages/smithy-core/tests/BUILD deleted file mode 100644 index b80471f73..000000000 --- a/python-packages/smithy-core/tests/BUILD +++ /dev/null @@ -1,20 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 - -python_test_utils( - name="test_utils", - sources=[ - "**/conftest.py", # pytest's conftest.py file - ], -) - -resource(name="pytyped", source="py.typed") - -python_tests( - name="tests", - dependencies=[":test_utils", ":pytyped"], - sources=[ - "**/test_*.py", - "**/tests.py", - ], -) diff --git a/python-packages/smithy-event-stream/BUILD b/python-packages/smithy-event-stream/BUILD deleted file mode 100644 index 6e1e52be1..000000000 --- a/python-packages/smithy-event-stream/BUILD +++ /dev/null @@ -1,29 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 - -resource(name="pyproject", source="pyproject.toml") -resource(name="readme", source="README.md") -resource(name="notice", source="NOTICE") - -python_distribution( - name="dist", - dependencies=[ - ":pyproject", - ":readme", - ":notice", - "python-packages/smithy-event-stream/smithy_event_stream:source", - "python-packages/smithy-core:dist", - ], - provides=python_artifact( - name="smithy_event_stream", - version="0.0.1", - ), -) - -# We shouldn't need this, but pants will assume that smithy_core is an external -# dependency since it's in pyproject.toml and there's no way to exclude it, so -# for now we need to duplicate things. -python_requirements( - name="requirements", - source="requirements.txt", -) diff --git a/python-packages/smithy-event-stream/MANIFEST.in b/python-packages/smithy-event-stream/MANIFEST.in deleted file mode 100644 index 522dbb500..000000000 --- a/python-packages/smithy-event-stream/MANIFEST.in +++ /dev/null @@ -1 +0,0 @@ -include smithy_event_stream/py.typed diff --git a/python-packages/smithy-event-stream/pyproject.toml b/python-packages/smithy-event-stream/pyproject.toml deleted file mode 100644 index d0b25973e..000000000 --- a/python-packages/smithy-event-stream/pyproject.toml +++ /dev/null @@ -1,49 +0,0 @@ -[build-system] -requires = ["setuptools", "setuptools-scm", "wheel"] -build-backend = "setuptools.build_meta" - -[project] -name = "smithy_event_stream" -version = "0.0.1" -description = "Core event stream library for Smithy defined services in Python." -readme = "README.md" -authors = [{name = "Amazon Web Services"}] -keywords = ["aws", "python", "sdk", "amazon", "smithy", "codegen", "http"] -requires-python = ">=3.12" -license = {text = "Apache License 2.0"} -classifiers = [ - "Development Status :: 2 - Pre-Alpha", - "Intended Audience :: Developers", - "Intended Audience :: System Administrators", - "Natural Language :: English", - "License :: OSI Approved :: Apache Software License", - "Operating System :: OS Independent", - "Programming Language :: Python", - "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.12", - "Programming Language :: Python :: Implementation :: CPython", - "Topic :: Software Development :: Libraries" -] -dependencies = [ - "smithy_core==0.0.1" -] - -[project.urls] -source = "https://github.com/awslabs/smithy-python/tree/develop/python-packages/smithy-event-stream" -changelog = "https://github.com/awslabs/smithy-python/blob/develop/CHANGES.md" - -[tool.setuptools] -license-files = ["NOTICE"] -include-package-data = true - -[tool.setuptools.packages.find] -exclude=["tests*", "codegen", "designs"] - -[tool.isort] -profile = "black" -honor_noqa = true -src_paths = ["smithy_event_stream", "tests"] - -[tool.pytest.ini_options] -asyncio_mode = "auto" diff --git a/python-packages/smithy-event-stream/requirements.txt b/python-packages/smithy-event-stream/requirements.txt deleted file mode 100644 index baedc420a..000000000 --- a/python-packages/smithy-event-stream/requirements.txt +++ /dev/null @@ -1,3 +0,0 @@ -# We shouldn't need this, but pants will assume that smithy_core is an external -# dependency since it's in pyproject.toml and there's no way to exclude it, so -# for now we need to duplicate things. diff --git a/python-packages/smithy-event-stream/smithy_event_stream/aio/__init__.py b/python-packages/smithy-event-stream/smithy_event_stream/aio/__init__.py deleted file mode 100644 index 04f8b7b76..000000000 --- a/python-packages/smithy-event-stream/smithy_event_stream/aio/__init__.py +++ /dev/null @@ -1,2 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 diff --git a/python-packages/smithy-event-stream/tests/BUILD b/python-packages/smithy-event-stream/tests/BUILD deleted file mode 100644 index b80471f73..000000000 --- a/python-packages/smithy-event-stream/tests/BUILD +++ /dev/null @@ -1,20 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 - -python_test_utils( - name="test_utils", - sources=[ - "**/conftest.py", # pytest's conftest.py file - ], -) - -resource(name="pytyped", source="py.typed") - -python_tests( - name="tests", - dependencies=[":test_utils", ":pytyped"], - sources=[ - "**/test_*.py", - "**/tests.py", - ], -) diff --git a/python-packages/smithy-event-stream/tests/__init__.py b/python-packages/smithy-event-stream/tests/__init__.py deleted file mode 100644 index 04f8b7b76..000000000 --- a/python-packages/smithy-event-stream/tests/__init__.py +++ /dev/null @@ -1,2 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 diff --git a/python-packages/smithy-event-stream/tests/unit/__init__.py b/python-packages/smithy-event-stream/tests/unit/__init__.py deleted file mode 100644 index 04f8b7b76..000000000 --- a/python-packages/smithy-event-stream/tests/unit/__init__.py +++ /dev/null @@ -1,2 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 diff --git a/python-packages/smithy-http/BUILD b/python-packages/smithy-http/BUILD deleted file mode 100644 index 51317e26d..000000000 --- a/python-packages/smithy-http/BUILD +++ /dev/null @@ -1,26 +0,0 @@ -resource(name="pyproject", source="pyproject.toml") -resource(name="readme", source="README.md") -resource(name="notice", source="NOTICE") - -python_distribution( - name="dist", - dependencies=[ - ":pyproject", - ":readme", - ":notice", - "python-packages/smithy-http/smithy_http:source", - "python-packages/smithy-core:dist", - ], - provides=python_artifact( - name="smithy_http", - version="0.0.1", - ), -) - -# We shouldn't need this, but pants will assume that smithy_core is an external -# dependency since it's in pyproject.toml and there's no way to exclude it, so -# for now we need to duplicate things. -python_requirements( - name="requirements", - source="requirements.txt", -) diff --git a/python-packages/smithy-http/MANIFEST.in b/python-packages/smithy-http/MANIFEST.in deleted file mode 100644 index 7bee3d68b..000000000 --- a/python-packages/smithy-http/MANIFEST.in +++ /dev/null @@ -1 +0,0 @@ -include smithy_http/py.typed diff --git a/python-packages/smithy-http/pyproject.toml b/python-packages/smithy-http/pyproject.toml deleted file mode 100644 index 524a79ffe..000000000 --- a/python-packages/smithy-http/pyproject.toml +++ /dev/null @@ -1,57 +0,0 @@ -[build-system] -requires = ["setuptools", "setuptools-scm", "wheel"] -build-backend = "setuptools.build_meta" - -[project] -name = "smithy_http" -version = "0.0.1" -description = "Core HTTP library for Smithy defined services in Python." -readme = "README.md" -authors = [{name = "Amazon Web Services"}] -keywords = ["aws", "python", "sdk", "amazon", "smithy", "codegen", "http"] -requires-python = ">=3.12" -license = {text = "Apache License 2.0"} -classifiers = [ - "Development Status :: 2 - Pre-Alpha", - "Intended Audience :: Developers", - "Intended Audience :: System Administrators", - "Natural Language :: English", - "License :: OSI Approved :: Apache Software License", - "Operating System :: OS Independent", - "Programming Language :: Python", - "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.12", - "Programming Language :: Python :: Implementation :: CPython", - "Topic :: Software Development :: Libraries" -] -dependencies = [ - "smithy_core==0.0.1" -] - -[project.optional-dependencies] -aiohttp = [ - "aiohttp>=3.8.6,<3.11.0", -] -awscrt = [ - "awscrt>=0.15,<1.0", -] - -[project.urls] -source = "https://github.com/awslabs/smithy-python/tree/develop/python-packages/smithy-http" -changelog = "https://github.com/awslabs/smithy-python/blob/develop/CHANGES.md" - -[tool.setuptools] -license-files = ["NOTICE"] -include-package-data = true - -[tool.setuptools.packages.find] -exclude=["tests*", "codegen", "designs"] - -[tool.isort] -profile = "black" -honor_noqa = true -src_paths = ["smithy_http", "tests"] - -[tool.pytest.ini_options] -asyncio_mode = "auto" diff --git a/python-packages/smithy-http/requirements.txt b/python-packages/smithy-http/requirements.txt deleted file mode 100644 index c66840dce..000000000 --- a/python-packages/smithy-http/requirements.txt +++ /dev/null @@ -1,5 +0,0 @@ -# We shouldn't need this, but pants will assume that smithy_core is an external -# dependency since it's in pyproject.toml and there's no way to exclude it, so -# for now we need to duplicate things. -aiohttp>=3.8.6,<3.11.0 -awscrt>=0.15,<1.0 diff --git a/python-packages/smithy-http/smithy_http/BUILD b/python-packages/smithy-http/smithy_http/BUILD deleted file mode 100644 index 9666c1f4b..000000000 --- a/python-packages/smithy-http/smithy_http/BUILD +++ /dev/null @@ -1,13 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 - -resource(name="pytyped", source="py.typed") - -python_sources( - name="source", - dependencies=[ - ":pytyped", - "python-packages/smithy-http:requirements", - ], - sources=["**/*.py"], -) diff --git a/python-packages/smithy-http/smithy_http/aio/identity/__init__.py b/python-packages/smithy-http/smithy_http/aio/identity/__init__.py deleted file mode 100644 index 33cbe867a..000000000 --- a/python-packages/smithy-http/smithy_http/aio/identity/__init__.py +++ /dev/null @@ -1,2 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 diff --git a/python-packages/smithy-http/tests/BUILD b/python-packages/smithy-http/tests/BUILD deleted file mode 100644 index d9fd5df17..000000000 --- a/python-packages/smithy-http/tests/BUILD +++ /dev/null @@ -1,30 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# -# Licensed under the Apache License, Version 2.0 (the "License"). You -# may not use this file except in compliance with the License. A copy of -# the License is located at -# -# http://aws.amazon.com/apache2.0/ -# -# or in the "license" file accompanying this file. This file is -# distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF -# ANY KIND, either express or implied. See the License for the specific -# language governing permissions and limitations under the License. - -python_test_utils( - name="test_utils", - sources=[ - "**/conftest.py", # pytest's conftest.py file - ], -) - -resource(name="pytyped", source="py.typed") - -python_tests( - name="tests", - dependencies=[":test_utils", ":pytyped"], - sources=[ - "**/test_*.py", - "**/tests.py", - ], -) diff --git a/python-packages/smithy-http/tests/__init__.py b/python-packages/smithy-http/tests/__init__.py deleted file mode 100644 index 04f8b7b76..000000000 --- a/python-packages/smithy-http/tests/__init__.py +++ /dev/null @@ -1,2 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 diff --git a/python-packages/smithy-http/tests/integration/__init__.py b/python-packages/smithy-http/tests/integration/__init__.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/python-packages/smithy-http/tests/integration/aio/__init__.py b/python-packages/smithy-http/tests/integration/aio/__init__.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/python-packages/smithy-http/tests/unit/__init__.py b/python-packages/smithy-http/tests/unit/__init__.py deleted file mode 100644 index 04f8b7b76..000000000 --- a/python-packages/smithy-http/tests/unit/__init__.py +++ /dev/null @@ -1,2 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 diff --git a/python-packages/smithy-http/tests/unit/aio/__init__.py b/python-packages/smithy-http/tests/unit/aio/__init__.py deleted file mode 100644 index 33cbe867a..000000000 --- a/python-packages/smithy-http/tests/unit/aio/__init__.py +++ /dev/null @@ -1,2 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 diff --git a/python-packages/smithy-http/tests/unit/aio/auth/__init__.py b/python-packages/smithy-http/tests/unit/aio/auth/__init__.py deleted file mode 100644 index 33cbe867a..000000000 --- a/python-packages/smithy-http/tests/unit/aio/auth/__init__.py +++ /dev/null @@ -1,2 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 diff --git a/python-packages/smithy-http/tests/unit/aio/identity/__init__.py b/python-packages/smithy-http/tests/unit/aio/identity/__init__.py deleted file mode 100644 index 33cbe867a..000000000 --- a/python-packages/smithy-http/tests/unit/aio/identity/__init__.py +++ /dev/null @@ -1,2 +0,0 @@ -# Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. -# SPDX-License-Identifier: Apache-2.0 diff --git a/python-packages/smithy-json/BUILD b/python-packages/smithy-json/BUILD deleted file mode 100644 index 2e599c22a..000000000 --- a/python-packages/smithy-json/BUILD +++ /dev/null @@ -1,26 +0,0 @@ -resource(name="pyproject", source="pyproject.toml") -resource(name="readme", source="README.md") -resource(name="notice", source="NOTICE") - -python_distribution( - name="dist", - dependencies=[ - ":pyproject", - ":readme", - ":notice", - "python-packages/smithy-json/smithy_json:source", - "python-packages/smithy-core:dist", - ], - provides=python_artifact( - name="smithy_json", - version="0.0.1", - ), -) - -# We shouldn't need this, but pants will assume that smithy_core is an external -# dependency since it's in pyproject.toml and there's no way to exclude it, so -# for now we need to duplicate things. -python_requirements( - name="requirements", - source="requirements.txt", -) diff --git a/python-packages/smithy-json/MANIFEST.in b/python-packages/smithy-json/MANIFEST.in deleted file mode 100644 index f6a4386f4..000000000 --- a/python-packages/smithy-json/MANIFEST.in +++ /dev/null @@ -1 +0,0 @@ -include smithy_json/py.typed diff --git a/python-packages/smithy-json/pyproject.toml b/python-packages/smithy-json/pyproject.toml deleted file mode 100644 index bb8a81373..000000000 --- a/python-packages/smithy-json/pyproject.toml +++ /dev/null @@ -1,47 +0,0 @@ -[build-system] -requires = ["setuptools", "setuptools-scm", "wheel"] -build-backend = "setuptools.build_meta" - -[project] -name = "smithy_json" -version = "0.0.1" -description = "JSON serialization and deserialization for Smithy clients." -readme = "README.md" -authors = [{name = "Amazon Web Services"}] -keywords = ["aws", "python", "sdk", "amazon", "smithy", "codegen", "json"] -requires-python = ">=3.12" -license = {text = "Apache License 2.0"} -classifiers = [ - "Development Status :: 2 - Pre-Alpha", - "Intended Audience :: Developers", - "Intended Audience :: System Administrators", - "Natural Language :: English", - "License :: OSI Approved :: Apache Software License", - "Operating System :: OS Independent", - "Programming Language :: Python", - "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3", - "Programming Language :: Python :: 3.12", - "Programming Language :: Python :: Implementation :: CPython", - "Topic :: Software Development :: Libraries" -] -dependencies = [ - "smithy_core==0.0.1", - "ijson==3.2.3", -] - -[project.urls] -source = "https://github.com/awslabs/smithy-python/tree/develop/python-packages/smithy-json" -changelog = "https://github.com/awslabs/smithy-python/blob/develop/CHANGES.md" - -[tool.setuptools] -license-files = ["NOTICE"] -include-package-data = true - -[tool.setuptools.packages.find] -exclude=["tests*", "codegen", "designs"] - -[tool.isort] -profile = "black" -honor_noqa = true -src_paths = ["smithy_json", "tests"] diff --git a/python-packages/smithy-json/requirements.txt b/python-packages/smithy-json/requirements.txt deleted file mode 100644 index bfe07e425..000000000 --- a/python-packages/smithy-json/requirements.txt +++ /dev/null @@ -1,4 +0,0 @@ -# We shouldn't need this, but pants will assume that smithy_core is an external -# dependency since it's in pyproject.toml and there's no way to exclude it, so -# for now we need to duplicate things. -ijson==3.2.3 diff --git a/python-packages/smithy-json/smithy_json/BUILD b/python-packages/smithy-json/smithy_json/BUILD deleted file mode 100644 index e8723ee52..000000000 --- a/python-packages/smithy-json/smithy_json/BUILD +++ /dev/null @@ -1,7 +0,0 @@ -resource(name="pytyped", source="py.typed") - -python_sources( - name="source", - dependencies=[":pytyped"], - sources=["**/*.py"], -) diff --git a/python-packages/smithy-json/tests/__init__.py b/python-packages/smithy-json/tests/__init__.py deleted file mode 100644 index e69de29bb..000000000 diff --git a/python-packages/smithy-json/tests/unit/BUILD b/python-packages/smithy-json/tests/unit/BUILD deleted file mode 100644 index ce941904a..000000000 --- a/python-packages/smithy-json/tests/unit/BUILD +++ /dev/null @@ -1,14 +0,0 @@ -python_test_utils( - name="test_utils", - sources=[ - "**/__init__.py", - ], -) - -python_tests( - name="tests", - dependencies=[":test_utils"], - sources=[ - "**/test_*.py", - ], -) diff --git a/requirements-dev.txt b/requirements-dev.txt deleted file mode 100644 index b2df40065..000000000 --- a/requirements-dev.txt +++ /dev/null @@ -1,11 +0,0 @@ -black<=25.1.0 -flake8<=7.1.2 -pyright==1.1.394 -pytest<=8.3.4 -pytest-asyncio<0.26.0 -pytest-cov<=6.0.0 -freezegun<1.6.0 -pyupgrade<3.20.0 -isort<6.1.0 -docformatter<1.7.6 -bandit<1.9.0 diff --git a/scripts/pantsw b/scripts/pantsw deleted file mode 100755 index f83fe2544..000000000 --- a/scripts/pantsw +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/sh - -# This is a wrapper script that verifies that pants is installed on the path, and calls it. This script is used as -# part of the Makefile to wrap non-local installations of pants in a way that's ergonomic to `make`. - -if ! command -v "pants" > /dev/null; then - echo "'pants' is not on the PATH, something may have gone wrong." -else - pants "$@" -fi diff --git a/setup.cfg b/setup.cfg deleted file mode 100644 index 97a6bfede..000000000 --- a/setup.cfg +++ /dev/null @@ -1,9 +0,0 @@ -# NOTE: changes in this file likely should be reflected in the setup.cfg that -# is copied into generated code. -[metadata] -requires_dist = - # TODO - -[flake8] -# We ignore E203, E501 for this project due to black -ignore = E203,E501,E704 diff --git a/uv.lock b/uv.lock new file mode 100644 index 000000000..e204ab079 --- /dev/null +++ b/uv.lock @@ -0,0 +1,765 @@ +version = 1 +revision = 1 +requires-python = ">=3.12" + +[manifest] +members = [ + "aws-event-stream", + "smithy-aws-core", + "smithy-core", + "smithy-event-stream", + "smithy-http", + "smithy-json", + "smithy-python", +] + +[[package]] +name = "aiohappyeyeballs" +version = "2.4.6" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/08/07/508f9ebba367fc3370162e53a3cfd12f5652ad79f0e0bfdf9f9847c6f159/aiohappyeyeballs-2.4.6.tar.gz", hash = "sha256:9b05052f9042985d32ecbe4b59a77ae19c006a78f1344d7fdad69d28ded3d0b0", size = 21726 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/44/4c/03fb05f56551828ec67ceb3665e5dc51638042d204983a03b0a1541475b6/aiohappyeyeballs-2.4.6-py3-none-any.whl", hash = "sha256:147ec992cf873d74f5062644332c539fcd42956dc69453fe5204195e560517e1", size = 14543 }, +] + +[[package]] +name = "aiohttp" +version = "3.11.12" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "aiohappyeyeballs" }, + { name = "aiosignal" }, + { name = "attrs" }, + { name = "frozenlist" }, + { name = "multidict" }, + { name = "propcache" }, + { name = "yarl" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/37/4b/952d49c73084fb790cb5c6ead50848c8e96b4980ad806cf4d2ad341eaa03/aiohttp-3.11.12.tar.gz", hash = "sha256:7603ca26d75b1b86160ce1bbe2787a0b706e592af5b2504e12caa88a217767b0", size = 7673175 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/4d/d0/94346961acb476569fca9a644cc6f9a02f97ef75961a6b8d2b35279b8d1f/aiohttp-3.11.12-cp312-cp312-macosx_10_13_universal2.whl", hash = "sha256:e392804a38353900c3fd8b7cacbea5132888f7129f8e241915e90b85f00e3250", size = 704837 }, + { url = "https://files.pythonhosted.org/packages/a9/af/05c503f1cc8f97621f199ef4b8db65fb88b8bc74a26ab2adb74789507ad3/aiohttp-3.11.12-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:8fa1510b96c08aaad49303ab11f8803787c99222288f310a62f493faf883ede1", size = 464218 }, + { url = "https://files.pythonhosted.org/packages/f2/48/b9949eb645b9bd699153a2ec48751b985e352ab3fed9d98c8115de305508/aiohttp-3.11.12-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:dc065a4285307607df3f3686363e7f8bdd0d8ab35f12226362a847731516e42c", size = 456166 }, + { url = "https://files.pythonhosted.org/packages/14/fb/980981807baecb6f54bdd38beb1bd271d9a3a786e19a978871584d026dcf/aiohttp-3.11.12-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:cddb31f8474695cd61fc9455c644fc1606c164b93bff2490390d90464b4655df", size = 1682528 }, + { url = "https://files.pythonhosted.org/packages/90/cb/77b1445e0a716914e6197b0698b7a3640590da6c692437920c586764d05b/aiohttp-3.11.12-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:9dec0000d2d8621d8015c293e24589d46fa218637d820894cb7356c77eca3259", size = 1737154 }, + { url = "https://files.pythonhosted.org/packages/ff/24/d6fb1f4cede9ccbe98e4def6f3ed1e1efcb658871bbf29f4863ec646bf38/aiohttp-3.11.12-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:e3552fe98e90fdf5918c04769f338a87fa4f00f3b28830ea9b78b1bdc6140e0d", size = 1793435 }, + { url = "https://files.pythonhosted.org/packages/17/e2/9f744cee0861af673dc271a3351f59ebd5415928e20080ab85be25641471/aiohttp-3.11.12-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6dfe7f984f28a8ae94ff3a7953cd9678550dbd2a1f9bda5dd9c5ae627744c78e", size = 1692010 }, + { url = "https://files.pythonhosted.org/packages/90/c4/4a1235c1df544223eb57ba553ce03bc706bdd065e53918767f7fa1ff99e0/aiohttp-3.11.12-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:a481a574af914b6e84624412666cbfbe531a05667ca197804ecc19c97b8ab1b0", size = 1619481 }, + { url = "https://files.pythonhosted.org/packages/60/70/cf12d402a94a33abda86dd136eb749b14c8eb9fec1e16adc310e25b20033/aiohttp-3.11.12-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:1987770fb4887560363b0e1a9b75aa303e447433c41284d3af2840a2f226d6e0", size = 1641578 }, + { url = "https://files.pythonhosted.org/packages/1b/25/7211973fda1f5e833fcfd98ccb7f9ce4fbfc0074e3e70c0157a751d00db8/aiohttp-3.11.12-cp312-cp312-musllinux_1_2_armv7l.whl", hash = "sha256:a4ac6a0f0f6402854adca4e3259a623f5c82ec3f0c049374133bcb243132baf9", size = 1684463 }, + { url = "https://files.pythonhosted.org/packages/93/60/b5905b4d0693f6018b26afa9f2221fefc0dcbd3773fe2dff1a20fb5727f1/aiohttp-3.11.12-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:c96a43822f1f9f69cc5c3706af33239489a6294be486a0447fb71380070d4d5f", size = 1646691 }, + { url = "https://files.pythonhosted.org/packages/b4/fc/ba1b14d6fdcd38df0b7c04640794b3683e949ea10937c8a58c14d697e93f/aiohttp-3.11.12-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:a5e69046f83c0d3cb8f0d5bd9b8838271b1bc898e01562a04398e160953e8eb9", size = 1702269 }, + { url = "https://files.pythonhosted.org/packages/5e/39/18c13c6f658b2ba9cc1e0c6fb2d02f98fd653ad2addcdf938193d51a9c53/aiohttp-3.11.12-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:68d54234c8d76d8ef74744f9f9fc6324f1508129e23da8883771cdbb5818cbef", size = 1734782 }, + { url = "https://files.pythonhosted.org/packages/9f/d2/ccc190023020e342419b265861877cd8ffb75bec37b7ddd8521dd2c6deb8/aiohttp-3.11.12-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:c9fd9dcf9c91affe71654ef77426f5cf8489305e1c66ed4816f5a21874b094b9", size = 1694740 }, + { url = "https://files.pythonhosted.org/packages/3f/54/186805bcada64ea90ea909311ffedcd74369bfc6e880d39d2473314daa36/aiohttp-3.11.12-cp312-cp312-win32.whl", hash = "sha256:0ed49efcd0dc1611378beadbd97beb5d9ca8fe48579fc04a6ed0844072261b6a", size = 411530 }, + { url = "https://files.pythonhosted.org/packages/3d/63/5eca549d34d141bcd9de50d4e59b913f3641559460c739d5e215693cb54a/aiohttp-3.11.12-cp312-cp312-win_amd64.whl", hash = "sha256:54775858c7f2f214476773ce785a19ee81d1294a6bedc5cc17225355aab74802", size = 437860 }, + { url = "https://files.pythonhosted.org/packages/c3/9b/cea185d4b543ae08ee478373e16653722c19fcda10d2d0646f300ce10791/aiohttp-3.11.12-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:413ad794dccb19453e2b97c2375f2ca3cdf34dc50d18cc2693bd5aed7d16f4b9", size = 698148 }, + { url = "https://files.pythonhosted.org/packages/91/5c/80d47fe7749fde584d1404a68ade29bcd7e58db8fa11fa38e8d90d77e447/aiohttp-3.11.12-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:4a93d28ed4b4b39e6f46fd240896c29b686b75e39cc6992692e3922ff6982b4c", size = 460831 }, + { url = "https://files.pythonhosted.org/packages/8e/f9/de568f8a8ca6b061d157c50272620c53168d6e3eeddae78dbb0f7db981eb/aiohttp-3.11.12-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:d589264dbba3b16e8951b6f145d1e6b883094075283dafcab4cdd564a9e353a0", size = 453122 }, + { url = "https://files.pythonhosted.org/packages/8b/fd/b775970a047543bbc1d0f66725ba72acef788028fce215dc959fd15a8200/aiohttp-3.11.12-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e5148ca8955affdfeb864aca158ecae11030e952b25b3ae15d4e2b5ba299bad2", size = 1665336 }, + { url = "https://files.pythonhosted.org/packages/82/9b/aff01d4f9716245a1b2965f02044e4474fadd2bcfe63cf249ca788541886/aiohttp-3.11.12-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:525410e0790aab036492eeea913858989c4cb070ff373ec3bc322d700bdf47c1", size = 1718111 }, + { url = "https://files.pythonhosted.org/packages/e0/a9/166fd2d8b2cc64f08104aa614fad30eee506b563154081bf88ce729bc665/aiohttp-3.11.12-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:9bd8695be2c80b665ae3f05cb584093a1e59c35ecb7d794d1edd96e8cc9201d7", size = 1775293 }, + { url = "https://files.pythonhosted.org/packages/13/c5/0d3c89bd9e36288f10dc246f42518ce8e1c333f27636ac78df091c86bb4a/aiohttp-3.11.12-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f0203433121484b32646a5f5ea93ae86f3d9559d7243f07e8c0eab5ff8e3f70e", size = 1677338 }, + { url = "https://files.pythonhosted.org/packages/72/b2/017db2833ef537be284f64ead78725984db8a39276c1a9a07c5c7526e238/aiohttp-3.11.12-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:40cd36749a1035c34ba8d8aaf221b91ca3d111532e5ccb5fa8c3703ab1b967ed", size = 1603365 }, + { url = "https://files.pythonhosted.org/packages/fc/72/b66c96a106ec7e791e29988c222141dd1219d7793ffb01e72245399e08d2/aiohttp-3.11.12-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:a7442662afebbf7b4c6d28cb7aab9e9ce3a5df055fc4116cc7228192ad6cb484", size = 1618464 }, + { url = "https://files.pythonhosted.org/packages/3f/50/e68a40f267b46a603bab569d48d57f23508801614e05b3369898c5b2910a/aiohttp-3.11.12-cp313-cp313-musllinux_1_2_armv7l.whl", hash = "sha256:8a2fb742ef378284a50766e985804bd6adb5adb5aa781100b09befdbfa757b65", size = 1657827 }, + { url = "https://files.pythonhosted.org/packages/c5/1d/aafbcdb1773d0ba7c20793ebeedfaba1f3f7462f6fc251f24983ed738aa7/aiohttp-3.11.12-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:2cee3b117a8d13ab98b38d5b6bdcd040cfb4181068d05ce0c474ec9db5f3c5bb", size = 1616700 }, + { url = "https://files.pythonhosted.org/packages/b0/5e/6cd9724a2932f36e2a6b742436a36d64784322cfb3406ca773f903bb9a70/aiohttp-3.11.12-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:f6a19bcab7fbd8f8649d6595624856635159a6527861b9cdc3447af288a00c00", size = 1685643 }, + { url = "https://files.pythonhosted.org/packages/8b/38/ea6c91d5c767fd45a18151675a07c710ca018b30aa876a9f35b32fa59761/aiohttp-3.11.12-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:e4cecdb52aaa9994fbed6b81d4568427b6002f0a91c322697a4bfcc2b2363f5a", size = 1715487 }, + { url = "https://files.pythonhosted.org/packages/8e/24/e9edbcb7d1d93c02e055490348df6f955d675e85a028c33babdcaeda0853/aiohttp-3.11.12-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:30f546358dfa0953db92ba620101fefc81574f87b2346556b90b5f3ef16e55ce", size = 1672948 }, + { url = "https://files.pythonhosted.org/packages/25/be/0b1fb737268e003198f25c3a68c2135e76e4754bf399a879b27bd508a003/aiohttp-3.11.12-cp313-cp313-win32.whl", hash = "sha256:ce1bb21fc7d753b5f8a5d5a4bae99566386b15e716ebdb410154c16c91494d7f", size = 410396 }, + { url = "https://files.pythonhosted.org/packages/68/fd/677def96a75057b0a26446b62f8fbb084435b20a7d270c99539c26573bfd/aiohttp-3.11.12-cp313-cp313-win_amd64.whl", hash = "sha256:f7914ab70d2ee8ab91c13e5402122edbc77821c66d2758abb53aabe87f013287", size = 436234 }, +] + +[[package]] +name = "aiosignal" +version = "1.3.2" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "frozenlist" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/ba/b5/6d55e80f6d8a08ce22b982eafa278d823b541c925f11ee774b0b9c43473d/aiosignal-1.3.2.tar.gz", hash = "sha256:a8c255c66fafb1e499c9351d0bf32ff2d8a0321595ebac3b93713656d2436f54", size = 19424 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/ec/6a/bc7e17a3e87a2985d3e8f4da4cd0f481060eb78fb08596c42be62c90a4d9/aiosignal-1.3.2-py2.py3-none-any.whl", hash = "sha256:45cde58e409a301715980c2b01d0c28bdde3770d8290b5eb2173759d9acb31a5", size = 7597 }, +] + +[[package]] +name = "attrs" +version = "25.1.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/49/7c/fdf464bcc51d23881d110abd74b512a42b3d5d376a55a831b44c603ae17f/attrs-25.1.0.tar.gz", hash = "sha256:1c97078a80c814273a76b2a298a932eb681c87415c11dee0a6921de7f1b02c3e", size = 810562 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/fc/30/d4986a882011f9df997a55e6becd864812ccfcd821d64aac8570ee39f719/attrs-25.1.0-py3-none-any.whl", hash = "sha256:c75a69e28a550a7e93789579c22aa26b0f5b83b75dc4e08fe092980051e1090a", size = 63152 }, +] + +[[package]] +name = "aws-event-stream" +version = "0.1.0" +source = { editable = "packages/aws-event-stream" } +dependencies = [ + { name = "smithy-core" }, + { name = "smithy-event-stream" }, +] + +[package.metadata] +requires-dist = [ + { name = "smithy-core", editable = "packages/smithy-core" }, + { name = "smithy-event-stream", editable = "packages/smithy-event-stream" }, +] + +[[package]] +name = "awscrt" +version = "0.23.10" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/33/c3/88ce9e147b6f6ae8c63507129fecf28e3979f0bea9249f1faa9969d7364e/awscrt-0.23.10.tar.gz", hash = "sha256:3394be3eb699099a6bcd7d8a72c0310f5572e18d88b303569256730be8878f0e", size = 77114125 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/15/02/fca435da667b1b44b10b822a900664228ddb8be9fd85f370a134e94a6ddd/awscrt-0.23.10-cp311-abi3-macosx_10_9_universal2.whl", hash = "sha256:b93c43b646400c56a97be7c3b676795c3d760ca6ef10296bf8ee990a8ab1b540", size = 1476555 }, + { url = "https://files.pythonhosted.org/packages/e4/86/120354037bb889253433acf9bab4b9632dadfb832d9902be37dff9017181/awscrt-0.23.10-cp311-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6fc647622533ad3fcbfe7a0e7238efce26fee105d8f37980a05e7d54550253d3", size = 8488644 }, + { url = "https://files.pythonhosted.org/packages/9c/c6/5a281029bdacc4e8a3f7bd3f4a355e333864cc7dc7e0e014c0eec5907fd8/awscrt-0.23.10-cp311-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:aab1f84ae3e6042620313e6c92212992ca11441373f9d527e907735bb1f581e9", size = 8763528 }, + { url = "https://files.pythonhosted.org/packages/87/b1/9f27be489418f053ca938d2db1d9a0636b83c5543082fd1e644053b8eca6/awscrt-0.23.10-cp311-abi3-musllinux_1_1_aarch64.whl", hash = "sha256:e3b3314b5c9ca12351f27ed871bca10b69521dd63dce18adce4a01af97c8f674", size = 8570518 }, + { url = "https://files.pythonhosted.org/packages/c0/d0/5f7accf5a0a0f5a82a2443c3a8d2a5771abb959d32aeb5cdbadd475ceb24/awscrt-0.23.10-cp311-abi3-musllinux_1_1_x86_64.whl", hash = "sha256:a4f7db90de9b50ef940a81610cc2ab44c8e2298331ca295fd7a31509e06c4b2d", size = 8957869 }, + { url = "https://files.pythonhosted.org/packages/0d/e9/980d869b43648e652cc2eeb026bd8346af1244b440af0b3fb37ecffe121d/awscrt-0.23.10-cp311-abi3-win32.whl", hash = "sha256:19b40930f98c89590fee6bc184de5a93bb530fb14b8958f8c2a76b5e8ca567ce", size = 2585114 }, + { url = "https://files.pythonhosted.org/packages/9f/17/91aa8528a47cc2e640944be75e3db56d30b3810e74dd3a76088ce9b6855b/awscrt-0.23.10-cp311-abi3-win_amd64.whl", hash = "sha256:6be2e6acca683960174422a4714972cb58803e00dc9cd06de9a7b9fe94fbb28f", size = 2639491 }, + { url = "https://files.pythonhosted.org/packages/86/32/457ca5e0b1f5327f09f5318e9f6ae0ed007030f34b64c11707ad4bb7e35e/awscrt-0.23.10-cp313-abi3-macosx_10_13_universal2.whl", hash = "sha256:c09a19fa74811b34a0090a6b83dde9425224df63f832590435de99faa971523e", size = 1468521 }, + { url = "https://files.pythonhosted.org/packages/72/3c/7841c4e0973f6f5716f0f54fb06e10cdb552a3d17f78de305652d2212d27/awscrt-0.23.10-cp313-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2d494ce3bd38d5936f52c1fb0118150979398e59da02c9283272a7bd12be4ab9", size = 8482595 }, + { url = "https://files.pythonhosted.org/packages/26/fb/80bd140eabaaebe5b2def3df4ec661a073d28dd7179dd59deab1ce43fe44/awscrt-0.23.10-cp313-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8f948ecd60280361b32f91d7bd3a957bc15033c83231bb1f8b9d9781b1daf81b", size = 8760758 }, + { url = "https://files.pythonhosted.org/packages/78/03/e28c94f6ccca7c06baa797825ae237e7965f06b38be7ddf513d9b2efd85e/awscrt-0.23.10-cp313-abi3-musllinux_1_1_aarch64.whl", hash = "sha256:a60694b053646d8a389a78e0e2a60dcc95fcfb794d95b9b1c0691f0341c4531f", size = 8565495 }, + { url = "https://files.pythonhosted.org/packages/62/f9/a08a96e0cfcd490510a96127796c87a107225db3e34a5693a1fb1c1fce19/awscrt-0.23.10-cp313-abi3-musllinux_1_1_x86_64.whl", hash = "sha256:144b8b6ff0414d9968706e53adcd68b73609fc4c4b9ff53234abea9fbf2f42b5", size = 8954290 }, + { url = "https://files.pythonhosted.org/packages/d6/fb/21ebaa59673369ee4073d62eddde941caa8d0a40ef8ffc14bc7b2e6a4b6e/awscrt-0.23.10-cp313-abi3-win32.whl", hash = "sha256:920ac0167b81f5b5a1edd6ae2e50b058515e9f21c71164d5ee1e3d03deb6f1c5", size = 2582551 }, + { url = "https://files.pythonhosted.org/packages/83/e3/f524d3211fe4491887767da03f58de4b431790ed120b0e446565caaad027/awscrt-0.23.10-cp313-abi3-win_amd64.whl", hash = "sha256:23d2dfeaa0b62bb3bad569cec03a959bdbf62e9123ad1f235bfacb61d420f8d0", size = 2635008 }, +] + +[[package]] +name = "black" +version = "25.1.0" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "click" }, + { name = "mypy-extensions" }, + { name = "packaging" }, + { name = "pathspec" }, + { name = "platformdirs" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/94/49/26a7b0f3f35da4b5a65f081943b7bcd22d7002f5f0fb8098ec1ff21cb6ef/black-25.1.0.tar.gz", hash = "sha256:33496d5cd1222ad73391352b4ae8da15253c5de89b93a80b3e2c8d9a19ec2666", size = 649449 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/83/71/3fe4741df7adf015ad8dfa082dd36c94ca86bb21f25608eb247b4afb15b2/black-25.1.0-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:4b60580e829091e6f9238c848ea6750efed72140b91b048770b64e74fe04908b", size = 1650988 }, + { url = "https://files.pythonhosted.org/packages/13/f3/89aac8a83d73937ccd39bbe8fc6ac8860c11cfa0af5b1c96d081facac844/black-25.1.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:1e2978f6df243b155ef5fa7e558a43037c3079093ed5d10fd84c43900f2d8ecc", size = 1453985 }, + { url = "https://files.pythonhosted.org/packages/6f/22/b99efca33f1f3a1d2552c714b1e1b5ae92efac6c43e790ad539a163d1754/black-25.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:3b48735872ec535027d979e8dcb20bf4f70b5ac75a8ea99f127c106a7d7aba9f", size = 1783816 }, + { url = "https://files.pythonhosted.org/packages/18/7e/a27c3ad3822b6f2e0e00d63d58ff6299a99a5b3aee69fa77cd4b0076b261/black-25.1.0-cp312-cp312-win_amd64.whl", hash = "sha256:ea0213189960bda9cf99be5b8c8ce66bb054af5e9e861249cd23471bd7b0b3ba", size = 1440860 }, + { url = "https://files.pythonhosted.org/packages/98/87/0edf98916640efa5d0696e1abb0a8357b52e69e82322628f25bf14d263d1/black-25.1.0-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:8f0b18a02996a836cc9c9c78e5babec10930862827b1b724ddfe98ccf2f2fe4f", size = 1650673 }, + { url = "https://files.pythonhosted.org/packages/52/e5/f7bf17207cf87fa6e9b676576749c6b6ed0d70f179a3d812c997870291c3/black-25.1.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:afebb7098bfbc70037a053b91ae8437c3857482d3a690fefc03e9ff7aa9a5fd3", size = 1453190 }, + { url = "https://files.pythonhosted.org/packages/e3/ee/adda3d46d4a9120772fae6de454c8495603c37c4c3b9c60f25b1ab6401fe/black-25.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:030b9759066a4ee5e5aca28c3c77f9c64789cdd4de8ac1df642c40b708be6171", size = 1782926 }, + { url = "https://files.pythonhosted.org/packages/cc/64/94eb5f45dcb997d2082f097a3944cfc7fe87e071907f677e80788a2d7b7a/black-25.1.0-cp313-cp313-win_amd64.whl", hash = "sha256:a22f402b410566e2d1c950708c77ebf5ebd5d0d88a6a2e87c86d9fb48afa0d18", size = 1442613 }, + { url = "https://files.pythonhosted.org/packages/09/71/54e999902aed72baf26bca0d50781b01838251a462612966e9fc4891eadd/black-25.1.0-py3-none-any.whl", hash = "sha256:95e8176dae143ba9097f351d174fdaf0ccd29efb414b362ae3fd72bf0f710717", size = 207646 }, +] + +[[package]] +name = "charset-normalizer" +version = "3.4.1" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/16/b0/572805e227f01586461c80e0fd25d65a2115599cc9dad142fee4b747c357/charset_normalizer-3.4.1.tar.gz", hash = "sha256:44251f18cd68a75b56585dd00dae26183e102cd5e0f9f1466e6df5da2ed64ea3", size = 123188 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/0a/9a/dd1e1cdceb841925b7798369a09279bd1cf183cef0f9ddf15a3a6502ee45/charset_normalizer-3.4.1-cp312-cp312-macosx_10_13_universal2.whl", hash = "sha256:73d94b58ec7fecbc7366247d3b0b10a21681004153238750bb67bd9012414545", size = 196105 }, + { url = "https://files.pythonhosted.org/packages/d3/8c/90bfabf8c4809ecb648f39794cf2a84ff2e7d2a6cf159fe68d9a26160467/charset_normalizer-3.4.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:dad3e487649f498dd991eeb901125411559b22e8d7ab25d3aeb1af367df5efd7", size = 140404 }, + { url = "https://files.pythonhosted.org/packages/ad/8f/e410d57c721945ea3b4f1a04b74f70ce8fa800d393d72899f0a40526401f/charset_normalizer-3.4.1-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:c30197aa96e8eed02200a83fba2657b4c3acd0f0aa4bdc9f6c1af8e8962e0757", size = 150423 }, + { url = "https://files.pythonhosted.org/packages/f0/b8/e6825e25deb691ff98cf5c9072ee0605dc2acfca98af70c2d1b1bc75190d/charset_normalizer-3.4.1-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2369eea1ee4a7610a860d88f268eb39b95cb588acd7235e02fd5a5601773d4fa", size = 143184 }, + { url = "https://files.pythonhosted.org/packages/3e/a2/513f6cbe752421f16d969e32f3583762bfd583848b763913ddab8d9bfd4f/charset_normalizer-3.4.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bc2722592d8998c870fa4e290c2eec2c1569b87fe58618e67d38b4665dfa680d", size = 145268 }, + { url = "https://files.pythonhosted.org/packages/74/94/8a5277664f27c3c438546f3eb53b33f5b19568eb7424736bdc440a88a31f/charset_normalizer-3.4.1-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:ffc9202a29ab3920fa812879e95a9e78b2465fd10be7fcbd042899695d75e616", size = 147601 }, + { url = "https://files.pythonhosted.org/packages/7c/5f/6d352c51ee763623a98e31194823518e09bfa48be2a7e8383cf691bbb3d0/charset_normalizer-3.4.1-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:804a4d582ba6e5b747c625bf1255e6b1507465494a40a2130978bda7b932c90b", size = 141098 }, + { url = "https://files.pythonhosted.org/packages/78/d4/f5704cb629ba5ab16d1d3d741396aec6dc3ca2b67757c45b0599bb010478/charset_normalizer-3.4.1-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:0f55e69f030f7163dffe9fd0752b32f070566451afe180f99dbeeb81f511ad8d", size = 149520 }, + { url = "https://files.pythonhosted.org/packages/c5/96/64120b1d02b81785f222b976c0fb79a35875457fa9bb40827678e54d1bc8/charset_normalizer-3.4.1-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:c4c3e6da02df6fa1410a7680bd3f63d4f710232d3139089536310d027950696a", size = 152852 }, + { url = "https://files.pythonhosted.org/packages/84/c9/98e3732278a99f47d487fd3468bc60b882920cef29d1fa6ca460a1fdf4e6/charset_normalizer-3.4.1-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:5df196eb874dae23dcfb968c83d4f8fdccb333330fe1fc278ac5ceeb101003a9", size = 150488 }, + { url = "https://files.pythonhosted.org/packages/13/0e/9c8d4cb99c98c1007cc11eda969ebfe837bbbd0acdb4736d228ccaabcd22/charset_normalizer-3.4.1-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:e358e64305fe12299a08e08978f51fc21fac060dcfcddd95453eabe5b93ed0e1", size = 146192 }, + { url = "https://files.pythonhosted.org/packages/b2/21/2b6b5b860781a0b49427309cb8670785aa543fb2178de875b87b9cc97746/charset_normalizer-3.4.1-cp312-cp312-win32.whl", hash = "sha256:9b23ca7ef998bc739bf6ffc077c2116917eabcc901f88da1b9856b210ef63f35", size = 95550 }, + { url = "https://files.pythonhosted.org/packages/21/5b/1b390b03b1d16c7e382b561c5329f83cc06623916aab983e8ab9239c7d5c/charset_normalizer-3.4.1-cp312-cp312-win_amd64.whl", hash = "sha256:6ff8a4a60c227ad87030d76e99cd1698345d4491638dfa6673027c48b3cd395f", size = 102785 }, + { url = "https://files.pythonhosted.org/packages/38/94/ce8e6f63d18049672c76d07d119304e1e2d7c6098f0841b51c666e9f44a0/charset_normalizer-3.4.1-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:aabfa34badd18f1da5ec1bc2715cadc8dca465868a4e73a0173466b688f29dda", size = 195698 }, + { url = "https://files.pythonhosted.org/packages/24/2e/dfdd9770664aae179a96561cc6952ff08f9a8cd09a908f259a9dfa063568/charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:22e14b5d70560b8dd51ec22863f370d1e595ac3d024cb8ad7d308b4cd95f8313", size = 140162 }, + { url = "https://files.pythonhosted.org/packages/24/4e/f646b9093cff8fc86f2d60af2de4dc17c759de9d554f130b140ea4738ca6/charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:8436c508b408b82d87dc5f62496973a1805cd46727c34440b0d29d8a2f50a6c9", size = 150263 }, + { url = "https://files.pythonhosted.org/packages/5e/67/2937f8d548c3ef6e2f9aab0f6e21001056f692d43282b165e7c56023e6dd/charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:2d074908e1aecee37a7635990b2c6d504cd4766c7bc9fc86d63f9c09af3fa11b", size = 142966 }, + { url = "https://files.pythonhosted.org/packages/52/ed/b7f4f07de100bdb95c1756d3a4d17b90c1a3c53715c1a476f8738058e0fa/charset_normalizer-3.4.1-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:955f8851919303c92343d2f66165294848d57e9bba6cf6e3625485a70a038d11", size = 144992 }, + { url = "https://files.pythonhosted.org/packages/96/2c/d49710a6dbcd3776265f4c923bb73ebe83933dfbaa841c5da850fe0fd20b/charset_normalizer-3.4.1-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:44ecbf16649486d4aebafeaa7ec4c9fed8b88101f4dd612dcaf65d5e815f837f", size = 147162 }, + { url = "https://files.pythonhosted.org/packages/b4/41/35ff1f9a6bd380303dea55e44c4933b4cc3c4850988927d4082ada230273/charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:0924e81d3d5e70f8126529951dac65c1010cdf117bb75eb02dd12339b57749dd", size = 140972 }, + { url = "https://files.pythonhosted.org/packages/fb/43/c6a0b685fe6910d08ba971f62cd9c3e862a85770395ba5d9cad4fede33ab/charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:2967f74ad52c3b98de4c3b32e1a44e32975e008a9cd2a8cc8966d6a5218c5cb2", size = 149095 }, + { url = "https://files.pythonhosted.org/packages/4c/ff/a9a504662452e2d2878512115638966e75633519ec11f25fca3d2049a94a/charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:c75cb2a3e389853835e84a2d8fb2b81a10645b503eca9bcb98df6b5a43eb8886", size = 152668 }, + { url = "https://files.pythonhosted.org/packages/6c/71/189996b6d9a4b932564701628af5cee6716733e9165af1d5e1b285c530ed/charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:09b26ae6b1abf0d27570633b2b078a2a20419c99d66fb2823173d73f188ce601", size = 150073 }, + { url = "https://files.pythonhosted.org/packages/e4/93/946a86ce20790e11312c87c75ba68d5f6ad2208cfb52b2d6a2c32840d922/charset_normalizer-3.4.1-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:fa88b843d6e211393a37219e6a1c1df99d35e8fd90446f1118f4216e307e48cd", size = 145732 }, + { url = "https://files.pythonhosted.org/packages/cd/e5/131d2fb1b0dddafc37be4f3a2fa79aa4c037368be9423061dccadfd90091/charset_normalizer-3.4.1-cp313-cp313-win32.whl", hash = "sha256:eb8178fe3dba6450a3e024e95ac49ed3400e506fd4e9e5c32d30adda88cbd407", size = 95391 }, + { url = "https://files.pythonhosted.org/packages/27/f2/4f9a69cc7712b9b5ad8fdb87039fd89abba997ad5cbe690d1835d40405b0/charset_normalizer-3.4.1-cp313-cp313-win_amd64.whl", hash = "sha256:b1ac5992a838106edb89654e0aebfc24f5848ae2547d22c2c3f66454daa11971", size = 102702 }, + { url = "https://files.pythonhosted.org/packages/0e/f6/65ecc6878a89bb1c23a086ea335ad4bf21a588990c3f535a227b9eea9108/charset_normalizer-3.4.1-py3-none-any.whl", hash = "sha256:d98b1668f06378c6dbefec3b92299716b931cd4e6061f3c875a71ced1780ab85", size = 49767 }, +] + +[[package]] +name = "click" +version = "8.1.8" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "colorama", marker = "sys_platform == 'win32'" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/b9/2e/0090cbf739cee7d23781ad4b89a9894a41538e4fcf4c31dcdd705b78eb8b/click-8.1.8.tar.gz", hash = "sha256:ed53c9d8990d83c2a27deae68e4ee337473f6330c040a31d4225c9574d16096a", size = 226593 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/7e/d4/7ebdbd03970677812aac39c869717059dbb71a4cfc033ca6e5221787892c/click-8.1.8-py3-none-any.whl", hash = "sha256:63c132bbbed01578a06712a2d1f497bb62d9c1c0d329b7903a866228027263b2", size = 98188 }, +] + +[[package]] +name = "colorama" +version = "0.4.6" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/d8/53/6f443c9a4a8358a93a6792e2acffb9d9d5cb0a5cfd8802644b7b1c9a02e4/colorama-0.4.6.tar.gz", hash = "sha256:08695f5cb7ed6e0531a20572697297273c47b8cae5a63ffc6d6ed5c201be6e44", size = 27697 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/d1/d6/3965ed04c63042e047cb6a3e6ed1a63a35087b6a609aa3a15ed8ac56c221/colorama-0.4.6-py2.py3-none-any.whl", hash = "sha256:4f1d9991f5acc0ca119f9d443620b77f9d6b33703e51011c16baf57afb285fc6", size = 25335 }, +] + +[[package]] +name = "coverage" +version = "7.6.12" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/0c/d6/2b53ab3ee99f2262e6f0b8369a43f6d66658eab45510331c0b3d5c8c4272/coverage-7.6.12.tar.gz", hash = "sha256:48cfc4641d95d34766ad41d9573cc0f22a48aa88d22657a1fe01dca0dbae4de2", size = 805941 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/e2/7f/4af2ed1d06ce6bee7eafc03b2ef748b14132b0bdae04388e451e4b2c529b/coverage-7.6.12-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:b172f8e030e8ef247b3104902cc671e20df80163b60a203653150d2fc204d1ad", size = 208645 }, + { url = "https://files.pythonhosted.org/packages/dc/60/d19df912989117caa95123524d26fc973f56dc14aecdec5ccd7d0084e131/coverage-7.6.12-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:641dfe0ab73deb7069fb972d4d9725bf11c239c309ce694dd50b1473c0f641c3", size = 208898 }, + { url = "https://files.pythonhosted.org/packages/bd/10/fecabcf438ba676f706bf90186ccf6ff9f6158cc494286965c76e58742fa/coverage-7.6.12-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0e549f54ac5f301e8e04c569dfdb907f7be71b06b88b5063ce9d6953d2d58574", size = 242987 }, + { url = "https://files.pythonhosted.org/packages/4c/53/4e208440389e8ea936f5f2b0762dcd4cb03281a7722def8e2bf9dc9c3d68/coverage-7.6.12-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:959244a17184515f8c52dcb65fb662808767c0bd233c1d8a166e7cf74c9ea985", size = 239881 }, + { url = "https://files.pythonhosted.org/packages/c4/47/2ba744af8d2f0caa1f17e7746147e34dfc5f811fb65fc153153722d58835/coverage-7.6.12-cp312-cp312-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bda1c5f347550c359f841d6614fb8ca42ae5cb0b74d39f8a1e204815ebe25750", size = 242142 }, + { url = "https://files.pythonhosted.org/packages/e9/90/df726af8ee74d92ee7e3bf113bf101ea4315d71508952bd21abc3fae471e/coverage-7.6.12-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:1ceeb90c3eda1f2d8c4c578c14167dbd8c674ecd7d38e45647543f19839dd6ea", size = 241437 }, + { url = "https://files.pythonhosted.org/packages/f6/af/995263fd04ae5f9cf12521150295bf03b6ba940d0aea97953bb4a6db3e2b/coverage-7.6.12-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:0f16f44025c06792e0fb09571ae454bcc7a3ec75eeb3c36b025eccf501b1a4c3", size = 239724 }, + { url = "https://files.pythonhosted.org/packages/1c/8e/5bb04f0318805e190984c6ce106b4c3968a9562a400180e549855d8211bd/coverage-7.6.12-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:b076e625396e787448d27a411aefff867db2bffac8ed04e8f7056b07024eed5a", size = 241329 }, + { url = "https://files.pythonhosted.org/packages/9e/9d/fa04d9e6c3f6459f4e0b231925277cfc33d72dfab7fa19c312c03e59da99/coverage-7.6.12-cp312-cp312-win32.whl", hash = "sha256:00b2086892cf06c7c2d74983c9595dc511acca00665480b3ddff749ec4fb2a95", size = 211289 }, + { url = "https://files.pythonhosted.org/packages/53/40/53c7ffe3c0c3fff4d708bc99e65f3d78c129110d6629736faf2dbd60ad57/coverage-7.6.12-cp312-cp312-win_amd64.whl", hash = "sha256:7ae6eabf519bc7871ce117fb18bf14e0e343eeb96c377667e3e5dd12095e0288", size = 212079 }, + { url = "https://files.pythonhosted.org/packages/76/89/1adf3e634753c0de3dad2f02aac1e73dba58bc5a3a914ac94a25b2ef418f/coverage-7.6.12-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:488c27b3db0ebee97a830e6b5a3ea930c4a6e2c07f27a5e67e1b3532e76b9ef1", size = 208673 }, + { url = "https://files.pythonhosted.org/packages/ce/64/92a4e239d64d798535c5b45baac6b891c205a8a2e7c9cc8590ad386693dc/coverage-7.6.12-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:5d1095bbee1851269f79fd8e0c9b5544e4c00c0c24965e66d8cba2eb5bb535fd", size = 208945 }, + { url = "https://files.pythonhosted.org/packages/b4/d0/4596a3ef3bca20a94539c9b1e10fd250225d1dec57ea78b0867a1cf9742e/coverage-7.6.12-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:0533adc29adf6a69c1baa88c3d7dbcaadcffa21afbed3ca7a225a440e4744bf9", size = 242484 }, + { url = "https://files.pythonhosted.org/packages/1c/ef/6fd0d344695af6718a38d0861408af48a709327335486a7ad7e85936dc6e/coverage-7.6.12-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:53c56358d470fa507a2b6e67a68fd002364d23c83741dbc4c2e0680d80ca227e", size = 239525 }, + { url = "https://files.pythonhosted.org/packages/0c/4b/373be2be7dd42f2bcd6964059fd8fa307d265a29d2b9bcf1d044bcc156ed/coverage-7.6.12-cp313-cp313-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:64cbb1a3027c79ca6310bf101014614f6e6e18c226474606cf725238cf5bc2d4", size = 241545 }, + { url = "https://files.pythonhosted.org/packages/a6/7d/0e83cc2673a7790650851ee92f72a343827ecaaea07960587c8f442b5cd3/coverage-7.6.12-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:79cac3390bfa9836bb795be377395f28410811c9066bc4eefd8015258a7578c6", size = 241179 }, + { url = "https://files.pythonhosted.org/packages/ff/8c/566ea92ce2bb7627b0900124e24a99f9244b6c8c92d09ff9f7633eb7c3c8/coverage-7.6.12-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:9b148068e881faa26d878ff63e79650e208e95cf1c22bd3f77c3ca7b1d9821a3", size = 239288 }, + { url = "https://files.pythonhosted.org/packages/7d/e4/869a138e50b622f796782d642c15fb5f25a5870c6d0059a663667a201638/coverage-7.6.12-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:8bec2ac5da793c2685ce5319ca9bcf4eee683b8a1679051f8e6ec04c4f2fd7dc", size = 241032 }, + { url = "https://files.pythonhosted.org/packages/ae/28/a52ff5d62a9f9e9fe9c4f17759b98632edd3a3489fce70154c7d66054dd3/coverage-7.6.12-cp313-cp313-win32.whl", hash = "sha256:200e10beb6ddd7c3ded322a4186313d5ca9e63e33d8fab4faa67ef46d3460af3", size = 211315 }, + { url = "https://files.pythonhosted.org/packages/bc/17/ab849b7429a639f9722fa5628364c28d675c7ff37ebc3268fe9840dda13c/coverage-7.6.12-cp313-cp313-win_amd64.whl", hash = "sha256:2b996819ced9f7dbb812c701485d58f261bef08f9b85304d41219b1496b591ef", size = 212099 }, + { url = "https://files.pythonhosted.org/packages/d2/1c/b9965bf23e171d98505eb5eb4fb4d05c44efd256f2e0f19ad1ba8c3f54b0/coverage-7.6.12-cp313-cp313t-macosx_10_13_x86_64.whl", hash = "sha256:299cf973a7abff87a30609879c10df0b3bfc33d021e1adabc29138a48888841e", size = 209511 }, + { url = "https://files.pythonhosted.org/packages/57/b3/119c201d3b692d5e17784fee876a9a78e1b3051327de2709392962877ca8/coverage-7.6.12-cp313-cp313t-macosx_11_0_arm64.whl", hash = "sha256:4b467a8c56974bf06e543e69ad803c6865249d7a5ccf6980457ed2bc50312703", size = 209729 }, + { url = "https://files.pythonhosted.org/packages/52/4e/a7feb5a56b266304bc59f872ea07b728e14d5a64f1ad3a2cc01a3259c965/coverage-7.6.12-cp313-cp313t-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:2458f275944db8129f95d91aee32c828a408481ecde3b30af31d552c2ce284a0", size = 253988 }, + { url = "https://files.pythonhosted.org/packages/65/19/069fec4d6908d0dae98126aa7ad08ce5130a6decc8509da7740d36e8e8d2/coverage-7.6.12-cp313-cp313t-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:0a9d8be07fb0832636a0f72b80d2a652fe665e80e720301fb22b191c3434d924", size = 249697 }, + { url = "https://files.pythonhosted.org/packages/1c/da/5b19f09ba39df7c55f77820736bf17bbe2416bbf5216a3100ac019e15839/coverage-7.6.12-cp313-cp313t-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:14d47376a4f445e9743f6c83291e60adb1b127607a3618e3185bbc8091f0467b", size = 252033 }, + { url = "https://files.pythonhosted.org/packages/1e/89/4c2750df7f80a7872267f7c5fe497c69d45f688f7b3afe1297e52e33f791/coverage-7.6.12-cp313-cp313t-musllinux_1_2_aarch64.whl", hash = "sha256:b95574d06aa9d2bd6e5cc35a5bbe35696342c96760b69dc4287dbd5abd4ad51d", size = 251535 }, + { url = "https://files.pythonhosted.org/packages/78/3b/6d3ae3c1cc05f1b0460c51e6f6dcf567598cbd7c6121e5ad06643974703c/coverage-7.6.12-cp313-cp313t-musllinux_1_2_i686.whl", hash = "sha256:ecea0c38c9079570163d663c0433a9af4094a60aafdca491c6a3d248c7432827", size = 249192 }, + { url = "https://files.pythonhosted.org/packages/6e/8e/c14a79f535ce41af7d436bbad0d3d90c43d9e38ec409b4770c894031422e/coverage-7.6.12-cp313-cp313t-musllinux_1_2_x86_64.whl", hash = "sha256:2251fabcfee0a55a8578a9d29cecfee5f2de02f11530e7d5c5a05859aa85aee9", size = 250627 }, + { url = "https://files.pythonhosted.org/packages/cb/79/b7cee656cfb17a7f2c1b9c3cee03dd5d8000ca299ad4038ba64b61a9b044/coverage-7.6.12-cp313-cp313t-win32.whl", hash = "sha256:eb5507795caabd9b2ae3f1adc95f67b1104971c22c624bb354232d65c4fc90b3", size = 212033 }, + { url = "https://files.pythonhosted.org/packages/b6/c3/f7aaa3813f1fa9a4228175a7bd368199659d392897e184435a3b66408dd3/coverage-7.6.12-cp313-cp313t-win_amd64.whl", hash = "sha256:f60a297c3987c6c02ffb29effc70eadcbb412fe76947d394a1091a3615948e2f", size = 213240 }, + { url = "https://files.pythonhosted.org/packages/fb/b2/f655700e1024dec98b10ebaafd0cedbc25e40e4abe62a3c8e2ceef4f8f0a/coverage-7.6.12-py3-none-any.whl", hash = "sha256:eb8668cfbc279a536c633137deeb9435d2962caec279c3f8cf8b91fff6ff8953", size = 200552 }, +] + +[[package]] +name = "docformatter" +version = "1.7.5" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "charset-normalizer" }, + { name = "untokenize" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/f4/44/aba2c40cf796121b35835ea8c00bc5d93f2f70730eca53b36b8bbbfaefe1/docformatter-1.7.5.tar.gz", hash = "sha256:ffed3da0daffa2e77f80ccba4f0e50bfa2755e1c10e130102571c890a61b246e", size = 25893 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/8b/95/568a2fca29df365b82012b09b64964a05f4f20ac83c2137b262f3fa3188f/docformatter-1.7.5-py3-none-any.whl", hash = "sha256:a24f5545ed1f30af00d106f5d85dc2fce4959295687c24c8f39f5263afaf9186", size = 32798 }, +] + +[[package]] +name = "freezegun" +version = "1.5.1" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "python-dateutil" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/2c/ef/722b8d71ddf4d48f25f6d78aa2533d505bf3eec000a7cacb8ccc8de61f2f/freezegun-1.5.1.tar.gz", hash = "sha256:b29dedfcda6d5e8e083ce71b2b542753ad48cfec44037b3fc79702e2980a89e9", size = 33697 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/51/0b/0d7fee5919bccc1fdc1c2a7528b98f65c6f69b223a3fd8f809918c142c36/freezegun-1.5.1-py3-none-any.whl", hash = "sha256:bf111d7138a8abe55ab48a71755673dbaa4ab87f4cff5634a4442dfec34c15f1", size = 17569 }, +] + +[[package]] +name = "frozenlist" +version = "1.5.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/8f/ed/0f4cec13a93c02c47ec32d81d11c0c1efbadf4a471e3f3ce7cad366cbbd3/frozenlist-1.5.0.tar.gz", hash = "sha256:81d5af29e61b9c8348e876d442253723928dce6433e0e76cd925cd83f1b4b817", size = 39930 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/79/73/fa6d1a96ab7fd6e6d1c3500700963eab46813847f01ef0ccbaa726181dd5/frozenlist-1.5.0-cp312-cp312-macosx_10_13_universal2.whl", hash = "sha256:31115ba75889723431aa9a4e77d5f398f5cf976eea3bdf61749731f62d4a4a21", size = 94026 }, + { url = "https://files.pythonhosted.org/packages/ab/04/ea8bf62c8868b8eada363f20ff1b647cf2e93377a7b284d36062d21d81d1/frozenlist-1.5.0-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:7437601c4d89d070eac8323f121fcf25f88674627505334654fd027b091db09d", size = 54150 }, + { url = "https://files.pythonhosted.org/packages/d0/9a/8e479b482a6f2070b26bda572c5e6889bb3ba48977e81beea35b5ae13ece/frozenlist-1.5.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:7948140d9f8ece1745be806f2bfdf390127cf1a763b925c4a805c603df5e697e", size = 51927 }, + { url = "https://files.pythonhosted.org/packages/e3/12/2aad87deb08a4e7ccfb33600871bbe8f0e08cb6d8224371387f3303654d7/frozenlist-1.5.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:feeb64bc9bcc6b45c6311c9e9b99406660a9c05ca8a5b30d14a78555088b0b3a", size = 282647 }, + { url = "https://files.pythonhosted.org/packages/77/f2/07f06b05d8a427ea0060a9cef6e63405ea9e0d761846b95ef3fb3be57111/frozenlist-1.5.0-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:683173d371daad49cffb8309779e886e59c2f369430ad28fe715f66d08d4ab1a", size = 289052 }, + { url = "https://files.pythonhosted.org/packages/bd/9f/8bf45a2f1cd4aa401acd271b077989c9267ae8463e7c8b1eb0d3f561b65e/frozenlist-1.5.0-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:7d57d8f702221405a9d9b40f9da8ac2e4a1a8b5285aac6100f3393675f0a85ee", size = 291719 }, + { url = "https://files.pythonhosted.org/packages/41/d1/1f20fd05a6c42d3868709b7604c9f15538a29e4f734c694c6bcfc3d3b935/frozenlist-1.5.0-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:30c72000fbcc35b129cb09956836c7d7abf78ab5416595e4857d1cae8d6251a6", size = 267433 }, + { url = "https://files.pythonhosted.org/packages/af/f2/64b73a9bb86f5a89fb55450e97cd5c1f84a862d4ff90d9fd1a73ab0f64a5/frozenlist-1.5.0-cp312-cp312-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:000a77d6034fbad9b6bb880f7ec073027908f1b40254b5d6f26210d2dab1240e", size = 283591 }, + { url = "https://files.pythonhosted.org/packages/29/e2/ffbb1fae55a791fd6c2938dd9ea779509c977435ba3940b9f2e8dc9d5316/frozenlist-1.5.0-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:5d7f5a50342475962eb18b740f3beecc685a15b52c91f7d975257e13e029eca9", size = 273249 }, + { url = "https://files.pythonhosted.org/packages/2e/6e/008136a30798bb63618a114b9321b5971172a5abddff44a100c7edc5ad4f/frozenlist-1.5.0-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:87f724d055eb4785d9be84e9ebf0f24e392ddfad00b3fe036e43f489fafc9039", size = 271075 }, + { url = "https://files.pythonhosted.org/packages/ae/f0/4e71e54a026b06724cec9b6c54f0b13a4e9e298cc8db0f82ec70e151f5ce/frozenlist-1.5.0-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:6e9080bb2fb195a046e5177f10d9d82b8a204c0736a97a153c2466127de87784", size = 285398 }, + { url = "https://files.pythonhosted.org/packages/4d/36/70ec246851478b1c0b59f11ef8ade9c482ff447c1363c2bd5fad45098b12/frozenlist-1.5.0-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:9b93d7aaa36c966fa42efcaf716e6b3900438632a626fb09c049f6a2f09fc631", size = 294445 }, + { url = "https://files.pythonhosted.org/packages/37/e0/47f87544055b3349b633a03c4d94b405956cf2437f4ab46d0928b74b7526/frozenlist-1.5.0-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:52ef692a4bc60a6dd57f507429636c2af8b6046db8b31b18dac02cbc8f507f7f", size = 280569 }, + { url = "https://files.pythonhosted.org/packages/f9/7c/490133c160fb6b84ed374c266f42800e33b50c3bbab1652764e6e1fc498a/frozenlist-1.5.0-cp312-cp312-win32.whl", hash = "sha256:29d94c256679247b33a3dc96cce0f93cbc69c23bf75ff715919332fdbb6a32b8", size = 44721 }, + { url = "https://files.pythonhosted.org/packages/b1/56/4e45136ffc6bdbfa68c29ca56ef53783ef4c2fd395f7cbf99a2624aa9aaa/frozenlist-1.5.0-cp312-cp312-win_amd64.whl", hash = "sha256:8969190d709e7c48ea386db202d708eb94bdb29207a1f269bab1196ce0dcca1f", size = 51329 }, + { url = "https://files.pythonhosted.org/packages/da/3b/915f0bca8a7ea04483622e84a9bd90033bab54bdf485479556c74fd5eaf5/frozenlist-1.5.0-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:7a1a048f9215c90973402e26c01d1cff8a209e1f1b53f72b95c13db61b00f953", size = 91538 }, + { url = "https://files.pythonhosted.org/packages/c7/d1/a7c98aad7e44afe5306a2b068434a5830f1470675f0e715abb86eb15f15b/frozenlist-1.5.0-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:dd47a5181ce5fcb463b5d9e17ecfdb02b678cca31280639255ce9d0e5aa67af0", size = 52849 }, + { url = "https://files.pythonhosted.org/packages/3a/c8/76f23bf9ab15d5f760eb48701909645f686f9c64fbb8982674c241fbef14/frozenlist-1.5.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:1431d60b36d15cda188ea222033eec8e0eab488f39a272461f2e6d9e1a8e63c2", size = 50583 }, + { url = "https://files.pythonhosted.org/packages/1f/22/462a3dd093d11df623179d7754a3b3269de3b42de2808cddef50ee0f4f48/frozenlist-1.5.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6482a5851f5d72767fbd0e507e80737f9c8646ae7fd303def99bfe813f76cf7f", size = 265636 }, + { url = "https://files.pythonhosted.org/packages/80/cf/e075e407fc2ae7328155a1cd7e22f932773c8073c1fc78016607d19cc3e5/frozenlist-1.5.0-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:44c49271a937625619e862baacbd037a7ef86dd1ee215afc298a417ff3270608", size = 270214 }, + { url = "https://files.pythonhosted.org/packages/a1/58/0642d061d5de779f39c50cbb00df49682832923f3d2ebfb0fedf02d05f7f/frozenlist-1.5.0-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:12f78f98c2f1c2429d42e6a485f433722b0061d5c0b0139efa64f396efb5886b", size = 273905 }, + { url = "https://files.pythonhosted.org/packages/ab/66/3fe0f5f8f2add5b4ab7aa4e199f767fd3b55da26e3ca4ce2cc36698e50c4/frozenlist-1.5.0-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:ce3aa154c452d2467487765e3adc730a8c153af77ad84096bc19ce19a2400840", size = 250542 }, + { url = "https://files.pythonhosted.org/packages/f6/b8/260791bde9198c87a465224e0e2bb62c4e716f5d198fc3a1dacc4895dbd1/frozenlist-1.5.0-cp313-cp313-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:9b7dc0c4338e6b8b091e8faf0db3168a37101943e687f373dce00959583f7439", size = 267026 }, + { url = "https://files.pythonhosted.org/packages/2e/a4/3d24f88c527f08f8d44ade24eaee83b2627793fa62fa07cbb7ff7a2f7d42/frozenlist-1.5.0-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:45e0896250900b5aa25180f9aec243e84e92ac84bd4a74d9ad4138ef3f5c97de", size = 257690 }, + { url = "https://files.pythonhosted.org/packages/de/9a/d311d660420b2beeff3459b6626f2ab4fb236d07afbdac034a4371fe696e/frozenlist-1.5.0-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:561eb1c9579d495fddb6da8959fd2a1fca2c6d060d4113f5844b433fc02f2641", size = 253893 }, + { url = "https://files.pythonhosted.org/packages/c6/23/e491aadc25b56eabd0f18c53bb19f3cdc6de30b2129ee0bc39cd387cd560/frozenlist-1.5.0-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:df6e2f325bfee1f49f81aaac97d2aa757c7646534a06f8f577ce184afe2f0a9e", size = 267006 }, + { url = "https://files.pythonhosted.org/packages/08/c4/ab918ce636a35fb974d13d666dcbe03969592aeca6c3ab3835acff01f79c/frozenlist-1.5.0-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:140228863501b44b809fb39ec56b5d4071f4d0aa6d216c19cbb08b8c5a7eadb9", size = 276157 }, + { url = "https://files.pythonhosted.org/packages/c0/29/3b7a0bbbbe5a34833ba26f686aabfe982924adbdcafdc294a7a129c31688/frozenlist-1.5.0-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:7707a25d6a77f5d27ea7dc7d1fc608aa0a478193823f88511ef5e6b8a48f9d03", size = 264642 }, + { url = "https://files.pythonhosted.org/packages/ab/42/0595b3dbffc2e82d7fe658c12d5a5bafcd7516c6bf2d1d1feb5387caa9c1/frozenlist-1.5.0-cp313-cp313-win32.whl", hash = "sha256:31a9ac2b38ab9b5a8933b693db4939764ad3f299fcaa931a3e605bc3460e693c", size = 44914 }, + { url = "https://files.pythonhosted.org/packages/17/c4/b7db1206a3fea44bf3b838ca61deb6f74424a8a5db1dd53ecb21da669be6/frozenlist-1.5.0-cp313-cp313-win_amd64.whl", hash = "sha256:11aabdd62b8b9c4b84081a3c246506d1cddd2dd93ff0ad53ede5defec7886b28", size = 51167 }, + { url = "https://files.pythonhosted.org/packages/c6/c8/a5be5b7550c10858fcf9b0ea054baccab474da77d37f1e828ce043a3a5d4/frozenlist-1.5.0-py3-none-any.whl", hash = "sha256:d994863bba198a4a518b467bb971c56e1db3f180a25c6cf7bb1949c267f748c3", size = 11901 }, +] + +[[package]] +name = "idna" +version = "3.10" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/f1/70/7703c29685631f5a7590aa73f1f1d3fa9a380e654b86af429e0934a32f7d/idna-3.10.tar.gz", hash = "sha256:12f65c9b470abda6dc35cf8e63cc574b1c52b11df2c86030af0ac09b01b13ea9", size = 190490 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/76/c6/c88e154df9c4e1a2a66ccf0005a88dfb2650c1dffb6f5ce603dfbd452ce3/idna-3.10-py3-none-any.whl", hash = "sha256:946d195a0d259cbba61165e88e65941f16e9b36ea6ddb97f00452bae8b1287d3", size = 70442 }, +] + +[[package]] +name = "ijson" +version = "3.3.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/6c/83/28e9e93a3a61913e334e3a2e78ea9924bb9f9b1ac45898977f9d9dd6133f/ijson-3.3.0.tar.gz", hash = "sha256:7f172e6ba1bee0d4c8f8ebd639577bfe429dee0f3f96775a067b8bae4492d8a0", size = 60079 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/8a/4d/3992f7383e26a950e02dc704bc6c5786a080d5c25fe0fc5543ef477c1883/ijson-3.3.0-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:988e959f2f3d59ebd9c2962ae71b97c0df58323910d0b368cc190ad07429d1bb", size = 84550 }, + { url = "https://files.pythonhosted.org/packages/1b/cc/3d4372e0d0b02a821b982f1fdf10385512dae9b9443c1597719dd37769a9/ijson-3.3.0-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:b2f73f0d0fce5300f23a1383d19b44d103bb113b57a69c36fd95b7c03099b181", size = 57572 }, + { url = "https://files.pythonhosted.org/packages/02/de/970d48b1ff9da5d9513c86fdd2acef5cb3415541c8069e0d92a151b84adb/ijson-3.3.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:0ee57a28c6bf523d7cb0513096e4eb4dac16cd935695049de7608ec110c2b751", size = 56902 }, + { url = "https://files.pythonhosted.org/packages/5e/a0/4537722c8b3b05e82c23dfe09a3a64dd1e44a013a5ca58b1e77dfe48b2f1/ijson-3.3.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:e0155a8f079c688c2ccaea05de1ad69877995c547ba3d3612c1c336edc12a3a5", size = 127400 }, + { url = "https://files.pythonhosted.org/packages/b2/96/54956062a99cf49f7a7064b573dcd756da0563ce57910dc34e27a473d9b9/ijson-3.3.0-cp312-cp312-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:7ab00721304af1ae1afa4313ecfa1bf16b07f55ef91e4a5b93aeaa3e2bd7917c", size = 118786 }, + { url = "https://files.pythonhosted.org/packages/07/74/795319531c5b5504508f595e631d592957f24bed7ff51a15bc4c61e7b24c/ijson-3.3.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:40ee3821ee90be0f0e95dcf9862d786a7439bd1113e370736bfdf197e9765bfb", size = 126288 }, + { url = "https://files.pythonhosted.org/packages/69/6a/e0cec06fbd98851d5d233b59058c1dc2ea767c9bb6feca41aa9164fff769/ijson-3.3.0-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:da3b6987a0bc3e6d0f721b42c7a0198ef897ae50579547b0345f7f02486898f5", size = 129569 }, + { url = "https://files.pythonhosted.org/packages/2a/4f/82c0d896d8dcb175f99ced7d87705057bcd13523998b48a629b90139a0dc/ijson-3.3.0-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:63afea5f2d50d931feb20dcc50954e23cef4127606cc0ecf7a27128ed9f9a9e6", size = 121508 }, + { url = "https://files.pythonhosted.org/packages/2b/b6/8973474eba4a917885e289d9e138267d3d1f052c2d93b8c968755661a42d/ijson-3.3.0-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:b5c3e285e0735fd8c5a26d177eca8b52512cdd8687ca86ec77a0c66e9c510182", size = 127896 }, + { url = "https://files.pythonhosted.org/packages/94/25/00e66af887adbbe70002e0479c3c2340bdfa17a168e25d4ab5a27b53582d/ijson-3.3.0-cp312-cp312-win32.whl", hash = "sha256:907f3a8674e489abdcb0206723e5560a5cb1fa42470dcc637942d7b10f28b695", size = 49272 }, + { url = "https://files.pythonhosted.org/packages/25/a2/e187beee237808b2c417109ae0f4f7ee7c81ecbe9706305d6ac2a509cc45/ijson-3.3.0-cp312-cp312-win_amd64.whl", hash = "sha256:8f890d04ad33262d0c77ead53c85f13abfb82f2c8f078dfbf24b78f59534dfdd", size = 51272 }, +] + +[[package]] +name = "iniconfig" +version = "2.0.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/d7/4b/cbd8e699e64a6f16ca3a8220661b5f83792b3017d0f79807cb8708d33913/iniconfig-2.0.0.tar.gz", hash = "sha256:2d91e135bf72d31a410b17c16da610a82cb55f6b0477d1a902134b24a455b8b3", size = 4646 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/ef/a6/62565a6e1cf69e10f5727360368e451d4b7f58beeac6173dc9db836a5b46/iniconfig-2.0.0-py3-none-any.whl", hash = "sha256:b6a85871a79d2e3b22d2d1b94ac2824226a63c6b741c88f7ae975f18b6778374", size = 5892 }, +] + +[[package]] +name = "multidict" +version = "6.1.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/d6/be/504b89a5e9ca731cd47487e91c469064f8ae5af93b7259758dcfc2b9c848/multidict-6.1.0.tar.gz", hash = "sha256:22ae2ebf9b0c69d206c003e2f6a914ea33f0a932d4aa16f236afc049d9958f4a", size = 64002 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/fd/16/92057c74ba3b96d5e211b553895cd6dc7cc4d1e43d9ab8fafc727681ef71/multidict-6.1.0-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:b04772ed465fa3cc947db808fa306d79b43e896beb677a56fb2347ca1a49c1fa", size = 48713 }, + { url = "https://files.pythonhosted.org/packages/94/3d/37d1b8893ae79716179540b89fc6a0ee56b4a65fcc0d63535c6f5d96f217/multidict-6.1.0-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:6180c0ae073bddeb5a97a38c03f30c233e0a4d39cd86166251617d1bbd0af436", size = 29516 }, + { url = "https://files.pythonhosted.org/packages/a2/12/adb6b3200c363062f805275b4c1e656be2b3681aada66c80129932ff0bae/multidict-6.1.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:071120490b47aa997cca00666923a83f02c7fbb44f71cf7f136df753f7fa8761", size = 29557 }, + { url = "https://files.pythonhosted.org/packages/47/e9/604bb05e6e5bce1e6a5cf80a474e0f072e80d8ac105f1b994a53e0b28c42/multidict-6.1.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:50b3a2710631848991d0bf7de077502e8994c804bb805aeb2925a981de58ec2e", size = 130170 }, + { url = "https://files.pythonhosted.org/packages/7e/13/9efa50801785eccbf7086b3c83b71a4fb501a4d43549c2f2f80b8787d69f/multidict-6.1.0-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:b58c621844d55e71c1b7f7c498ce5aa6985d743a1a59034c57a905b3f153c1ef", size = 134836 }, + { url = "https://files.pythonhosted.org/packages/bf/0f/93808b765192780d117814a6dfcc2e75de6dcc610009ad408b8814dca3ba/multidict-6.1.0-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:55b6d90641869892caa9ca42ff913f7ff1c5ece06474fbd32fb2cf6834726c95", size = 133475 }, + { url = "https://files.pythonhosted.org/packages/d3/c8/529101d7176fe7dfe1d99604e48d69c5dfdcadb4f06561f465c8ef12b4df/multidict-6.1.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:4b820514bfc0b98a30e3d85462084779900347e4d49267f747ff54060cc33925", size = 131049 }, + { url = "https://files.pythonhosted.org/packages/ca/0c/fc85b439014d5a58063e19c3a158a889deec399d47b5269a0f3b6a2e28bc/multidict-6.1.0-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:10a9b09aba0c5b48c53761b7c720aaaf7cf236d5fe394cd399c7ba662d5f9966", size = 120370 }, + { url = "https://files.pythonhosted.org/packages/db/46/d4416eb20176492d2258fbd47b4abe729ff3b6e9c829ea4236f93c865089/multidict-6.1.0-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:1e16bf3e5fc9f44632affb159d30a437bfe286ce9e02754759be5536b169b305", size = 125178 }, + { url = "https://files.pythonhosted.org/packages/5b/46/73697ad7ec521df7de5531a32780bbfd908ded0643cbe457f981a701457c/multidict-6.1.0-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:76f364861c3bfc98cbbcbd402d83454ed9e01a5224bb3a28bf70002a230f73e2", size = 119567 }, + { url = "https://files.pythonhosted.org/packages/cd/ed/51f060e2cb0e7635329fa6ff930aa5cffa17f4c7f5c6c3ddc3500708e2f2/multidict-6.1.0-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:820c661588bd01a0aa62a1283f20d2be4281b086f80dad9e955e690c75fb54a2", size = 129822 }, + { url = "https://files.pythonhosted.org/packages/df/9e/ee7d1954b1331da3eddea0c4e08d9142da5f14b1321c7301f5014f49d492/multidict-6.1.0-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:0e5f362e895bc5b9e67fe6e4ded2492d8124bdf817827f33c5b46c2fe3ffaca6", size = 128656 }, + { url = "https://files.pythonhosted.org/packages/77/00/8538f11e3356b5d95fa4b024aa566cde7a38aa7a5f08f4912b32a037c5dc/multidict-6.1.0-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:3ec660d19bbc671e3a6443325f07263be452c453ac9e512f5eb935e7d4ac28b3", size = 125360 }, + { url = "https://files.pythonhosted.org/packages/be/05/5d334c1f2462d43fec2363cd00b1c44c93a78c3925d952e9a71caf662e96/multidict-6.1.0-cp312-cp312-win32.whl", hash = "sha256:58130ecf8f7b8112cdb841486404f1282b9c86ccb30d3519faf301b2e5659133", size = 26382 }, + { url = "https://files.pythonhosted.org/packages/a3/bf/f332a13486b1ed0496d624bcc7e8357bb8053823e8cd4b9a18edc1d97e73/multidict-6.1.0-cp312-cp312-win_amd64.whl", hash = "sha256:188215fc0aafb8e03341995e7c4797860181562380f81ed0a87ff455b70bf1f1", size = 28529 }, + { url = "https://files.pythonhosted.org/packages/22/67/1c7c0f39fe069aa4e5d794f323be24bf4d33d62d2a348acdb7991f8f30db/multidict-6.1.0-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:d569388c381b24671589335a3be6e1d45546c2988c2ebe30fdcada8457a31008", size = 48771 }, + { url = "https://files.pythonhosted.org/packages/3c/25/c186ee7b212bdf0df2519eacfb1981a017bda34392c67542c274651daf23/multidict-6.1.0-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:052e10d2d37810b99cc170b785945421141bf7bb7d2f8799d431e7db229c385f", size = 29533 }, + { url = "https://files.pythonhosted.org/packages/67/5e/04575fd837e0958e324ca035b339cea174554f6f641d3fb2b4f2e7ff44a2/multidict-6.1.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:f90c822a402cb865e396a504f9fc8173ef34212a342d92e362ca498cad308e28", size = 29595 }, + { url = "https://files.pythonhosted.org/packages/d3/b2/e56388f86663810c07cfe4a3c3d87227f3811eeb2d08450b9e5d19d78876/multidict-6.1.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:b225d95519a5bf73860323e633a664b0d85ad3d5bede6d30d95b35d4dfe8805b", size = 130094 }, + { url = "https://files.pythonhosted.org/packages/6c/ee/30ae9b4186a644d284543d55d491fbd4239b015d36b23fea43b4c94f7052/multidict-6.1.0-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:23bfd518810af7de1116313ebd9092cb9aa629beb12f6ed631ad53356ed6b86c", size = 134876 }, + { url = "https://files.pythonhosted.org/packages/84/c7/70461c13ba8ce3c779503c70ec9d0345ae84de04521c1f45a04d5f48943d/multidict-6.1.0-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:5c09fcfdccdd0b57867577b719c69e347a436b86cd83747f179dbf0cc0d4c1f3", size = 133500 }, + { url = "https://files.pythonhosted.org/packages/4a/9f/002af221253f10f99959561123fae676148dd730e2daa2cd053846a58507/multidict-6.1.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:bf6bea52ec97e95560af5ae576bdac3aa3aae0b6758c6efa115236d9e07dae44", size = 131099 }, + { url = "https://files.pythonhosted.org/packages/82/42/d1c7a7301d52af79d88548a97e297f9d99c961ad76bbe6f67442bb77f097/multidict-6.1.0-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:57feec87371dbb3520da6192213c7d6fc892d5589a93db548331954de8248fd2", size = 120403 }, + { url = "https://files.pythonhosted.org/packages/68/f3/471985c2c7ac707547553e8f37cff5158030d36bdec4414cb825fbaa5327/multidict-6.1.0-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:0c3f390dc53279cbc8ba976e5f8035eab997829066756d811616b652b00a23a3", size = 125348 }, + { url = "https://files.pythonhosted.org/packages/67/2c/e6df05c77e0e433c214ec1d21ddd203d9a4770a1f2866a8ca40a545869a0/multidict-6.1.0-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:59bfeae4b25ec05b34f1956eaa1cb38032282cd4dfabc5056d0a1ec4d696d3aa", size = 119673 }, + { url = "https://files.pythonhosted.org/packages/c5/cd/bc8608fff06239c9fb333f9db7743a1b2eafe98c2666c9a196e867a3a0a4/multidict-6.1.0-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:b2f59caeaf7632cc633b5cf6fc449372b83bbdf0da4ae04d5be36118e46cc0aa", size = 129927 }, + { url = "https://files.pythonhosted.org/packages/44/8e/281b69b7bc84fc963a44dc6e0bbcc7150e517b91df368a27834299a526ac/multidict-6.1.0-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:37bb93b2178e02b7b618893990941900fd25b6b9ac0fa49931a40aecdf083fe4", size = 128711 }, + { url = "https://files.pythonhosted.org/packages/12/a4/63e7cd38ed29dd9f1881d5119f272c898ca92536cdb53ffe0843197f6c85/multidict-6.1.0-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:4e9f48f58c2c523d5a06faea47866cd35b32655c46b443f163d08c6d0ddb17d6", size = 125519 }, + { url = "https://files.pythonhosted.org/packages/38/e0/4f5855037a72cd8a7a2f60a3952d9aa45feedb37ae7831642102604e8a37/multidict-6.1.0-cp313-cp313-win32.whl", hash = "sha256:3a37ffb35399029b45c6cc33640a92bef403c9fd388acce75cdc88f58bd19a81", size = 26426 }, + { url = "https://files.pythonhosted.org/packages/7e/a5/17ee3a4db1e310b7405f5d25834460073a8ccd86198ce044dfaf69eac073/multidict-6.1.0-cp313-cp313-win_amd64.whl", hash = "sha256:e9aa71e15d9d9beaad2c6b9319edcdc0a49a43ef5c0a4c8265ca9ee7d6c67774", size = 28531 }, + { url = "https://files.pythonhosted.org/packages/99/b7/b9e70fde2c0f0c9af4cc5277782a89b66d35948ea3369ec9f598358c3ac5/multidict-6.1.0-py3-none-any.whl", hash = "sha256:48e171e52d1c4d33888e529b999e5900356b9ae588c2f09a52dcefb158b27506", size = 10051 }, +] + +[[package]] +name = "mypy-extensions" +version = "1.0.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/98/a4/1ab47638b92648243faf97a5aeb6ea83059cc3624972ab6b8d2316078d3f/mypy_extensions-1.0.0.tar.gz", hash = "sha256:75dbf8955dc00442a438fc4d0666508a9a97b6bd41aa2f0ffe9d2f2725af0782", size = 4433 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/2a/e2/5d3f6ada4297caebe1a2add3b126fe800c96f56dbe5d1988a2cbe0b267aa/mypy_extensions-1.0.0-py3-none-any.whl", hash = "sha256:4392f6c0eb8a5668a69e23d168ffa70f0be9ccfd32b5cc2d26a34ae5b844552d", size = 4695 }, +] + +[[package]] +name = "nodeenv" +version = "1.9.1" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/43/16/fc88b08840de0e0a72a2f9d8c6bae36be573e475a6326ae854bcc549fc45/nodeenv-1.9.1.tar.gz", hash = "sha256:6ec12890a2dab7946721edbfbcd91f3319c6ccc9aec47be7c7e6b7011ee6645f", size = 47437 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/d2/1d/1b658dbd2b9fa9c4c9f32accbfc0205d532c8c6194dc0f2a4c0428e7128a/nodeenv-1.9.1-py2.py3-none-any.whl", hash = "sha256:ba11c9782d29c27c70ffbdda2d7415098754709be8a7056d79a737cd901155c9", size = 22314 }, +] + +[[package]] +name = "packaging" +version = "24.2" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/d0/63/68dbb6eb2de9cb10ee4c9c14a0148804425e13c4fb20d61cce69f53106da/packaging-24.2.tar.gz", hash = "sha256:c228a6dc5e932d346bc5739379109d49e8853dd8223571c7c5b55260edc0b97f", size = 163950 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/88/ef/eb23f262cca3c0c4eb7ab1933c3b1f03d021f2c48f54763065b6f0e321be/packaging-24.2-py3-none-any.whl", hash = "sha256:09abb1bccd265c01f4a3aa3f7a7db064b36514d2cba19a2f694fe6150451a759", size = 65451 }, +] + +[[package]] +name = "pathspec" +version = "0.12.1" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/ca/bc/f35b8446f4531a7cb215605d100cd88b7ac6f44ab3fc94870c120ab3adbf/pathspec-0.12.1.tar.gz", hash = "sha256:a482d51503a1ab33b1c67a6c3813a26953dbdc71c31dacaef9a838c4e29f5712", size = 51043 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/cc/20/ff623b09d963f88bfde16306a54e12ee5ea43e9b597108672ff3a408aad6/pathspec-0.12.1-py3-none-any.whl", hash = "sha256:a0d503e138a4c123b27490a4f7beda6a01c6f288df0e4a8b79c7eb0dc7b4cc08", size = 31191 }, +] + +[[package]] +name = "platformdirs" +version = "4.3.6" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/13/fc/128cc9cb8f03208bdbf93d3aa862e16d376844a14f9a0ce5cf4507372de4/platformdirs-4.3.6.tar.gz", hash = "sha256:357fb2acbc885b0419afd3ce3ed34564c13c9b95c89360cd9563f73aa5e2b907", size = 21302 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/3c/a6/bc1012356d8ece4d66dd75c4b9fc6c1f6650ddd5991e421177d9f8f671be/platformdirs-4.3.6-py3-none-any.whl", hash = "sha256:73e575e1408ab8103900836b97580d5307456908a03e92031bab39e4554cc3fb", size = 18439 }, +] + +[[package]] +name = "pluggy" +version = "1.5.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/96/2d/02d4312c973c6050a18b314a5ad0b3210edb65a906f868e31c111dede4a6/pluggy-1.5.0.tar.gz", hash = "sha256:2cffa88e94fdc978c4c574f15f9e59b7f4201d439195c3715ca9e2486f1d0cf1", size = 67955 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/88/5f/e351af9a41f866ac3f1fac4ca0613908d9a41741cfcf2228f4ad853b697d/pluggy-1.5.0-py3-none-any.whl", hash = "sha256:44e1ad92c8ca002de6377e165f3e0f1be63266ab4d554740532335b9d75ea669", size = 20556 }, +] + +[[package]] +name = "propcache" +version = "0.3.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/92/76/f941e63d55c0293ff7829dd21e7cf1147e90a526756869a9070f287a68c9/propcache-0.3.0.tar.gz", hash = "sha256:a8fd93de4e1d278046345f49e2238cdb298589325849b2645d4a94c53faeffc5", size = 42722 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/8d/2c/921f15dc365796ec23975b322b0078eae72995c7b4d49eba554c6a308d70/propcache-0.3.0-cp312-cp312-macosx_10_13_universal2.whl", hash = "sha256:e53d19c2bf7d0d1e6998a7e693c7e87300dd971808e6618964621ccd0e01fe4e", size = 79867 }, + { url = "https://files.pythonhosted.org/packages/11/a5/4a6cc1a559d1f2fb57ea22edc4245158cdffae92f7f92afcee2913f84417/propcache-0.3.0-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:a61a68d630e812b67b5bf097ab84e2cd79b48c792857dc10ba8a223f5b06a2af", size = 46109 }, + { url = "https://files.pythonhosted.org/packages/e1/6d/28bfd3af3a567ad7d667348e7f46a520bda958229c4d545ba138a044232f/propcache-0.3.0-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:fb91d20fa2d3b13deea98a690534697742029f4fb83673a3501ae6e3746508b5", size = 45635 }, + { url = "https://files.pythonhosted.org/packages/73/20/d75b42eaffe5075eac2f4e168f6393d21c664c91225288811d85451b2578/propcache-0.3.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:67054e47c01b7b349b94ed0840ccae075449503cf1fdd0a1fdd98ab5ddc2667b", size = 242159 }, + { url = "https://files.pythonhosted.org/packages/a5/fb/4b537dd92f9fd4be68042ec51c9d23885ca5fafe51ec24c58d9401034e5f/propcache-0.3.0-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:997e7b8f173a391987df40f3b52c423e5850be6f6df0dcfb5376365440b56667", size = 248163 }, + { url = "https://files.pythonhosted.org/packages/e7/af/8a9db04ac596d531ca0ef7dde518feaadfcdabef7b17d6a5ec59ee3effc2/propcache-0.3.0-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:8d663fd71491dde7dfdfc899d13a067a94198e90695b4321084c6e450743b8c7", size = 248794 }, + { url = "https://files.pythonhosted.org/packages/9d/c4/ecfc988879c0fd9db03228725b662d76cf484b6b46f7e92fee94e4b52490/propcache-0.3.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8884ba1a0fe7210b775106b25850f5e5a9dc3c840d1ae9924ee6ea2eb3acbfe7", size = 243912 }, + { url = "https://files.pythonhosted.org/packages/04/a2/298dd27184faa8b7d91cc43488b578db218b3cc85b54d912ed27b8c5597a/propcache-0.3.0-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:aa806bbc13eac1ab6291ed21ecd2dd426063ca5417dd507e6be58de20e58dfcf", size = 229402 }, + { url = "https://files.pythonhosted.org/packages/be/0d/efe7fec316ca92dbf4bc4a9ba49ca889c43ca6d48ab1d6fa99fc94e5bb98/propcache-0.3.0-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:6f4d7a7c0aff92e8354cceca6fe223973ddf08401047920df0fcb24be2bd5138", size = 226896 }, + { url = "https://files.pythonhosted.org/packages/60/63/72404380ae1d9c96d96e165aa02c66c2aae6072d067fc4713da5cde96762/propcache-0.3.0-cp312-cp312-musllinux_1_2_armv7l.whl", hash = "sha256:9be90eebc9842a93ef8335291f57b3b7488ac24f70df96a6034a13cb58e6ff86", size = 221447 }, + { url = "https://files.pythonhosted.org/packages/9d/18/b8392cab6e0964b67a30a8f4dadeaff64dc7022b5a34bb1d004ea99646f4/propcache-0.3.0-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:bf15fc0b45914d9d1b706f7c9c4f66f2b7b053e9517e40123e137e8ca8958b3d", size = 222440 }, + { url = "https://files.pythonhosted.org/packages/6f/be/105d9ceda0f97eff8c06bac1673448b2db2a497444de3646464d3f5dc881/propcache-0.3.0-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:5a16167118677d94bb48bfcd91e420088854eb0737b76ec374b91498fb77a70e", size = 234104 }, + { url = "https://files.pythonhosted.org/packages/cb/c9/f09a4ec394cfcce4053d8b2a04d622b5f22d21ba9bb70edd0cad061fa77b/propcache-0.3.0-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:41de3da5458edd5678b0f6ff66691507f9885f5fe6a0fb99a5d10d10c0fd2d64", size = 239086 }, + { url = "https://files.pythonhosted.org/packages/ea/aa/96f7f9ed6def82db67c972bdb7bd9f28b95d7d98f7e2abaf144c284bf609/propcache-0.3.0-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:728af36011bb5d344c4fe4af79cfe186729efb649d2f8b395d1572fb088a996c", size = 230991 }, + { url = "https://files.pythonhosted.org/packages/5a/11/bee5439de1307d06fad176f7143fec906e499c33d7aff863ea8428b8e98b/propcache-0.3.0-cp312-cp312-win32.whl", hash = "sha256:6b5b7fd6ee7b54e01759f2044f936dcf7dea6e7585f35490f7ca0420fe723c0d", size = 40337 }, + { url = "https://files.pythonhosted.org/packages/e4/17/e5789a54a0455a61cb9efc4ca6071829d992220c2998a27c59aeba749f6f/propcache-0.3.0-cp312-cp312-win_amd64.whl", hash = "sha256:2d15bc27163cd4df433e75f546b9ac31c1ba7b0b128bfb1b90df19082466ff57", size = 44404 }, + { url = "https://files.pythonhosted.org/packages/3a/0f/a79dd23a0efd6ee01ab0dc9750d8479b343bfd0c73560d59d271eb6a99d4/propcache-0.3.0-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:a2b9bf8c79b660d0ca1ad95e587818c30ccdb11f787657458d6f26a1ea18c568", size = 77287 }, + { url = "https://files.pythonhosted.org/packages/b8/51/76675703c90de38ac75adb8deceb3f3ad99b67ff02a0fa5d067757971ab8/propcache-0.3.0-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:b0c1a133d42c6fc1f5fbcf5c91331657a1ff822e87989bf4a6e2e39b818d0ee9", size = 44923 }, + { url = "https://files.pythonhosted.org/packages/01/9b/fd5ddbee66cf7686e73c516227c2fd9bf471dbfed0f48329d095ea1228d3/propcache-0.3.0-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:bb2f144c6d98bb5cbc94adeb0447cfd4c0f991341baa68eee3f3b0c9c0e83767", size = 44325 }, + { url = "https://files.pythonhosted.org/packages/13/1c/6961f11eb215a683b34b903b82bde486c606516c1466bf1fa67f26906d51/propcache-0.3.0-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d1323cd04d6e92150bcc79d0174ce347ed4b349d748b9358fd2e497b121e03c8", size = 225116 }, + { url = "https://files.pythonhosted.org/packages/ef/ea/f8410c40abcb2e40dffe9adeed017898c930974650a63e5c79b886aa9f73/propcache-0.3.0-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:3b812b3cb6caacd072276ac0492d249f210006c57726b6484a1e1805b3cfeea0", size = 229905 }, + { url = "https://files.pythonhosted.org/packages/ef/5a/a9bf90894001468bf8e6ea293bb00626cc9ef10f8eb7996e9ec29345c7ed/propcache-0.3.0-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:742840d1d0438eb7ea4280f3347598f507a199a35a08294afdcc560c3739989d", size = 233221 }, + { url = "https://files.pythonhosted.org/packages/dd/ce/fffdddd9725b690b01d345c1156b4c2cc6dca09ab5c23a6d07b8f37d6e2f/propcache-0.3.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:7c6e7e4f9167fddc438cd653d826f2222222564daed4116a02a184b464d3ef05", size = 227627 }, + { url = "https://files.pythonhosted.org/packages/58/ae/45c89a5994a334735a3032b48e8e4a98c05d9536ddee0719913dc27da548/propcache-0.3.0-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:a94ffc66738da99232ddffcf7910e0f69e2bbe3a0802e54426dbf0714e1c2ffe", size = 214217 }, + { url = "https://files.pythonhosted.org/packages/01/84/bc60188c3290ff8f5f4a92b9ca2d93a62e449c8daf6fd11ad517ad136926/propcache-0.3.0-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:3c6ec957025bf32b15cbc6b67afe233c65b30005e4c55fe5768e4bb518d712f1", size = 212921 }, + { url = "https://files.pythonhosted.org/packages/14/b3/39d60224048feef7a96edabb8217dc3f75415457e5ebbef6814f8b2a27b5/propcache-0.3.0-cp313-cp313-musllinux_1_2_armv7l.whl", hash = "sha256:549722908de62aa0b47a78b90531c022fa6e139f9166be634f667ff45632cc92", size = 208200 }, + { url = "https://files.pythonhosted.org/packages/9d/b3/0a6720b86791251273fff8a01bc8e628bc70903513bd456f86cde1e1ef84/propcache-0.3.0-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:5d62c4f6706bff5d8a52fd51fec6069bef69e7202ed481486c0bc3874912c787", size = 208400 }, + { url = "https://files.pythonhosted.org/packages/e9/4f/bb470f3e687790547e2e78105fb411f54e0cdde0d74106ccadd2521c6572/propcache-0.3.0-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:24c04f8fbf60094c531667b8207acbae54146661657a1b1be6d3ca7773b7a545", size = 218116 }, + { url = "https://files.pythonhosted.org/packages/34/71/277f7f9add469698ac9724c199bfe06f85b199542121a71f65a80423d62a/propcache-0.3.0-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:7c5f5290799a3f6539cc5e6f474c3e5c5fbeba74a5e1e5be75587746a940d51e", size = 222911 }, + { url = "https://files.pythonhosted.org/packages/92/e3/a7b9782aef5a2fc765b1d97da9ec7aed2f25a4e985703608e73232205e3f/propcache-0.3.0-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:4fa0e7c9c3cf7c276d4f6ab9af8adddc127d04e0fcabede315904d2ff76db626", size = 216563 }, + { url = "https://files.pythonhosted.org/packages/ab/76/0583ca2c551aa08ffcff87b2c6849c8f01c1f6fb815a5226f0c5c202173e/propcache-0.3.0-cp313-cp313-win32.whl", hash = "sha256:ee0bd3a7b2e184e88d25c9baa6a9dc609ba25b76daae942edfb14499ac7ec374", size = 39763 }, + { url = "https://files.pythonhosted.org/packages/80/ec/c6a84f9a36f608379b95f0e786c111d5465926f8c62f12be8cdadb02b15c/propcache-0.3.0-cp313-cp313-win_amd64.whl", hash = "sha256:1c8f7d896a16da9455f882870a507567d4f58c53504dc2d4b1e1d386dfe4588a", size = 43650 }, + { url = "https://files.pythonhosted.org/packages/ee/95/7d32e3560f5bf83fc2f2a4c1b0c181d327d53d5f85ebd045ab89d4d97763/propcache-0.3.0-cp313-cp313t-macosx_10_13_universal2.whl", hash = "sha256:e560fd75aaf3e5693b91bcaddd8b314f4d57e99aef8a6c6dc692f935cc1e6bbf", size = 82140 }, + { url = "https://files.pythonhosted.org/packages/86/89/752388f12e6027a5e63f5d075f15291ded48e2d8311314fff039da5a9b11/propcache-0.3.0-cp313-cp313t-macosx_10_13_x86_64.whl", hash = "sha256:65a37714b8ad9aba5780325228598a5b16c47ba0f8aeb3dc0514701e4413d7c0", size = 47296 }, + { url = "https://files.pythonhosted.org/packages/1b/4c/b55c98d586c69180d3048984a57a5ea238bdeeccf82dbfcd598e935e10bb/propcache-0.3.0-cp313-cp313t-macosx_11_0_arm64.whl", hash = "sha256:07700939b2cbd67bfb3b76a12e1412405d71019df00ca5697ce75e5ef789d829", size = 46724 }, + { url = "https://files.pythonhosted.org/packages/0f/b6/67451a437aed90c4e951e320b5b3d7eb584ade1d5592f6e5e8f678030989/propcache-0.3.0-cp313-cp313t-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7c0fdbdf6983526e269e5a8d53b7ae3622dd6998468821d660d0daf72779aefa", size = 291499 }, + { url = "https://files.pythonhosted.org/packages/ee/ff/e4179facd21515b24737e1e26e02615dfb5ed29416eed4cf5bc6ac5ce5fb/propcache-0.3.0-cp313-cp313t-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:794c3dd744fad478b6232289c866c25406ecdfc47e294618bdf1697e69bd64a6", size = 293911 }, + { url = "https://files.pythonhosted.org/packages/76/8d/94a8585992a064a23bd54f56c5e58c3b8bf0c0a06ae10e56f2353ae16c3d/propcache-0.3.0-cp313-cp313t-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:4544699674faf66fb6b4473a1518ae4999c1b614f0b8297b1cef96bac25381db", size = 293301 }, + { url = "https://files.pythonhosted.org/packages/b0/b8/2c860c92b4134f68c7716c6f30a0d723973f881c32a6d7a24c4ddca05fdf/propcache-0.3.0-cp313-cp313t-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:fddb8870bdb83456a489ab67c6b3040a8d5a55069aa6f72f9d872235fbc52f54", size = 281947 }, + { url = "https://files.pythonhosted.org/packages/cd/72/b564be7411b525d11757b713c757c21cd4dc13b6569c3b2b8f6d3c96fd5e/propcache-0.3.0-cp313-cp313t-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:f857034dc68d5ceb30fb60afb6ff2103087aea10a01b613985610e007053a121", size = 268072 }, + { url = "https://files.pythonhosted.org/packages/37/68/d94649e399e8d7fc051e5a4f2334efc567993525af083db145a70690a121/propcache-0.3.0-cp313-cp313t-musllinux_1_2_aarch64.whl", hash = "sha256:02df07041e0820cacc8f739510078f2aadcfd3fc57eaeeb16d5ded85c872c89e", size = 275190 }, + { url = "https://files.pythonhosted.org/packages/d8/3c/446e125f5bbbc1922964dd67cb541c01cdb678d811297b79a4ff6accc843/propcache-0.3.0-cp313-cp313t-musllinux_1_2_armv7l.whl", hash = "sha256:f47d52fd9b2ac418c4890aad2f6d21a6b96183c98021f0a48497a904199f006e", size = 254145 }, + { url = "https://files.pythonhosted.org/packages/f4/80/fd3f741483dc8e59f7ba7e05eaa0f4e11677d7db2077522b92ff80117a2a/propcache-0.3.0-cp313-cp313t-musllinux_1_2_i686.whl", hash = "sha256:9ff4e9ecb6e4b363430edf2c6e50173a63e0820e549918adef70515f87ced19a", size = 257163 }, + { url = "https://files.pythonhosted.org/packages/dc/cf/6292b5ce6ed0017e6a89024a827292122cc41b6259b30ada0c6732288513/propcache-0.3.0-cp313-cp313t-musllinux_1_2_ppc64le.whl", hash = "sha256:ecc2920630283e0783c22e2ac94427f8cca29a04cfdf331467d4f661f4072dac", size = 280249 }, + { url = "https://files.pythonhosted.org/packages/e8/f0/fd9b8247b449fe02a4f96538b979997e229af516d7462b006392badc59a1/propcache-0.3.0-cp313-cp313t-musllinux_1_2_s390x.whl", hash = "sha256:c441c841e82c5ba7a85ad25986014be8d7849c3cfbdb6004541873505929a74e", size = 288741 }, + { url = "https://files.pythonhosted.org/packages/64/71/cf831fdc2617f86cfd7f414cfc487d018e722dac8acc098366ce9bba0941/propcache-0.3.0-cp313-cp313t-musllinux_1_2_x86_64.whl", hash = "sha256:6c929916cbdb540d3407c66f19f73387f43e7c12fa318a66f64ac99da601bcdf", size = 277061 }, + { url = "https://files.pythonhosted.org/packages/42/78/9432542a35d944abeca9e02927a0de38cd7a298466d8ffa171536e2381c3/propcache-0.3.0-cp313-cp313t-win32.whl", hash = "sha256:0c3e893c4464ebd751b44ae76c12c5f5c1e4f6cbd6fbf67e3783cd93ad221863", size = 42252 }, + { url = "https://files.pythonhosted.org/packages/6f/45/960365f4f8978f48ebb56b1127adf33a49f2e69ecd46ac1f46d6cf78a79d/propcache-0.3.0-cp313-cp313t-win_amd64.whl", hash = "sha256:75e872573220d1ee2305b35c9813626e620768248425f58798413e9c39741f46", size = 46425 }, + { url = "https://files.pythonhosted.org/packages/b5/35/6c4c6fc8774a9e3629cd750dc24a7a4fb090a25ccd5c3246d127b70f9e22/propcache-0.3.0-py3-none-any.whl", hash = "sha256:67dda3c7325691c2081510e92c561f465ba61b975f481735aefdfc845d2cd043", size = 12101 }, +] + +[[package]] +name = "pyright" +version = "1.1.394" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "nodeenv" }, + { name = "typing-extensions" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/b1/e4/79f4d8a342eed6790fdebdb500e95062f319ee3d7d75ae27304ff995ae8c/pyright-1.1.394.tar.gz", hash = "sha256:56f2a3ab88c5214a451eb71d8f2792b7700434f841ea219119ade7f42ca93608", size = 3809348 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/d6/4c/50c74e3d589517a9712a61a26143b587dba6285434a17aebf2ce6b82d2c3/pyright-1.1.394-py3-none-any.whl", hash = "sha256:5f74cce0a795a295fb768759bbeeec62561215dea657edcaab48a932b031ddbb", size = 5679540 }, +] + +[[package]] +name = "pytest" +version = "8.3.4" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "colorama", marker = "sys_platform == 'win32'" }, + { name = "iniconfig" }, + { name = "packaging" }, + { name = "pluggy" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/05/35/30e0d83068951d90a01852cb1cef56e5d8a09d20c7f511634cc2f7e0372a/pytest-8.3.4.tar.gz", hash = "sha256:965370d062bce11e73868e0335abac31b4d3de0e82f4007408d242b4f8610761", size = 1445919 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/11/92/76a1c94d3afee238333bc0a42b82935dd8f9cf8ce9e336ff87ee14d9e1cf/pytest-8.3.4-py3-none-any.whl", hash = "sha256:50e16d954148559c9a74109af1eaf0c945ba2d8f30f0a3d3335edde19788b6f6", size = 343083 }, +] + +[[package]] +name = "pytest-asyncio" +version = "0.25.3" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "pytest" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/f2/a8/ecbc8ede70921dd2f544ab1cadd3ff3bf842af27f87bbdea774c7baa1d38/pytest_asyncio-0.25.3.tar.gz", hash = "sha256:fc1da2cf9f125ada7e710b4ddad05518d4cee187ae9412e9ac9271003497f07a", size = 54239 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/67/17/3493c5624e48fd97156ebaec380dcaafee9506d7e2c46218ceebbb57d7de/pytest_asyncio-0.25.3-py3-none-any.whl", hash = "sha256:9e89518e0f9bd08928f97a3482fdc4e244df17529460bc038291ccaf8f85c7c3", size = 19467 }, +] + +[[package]] +name = "pytest-cov" +version = "6.0.0" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "coverage" }, + { name = "pytest" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/be/45/9b538de8cef30e17c7b45ef42f538a94889ed6a16f2387a6c89e73220651/pytest-cov-6.0.0.tar.gz", hash = "sha256:fde0b595ca248bb8e2d76f020b465f3b107c9632e6a1d1705f17834c89dcadc0", size = 66945 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/36/3b/48e79f2cd6a61dbbd4807b4ed46cb564b4fd50a76166b1c4ea5c1d9e2371/pytest_cov-6.0.0-py3-none-any.whl", hash = "sha256:eee6f1b9e61008bd34975a4d5bab25801eb31898b032dd55addc93e96fcaaa35", size = 22949 }, +] + +[[package]] +name = "python-dateutil" +version = "2.9.0.post0" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "six" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/66/c0/0c8b6ad9f17a802ee498c46e004a0eb49bc148f2fd230864601a86dcf6db/python-dateutil-2.9.0.post0.tar.gz", hash = "sha256:37dd54208da7e1cd875388217d5e00ebd4179249f90fb72437e91a35459a0ad3", size = 342432 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/ec/57/56b9bcc3c9c6a792fcbaf139543cee77261f3651ca9da0c93f5c1221264b/python_dateutil-2.9.0.post0-py2.py3-none-any.whl", hash = "sha256:a8b2bc7bffae282281c8140a97d3aa9c14da0b136dfe83f850eea9a5f7470427", size = 229892 }, +] + +[[package]] +name = "ruff" +version = "0.9.7" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/39/8b/a86c300359861b186f18359adf4437ac8e4c52e42daa9eedc731ef9d5b53/ruff-0.9.7.tar.gz", hash = "sha256:643757633417907510157b206e490c3aa11cab0c087c912f60e07fbafa87a4c6", size = 3669813 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/b1/f3/3a1d22973291226df4b4e2ff70196b926b6f910c488479adb0eeb42a0d7f/ruff-0.9.7-py3-none-linux_armv6l.whl", hash = "sha256:99d50def47305fe6f233eb8dabfd60047578ca87c9dcb235c9723ab1175180f4", size = 11774588 }, + { url = "https://files.pythonhosted.org/packages/8e/c9/b881f4157b9b884f2994fd08ee92ae3663fb24e34b0372ac3af999aa7fc6/ruff-0.9.7-py3-none-macosx_10_12_x86_64.whl", hash = "sha256:d59105ae9c44152c3d40a9c40d6331a7acd1cdf5ef404fbe31178a77b174ea66", size = 11746848 }, + { url = "https://files.pythonhosted.org/packages/14/89/2f546c133f73886ed50a3d449e6bf4af27d92d2f960a43a93d89353f0945/ruff-0.9.7-py3-none-macosx_11_0_arm64.whl", hash = "sha256:f313b5800483770bd540cddac7c90fc46f895f427b7820f18fe1822697f1fec9", size = 11177525 }, + { url = "https://files.pythonhosted.org/packages/d7/93/6b98f2c12bf28ab9def59c50c9c49508519c5b5cfecca6de871cf01237f6/ruff-0.9.7-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:042ae32b41343888f59c0a4148f103208bf6b21c90118d51dc93a68366f4e903", size = 11996580 }, + { url = "https://files.pythonhosted.org/packages/8e/3f/b3fcaf4f6d875e679ac2b71a72f6691a8128ea3cb7be07cbb249f477c061/ruff-0.9.7-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:87862589373b33cc484b10831004e5e5ec47dc10d2b41ba770e837d4f429d721", size = 11525674 }, + { url = "https://files.pythonhosted.org/packages/f0/48/33fbf18defb74d624535d5d22adcb09a64c9bbabfa755bc666189a6b2210/ruff-0.9.7-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:a17e1e01bee0926d351a1ee9bc15c445beae888f90069a6192a07a84af544b6b", size = 12739151 }, + { url = "https://files.pythonhosted.org/packages/63/b5/7e161080c5e19fa69495cbab7c00975ef8a90f3679caa6164921d7f52f4a/ruff-0.9.7-py3-none-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:7c1f880ac5b2cbebd58b8ebde57069a374865c73f3bf41f05fe7a179c1c8ef22", size = 13416128 }, + { url = "https://files.pythonhosted.org/packages/4e/c8/b5e7d61fb1c1b26f271ac301ff6d9de5e4d9a9a63f67d732fa8f200f0c88/ruff-0.9.7-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:e63fc20143c291cab2841dbb8260e96bafbe1ba13fd3d60d28be2c71e312da49", size = 12870858 }, + { url = "https://files.pythonhosted.org/packages/da/cb/2a1a8e4e291a54d28259f8fc6a674cd5b8833e93852c7ef5de436d6ed729/ruff-0.9.7-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:91ff963baed3e9a6a4eba2a02f4ca8eaa6eba1cc0521aec0987da8d62f53cbef", size = 14786046 }, + { url = "https://files.pythonhosted.org/packages/ca/6c/c8f8a313be1943f333f376d79724260da5701426c0905762e3ddb389e3f4/ruff-0.9.7-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:88362e3227c82f63eaebf0b2eff5b88990280fb1ecf7105523883ba8c3aaf6fb", size = 12550834 }, + { url = "https://files.pythonhosted.org/packages/9d/ad/f70cf5e8e7c52a25e166bdc84c082163c9c6f82a073f654c321b4dff9660/ruff-0.9.7-py3-none-musllinux_1_2_aarch64.whl", hash = "sha256:0372c5a90349f00212270421fe91874b866fd3626eb3b397ede06cd385f6f7e0", size = 11961307 }, + { url = "https://files.pythonhosted.org/packages/52/d5/4f303ea94a5f4f454daf4d02671b1fbfe2a318b5fcd009f957466f936c50/ruff-0.9.7-py3-none-musllinux_1_2_armv7l.whl", hash = "sha256:d76b8ab60e99e6424cd9d3d923274a1324aefce04f8ea537136b8398bbae0a62", size = 11612039 }, + { url = "https://files.pythonhosted.org/packages/eb/c8/bd12a23a75603c704ce86723be0648ba3d4ecc2af07eecd2e9fa112f7e19/ruff-0.9.7-py3-none-musllinux_1_2_i686.whl", hash = "sha256:0c439bdfc8983e1336577f00e09a4e7a78944fe01e4ea7fe616d00c3ec69a3d0", size = 12168177 }, + { url = "https://files.pythonhosted.org/packages/cc/57/d648d4f73400fef047d62d464d1a14591f2e6b3d4a15e93e23a53c20705d/ruff-0.9.7-py3-none-musllinux_1_2_x86_64.whl", hash = "sha256:115d1f15e8fdd445a7b4dc9a30abae22de3f6bcabeb503964904471691ef7606", size = 12610122 }, + { url = "https://files.pythonhosted.org/packages/49/79/acbc1edd03ac0e2a04ae2593555dbc9990b34090a9729a0c4c0cf20fb595/ruff-0.9.7-py3-none-win32.whl", hash = "sha256:e9ece95b7de5923cbf38893f066ed2872be2f2f477ba94f826c8defdd6ec6b7d", size = 9988751 }, + { url = "https://files.pythonhosted.org/packages/6d/95/67153a838c6b6ba7a2401241fd8a00cd8c627a8e4a0491b8d853dedeffe0/ruff-0.9.7-py3-none-win_amd64.whl", hash = "sha256:3770fe52b9d691a15f0b87ada29c45324b2ace8f01200fb0c14845e499eb0c2c", size = 11002987 }, + { url = "https://files.pythonhosted.org/packages/63/6a/aca01554949f3a401991dc32fe22837baeaccb8a0d868256cbb26a029778/ruff-0.9.7-py3-none-win_arm64.whl", hash = "sha256:b075a700b2533feb7a01130ff656a4ec0d5f340bb540ad98759b8401c32c2037", size = 10177763 }, +] + +[[package]] +name = "six" +version = "1.17.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/94/e7/b2c673351809dca68a0e064b6af791aa332cf192da575fd474ed7d6f16a2/six-1.17.0.tar.gz", hash = "sha256:ff70335d468e7eb6ec65b95b99d3a2836546063f63acc5171de367e834932a81", size = 34031 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/b7/ce/149a00dd41f10bc29e5921b496af8b574d8413afcd5e30dfa0ed46c2cc5e/six-1.17.0-py2.py3-none-any.whl", hash = "sha256:4721f391ed90541fddacab5acf947aa0d3dc7d27b2e1e8eda2be8970586c3274", size = 11050 }, +] + +[[package]] +name = "smithy-aws-core" +version = "0.1.0" +source = { editable = "packages/smithy-aws-core" } +dependencies = [ + { name = "smithy-core" }, +] + +[package.metadata] +requires-dist = [{ name = "smithy-core", editable = "packages/smithy-core" }] + +[[package]] +name = "smithy-core" +version = "0.1.0" +source = { editable = "packages/smithy-core" } + +[package.dev-dependencies] +dev = [ + { name = "freezegun" }, +] + +[package.metadata] + +[package.metadata.requires-dev] +dev = [{ name = "freezegun", specifier = ">=1.5.1" }] + +[[package]] +name = "smithy-event-stream" +version = "0.1.0" +source = { editable = "packages/smithy-event-stream" } +dependencies = [ + { name = "smithy-core" }, +] + +[package.metadata] +requires-dist = [{ name = "smithy-core", editable = "packages/smithy-core" }] + +[[package]] +name = "smithy-http" +version = "0.1.0" +source = { editable = "packages/smithy-http" } +dependencies = [ + { name = "smithy-core" }, +] + +[package.optional-dependencies] +aiohttp = [ + { name = "aiohttp" }, +] +awscrt = [ + { name = "awscrt" }, +] + +[package.metadata] +requires-dist = [ + { name = "aiohttp", marker = "extra == 'aiohttp'", specifier = ">=3.11.12" }, + { name = "awscrt", marker = "extra == 'awscrt'", specifier = ">=0.23.10" }, + { name = "smithy-core", editable = "packages/smithy-core" }, +] +provides-extras = ["awscrt", "aiohttp"] + +[[package]] +name = "smithy-json" +version = "0.1.0" +source = { editable = "packages/smithy-json" } +dependencies = [ + { name = "ijson" }, + { name = "smithy-core" }, +] + +[package.metadata] +requires-dist = [ + { name = "ijson", specifier = ">=3.3.0" }, + { name = "smithy-core", editable = "packages/smithy-core" }, +] + +[[package]] +name = "smithy-python" +version = "0.1.0" +source = { virtual = "." } + +[package.dev-dependencies] +dev = [ + { name = "black" }, + { name = "docformatter" }, + { name = "pyright" }, + { name = "pytest" }, + { name = "pytest-asyncio" }, + { name = "pytest-cov" }, + { name = "ruff" }, +] + +[package.metadata] + +[package.metadata.requires-dev] +dev = [ + { name = "black", specifier = ">=25.1.0" }, + { name = "docformatter", specifier = ">=1.7.5" }, + { name = "pyright", specifier = ">=1.1.394" }, + { name = "pytest", specifier = ">=8.3.4" }, + { name = "pytest-asyncio", specifier = ">=0.25.3" }, + { name = "pytest-cov", specifier = ">=6.0.0" }, + { name = "ruff", specifier = ">=0.9.7" }, +] + +[[package]] +name = "typing-extensions" +version = "4.12.2" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/df/db/f35a00659bc03fec321ba8bce9420de607a1d37f8342eee1863174c69557/typing_extensions-4.12.2.tar.gz", hash = "sha256:1a7ead55c7e559dd4dee8856e3a88b41225abfe1ce8df57b7c13915fe121ffb8", size = 85321 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/26/9f/ad63fc0248c5379346306f8668cda6e2e2e9c95e01216d2b8ffd9ff037d0/typing_extensions-4.12.2-py3-none-any.whl", hash = "sha256:04e5ca0351e0f3f85c6853954072df659d0d13fac324d0072316b67d7794700d", size = 37438 }, +] + +[[package]] +name = "untokenize" +version = "0.1.1" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/f7/46/e7cea8159199096e1df52da20a57a6665da80c37fb8aeb848a3e47442c32/untokenize-0.1.1.tar.gz", hash = "sha256:3865dbbbb8efb4bb5eaa72f1be7f3e0be00ea8b7f125c69cbd1f5fda926f37a2", size = 3099 } + +[[package]] +name = "yarl" +version = "1.18.3" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "idna" }, + { name = "multidict" }, + { name = "propcache" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/b7/9d/4b94a8e6d2b51b599516a5cb88e5bc99b4d8d4583e468057eaa29d5f0918/yarl-1.18.3.tar.gz", hash = "sha256:ac1801c45cbf77b6c99242eeff4fffb5e4e73a800b5c4ad4fc0be5def634d2e1", size = 181062 } +wheels = [ + { url = "https://files.pythonhosted.org/packages/33/85/bd2e2729752ff4c77338e0102914897512e92496375e079ce0150a6dc306/yarl-1.18.3-cp312-cp312-macosx_10_13_universal2.whl", hash = "sha256:1dd4bdd05407ced96fed3d7f25dbbf88d2ffb045a0db60dbc247f5b3c5c25d50", size = 142644 }, + { url = "https://files.pythonhosted.org/packages/ff/74/1178322cc0f10288d7eefa6e4a85d8d2e28187ccab13d5b844e8b5d7c88d/yarl-1.18.3-cp312-cp312-macosx_10_13_x86_64.whl", hash = "sha256:7c33dd1931a95e5d9a772d0ac5e44cac8957eaf58e3c8da8c1414de7dd27c576", size = 94962 }, + { url = "https://files.pythonhosted.org/packages/be/75/79c6acc0261e2c2ae8a1c41cf12265e91628c8c58ae91f5ff59e29c0787f/yarl-1.18.3-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:25b411eddcfd56a2f0cd6a384e9f4f7aa3efee14b188de13048c25b5e91f1640", size = 92795 }, + { url = "https://files.pythonhosted.org/packages/6b/32/927b2d67a412c31199e83fefdce6e645247b4fb164aa1ecb35a0f9eb2058/yarl-1.18.3-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:436c4fc0a4d66b2badc6c5fc5ef4e47bb10e4fd9bf0c79524ac719a01f3607c2", size = 332368 }, + { url = "https://files.pythonhosted.org/packages/19/e5/859fca07169d6eceeaa4fde1997c91d8abde4e9a7c018e371640c2da2b71/yarl-1.18.3-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:e35ef8683211db69ffe129a25d5634319a677570ab6b2eba4afa860f54eeaf75", size = 342314 }, + { url = "https://files.pythonhosted.org/packages/08/75/76b63ccd91c9e03ab213ef27ae6add2e3400e77e5cdddf8ed2dbc36e3f21/yarl-1.18.3-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:84b2deecba4a3f1a398df819151eb72d29bfeb3b69abb145a00ddc8d30094512", size = 341987 }, + { url = "https://files.pythonhosted.org/packages/1a/e1/a097d5755d3ea8479a42856f51d97eeff7a3a7160593332d98f2709b3580/yarl-1.18.3-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:00e5a1fea0fd4f5bfa7440a47eff01d9822a65b4488f7cff83155a0f31a2ecba", size = 336914 }, + { url = "https://files.pythonhosted.org/packages/0b/42/e1b4d0e396b7987feceebe565286c27bc085bf07d61a59508cdaf2d45e63/yarl-1.18.3-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:d0e883008013c0e4aef84dcfe2a0b172c4d23c2669412cf5b3371003941f72bb", size = 325765 }, + { url = "https://files.pythonhosted.org/packages/7e/18/03a5834ccc9177f97ca1bbb245b93c13e58e8225276f01eedc4cc98ab820/yarl-1.18.3-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:5a3f356548e34a70b0172d8890006c37be92995f62d95a07b4a42e90fba54272", size = 344444 }, + { url = "https://files.pythonhosted.org/packages/c8/03/a713633bdde0640b0472aa197b5b86e90fbc4c5bc05b727b714cd8a40e6d/yarl-1.18.3-cp312-cp312-musllinux_1_2_armv7l.whl", hash = "sha256:ccd17349166b1bee6e529b4add61727d3f55edb7babbe4069b5764c9587a8cc6", size = 340760 }, + { url = "https://files.pythonhosted.org/packages/eb/99/f6567e3f3bbad8fd101886ea0276c68ecb86a2b58be0f64077396cd4b95e/yarl-1.18.3-cp312-cp312-musllinux_1_2_i686.whl", hash = "sha256:b958ddd075ddba5b09bb0be8a6d9906d2ce933aee81100db289badbeb966f54e", size = 346484 }, + { url = "https://files.pythonhosted.org/packages/8e/a9/84717c896b2fc6cb15bd4eecd64e34a2f0a9fd6669e69170c73a8b46795a/yarl-1.18.3-cp312-cp312-musllinux_1_2_ppc64le.whl", hash = "sha256:c7d79f7d9aabd6011004e33b22bc13056a3e3fb54794d138af57f5ee9d9032cb", size = 359864 }, + { url = "https://files.pythonhosted.org/packages/1e/2e/d0f5f1bef7ee93ed17e739ec8dbcb47794af891f7d165fa6014517b48169/yarl-1.18.3-cp312-cp312-musllinux_1_2_s390x.whl", hash = "sha256:4891ed92157e5430874dad17b15eb1fda57627710756c27422200c52d8a4e393", size = 364537 }, + { url = "https://files.pythonhosted.org/packages/97/8a/568d07c5d4964da5b02621a517532adb8ec5ba181ad1687191fffeda0ab6/yarl-1.18.3-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:ce1af883b94304f493698b00d0f006d56aea98aeb49d75ec7d98cd4a777e9285", size = 357861 }, + { url = "https://files.pythonhosted.org/packages/7d/e3/924c3f64b6b3077889df9a1ece1ed8947e7b61b0a933f2ec93041990a677/yarl-1.18.3-cp312-cp312-win32.whl", hash = "sha256:f91c4803173928a25e1a55b943c81f55b8872f0018be83e3ad4938adffb77dd2", size = 84097 }, + { url = "https://files.pythonhosted.org/packages/34/45/0e055320daaabfc169b21ff6174567b2c910c45617b0d79c68d7ab349b02/yarl-1.18.3-cp312-cp312-win_amd64.whl", hash = "sha256:7e2ee16578af3b52ac2f334c3b1f92262f47e02cc6193c598502bd46f5cd1477", size = 90399 }, + { url = "https://files.pythonhosted.org/packages/30/c7/c790513d5328a8390be8f47be5d52e141f78b66c6c48f48d241ca6bd5265/yarl-1.18.3-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:90adb47ad432332d4f0bc28f83a5963f426ce9a1a8809f5e584e704b82685dcb", size = 140789 }, + { url = "https://files.pythonhosted.org/packages/30/aa/a2f84e93554a578463e2edaaf2300faa61c8701f0898725842c704ba5444/yarl-1.18.3-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:913829534200eb0f789d45349e55203a091f45c37a2674678744ae52fae23efa", size = 94144 }, + { url = "https://files.pythonhosted.org/packages/c6/fc/d68d8f83714b221a85ce7866832cba36d7c04a68fa6a960b908c2c84f325/yarl-1.18.3-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:ef9f7768395923c3039055c14334ba4d926f3baf7b776c923c93d80195624782", size = 91974 }, + { url = "https://files.pythonhosted.org/packages/56/4e/d2563d8323a7e9a414b5b25341b3942af5902a2263d36d20fb17c40411e2/yarl-1.18.3-cp313-cp313-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:88a19f62ff30117e706ebc9090b8ecc79aeb77d0b1f5ec10d2d27a12bc9f66d0", size = 333587 }, + { url = "https://files.pythonhosted.org/packages/25/c9/cfec0bc0cac8d054be223e9f2c7909d3e8442a856af9dbce7e3442a8ec8d/yarl-1.18.3-cp313-cp313-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:e17c9361d46a4d5addf777c6dd5eab0715a7684c2f11b88c67ac37edfba6c482", size = 344386 }, + { url = "https://files.pythonhosted.org/packages/ab/5d/4c532190113b25f1364d25f4c319322e86232d69175b91f27e3ebc2caf9a/yarl-1.18.3-cp313-cp313-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1a74a13a4c857a84a845505fd2d68e54826a2cd01935a96efb1e9d86c728e186", size = 345421 }, + { url = "https://files.pythonhosted.org/packages/23/d1/6cdd1632da013aa6ba18cee4d750d953104a5e7aac44e249d9410a972bf5/yarl-1.18.3-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:41f7ce59d6ee7741af71d82020346af364949314ed3d87553763a2df1829cc58", size = 339384 }, + { url = "https://files.pythonhosted.org/packages/9a/c4/6b3c39bec352e441bd30f432cda6ba51681ab19bb8abe023f0d19777aad1/yarl-1.18.3-cp313-cp313-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:f52a265001d830bc425f82ca9eabda94a64a4d753b07d623a9f2863fde532b53", size = 326689 }, + { url = "https://files.pythonhosted.org/packages/23/30/07fb088f2eefdc0aa4fc1af4e3ca4eb1a3aadd1ce7d866d74c0f124e6a85/yarl-1.18.3-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:82123d0c954dc58db301f5021a01854a85bf1f3bb7d12ae0c01afc414a882ca2", size = 345453 }, + { url = "https://files.pythonhosted.org/packages/63/09/d54befb48f9cd8eec43797f624ec37783a0266855f4930a91e3d5c7717f8/yarl-1.18.3-cp313-cp313-musllinux_1_2_armv7l.whl", hash = "sha256:2ec9bbba33b2d00999af4631a3397d1fd78290c48e2a3e52d8dd72db3a067ac8", size = 341872 }, + { url = "https://files.pythonhosted.org/packages/91/26/fd0ef9bf29dd906a84b59f0cd1281e65b0c3e08c6aa94b57f7d11f593518/yarl-1.18.3-cp313-cp313-musllinux_1_2_i686.whl", hash = "sha256:fbd6748e8ab9b41171bb95c6142faf068f5ef1511935a0aa07025438dd9a9bc1", size = 347497 }, + { url = "https://files.pythonhosted.org/packages/d9/b5/14ac7a256d0511b2ac168d50d4b7d744aea1c1aa20c79f620d1059aab8b2/yarl-1.18.3-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:877d209b6aebeb5b16c42cbb377f5f94d9e556626b1bfff66d7b0d115be88d0a", size = 359981 }, + { url = "https://files.pythonhosted.org/packages/ca/b3/d493221ad5cbd18bc07e642894030437e405e1413c4236dd5db6e46bcec9/yarl-1.18.3-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:b464c4ab4bfcb41e3bfd3f1c26600d038376c2de3297760dfe064d2cb7ea8e10", size = 366229 }, + { url = "https://files.pythonhosted.org/packages/04/56/6a3e2a5d9152c56c346df9b8fb8edd2c8888b1e03f96324d457e5cf06d34/yarl-1.18.3-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:8d39d351e7faf01483cc7ff7c0213c412e38e5a340238826be7e0e4da450fdc8", size = 360383 }, + { url = "https://files.pythonhosted.org/packages/fd/b7/4b3c7c7913a278d445cc6284e59b2e62fa25e72758f888b7a7a39eb8423f/yarl-1.18.3-cp313-cp313-win32.whl", hash = "sha256:61ee62ead9b68b9123ec24bc866cbef297dd266175d53296e2db5e7f797f902d", size = 310152 }, + { url = "https://files.pythonhosted.org/packages/f5/d5/688db678e987c3e0fb17867970700b92603cadf36c56e5fb08f23e822a0c/yarl-1.18.3-cp313-cp313-win_amd64.whl", hash = "sha256:578e281c393af575879990861823ef19d66e2b1d0098414855dd367e234f5b3c", size = 315723 }, + { url = "https://files.pythonhosted.org/packages/f5/4b/a06e0ec3d155924f77835ed2d167ebd3b211a7b0853da1cf8d8414d784ef/yarl-1.18.3-py3-none-any.whl", hash = "sha256:b57f4f58099328dfb26c6a771d09fb20dbbae81d20cfb66141251ea063bd101b", size = 45109 }, +]