From 7fca06493baaa92be2c8564090916c7d312a37e6 Mon Sep 17 00:00:00 2001 From: Simon Krol Date: Wed, 31 Dec 2025 11:51:55 -0500 Subject: [PATCH] Update to version v4.0.3 --- CHANGELOG.md | 11 ++ NOTICE.txt | 12 +- .../ecr/gaab-strands-agent/pyproject.toml | 2 +- deployment/ecr/gaab-strands-agent/uv.lock | 16 +-- deployment/ecr/gaab-strands-common/uv.lock | 12 +- .../ecr/gaab-strands-workflow-agent/uv.lock | 12 +- deployment/run-unit-tests.sh | 11 +- source/infrastructure/cdk.json | 2 +- source/infrastructure/package-lock.json | 4 +- source/infrastructure/package.json | 2 +- .../node-lambda/package-lock.json | 4 +- .../mock-lambda-func/node-lambda/package.json | 2 +- .../python-lambda/pyproject.toml | 2 +- .../typescript-lambda/package-lock.json | 4 +- .../typescript-lambda/package.json | 2 +- .../test/mock-ui/package-lock.json | 4 +- .../infrastructure/test/mock-ui/package.json | 2 +- .../lambda/agentcore-invocation/poetry.lock | 6 +- .../agentcore-invocation/pyproject.toml | 2 +- source/lambda/chat/poetry.lock | 66 +++++++---- source/lambda/chat/pyproject.toml | 3 +- .../test_conversation_memory_factory.py | 24 ++-- .../factories/test_knowledge_base_factory.py | 33 +++--- .../chat/test/clients/test_llm_chat_client.py | 35 +++--- .../knowledge/test_bedrock_knowledge_base.py | 44 ++++--- .../custom-authorizer/package-lock.json | 4 +- source/lambda/custom-authorizer/package.json | 2 +- source/lambda/custom-resource/poetry.lock | 44 ++++++- source/lambda/custom-resource/pyproject.toml | 3 +- .../lambda/ext-idp-group-mapper/poetry.lock | 6 +- .../ext-idp-group-mapper/pyproject.toml | 2 +- .../feedback-management/package-lock.json | 4 +- .../lambda/feedback-management/package.json | 2 +- .../lambda/files-management/package-lock.json | 4 +- source/lambda/files-management/package.json | 2 +- .../package-lock.json | 4 +- .../files-metadata-management/package.json | 2 +- source/lambda/invoke-agent/poetry.lock | 6 +- source/lambda/invoke-agent/pyproject.toml | 2 +- .../package-lock.json | 4 +- .../aws-node-user-agent-config/package.json | 2 +- .../layers/aws-sdk-lib/package-lock.json | 4 +- source/lambda/layers/aws-sdk-lib/package.json | 2 +- source/lambda/layers/aws_boto3/pyproject.toml | 2 +- .../layers/custom_boto3_init/poetry.lock | 4 +- .../layers/custom_boto3_init/pyproject.toml | 2 +- source/lambda/layers/langchain/poetry.lock | 22 +--- source/lambda/layers/langchain/pyproject.toml | 4 +- source/lambda/model-info/package-lock.json | 4 +- source/lambda/model-info/package.json | 2 +- .../lambda/use-case-details/package-lock.json | 4 +- source/lambda/use-case-details/package.json | 2 +- .../use-case-management/package-lock.json | 4 +- .../lambda/use-case-management/package.json | 2 +- .../websocket-connectors/package-lock.json | 4 +- .../lambda/websocket-connectors/package.json | 2 +- source/scripts/v2_migration/pyproject.toml | 2 +- source/ui-chat/package-lock.json | 4 +- source/ui-chat/package.json | 2 +- .../src/utils/extract-thinking-content.ts | 3 + source/ui-deployment/package-lock.json | 110 ++++++++++++++---- source/ui-deployment/package.json | 2 +- 62 files changed, 373 insertions(+), 224 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 734eb12c..a7ad209e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,17 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [4.0.3] - 2025-12-31 + +### Security + +- Upgraded langchain-core to `0.3.81` to mitigate [CVE-2025-68664](https://avd.aquasec.com/nvd/2025/cve-2025-68664/) +- Upgraded qs to `6.14.1` to mitigate [CVE-2025-15284](https://avd.aquasec.com/nvd/2025/cve-2025-15284/) + +### Changed + +- Parallelized execution of chat and custom resource lambda tests in unit test script. + ## [4.0.2] - 2025-12-11 ### Security diff --git a/NOTICE.txt b/NOTICE.txt index 41eac261..9f9b88e3 100644 --- a/NOTICE.txt +++ b/NOTICE.txt @@ -953,6 +953,7 @@ diff-sequences under the MIT license. dijkstrajs under the MIT license. dir-glob under the MIT license. dlv under the MIT license. +docker/library/python under the MIT license. doctrine under the Apache-2.0 license. docutils under the BSD license. dom-accessibility-api under the MIT license. @@ -1033,6 +1034,7 @@ event-target-shim under the MIT license. eventemitter2 under the MIT license. events under the MIT license. execa under the MIT license. +execnet under the MIT license. executable under the MIT license. exit under the MIT license. expect under the MIT license. @@ -1285,7 +1287,7 @@ json-stringify-safe under the ISC license. json5 under the MIT license. jsonc-parser under the MIT license. jsonfile under the MIT license. -jsonify under the Public Domain license. +jsonify under the MIT license. jsonpatch under the 0BSD license. jsonpath-ng under the Apache-2.0 license. jsonpath-plus under the MIT license. @@ -1455,7 +1457,7 @@ normalize-path under the MIT license. npm-run-path under the MIT license. npmlog under the ISC license. nullthrows under the MIT license. -numpy under the Apache-2.0 license. +numpy under the BSD-3-Clause license. nwsapi under the MIT license. ob1 under the MIT license. object-assign under the MIT license. @@ -1549,12 +1551,12 @@ pyasn1 under the BSD-2-Clause license. pycparser under the 0BSD license. pydantic under the MIT license. pydantic-core under the MIT license. -PyJWT under the MIT license. -PyJWT under the MIT license. +pyjwt under the MIT license. pytest under the MIT license. pytest-asyncio under the Apache-2.0 license. pytest-cov under the MIT license. pytest-env under the MIT license. +pytest-xdist under the MIT license. python-dateutil under the Dual License license(s). pyyaml under the MIT license. qrcode under the MIT license. @@ -1854,7 +1856,7 @@ webidl-conversions under the BSD-2-Clause license. webpack under the MIT license. webpack-sources under the MIT license. weekstart under the MIT license. -werkzeug under the 0BSD license. +werkzeug under the BSD-3-Clause license. whatwg-encoding under the MIT license. whatwg-fetch under the MIT license. whatwg-mimetype under the MIT license. diff --git a/deployment/ecr/gaab-strands-agent/pyproject.toml b/deployment/ecr/gaab-strands-agent/pyproject.toml index a5580f81..e09e6fc5 100644 --- a/deployment/ecr/gaab-strands-agent/pyproject.toml +++ b/deployment/ecr/gaab-strands-agent/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "gaab-strands-agent" -version = "4.0.0" +version = "4.0.3" description = "GAAB Strands Agent Runtime for Amazon Bedrock AgentCore" readme = "README.md" requires-python = ">=3.13" diff --git a/deployment/ecr/gaab-strands-agent/uv.lock b/deployment/ecr/gaab-strands-agent/uv.lock index c09df7ed..8eb64fe1 100644 --- a/deployment/ecr/gaab-strands-agent/uv.lock +++ b/deployment/ecr/gaab-strands-agent/uv.lock @@ -1,5 +1,5 @@ version = 1 -revision = 2 +revision = 3 requires-python = ">=3.13" [[package]] @@ -627,7 +627,7 @@ wheels = [ [[package]] name = "gaab-strands-agent" -version = "4.0.0" +version = "4.0.3" source = { editable = "." } dependencies = [ { name = "aws-opentelemetry-distro" }, @@ -2795,11 +2795,11 @@ wheels = [ [[package]] name = "urllib3" -version = "2.5.0" +version = "2.6.1" source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/15/22/9ee70a2574a4f4599c47dd506532914ce044817c7752a79b6a51286319bc/urllib3-2.5.0.tar.gz", hash = "sha256:3fc47733c7e419d4bc3f6b3dc2b4f890bb743906a30d56ba4a5bfa4bbff92760", size = 393185, upload-time = "2025-06-18T14:07:41.644Z" } +sdist = { url = "https://files.pythonhosted.org/packages/5e/1d/0f3a93cca1ac5e8287842ed4eebbd0f7a991315089b1a0b01c7788aa7b63/urllib3-2.6.1.tar.gz", hash = "sha256:5379eb6e1aba4088bae84f8242960017ec8d8e3decf30480b3a1abdaa9671a3f", size = 432678, upload-time = "2025-12-08T15:25:26.773Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/a7/c2/fe1e52489ae3122415c51f387e221dd0773709bad6c6cdaa599e8a2c5185/urllib3-2.5.0-py3-none-any.whl", hash = "sha256:e6b01673c0fa6a13e374b50871808eb3bf7046c4b125b216f6bf1cc604cff0dc", size = 129795, upload-time = "2025-06-18T14:07:40.39Z" }, + { url = "https://files.pythonhosted.org/packages/bc/56/190ceb8cb10511b730b564fb1e0293fa468363dbad26145c34928a60cb0c/urllib3-2.6.1-py3-none-any.whl", hash = "sha256:e67d06fe947c36a7ca39f4994b08d73922d40e6cca949907be05efa6fd75110b", size = 131138, upload-time = "2025-12-08T15:25:25.51Z" }, ] [[package]] @@ -2847,14 +2847,14 @@ wheels = [ [[package]] name = "werkzeug" -version = "3.1.3" +version = "3.1.4" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "markupsafe" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/9f/69/83029f1f6300c5fb2471d621ab06f6ec6b3324685a2ce0f9777fd4a8b71e/werkzeug-3.1.3.tar.gz", hash = "sha256:60723ce945c19328679790e3282cc758aa4a6040e4bb330f53d30fa546d44746", size = 806925, upload-time = "2024-11-08T15:52:18.093Z" } +sdist = { url = "https://files.pythonhosted.org/packages/45/ea/b0f8eeb287f8df9066e56e831c7824ac6bab645dd6c7a8f4b2d767944f9b/werkzeug-3.1.4.tar.gz", hash = "sha256:cd3cd98b1b92dc3b7b3995038826c68097dcb16f9baa63abe35f20eafeb9fe5e", size = 864687, upload-time = "2025-11-29T02:15:22.841Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/52/24/ab44c871b0f07f491e5d2ad12c9bd7358e527510618cb1b803a88e986db1/werkzeug-3.1.3-py3-none-any.whl", hash = "sha256:54b78bf3716d19a65be4fceccc0d1d7b89e608834989dfae50ea87564639213e", size = 224498, upload-time = "2024-11-08T15:52:16.132Z" }, + { url = "https://files.pythonhosted.org/packages/2f/f9/9e082990c2585c744734f85bec79b5dae5df9c974ffee58fe421652c8e91/werkzeug-3.1.4-py3-none-any.whl", hash = "sha256:2ad50fb9ed09cc3af22c54698351027ace879a0b60a3b5edf5730b2f7d876905", size = 224960, upload-time = "2025-11-29T02:15:21.13Z" }, ] [[package]] diff --git a/deployment/ecr/gaab-strands-common/uv.lock b/deployment/ecr/gaab-strands-common/uv.lock index 6531a620..fd318baf 100644 --- a/deployment/ecr/gaab-strands-common/uv.lock +++ b/deployment/ecr/gaab-strands-common/uv.lock @@ -1154,11 +1154,11 @@ wheels = [ [[package]] name = "urllib3" -version = "2.5.0" +version = "2.6.1" source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/15/22/9ee70a2574a4f4599c47dd506532914ce044817c7752a79b6a51286319bc/urllib3-2.5.0.tar.gz", hash = "sha256:3fc47733c7e419d4bc3f6b3dc2b4f890bb743906a30d56ba4a5bfa4bbff92760", size = 393185, upload-time = "2025-06-18T14:07:41.644Z" } +sdist = { url = "https://files.pythonhosted.org/packages/5e/1d/0f3a93cca1ac5e8287842ed4eebbd0f7a991315089b1a0b01c7788aa7b63/urllib3-2.6.1.tar.gz", hash = "sha256:5379eb6e1aba4088bae84f8242960017ec8d8e3decf30480b3a1abdaa9671a3f", size = 432678, upload-time = "2025-12-08T15:25:26.773Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/a7/c2/fe1e52489ae3122415c51f387e221dd0773709bad6c6cdaa599e8a2c5185/urllib3-2.5.0-py3-none-any.whl", hash = "sha256:e6b01673c0fa6a13e374b50871808eb3bf7046c4b125b216f6bf1cc604cff0dc", size = 129795, upload-time = "2025-06-18T14:07:40.39Z" }, + { url = "https://files.pythonhosted.org/packages/bc/56/190ceb8cb10511b730b564fb1e0293fa468363dbad26145c34928a60cb0c/urllib3-2.6.1-py3-none-any.whl", hash = "sha256:e67d06fe947c36a7ca39f4994b08d73922d40e6cca949907be05efa6fd75110b", size = 131138, upload-time = "2025-12-08T15:25:25.51Z" }, ] [[package]] @@ -1197,14 +1197,14 @@ wheels = [ [[package]] name = "werkzeug" -version = "3.1.3" +version = "3.1.4" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "markupsafe" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/9f/69/83029f1f6300c5fb2471d621ab06f6ec6b3324685a2ce0f9777fd4a8b71e/werkzeug-3.1.3.tar.gz", hash = "sha256:60723ce945c19328679790e3282cc758aa4a6040e4bb330f53d30fa546d44746", size = 806925, upload-time = "2024-11-08T15:52:18.093Z" } +sdist = { url = "https://files.pythonhosted.org/packages/45/ea/b0f8eeb287f8df9066e56e831c7824ac6bab645dd6c7a8f4b2d767944f9b/werkzeug-3.1.4.tar.gz", hash = "sha256:cd3cd98b1b92dc3b7b3995038826c68097dcb16f9baa63abe35f20eafeb9fe5e", size = 864687, upload-time = "2025-11-29T02:15:22.841Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/52/24/ab44c871b0f07f491e5d2ad12c9bd7358e527510618cb1b803a88e986db1/werkzeug-3.1.3-py3-none-any.whl", hash = "sha256:54b78bf3716d19a65be4fceccc0d1d7b89e608834989dfae50ea87564639213e", size = 224498, upload-time = "2024-11-08T15:52:16.132Z" }, + { url = "https://files.pythonhosted.org/packages/2f/f9/9e082990c2585c744734f85bec79b5dae5df9c974ffee58fe421652c8e91/werkzeug-3.1.4-py3-none-any.whl", hash = "sha256:2ad50fb9ed09cc3af22c54698351027ace879a0b60a3b5edf5730b2f7d876905", size = 224960, upload-time = "2025-11-29T02:15:21.13Z" }, ] [[package]] diff --git a/deployment/ecr/gaab-strands-workflow-agent/uv.lock b/deployment/ecr/gaab-strands-workflow-agent/uv.lock index 5b73ff94..3b09fdfc 100644 --- a/deployment/ecr/gaab-strands-workflow-agent/uv.lock +++ b/deployment/ecr/gaab-strands-workflow-agent/uv.lock @@ -2780,11 +2780,11 @@ wheels = [ [[package]] name = "urllib3" -version = "2.5.0" +version = "2.6.1" source = { registry = "https://pypi.org/simple" } -sdist = { url = "https://files.pythonhosted.org/packages/15/22/9ee70a2574a4f4599c47dd506532914ce044817c7752a79b6a51286319bc/urllib3-2.5.0.tar.gz", hash = "sha256:3fc47733c7e419d4bc3f6b3dc2b4f890bb743906a30d56ba4a5bfa4bbff92760", size = 393185, upload-time = "2025-06-18T14:07:41.644Z" } +sdist = { url = "https://files.pythonhosted.org/packages/5e/1d/0f3a93cca1ac5e8287842ed4eebbd0f7a991315089b1a0b01c7788aa7b63/urllib3-2.6.1.tar.gz", hash = "sha256:5379eb6e1aba4088bae84f8242960017ec8d8e3decf30480b3a1abdaa9671a3f", size = 432678, upload-time = "2025-12-08T15:25:26.773Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/a7/c2/fe1e52489ae3122415c51f387e221dd0773709bad6c6cdaa599e8a2c5185/urllib3-2.5.0-py3-none-any.whl", hash = "sha256:e6b01673c0fa6a13e374b50871808eb3bf7046c4b125b216f6bf1cc604cff0dc", size = 129795, upload-time = "2025-06-18T14:07:40.39Z" }, + { url = "https://files.pythonhosted.org/packages/bc/56/190ceb8cb10511b730b564fb1e0293fa468363dbad26145c34928a60cb0c/urllib3-2.6.1-py3-none-any.whl", hash = "sha256:e67d06fe947c36a7ca39f4994b08d73922d40e6cca949907be05efa6fd75110b", size = 131138, upload-time = "2025-12-08T15:25:25.51Z" }, ] [[package]] @@ -2832,14 +2832,14 @@ wheels = [ [[package]] name = "werkzeug" -version = "3.1.3" +version = "3.1.4" source = { registry = "https://pypi.org/simple" } dependencies = [ { name = "markupsafe" }, ] -sdist = { url = "https://files.pythonhosted.org/packages/9f/69/83029f1f6300c5fb2471d621ab06f6ec6b3324685a2ce0f9777fd4a8b71e/werkzeug-3.1.3.tar.gz", hash = "sha256:60723ce945c19328679790e3282cc758aa4a6040e4bb330f53d30fa546d44746", size = 806925, upload-time = "2024-11-08T15:52:18.093Z" } +sdist = { url = "https://files.pythonhosted.org/packages/45/ea/b0f8eeb287f8df9066e56e831c7824ac6bab645dd6c7a8f4b2d767944f9b/werkzeug-3.1.4.tar.gz", hash = "sha256:cd3cd98b1b92dc3b7b3995038826c68097dcb16f9baa63abe35f20eafeb9fe5e", size = 864687, upload-time = "2025-11-29T02:15:22.841Z" } wheels = [ - { url = "https://files.pythonhosted.org/packages/52/24/ab44c871b0f07f491e5d2ad12c9bd7358e527510618cb1b803a88e986db1/werkzeug-3.1.3-py3-none-any.whl", hash = "sha256:54b78bf3716d19a65be4fceccc0d1d7b89e608834989dfae50ea87564639213e", size = 224498, upload-time = "2024-11-08T15:52:16.132Z" }, + { url = "https://files.pythonhosted.org/packages/2f/f9/9e082990c2585c744734f85bec79b5dae5df9c974ffee58fe421652c8e91/werkzeug-3.1.4-py3-none-any.whl", hash = "sha256:2ad50fb9ed09cc3af22c54698351027ace879a0b60a3b5edf5730b2f7d876905", size = 224960, upload-time = "2025-11-29T02:15:21.13Z" }, ] [[package]] diff --git a/deployment/run-unit-tests.sh b/deployment/run-unit-tests.sh index 8b4256a3..566cbb41 100755 --- a/deployment/run-unit-tests.sh +++ b/deployment/run-unit-tests.sh @@ -37,7 +37,7 @@ setup_uv() { echo "Installing UV for ECR container tests..." if command -v pip3 &> /dev/null; then - pip3 install uv>=0.5.0 + pip3 install "uv>=0.5.0" # Verify installation if command -v uv &> /dev/null; then @@ -91,8 +91,13 @@ run_python_lambda_test() { coverage_report_path=$source_dir/test/coverage-reports/$lambda_name.coverage.xml echo "coverage report path set to $coverage_report_path" - # Use -vv for debugging - poetry run pytest -sv -vv --cov --cov-report=term-missing --cov-report "xml:$coverage_report_path" + if poetry install --dry-run | grep "pytest-xdist"; then + echo "Parallelism supported. Running poetry tests in parallel." + poetry run pytest -sv -vv --cov --cov-report=term-missing --cov-report "xml:$coverage_report_path" -n auto + else + echo "Parallelism not supported. Running poetry tests sequentially." + poetry run pytest -sv -vv --cov --cov-report=term-missing --cov-report "xml:$coverage_report_path" + fi if [ "$?" = "1" ]; then echo "(source/run-all-tests.sh) ERROR: there is likely output above." 1>&2 exit 1 diff --git a/source/infrastructure/cdk.json b/source/infrastructure/cdk.json index 691ced9a..5e90018a 100644 --- a/source/infrastructure/cdk.json +++ b/source/infrastructure/cdk.json @@ -64,7 +64,7 @@ "@custom-bundler/unit-test": false, "solution_id": "SO0276", "solution_name": "generative-ai-application-builder-on-aws", - "solution_version": "v4.0.2", + "solution_version": "v4.0.3", "app_registry_name": "GAAB", "application_type": "AWS-Solutions", "application_trademark_name": "Generative AI Application Builder on AWS", diff --git a/source/infrastructure/package-lock.json b/source/infrastructure/package-lock.json index 881f1daa..e9db13d0 100644 --- a/source/infrastructure/package-lock.json +++ b/source/infrastructure/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/gen-ai-app-builder-on-aws-infrastructure", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@amzn/gen-ai-app-builder-on-aws-infrastructure", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "dependencies": { "@aws-solutions-constructs/aws-apigateway-lambda": "^2.74.0", diff --git a/source/infrastructure/package.json b/source/infrastructure/package.json index 4c512e17..99186db3 100644 --- a/source/infrastructure/package.json +++ b/source/infrastructure/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/gen-ai-app-builder-on-aws-infrastructure", - "version": "4.0.2", + "version": "4.0.3", "bin": { "infrastructure": "bin/gen-ai-app-builder.js" }, diff --git a/source/infrastructure/test/mock-lambda-func/node-lambda/package-lock.json b/source/infrastructure/test/mock-lambda-func/node-lambda/package-lock.json index f3813054..2614cb5b 100644 --- a/source/infrastructure/test/mock-lambda-func/node-lambda/package-lock.json +++ b/source/infrastructure/test/mock-lambda-func/node-lambda/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/node-lambda", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@amzn/node-lambda", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0" } } diff --git a/source/infrastructure/test/mock-lambda-func/node-lambda/package.json b/source/infrastructure/test/mock-lambda-func/node-lambda/package.json index 71ed6b02..e8f262d2 100644 --- a/source/infrastructure/test/mock-lambda-func/node-lambda/package.json +++ b/source/infrastructure/test/mock-lambda-func/node-lambda/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/node-lambda", - "version": "4.0.2", + "version": "4.0.3", "description": "A mock lambda implementation for CDK infrastructure unit", "main": "index.js", "scripts": { diff --git a/source/infrastructure/test/mock-lambda-func/python-lambda/pyproject.toml b/source/infrastructure/test/mock-lambda-func/python-lambda/pyproject.toml index 080014ea..c8b7fa58 100644 --- a/source/infrastructure/test/mock-lambda-func/python-lambda/pyproject.toml +++ b/source/infrastructure/test/mock-lambda-func/python-lambda/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "mock-lambda-function" -version = "4.0.2" +version = "4.0.3" authors = [ "Amazon Web Services" ] description = "Mock lambda implementation to unit test infrastructure code" packages = [ diff --git a/source/infrastructure/test/mock-lambda-func/typescript-lambda/package-lock.json b/source/infrastructure/test/mock-lambda-func/typescript-lambda/package-lock.json index 29c33ce8..fce0e44c 100644 --- a/source/infrastructure/test/mock-lambda-func/typescript-lambda/package-lock.json +++ b/source/infrastructure/test/mock-lambda-func/typescript-lambda/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/mock-typescript-lambda", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@amzn/mock-typescript-lambda", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "dependencies": { "@types/aws-lambda": "^8.10.138", diff --git a/source/infrastructure/test/mock-lambda-func/typescript-lambda/package.json b/source/infrastructure/test/mock-lambda-func/typescript-lambda/package.json index ae486f2f..12a6183c 100644 --- a/source/infrastructure/test/mock-lambda-func/typescript-lambda/package.json +++ b/source/infrastructure/test/mock-lambda-func/typescript-lambda/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/mock-typescript-lambda", - "version": "4.0.2", + "version": "4.0.3", "description": "A mock lambda implementation for CDK infrastructure unit", "main": "index.ts", "scripts": { diff --git a/source/infrastructure/test/mock-ui/package-lock.json b/source/infrastructure/test/mock-ui/package-lock.json index cf618dfe..dc2dc731 100644 --- a/source/infrastructure/test/mock-ui/package-lock.json +++ b/source/infrastructure/test/mock-ui/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/mock-react-app", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@amzn/mock-react-app", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "devDependencies": { "@babel/plugin-proposal-private-property-in-object": "^7.21.11", diff --git a/source/infrastructure/test/mock-ui/package.json b/source/infrastructure/test/mock-ui/package.json index 2ab5d239..0be99ea9 100644 --- a/source/infrastructure/test/mock-ui/package.json +++ b/source/infrastructure/test/mock-ui/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/mock-react-app", - "version": "4.0.2", + "version": "4.0.3", "description": "Mock Reactjs app used for unit testing constructs", "devDependencies": { "@babel/plugin-proposal-private-property-in-object": "^7.21.11", diff --git a/source/lambda/agentcore-invocation/poetry.lock b/source/lambda/agentcore-invocation/poetry.lock index 05f90bc2..aa9145a6 100644 --- a/source/lambda/agentcore-invocation/poetry.lock +++ b/source/lambda/agentcore-invocation/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 2.2.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 2.1.3 and should not be changed by hand. [[package]] name = "aws-lambda-powertools" @@ -67,7 +67,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "boto3-layer" -version = "4.0.2" +version = "4.0.3" description = "Layer for AWS Boto3 python SDK" optional = false python-versions = "^3.13" @@ -479,7 +479,7 @@ test-randomorder = ["pytest-randomly"] [[package]] name = "custom-boto3-init" -version = "4.0.2" +version = "4.0.3" description = "Initialize boto config for AWS Python SDK with custom configuration" optional = false python-versions = "^3.13" diff --git a/source/lambda/agentcore-invocation/pyproject.toml b/source/lambda/agentcore-invocation/pyproject.toml index 34196a1e..4d47320a 100644 --- a/source/lambda/agentcore-invocation/pyproject.toml +++ b/source/lambda/agentcore-invocation/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "agent-invocation" -version = "4.0.2" +version = "4.0.3" authors = [ "Amazon Web Services" ] description = "Lambda implementation for agent invocation feature" packages = [ diff --git a/source/lambda/chat/poetry.lock b/source/lambda/chat/poetry.lock index 2f33fd90..4851f66d 100644 --- a/source/lambda/chat/poetry.lock +++ b/source/lambda/chat/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 2.2.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 2.1.3 and should not be changed by hand. [[package]] name = "annotated-types" @@ -98,7 +98,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "boto3-layer" -version = "4.0.2" +version = "4.0.3" description = "Layer for AWS Boto3 python SDK" optional = false python-versions = "^3.13" @@ -493,7 +493,7 @@ test-randomorder = ["pytest-randomly"] [[package]] name = "custom-boto3-init" -version = "4.0.2" +version = "4.0.3" description = "Initialize boto config for AWS Python SDK with custom configuration" optional = false python-versions = "^3.13" @@ -511,6 +511,21 @@ pyjwt = "^2.10.1" type = "directory" url = "../layers/custom_boto3_init" +[[package]] +name = "execnet" +version = "2.1.2" +description = "execnet: rapid multi-Python deployment" +optional = false +python-versions = ">=3.8" +groups = ["test"] +files = [ + {file = "execnet-2.1.2-py3-none-any.whl", hash = "sha256:67fba928dd5a544b783f6056f449e5e3931a5c378b128bc18501f7ea79e296ec"}, + {file = "execnet-2.1.2.tar.gz", hash = "sha256:63d83bfdd9a23e35b9c6a3261412324f964c2ec8dcd8d3c6916ee9373e0befcd"}, +] + +[package.extras] +testing = ["hatch", "pre-commit", "pytest", "tox"] + [[package]] name = "freezegun" version = "1.5.1" @@ -543,8 +558,6 @@ files = [ {file = "greenlet-3.2.4-cp310-cp310-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:c2ca18a03a8cfb5b25bc1cbe20f3d9a4c80d8c3b13ba3df49ac3961af0b1018d"}, {file = "greenlet-3.2.4-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:9fe0a28a7b952a21e2c062cd5756d34354117796c6d9215a87f55e38d15402c5"}, {file = "greenlet-3.2.4-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:8854167e06950ca75b898b104b63cc646573aa5fef1353d4508ecdd1ee76254f"}, - {file = "greenlet-3.2.4-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:f47617f698838ba98f4ff4189aef02e7343952df3a615f847bb575c3feb177a7"}, - {file = "greenlet-3.2.4-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:af41be48a4f60429d5cad9d22175217805098a9ef7c40bfef44f7669fb9d74d8"}, {file = "greenlet-3.2.4-cp310-cp310-win_amd64.whl", hash = "sha256:73f49b5368b5359d04e18d15828eecc1806033db5233397748f4ca813ff1056c"}, {file = "greenlet-3.2.4-cp311-cp311-macosx_11_0_universal2.whl", hash = "sha256:96378df1de302bc38e99c3a9aa311967b7dc80ced1dcc6f171e99842987882a2"}, {file = "greenlet-3.2.4-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:1ee8fae0519a337f2329cb78bd7a8e128ec0f881073d43f023c7b8d4831d5246"}, @@ -554,8 +567,6 @@ files = [ {file = "greenlet-3.2.4-cp311-cp311-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:2523e5246274f54fdadbce8494458a2ebdcdbc7b802318466ac5606d3cded1f8"}, {file = "greenlet-3.2.4-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:1987de92fec508535687fb807a5cea1560f6196285a4cde35c100b8cd632cc52"}, {file = "greenlet-3.2.4-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:55e9c5affaa6775e2c6b67659f3a71684de4c549b3dd9afca3bc773533d284fa"}, - {file = "greenlet-3.2.4-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:c9c6de1940a7d828635fbd254d69db79e54619f165ee7ce32fda763a9cb6a58c"}, - {file = "greenlet-3.2.4-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:03c5136e7be905045160b1b9fdca93dd6727b180feeafda6818e6496434ed8c5"}, {file = "greenlet-3.2.4-cp311-cp311-win_amd64.whl", hash = "sha256:9c40adce87eaa9ddb593ccb0fa6a07caf34015a29bf8d344811665b573138db9"}, {file = "greenlet-3.2.4-cp312-cp312-macosx_11_0_universal2.whl", hash = "sha256:3b67ca49f54cede0186854a008109d6ee71f66bd57bb36abd6d0a0267b540cdd"}, {file = "greenlet-3.2.4-cp312-cp312-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:ddf9164e7a5b08e9d22511526865780a576f19ddd00d62f8a665949327fde8bb"}, @@ -565,8 +576,6 @@ files = [ {file = "greenlet-3.2.4-cp312-cp312-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:3b3812d8d0c9579967815af437d96623f45c0f2ae5f04e366de62a12d83a8fb0"}, {file = "greenlet-3.2.4-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:abbf57b5a870d30c4675928c37278493044d7c14378350b3aa5d484fa65575f0"}, {file = "greenlet-3.2.4-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:20fb936b4652b6e307b8f347665e2c615540d4b42b3b4c8a321d8286da7e520f"}, - {file = "greenlet-3.2.4-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:ee7a6ec486883397d70eec05059353b8e83eca9168b9f3f9a361971e77e0bcd0"}, - {file = "greenlet-3.2.4-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:326d234cbf337c9c3def0676412eb7040a35a768efc92504b947b3e9cfc7543d"}, {file = "greenlet-3.2.4-cp312-cp312-win_amd64.whl", hash = "sha256:a7d4e128405eea3814a12cc2605e0e6aedb4035bf32697f72deca74de4105e02"}, {file = "greenlet-3.2.4-cp313-cp313-macosx_11_0_universal2.whl", hash = "sha256:1a921e542453fe531144e91e1feedf12e07351b1cf6c9e8a3325ea600a715a31"}, {file = "greenlet-3.2.4-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:cd3c8e693bff0fff6ba55f140bf390fa92c994083f838fece0f63be121334945"}, @@ -576,8 +585,6 @@ files = [ {file = "greenlet-3.2.4-cp313-cp313-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:23768528f2911bcd7e475210822ffb5254ed10d71f4028387e5a99b4c6699671"}, {file = "greenlet-3.2.4-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:00fadb3fedccc447f517ee0d3fd8fe49eae949e1cd0f6a611818f4f6fb7dc83b"}, {file = "greenlet-3.2.4-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:d25c5091190f2dc0eaa3f950252122edbbadbb682aa7b1ef2f8af0f8c0afefae"}, - {file = "greenlet-3.2.4-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:6e343822feb58ac4d0a1211bd9399de2b3a04963ddeec21530fc426cc121f19b"}, - {file = "greenlet-3.2.4-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:ca7f6f1f2649b89ce02f6f229d7c19f680a6238af656f61e0115b24857917929"}, {file = "greenlet-3.2.4-cp313-cp313-win_amd64.whl", hash = "sha256:554b03b6e73aaabec3745364d6239e9e012d64c68ccd0b8430c64ccc14939a8b"}, {file = "greenlet-3.2.4-cp314-cp314-macosx_11_0_universal2.whl", hash = "sha256:49a30d5fda2507ae77be16479bdb62a660fa51b1eb4928b524975b3bde77b3c0"}, {file = "greenlet-3.2.4-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:299fd615cd8fc86267b47597123e3f43ad79c9d8a22bebdce535e53550763e2f"}, @@ -585,8 +592,6 @@ files = [ {file = "greenlet-3.2.4-cp314-cp314-manylinux2014_s390x.manylinux_2_17_s390x.whl", hash = "sha256:b4a1870c51720687af7fa3e7cda6d08d801dae660f75a76f3845b642b4da6ee1"}, {file = "greenlet-3.2.4-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", hash = "sha256:061dc4cf2c34852b052a8620d40f36324554bc192be474b9e9770e8c042fd735"}, {file = "greenlet-3.2.4-cp314-cp314-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:44358b9bf66c8576a9f57a590d5f5d6e72fa4228b763d0e43fee6d3b06d3a337"}, - {file = "greenlet-3.2.4-cp314-cp314-musllinux_1_2_aarch64.whl", hash = "sha256:2917bdf657f5859fbf3386b12d68ede4cf1f04c90c3a6bc1f013dd68a22e2269"}, - {file = "greenlet-3.2.4-cp314-cp314-musllinux_1_2_x86_64.whl", hash = "sha256:015d48959d4add5d6c9f6c5210ee3803a830dce46356e3bc326d6776bde54681"}, {file = "greenlet-3.2.4-cp314-cp314-win_amd64.whl", hash = "sha256:e37ab26028f12dbb0ff65f29a8d3d44a765c61e729647bf2ddfbbed621726f01"}, {file = "greenlet-3.2.4-cp39-cp39-macosx_11_0_universal2.whl", hash = "sha256:b6a7c19cf0d2742d0809a4c05975db036fdff50cd294a93632d6a310bf9ac02c"}, {file = "greenlet-3.2.4-cp39-cp39-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:27890167f55d2387576d1f41d9487ef171849ea0359ce1510ca6e06c8bece11d"}, @@ -596,8 +601,6 @@ files = [ {file = "greenlet-3.2.4-cp39-cp39-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:c9913f1a30e4526f432991f89ae263459b1c64d1608c0d22a5c79c287b3c70df"}, {file = "greenlet-3.2.4-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:b90654e092f928f110e0007f572007c9727b5265f7632c2fa7415b4689351594"}, {file = "greenlet-3.2.4-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:81701fd84f26330f0d5f4944d4e92e61afe6319dcd9775e39396e39d7c3e5f98"}, - {file = "greenlet-3.2.4-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:28a3c6b7cd72a96f61b0e4b2a36f681025b60ae4779cc73c1535eb5f29560b10"}, - {file = "greenlet-3.2.4-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:52206cd642670b0b320a1fd1cbfd95bca0e043179c1d8a045f2c6109dfe973be"}, {file = "greenlet-3.2.4-cp39-cp39-win32.whl", hash = "sha256:65458b409c1ed459ea899e939f0e1cdb14f58dbc803f2f93c5eab5694d32671b"}, {file = "greenlet-3.2.4-cp39-cp39-win_amd64.whl", hash = "sha256:d2e685ade4dafd447ede19c31277a224a239a0a1a4eca4e6390efedf20260cfb"}, {file = "greenlet-3.2.4.tar.gz", hash = "sha256:0dca0d95ff849f9a364385f36ab49f50065d76964944638be9691e1832e9f86d"}, @@ -829,14 +832,14 @@ tools = ["beautifulsoup4 (>=4.13.4)", "bedrock-agentcore (>=0.1.0) ; python_vers [[package]] name = "langchain-core" -version = "0.3.80" +version = "0.3.81" description = "Building applications with LLMs through composability" optional = false python-versions = "<4.0.0,>=3.9.0" groups = ["test"] files = [ - {file = "langchain_core-0.3.80-py3-none-any.whl", hash = "sha256:2141e3838d100d17dce2359f561ec0df52c526bae0de6d4f469f8026c5747456"}, - {file = "langchain_core-0.3.80.tar.gz", hash = "sha256:29636b82513ab49e834764d023c4d18554d3d719a185d37b019d0a8ae948c6bb"}, + {file = "langchain_core-0.3.81-py3-none-any.whl", hash = "sha256:d0f34c88254d78ccb1b9a038f860d13dea90186045026fd8fc3e1265eed73a4e"}, + {file = "langchain_core-0.3.81.tar.gz", hash = "sha256:0473e7cffbba06017393f2f1ee116da098c298e4ec478ada91d321f42dff921c"}, ] [package.dependencies] @@ -850,7 +853,7 @@ typing-extensions = ">=4.7.0,<5.0.0" [[package]] name = "langchain-layer" -version = "4.0.2" +version = "4.0.3" description = "Layer for LangChain libraries" optional = false python-versions = "^3.13" @@ -861,7 +864,7 @@ develop = true [package.dependencies] langchain = "0.3.27" langchain-aws = "0.2.31" -langchain-core = "0.3.80" +langchain-core = "0.3.81" numpy = "2.2.2" pydantic = "2.11.0" requests = "2.32.4" @@ -1470,6 +1473,27 @@ pytest = ">=8.3.3" [package.extras] testing = ["covdefaults (>=2.3)", "coverage (>=7.6.1)", "pytest-mock (>=3.14)"] +[[package]] +name = "pytest-xdist" +version = "3.8.0" +description = "pytest xdist plugin for distributed testing, most importantly across multiple CPUs" +optional = false +python-versions = ">=3.9" +groups = ["test"] +files = [ + {file = "pytest_xdist-3.8.0-py3-none-any.whl", hash = "sha256:202ca578cfeb7370784a8c33d6d05bc6e13b4f25b5053c30a152269fd10f0b88"}, + {file = "pytest_xdist-3.8.0.tar.gz", hash = "sha256:7e578125ec9bc6050861aa93f2d59f1d8d085595d6551c2c90b6f4fad8d3a9f1"}, +] + +[package.dependencies] +execnet = ">=2.1" +pytest = ">=7.0.0" + +[package.extras] +psutil = ["psutil (>=3.0)"] +setproctitle = ["setproctitle"] +testing = ["filelock"] + [[package]] name = "python-dateutil" version = "2.9.0.post0" @@ -2061,4 +2085,4 @@ cffi = ["cffi (>=1.17) ; python_version >= \"3.13\" and platform_python_implemen [metadata] lock-version = "2.1" python-versions = "^3.13" -content-hash = "d93ed0bf6dccc4d6563d314c8a19f5a05c6060e1b1df625bb630e70e3f9ffdeb" +content-hash = "39df50616e8ea97c68abf7ac883961100f8582bb75b0914b79e1542bbc254ef2" diff --git a/source/lambda/chat/pyproject.toml b/source/lambda/chat/pyproject.toml index 13424712..35c1268c 100644 --- a/source/lambda/chat/pyproject.toml +++ b/source/lambda/chat/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "llm-chat-lambda" -version = "4.0.2" +version = "4.0.3" authors = [ "Amazon Web Services" ] description = "Lambda implementation for chat feature" packages = [ @@ -29,6 +29,7 @@ PyYAML = "6.0.2" setuptools = "80.8.0" requests="2.32.4" urllib3="2.6.1" +pytest-xdist = "^3.8.0" boto3-layer = { path = "../layers/aws_boto3/", develop = true } custom_boto3_init = { path = "../layers/custom_boto3_init", develop = true } langchain-layer = { path = "../layers/langchain", develop = true } diff --git a/source/lambda/chat/test/clients/factories/test_conversation_memory_factory.py b/source/lambda/chat/test/clients/factories/test_conversation_memory_factory.py index d936b1b8..27551eaa 100644 --- a/source/lambda/chat/test/clients/factories/test_conversation_memory_factory.py +++ b/source/lambda/chat/test/clients/factories/test_conversation_memory_factory.py @@ -10,6 +10,7 @@ from clients.factories.conversation_memory_factory import ConversationMemoryFactory from shared.memory.ddb_enhanced_message_history import DynamoDBChatMessageHistory from utils.constants import CONVERSATION_TABLE_NAME_ENV_VAR +from unittest.mock import patch TEST_PROMPT = """\n\n{history}\n\n{input}""" MODEL_INFO_CONFIG = { @@ -29,8 +30,8 @@ (TEST_PROMPT, False, False, None, False, "google/flan-t5-xxl", None), ], ) +@patch.dict(os.environ, {CONVERSATION_TABLE_NAME_ENV_VAR: "fake-table"}) def test_get_ddb_memory_success(bedrock_llm_config, model_id, dynamodb_resource, history_length): - os.environ[CONVERSATION_TABLE_NAME_ENV_VAR] = "fake-table" config = bedrock_llm_config if history_length is None: del config["ConversationMemoryParams"]["ChatHistoryLength"] @@ -87,16 +88,17 @@ def test_get_ddb_memory_error(bedrock_llm_config, model_id, setup_environment): ], ) def test_get_ddb_memory_missing_table_name(model_id, bedrock_llm_config): - os.environ.pop(CONVERSATION_TABLE_NAME_ENV_VAR) - errors_list = [] - config = deepcopy(bedrock_llm_config) - response = ConversationMemoryFactory().get_conversation_memory( - config, MODEL_INFO_CONFIG, "fake-user-id", "fake-conversation-id", "fake-message-id", errors_list - ) - assert response is None - assert errors_list == [ - f"Missing required environment variable {CONVERSATION_TABLE_NAME_ENV_VAR} which is required for constructing conversation memory for the LLM." - ] + with patch.dict(os.environ, clear=False): + os.environ.pop(CONVERSATION_TABLE_NAME_ENV_VAR, None) + errors_list = [] + config = deepcopy(bedrock_llm_config) + response = ConversationMemoryFactory().get_conversation_memory( + config, MODEL_INFO_CONFIG, "fake-user-id", "fake-conversation-id", "fake-message-id", errors_list + ) + assert response is None + assert errors_list == [ + f"Missing required environment variable {CONVERSATION_TABLE_NAME_ENV_VAR} which is required for constructing conversation memory for the LLM." + ] @pytest.mark.parametrize( diff --git a/source/lambda/chat/test/clients/factories/test_knowledge_base_factory.py b/source/lambda/chat/test/clients/factories/test_knowledge_base_factory.py index 2520ff84..32c1c312 100644 --- a/source/lambda/chat/test/clients/factories/test_knowledge_base_factory.py +++ b/source/lambda/chat/test/clients/factories/test_knowledge_base_factory.py @@ -9,9 +9,12 @@ from clients.factories.knowledge_base_factory import KNOWLEDGE_BASE_MAP, KnowledgeBaseFactory from utils.constants import BEDROCK_KNOWLEDGE_BASE_ID_ENV_VAR, KENDRA_INDEX_ID_ENV_VAR from utils.enum_types import KnowledgeBaseTypes +from unittest.mock import patch TEST_PROMPT = """\n\n{history}\n\n{input}""" +os.environ["_X_AMZN_TRACE_ID"] = "Root=1-12345678-123456789abcdef0;Parent=123456789abcdef0;Sampled=1" + @pytest.mark.parametrize( "prompt, is_streaming, rag_enabled, knowledge_base_type, return_source_docs, model_id", @@ -64,13 +67,14 @@ def test_get_kb_missing_kendra_index( ): errors_list = [] config = deepcopy(bedrock_llm_config) - os.environ.pop(KENDRA_INDEX_ID_ENV_VAR, None) - with pytest.raises(ValueError): - response = KnowledgeBaseFactory().get_knowledge_base(config, errors_list, user_context_token) - assert response is None - assert errors_list == [ - f"Missing required environment variable {KENDRA_INDEX_ID_ENV_VAR} for Kendra knowledge base." - ] + with patch.dict(os.environ, clear=False): + os.environ.pop(KENDRA_INDEX_ID_ENV_VAR, None) + with pytest.raises(ValueError): + response = KnowledgeBaseFactory().get_knowledge_base(config, errors_list, user_context_token) + assert response is None + assert errors_list == [ + f"Missing required environment variable {KENDRA_INDEX_ID_ENV_VAR} for Kendra knowledge base." + ] @pytest.mark.parametrize( @@ -85,13 +89,14 @@ def test_get_kb_missing_bedrock_knowledge_base_id( ): errors_list = [] config = deepcopy(bedrock_llm_config) - os.environ.pop(BEDROCK_KNOWLEDGE_BASE_ID_ENV_VAR, None) - with pytest.raises(ValueError): - response = KnowledgeBaseFactory().get_knowledge_base(config, errors_list, user_context_token) - assert response is None - assert errors_list == [ - f"Missing required environment variable {BEDROCK_KNOWLEDGE_BASE_ID_ENV_VAR} for Kendra knowledge base." - ] + with patch.dict(os.environ, clear=False): + os.environ.pop(BEDROCK_KNOWLEDGE_BASE_ID_ENV_VAR, None) + with pytest.raises(ValueError): + response = KnowledgeBaseFactory().get_knowledge_base(config, errors_list, user_context_token) + assert response is None + assert errors_list == [ + f"Missing required environment variable {BEDROCK_KNOWLEDGE_BASE_ID_ENV_VAR} for Kendra knowledge base." + ] @pytest.mark.parametrize( diff --git a/source/lambda/chat/test/clients/test_llm_chat_client.py b/source/lambda/chat/test/clients/test_llm_chat_client.py index 3a818f89..754df3a9 100644 --- a/source/lambda/chat/test/clients/test_llm_chat_client.py +++ b/source/lambda/chat/test/clients/test_llm_chat_client.py @@ -21,6 +21,7 @@ USER_ID_EVENT_KEY, ) from utils.enum_types import BedrockModelProviders, LLMProviderTypes +from unittest.mock import patch # Testing LLMChatClient using subclass BASIC_PROMPT = """{input}""" @@ -213,16 +214,17 @@ def test_get_event_conversation_id(simple_llm_client): def test_env_not_set(setup_environment, simple_llm_client): - os.environ.pop(USE_CASE_CONFIG_TABLE_NAME_ENV_VAR, None) - with pytest.raises(ValueError) as error: - simple_llm_client.check_env() - assert error.value.args[0] == f"Missing required environment variable {USE_CASE_CONFIG_TABLE_NAME_ENV_VAR}." + with patch.dict(os.environ, clear=False): + os.environ.pop(USE_CASE_CONFIG_TABLE_NAME_ENV_VAR, None) + with pytest.raises(ValueError) as error: + simple_llm_client.check_env() + assert error.value.args[0] == f"Missing required environment variable {USE_CASE_CONFIG_TABLE_NAME_ENV_VAR}." - os.environ[USE_CASE_CONFIG_TABLE_NAME_ENV_VAR] = "fake-table" - os.environ.pop(USE_CASE_CONFIG_RECORD_KEY_ENV_VAR, None) - with pytest.raises(ValueError) as error: - simple_llm_client.check_env() - assert error.value.args[0] == f"Missing required environment variable {USE_CASE_CONFIG_RECORD_KEY_ENV_VAR}." + os.environ[USE_CASE_CONFIG_TABLE_NAME_ENV_VAR] = "fake-table" + os.environ.pop(USE_CASE_CONFIG_RECORD_KEY_ENV_VAR, None) + with pytest.raises(ValueError) as error: + simple_llm_client.check_env() + assert error.value.args[0] == f"Missing required environment variable {USE_CASE_CONFIG_RECORD_KEY_ENV_VAR}." def test_env_set(setup_environment, simple_llm_client): @@ -339,13 +341,14 @@ def test_retrieve_usecase_empty_config( def test_parent_retrieve_llm_config_missing_env(setup_environment, simple_llm_client): - os.environ.pop(USE_CASE_CONFIG_RECORD_KEY_ENV_VAR, None) - with pytest.raises(ValueError) as error: - simple_llm_client.retrieve_use_case_config() - assert ( - error.value.args[0] - == f"Missing required environment variable {USE_CASE_CONFIG_TABLE_NAME_ENV_VAR} or {USE_CASE_CONFIG_RECORD_KEY_ENV_VAR}." - ) + with patch.dict(os.environ, clear=False): + os.environ.pop(USE_CASE_CONFIG_RECORD_KEY_ENV_VAR, None) + with pytest.raises(ValueError) as error: + simple_llm_client.retrieve_use_case_config() + assert ( + error.value.args[0] + == f"Missing required environment variable {USE_CASE_CONFIG_TABLE_NAME_ENV_VAR} or {USE_CASE_CONFIG_RECORD_KEY_ENV_VAR}." + ) def test_construct_chat_model_failure(simple_llm_client, chat_event): diff --git a/source/lambda/chat/test/shared/knowledge/test_bedrock_knowledge_base.py b/source/lambda/chat/test/shared/knowledge/test_bedrock_knowledge_base.py index 56642117..f8df7168 100644 --- a/source/lambda/chat/test/shared/knowledge/test_bedrock_knowledge_base.py +++ b/source/lambda/chat/test/shared/knowledge/test_bedrock_knowledge_base.py @@ -7,6 +7,7 @@ import pytest from langchain_aws.retrievers.bedrock import RetrievalConfig, VectorSearchConfig from langchain_core.documents import Document +import copy from shared.knowledge.bedrock_knowledge_base import BedrockKnowledgeBase from utils.constants import BEDROCK_KNOWLEDGE_BASE_ID_ENV_VAR @@ -56,37 +57,40 @@ def test_knowledge_base_construction(setup_environment): def test_knowledge_base_construction_no_filter(setup_environment): - del knowledge_base_params["BedrockKnowledgeBaseParams"]["RetrievalFilter"] - knowledge_base = BedrockKnowledgeBase(knowledge_base_params) + param_copy = copy.deepcopy(knowledge_base_params) + del param_copy["BedrockKnowledgeBaseParams"]["RetrievalFilter"] + knowledge_base = BedrockKnowledgeBase(param_copy) assert knowledge_base.knowledge_base_id == "fake-bedrock-knowledge-base-id" - assert knowledge_base.number_of_docs == knowledge_base_params["NumberOfDocs"] - assert knowledge_base.return_source_documents == knowledge_base_params["ReturnSourceDocs"] + assert knowledge_base.number_of_docs == param_copy["NumberOfDocs"] + assert knowledge_base.return_source_documents == param_copy["ReturnSourceDocs"] assert knowledge_base.retriever.knowledge_base_id == "fake-bedrock-knowledge-base-id" assert knowledge_base.retriever.retrieval_config == RetrievalConfig( **{ "vectorSearchConfiguration": VectorSearchConfig( - **{"numberOfResults": knowledge_base_params["NumberOfDocs"]} + **{"numberOfResults": param_copy["NumberOfDocs"]} ) } ) - assert knowledge_base.retriever.return_source_documents == knowledge_base_params["ReturnSourceDocs"] + assert knowledge_base.retriever.return_source_documents == param_copy["ReturnSourceDocs"] def test_knowledge_base_construction_override_search(setup_environment): - knowledge_base_params["BedrockKnowledgeBaseParams"]["OverrideSearchType"] = "SEMANTIC" - knowledge_base = BedrockKnowledgeBase(knowledge_base_params) + param_copy = copy.deepcopy(knowledge_base_params) + del param_copy["BedrockKnowledgeBaseParams"]["RetrievalFilter"] + param_copy["BedrockKnowledgeBaseParams"]["OverrideSearchType"] = "SEMANTIC" + knowledge_base = BedrockKnowledgeBase(param_copy) assert knowledge_base.knowledge_base_id == "fake-bedrock-knowledge-base-id" - assert knowledge_base.min_score_confidence == knowledge_base_params["ScoreThreshold"] - assert knowledge_base.number_of_docs == knowledge_base_params["NumberOfDocs"] - assert knowledge_base.return_source_documents == knowledge_base_params["ReturnSourceDocs"] + assert knowledge_base.min_score_confidence == param_copy["ScoreThreshold"] + assert knowledge_base.number_of_docs == param_copy["NumberOfDocs"] + assert knowledge_base.return_source_documents == param_copy["ReturnSourceDocs"] assert knowledge_base.retriever.knowledge_base_id == "fake-bedrock-knowledge-base-id" assert knowledge_base.retriever.retrieval_config == RetrievalConfig( **{ "vectorSearchConfiguration": VectorSearchConfig( **{ - "numberOfResults": knowledge_base_params["NumberOfDocs"], + "numberOfResults": param_copy["NumberOfDocs"], "overrideSearchType": "SEMANTIC", } ) @@ -97,22 +101,24 @@ def test_knowledge_base_construction_override_search(setup_environment): def test_knowledge_base_construction_override_search_nullified(setup_environment): - knowledge_base_params["BedrockKnowledgeBaseParams"]["OverrideSearchType"] = None - knowledge_base = BedrockKnowledgeBase(knowledge_base_params) + param_copy = copy.deepcopy(knowledge_base_params) + del param_copy["BedrockKnowledgeBaseParams"]["RetrievalFilter"] + param_copy["BedrockKnowledgeBaseParams"]["OverrideSearchType"] = None + knowledge_base = BedrockKnowledgeBase(param_copy) assert knowledge_base.knowledge_base_id == "fake-bedrock-knowledge-base-id" - assert knowledge_base.min_score_confidence == knowledge_base_params["ScoreThreshold"] - assert knowledge_base.number_of_docs == knowledge_base_params["NumberOfDocs"] - assert knowledge_base.return_source_documents == knowledge_base_params["ReturnSourceDocs"] + assert knowledge_base.min_score_confidence == param_copy["ScoreThreshold"] + assert knowledge_base.number_of_docs == param_copy["NumberOfDocs"] + assert knowledge_base.return_source_documents == param_copy["ReturnSourceDocs"] assert knowledge_base.retriever.knowledge_base_id == "fake-bedrock-knowledge-base-id" assert knowledge_base.retriever.retrieval_config == RetrievalConfig( **{ "vectorSearchConfiguration": VectorSearchConfig( - **{"numberOfResults": knowledge_base_params["NumberOfDocs"]} + **{"numberOfResults": param_copy["NumberOfDocs"]} ) } ) - assert knowledge_base.retriever.return_source_documents == knowledge_base_params["ReturnSourceDocs"] + assert knowledge_base.retriever.return_source_documents == param_copy["ReturnSourceDocs"] def test_source_docs_formatter(): diff --git a/source/lambda/custom-authorizer/package-lock.json b/source/lambda/custom-authorizer/package-lock.json index 39e38156..ef63c08d 100644 --- a/source/lambda/custom-authorizer/package-lock.json +++ b/source/lambda/custom-authorizer/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/custom-authorizer", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@amzn/custom-authorizer", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "dependencies": { "aws-jwt-verify": "^4.0.1", diff --git a/source/lambda/custom-authorizer/package.json b/source/lambda/custom-authorizer/package.json index 6449d3f9..d6c7f44d 100644 --- a/source/lambda/custom-authorizer/package.json +++ b/source/lambda/custom-authorizer/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/custom-authorizer", - "version": "4.0.2", + "version": "4.0.3", "description": "This lambda function is used as a custom REQUEST authorizer for APIs", "main": "rest-handler.ts", "scripts": { diff --git a/source/lambda/custom-resource/poetry.lock b/source/lambda/custom-resource/poetry.lock index 879a9e53..20b9f675 100644 --- a/source/lambda/custom-resource/poetry.lock +++ b/source/lambda/custom-resource/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 2.2.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 2.1.3 and should not be changed by hand. [[package]] name = "aws-lambda-powertools" @@ -67,7 +67,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "boto3-layer" -version = "4.0.2" +version = "4.0.3" description = "Layer for AWS Boto3 python SDK" optional = false python-versions = "^3.13" @@ -495,7 +495,7 @@ test-randomorder = ["pytest-randomly"] [[package]] name = "custom-boto3-init" -version = "4.0.2" +version = "4.0.3" description = "Initialize boto config for AWS Python SDK with custom configuration" optional = false python-versions = "^3.13" @@ -513,6 +513,21 @@ pyjwt = "^2.10.1" type = "directory" url = "../layers/custom_boto3_init" +[[package]] +name = "execnet" +version = "2.1.2" +description = "execnet: rapid multi-Python deployment" +optional = false +python-versions = ">=3.8" +groups = ["test"] +files = [ + {file = "execnet-2.1.2-py3-none-any.whl", hash = "sha256:67fba928dd5a544b783f6056f449e5e3931a5c378b128bc18501f7ea79e296ec"}, + {file = "execnet-2.1.2.tar.gz", hash = "sha256:63d83bfdd9a23e35b9c6a3261412324f964c2ec8dcd8d3c6916ee9373e0befcd"}, +] + +[package.extras] +testing = ["hatch", "pre-commit", "pytest", "tox"] + [[package]] name = "freezegun" version = "1.5.1" @@ -882,6 +897,27 @@ pytest = ">=8.3.3" [package.extras] testing = ["covdefaults (>=2.3)", "coverage (>=7.6.1)", "pytest-mock (>=3.14)"] +[[package]] +name = "pytest-xdist" +version = "3.8.0" +description = "pytest xdist plugin for distributed testing, most importantly across multiple CPUs" +optional = false +python-versions = ">=3.9" +groups = ["test"] +files = [ + {file = "pytest_xdist-3.8.0-py3-none-any.whl", hash = "sha256:202ca578cfeb7370784a8c33d6d05bc6e13b4f25b5053c30a152269fd10f0b88"}, + {file = "pytest_xdist-3.8.0.tar.gz", hash = "sha256:7e578125ec9bc6050861aa93f2d59f1d8d085595d6551c2c90b6f4fad8d3a9f1"}, +] + +[package.dependencies] +execnet = ">=2.1" +pytest = ">=7.0.0" + +[package.extras] +psutil = ["psutil (>=3.0)"] +setproctitle = ["setproctitle"] +testing = ["filelock"] + [[package]] name = "python-dateutil" version = "2.9.0.post0" @@ -1210,4 +1246,4 @@ test = ["pytest", "pytest-cov"] [metadata] lock-version = "2.1" python-versions = "^3.13" -content-hash = "4ccfa5db10a0757b383ff1ec813f4446a1251dcd1f13922e1983d186f29d1cca" +content-hash = "f84862a4839a3347512010f35d4bd4119bdeed1fba51fbee3fb8dedfb29f0e20" diff --git a/source/lambda/custom-resource/pyproject.toml b/source/lambda/custom-resource/pyproject.toml index 3250722d..caa84977 100644 --- a/source/lambda/custom-resource/pyproject.toml +++ b/source/lambda/custom-resource/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "custom-resource" -version = "4.0.2" +version = "4.0.3" authors = [ "Amazon Web Services" ] description = "Perform specific operations triggered by AWS CloudFormation events" packages = [ @@ -26,6 +26,7 @@ pytest = "8.3.4" pytest-cov = "6.0.0" pytest-env = "1.1.5" PyYAML = "6.0.2" +pytest-xdist = "^3.8.0" setuptools = "80.8.0" pyjwt = "^2.10.1" urllib3="2.6.1" diff --git a/source/lambda/ext-idp-group-mapper/poetry.lock b/source/lambda/ext-idp-group-mapper/poetry.lock index 4e19b08a..9c080340 100644 --- a/source/lambda/ext-idp-group-mapper/poetry.lock +++ b/source/lambda/ext-idp-group-mapper/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 2.2.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 2.1.3 and should not be changed by hand. [[package]] name = "aws-lambda-powertools" @@ -67,7 +67,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "boto3-layer" -version = "4.0.2" +version = "4.0.3" description = "Layer for AWS Boto3 python SDK" optional = false python-versions = "^3.13" @@ -462,7 +462,7 @@ test-randomorder = ["pytest-randomly"] [[package]] name = "custom-boto3-init" -version = "4.0.2" +version = "4.0.3" description = "Initialize boto config for AWS Python SDK with custom configuration" optional = false python-versions = "^3.13" diff --git a/source/lambda/ext-idp-group-mapper/pyproject.toml b/source/lambda/ext-idp-group-mapper/pyproject.toml index e72599f0..44cbfe72 100644 --- a/source/lambda/ext-idp-group-mapper/pyproject.toml +++ b/source/lambda/ext-idp-group-mapper/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "ext-idp-group-mapper" -version = "4.0.2" +version = "4.0.3" authors = [ "Amazon Web Services" ] description = "Lambda implementation to change Cognito user groups to External Identity Provider groups in the JWT token" packages = [ diff --git a/source/lambda/feedback-management/package-lock.json b/source/lambda/feedback-management/package-lock.json index c4506ab7..15f71041 100644 --- a/source/lambda/feedback-management/package-lock.json +++ b/source/lambda/feedback-management/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/feedback-management", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@amzn/feedback-management", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "dependencies": { "jsonpath-plus": "^10.3.0", diff --git a/source/lambda/feedback-management/package.json b/source/lambda/feedback-management/package.json index d436e126..48aff128 100644 --- a/source/lambda/feedback-management/package.json +++ b/source/lambda/feedback-management/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/feedback-management", - "version": "4.0.2", + "version": "4.0.3", "description": "This lambda supports backs the API to process chat response feedbacks", "main": "index.ts", "scripts": { diff --git a/source/lambda/files-management/package-lock.json b/source/lambda/files-management/package-lock.json index 758a0dc3..217ecdad 100644 --- a/source/lambda/files-management/package-lock.json +++ b/source/lambda/files-management/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/files-handler", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@amzn/files-handler", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "devDependencies": { "@types/jest": "^29.5.14", diff --git a/source/lambda/files-management/package.json b/source/lambda/files-management/package.json index a02420b1..c552b972 100644 --- a/source/lambda/files-management/package.json +++ b/source/lambda/files-management/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/files-handler", - "version": "4.0.2", + "version": "4.0.3", "description": "This lambda supports APIs that provide export functionality for use cases", "main": "index.ts", "scripts": { diff --git a/source/lambda/files-metadata-management/package-lock.json b/source/lambda/files-metadata-management/package-lock.json index efa18d62..b3ee06fd 100644 --- a/source/lambda/files-metadata-management/package-lock.json +++ b/source/lambda/files-metadata-management/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/files-metadata", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@amzn/files-metadata", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "dependencies": { "file-type": "^16.5.4" diff --git a/source/lambda/files-metadata-management/package.json b/source/lambda/files-metadata-management/package.json index 9fc83382..329a6ec1 100644 --- a/source/lambda/files-metadata-management/package.json +++ b/source/lambda/files-metadata-management/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/files-metadata", - "version": "4.0.2", + "version": "4.0.3", "description": "This lambda supports APIs that provide export functionality for use cases", "main": "index.ts", "scripts": { diff --git a/source/lambda/invoke-agent/poetry.lock b/source/lambda/invoke-agent/poetry.lock index a3631818..77410a7c 100644 --- a/source/lambda/invoke-agent/poetry.lock +++ b/source/lambda/invoke-agent/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 2.2.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 2.1.3 and should not be changed by hand. [[package]] name = "aws-lambda-powertools" @@ -67,7 +67,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "boto3-layer" -version = "4.0.1" +version = "4.0.3" description = "Layer for AWS Boto3 python SDK" optional = false python-versions = "^3.13" @@ -462,7 +462,7 @@ test-randomorder = ["pytest-randomly"] [[package]] name = "custom-boto3-init" -version = "4.0.1" +version = "4.0.3" description = "Initialize boto config for AWS Python SDK with custom configuration" optional = false python-versions = "^3.13" diff --git a/source/lambda/invoke-agent/pyproject.toml b/source/lambda/invoke-agent/pyproject.toml index 6a8bcd21..b647421e 100644 --- a/source/lambda/invoke-agent/pyproject.toml +++ b/source/lambda/invoke-agent/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "invoke-agent" -version = "4.0.2" +version = "4.0.3" authors = [ "Amazon Web Services" ] description = "Lambda implementation for chat feature" packages = [ diff --git a/source/lambda/layers/aws-node-user-agent-config/package-lock.json b/source/lambda/layers/aws-node-user-agent-config/package-lock.json index 7a85e46a..53be36d8 100644 --- a/source/lambda/layers/aws-node-user-agent-config/package-lock.json +++ b/source/lambda/layers/aws-node-user-agent-config/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/aws-node-user-agent-config", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@amzn/aws-node-user-agent-config", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "dependencies": { "@aws-lambda-powertools/logger": "^2.11.0", diff --git a/source/lambda/layers/aws-node-user-agent-config/package.json b/source/lambda/layers/aws-node-user-agent-config/package.json index fc50626d..b550b32f 100644 --- a/source/lambda/layers/aws-node-user-agent-config/package.json +++ b/source/lambda/layers/aws-node-user-agent-config/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/aws-node-user-agent-config", - "version": "4.0.2", + "version": "4.0.3", "description": "AWS Nodejs SDK Config initialization layer", "main": "index.js", "scripts": { diff --git a/source/lambda/layers/aws-sdk-lib/package-lock.json b/source/lambda/layers/aws-sdk-lib/package-lock.json index 4c9d6dd3..43713d28 100644 --- a/source/lambda/layers/aws-sdk-lib/package-lock.json +++ b/source/lambda/layers/aws-sdk-lib/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/aws-sdk-layer", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@amzn/aws-sdk-layer", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "dependencies": { "@aws-sdk/client-api-gateway": "^3.875.0", diff --git a/source/lambda/layers/aws-sdk-lib/package.json b/source/lambda/layers/aws-sdk-lib/package.json index b8f73902..d51d60d3 100644 --- a/source/lambda/layers/aws-sdk-lib/package.json +++ b/source/lambda/layers/aws-sdk-lib/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/aws-sdk-layer", - "version": "4.0.2", + "version": "4.0.3", "description": "AWS Javascript SDK v3 layer", "main": "index.js", "scripts": { diff --git a/source/lambda/layers/aws_boto3/pyproject.toml b/source/lambda/layers/aws_boto3/pyproject.toml index b9f73b34..bfbc8daf 100644 --- a/source/lambda/layers/aws_boto3/pyproject.toml +++ b/source/lambda/layers/aws_boto3/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "boto3-layer" -version = "4.0.2" +version = "4.0.3" authors = [ "Amazon Web Services" ] description = "Layer for AWS Boto3 python SDK" packages = [ diff --git a/source/lambda/layers/custom_boto3_init/poetry.lock b/source/lambda/layers/custom_boto3_init/poetry.lock index 78b3d612..5daf02dc 100644 --- a/source/lambda/layers/custom_boto3_init/poetry.lock +++ b/source/lambda/layers/custom_boto3_init/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 2.2.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 2.1.3 and should not be changed by hand. [[package]] name = "aws-lambda-powertools" @@ -67,7 +67,7 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] [[package]] name = "boto3-layer" -version = "4.0.2" +version = "4.0.3" description = "Layer for AWS Boto3 python SDK" optional = false python-versions = "^3.13" diff --git a/source/lambda/layers/custom_boto3_init/pyproject.toml b/source/lambda/layers/custom_boto3_init/pyproject.toml index 4af1b568..d20fe489 100644 --- a/source/lambda/layers/custom_boto3_init/pyproject.toml +++ b/source/lambda/layers/custom_boto3_init/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "custom_boto3_init" -version = "4.0.2" +version = "4.0.3" authors = [ "Amazon Web Services" ] description = "Initialize boto config for AWS Python SDK with custom configuration" packages = [ diff --git a/source/lambda/layers/langchain/poetry.lock b/source/lambda/layers/langchain/poetry.lock index 67e92787..25f890c6 100644 --- a/source/lambda/layers/langchain/poetry.lock +++ b/source/lambda/layers/langchain/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 2.2.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 2.1.3 and should not be changed by hand. [[package]] name = "annotated-types" @@ -189,8 +189,6 @@ files = [ {file = "greenlet-3.2.4-cp310-cp310-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:c2ca18a03a8cfb5b25bc1cbe20f3d9a4c80d8c3b13ba3df49ac3961af0b1018d"}, {file = "greenlet-3.2.4-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:9fe0a28a7b952a21e2c062cd5756d34354117796c6d9215a87f55e38d15402c5"}, {file = "greenlet-3.2.4-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:8854167e06950ca75b898b104b63cc646573aa5fef1353d4508ecdd1ee76254f"}, - {file = "greenlet-3.2.4-cp310-cp310-musllinux_1_2_aarch64.whl", hash = "sha256:f47617f698838ba98f4ff4189aef02e7343952df3a615f847bb575c3feb177a7"}, - {file = "greenlet-3.2.4-cp310-cp310-musllinux_1_2_x86_64.whl", hash = "sha256:af41be48a4f60429d5cad9d22175217805098a9ef7c40bfef44f7669fb9d74d8"}, {file = "greenlet-3.2.4-cp310-cp310-win_amd64.whl", hash = "sha256:73f49b5368b5359d04e18d15828eecc1806033db5233397748f4ca813ff1056c"}, {file = "greenlet-3.2.4-cp311-cp311-macosx_11_0_universal2.whl", hash = "sha256:96378df1de302bc38e99c3a9aa311967b7dc80ced1dcc6f171e99842987882a2"}, {file = "greenlet-3.2.4-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:1ee8fae0519a337f2329cb78bd7a8e128ec0f881073d43f023c7b8d4831d5246"}, @@ -200,8 +198,6 @@ files = [ {file = "greenlet-3.2.4-cp311-cp311-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:2523e5246274f54fdadbce8494458a2ebdcdbc7b802318466ac5606d3cded1f8"}, {file = "greenlet-3.2.4-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:1987de92fec508535687fb807a5cea1560f6196285a4cde35c100b8cd632cc52"}, {file = "greenlet-3.2.4-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:55e9c5affaa6775e2c6b67659f3a71684de4c549b3dd9afca3bc773533d284fa"}, - {file = "greenlet-3.2.4-cp311-cp311-musllinux_1_2_aarch64.whl", hash = "sha256:c9c6de1940a7d828635fbd254d69db79e54619f165ee7ce32fda763a9cb6a58c"}, - {file = "greenlet-3.2.4-cp311-cp311-musllinux_1_2_x86_64.whl", hash = "sha256:03c5136e7be905045160b1b9fdca93dd6727b180feeafda6818e6496434ed8c5"}, {file = "greenlet-3.2.4-cp311-cp311-win_amd64.whl", hash = "sha256:9c40adce87eaa9ddb593ccb0fa6a07caf34015a29bf8d344811665b573138db9"}, {file = "greenlet-3.2.4-cp312-cp312-macosx_11_0_universal2.whl", hash = "sha256:3b67ca49f54cede0186854a008109d6ee71f66bd57bb36abd6d0a0267b540cdd"}, {file = "greenlet-3.2.4-cp312-cp312-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:ddf9164e7a5b08e9d22511526865780a576f19ddd00d62f8a665949327fde8bb"}, @@ -211,8 +207,6 @@ files = [ {file = "greenlet-3.2.4-cp312-cp312-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:3b3812d8d0c9579967815af437d96623f45c0f2ae5f04e366de62a12d83a8fb0"}, {file = "greenlet-3.2.4-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:abbf57b5a870d30c4675928c37278493044d7c14378350b3aa5d484fa65575f0"}, {file = "greenlet-3.2.4-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:20fb936b4652b6e307b8f347665e2c615540d4b42b3b4c8a321d8286da7e520f"}, - {file = "greenlet-3.2.4-cp312-cp312-musllinux_1_2_aarch64.whl", hash = "sha256:ee7a6ec486883397d70eec05059353b8e83eca9168b9f3f9a361971e77e0bcd0"}, - {file = "greenlet-3.2.4-cp312-cp312-musllinux_1_2_x86_64.whl", hash = "sha256:326d234cbf337c9c3def0676412eb7040a35a768efc92504b947b3e9cfc7543d"}, {file = "greenlet-3.2.4-cp312-cp312-win_amd64.whl", hash = "sha256:a7d4e128405eea3814a12cc2605e0e6aedb4035bf32697f72deca74de4105e02"}, {file = "greenlet-3.2.4-cp313-cp313-macosx_11_0_universal2.whl", hash = "sha256:1a921e542453fe531144e91e1feedf12e07351b1cf6c9e8a3325ea600a715a31"}, {file = "greenlet-3.2.4-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:cd3c8e693bff0fff6ba55f140bf390fa92c994083f838fece0f63be121334945"}, @@ -222,8 +216,6 @@ files = [ {file = "greenlet-3.2.4-cp313-cp313-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:23768528f2911bcd7e475210822ffb5254ed10d71f4028387e5a99b4c6699671"}, {file = "greenlet-3.2.4-cp313-cp313-musllinux_1_1_aarch64.whl", hash = "sha256:00fadb3fedccc447f517ee0d3fd8fe49eae949e1cd0f6a611818f4f6fb7dc83b"}, {file = "greenlet-3.2.4-cp313-cp313-musllinux_1_1_x86_64.whl", hash = "sha256:d25c5091190f2dc0eaa3f950252122edbbadbb682aa7b1ef2f8af0f8c0afefae"}, - {file = "greenlet-3.2.4-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:6e343822feb58ac4d0a1211bd9399de2b3a04963ddeec21530fc426cc121f19b"}, - {file = "greenlet-3.2.4-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:ca7f6f1f2649b89ce02f6f229d7c19f680a6238af656f61e0115b24857917929"}, {file = "greenlet-3.2.4-cp313-cp313-win_amd64.whl", hash = "sha256:554b03b6e73aaabec3745364d6239e9e012d64c68ccd0b8430c64ccc14939a8b"}, {file = "greenlet-3.2.4-cp314-cp314-macosx_11_0_universal2.whl", hash = "sha256:49a30d5fda2507ae77be16479bdb62a660fa51b1eb4928b524975b3bde77b3c0"}, {file = "greenlet-3.2.4-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:299fd615cd8fc86267b47597123e3f43ad79c9d8a22bebdce535e53550763e2f"}, @@ -231,8 +223,6 @@ files = [ {file = "greenlet-3.2.4-cp314-cp314-manylinux2014_s390x.manylinux_2_17_s390x.whl", hash = "sha256:b4a1870c51720687af7fa3e7cda6d08d801dae660f75a76f3845b642b4da6ee1"}, {file = "greenlet-3.2.4-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", hash = "sha256:061dc4cf2c34852b052a8620d40f36324554bc192be474b9e9770e8c042fd735"}, {file = "greenlet-3.2.4-cp314-cp314-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:44358b9bf66c8576a9f57a590d5f5d6e72fa4228b763d0e43fee6d3b06d3a337"}, - {file = "greenlet-3.2.4-cp314-cp314-musllinux_1_2_aarch64.whl", hash = "sha256:2917bdf657f5859fbf3386b12d68ede4cf1f04c90c3a6bc1f013dd68a22e2269"}, - {file = "greenlet-3.2.4-cp314-cp314-musllinux_1_2_x86_64.whl", hash = "sha256:015d48959d4add5d6c9f6c5210ee3803a830dce46356e3bc326d6776bde54681"}, {file = "greenlet-3.2.4-cp314-cp314-win_amd64.whl", hash = "sha256:e37ab26028f12dbb0ff65f29a8d3d44a765c61e729647bf2ddfbbed621726f01"}, {file = "greenlet-3.2.4-cp39-cp39-macosx_11_0_universal2.whl", hash = "sha256:b6a7c19cf0d2742d0809a4c05975db036fdff50cd294a93632d6a310bf9ac02c"}, {file = "greenlet-3.2.4-cp39-cp39-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:27890167f55d2387576d1f41d9487ef171849ea0359ce1510ca6e06c8bece11d"}, @@ -242,8 +232,6 @@ files = [ {file = "greenlet-3.2.4-cp39-cp39-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:c9913f1a30e4526f432991f89ae263459b1c64d1608c0d22a5c79c287b3c70df"}, {file = "greenlet-3.2.4-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:b90654e092f928f110e0007f572007c9727b5265f7632c2fa7415b4689351594"}, {file = "greenlet-3.2.4-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:81701fd84f26330f0d5f4944d4e92e61afe6319dcd9775e39396e39d7c3e5f98"}, - {file = "greenlet-3.2.4-cp39-cp39-musllinux_1_2_aarch64.whl", hash = "sha256:28a3c6b7cd72a96f61b0e4b2a36f681025b60ae4779cc73c1535eb5f29560b10"}, - {file = "greenlet-3.2.4-cp39-cp39-musllinux_1_2_x86_64.whl", hash = "sha256:52206cd642670b0b320a1fd1cbfd95bca0e043179c1d8a045f2c6109dfe973be"}, {file = "greenlet-3.2.4-cp39-cp39-win32.whl", hash = "sha256:65458b409c1ed459ea899e939f0e1cdb14f58dbc803f2f93c5eab5694d32671b"}, {file = "greenlet-3.2.4-cp39-cp39-win_amd64.whl", hash = "sha256:d2e685ade4dafd447ede19c31277a224a239a0a1a4eca4e6390efedf20260cfb"}, {file = "greenlet-3.2.4.tar.gz", hash = "sha256:0dca0d95ff849f9a364385f36ab49f50065d76964944638be9691e1832e9f86d"}, @@ -429,14 +417,14 @@ tools = ["beautifulsoup4 (>=4.13.4)", "bedrock-agentcore (>=0.1.0) ; python_vers [[package]] name = "langchain-core" -version = "0.3.80" +version = "0.3.81" description = "Building applications with LLMs through composability" optional = false python-versions = "<4.0.0,>=3.9.0" groups = ["main"] files = [ - {file = "langchain_core-0.3.80-py3-none-any.whl", hash = "sha256:2141e3838d100d17dce2359f561ec0df52c526bae0de6d4f469f8026c5747456"}, - {file = "langchain_core-0.3.80.tar.gz", hash = "sha256:29636b82513ab49e834764d023c4d18554d3d719a185d37b019d0a8ae948c6bb"}, + {file = "langchain_core-0.3.81-py3-none-any.whl", hash = "sha256:d0f34c88254d78ccb1b9a038f860d13dea90186045026fd8fc3e1265eed73a4e"}, + {file = "langchain_core-0.3.81.tar.gz", hash = "sha256:0473e7cffbba06017393f2f1ee116da098c298e4ec478ada91d321f42dff921c"}, ] [package.dependencies] @@ -1225,4 +1213,4 @@ cffi = ["cffi (>=1.17) ; python_version >= \"3.13\" and platform_python_implemen [metadata] lock-version = "2.1" python-versions = "^3.13" -content-hash = "8357dd18c9f84e84942b25073a647c63c53fa5f94d2c011b008936608684f81b" +content-hash = "6bbc01cd5660787900aa7f3c56e120365d21a4db40b34238944b07500d4e304b" diff --git a/source/lambda/layers/langchain/pyproject.toml b/source/lambda/layers/langchain/pyproject.toml index 9ebcd9f1..3cd50032 100644 --- a/source/lambda/layers/langchain/pyproject.toml +++ b/source/lambda/layers/langchain/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "langchain-layer" -version = "4.0.2" +version = "4.0.3" authors = [ "Amazon Web Services" ] description = "Layer for LangChain libraries" packages = [ @@ -17,7 +17,7 @@ license = "Apache-2.0" python = "^3.13" numpy = "2.2.2" langchain = "0.3.27" -langchain-core = "0.3.80" +langchain-core = "0.3.81" langchain-aws = "0.2.31" pydantic = "2.11.0" requests="2.32.4" diff --git a/source/lambda/model-info/package-lock.json b/source/lambda/model-info/package-lock.json index 5066e3ce..9ffd5efa 100644 --- a/source/lambda/model-info/package-lock.json +++ b/source/lambda/model-info/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/model-info", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@amzn/model-info", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "devDependencies": { "@types/jest": "^29.5.12", diff --git a/source/lambda/model-info/package.json b/source/lambda/model-info/package.json index a0d1ad6f..ca4f25d5 100644 --- a/source/lambda/model-info/package.json +++ b/source/lambda/model-info/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/model-info", - "version": "4.0.2", + "version": "4.0.3", "description": "This lambda supports APIs that provide the capability to deploy GenAI use cases", "main": "index.ts", "scripts": { diff --git a/source/lambda/use-case-details/package-lock.json b/source/lambda/use-case-details/package-lock.json index bb82f118..bcdf7cad 100644 --- a/source/lambda/use-case-details/package-lock.json +++ b/source/lambda/use-case-details/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/use-case-details", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@amzn/use-case-details", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "devDependencies": { "@types/jest": "^29.5.14", diff --git a/source/lambda/use-case-details/package.json b/source/lambda/use-case-details/package.json index 87362c76..8066627f 100644 --- a/source/lambda/use-case-details/package.json +++ b/source/lambda/use-case-details/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/use-case-details", - "version": "4.0.2", + "version": "4.0.3", "description": "This lambda supports APIs that provide details about a deployed use case", "main": "index.ts", "scripts": { diff --git a/source/lambda/use-case-management/package-lock.json b/source/lambda/use-case-management/package-lock.json index f6ec01c7..0700ffcf 100644 --- a/source/lambda/use-case-management/package-lock.json +++ b/source/lambda/use-case-management/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/use-case-management", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@amzn/use-case-management", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "dependencies": { "aws-jwt-verify": "^5.0.0" diff --git a/source/lambda/use-case-management/package.json b/source/lambda/use-case-management/package.json index 7ae8720f..bbe6e4d7 100644 --- a/source/lambda/use-case-management/package.json +++ b/source/lambda/use-case-management/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/use-case-management", - "version": "4.0.2", + "version": "4.0.3", "description": "This lambda supports APIs that provide the capability to deploy GenAI use cases", "main": "index.ts", "scripts": { diff --git a/source/lambda/websocket-connectors/package-lock.json b/source/lambda/websocket-connectors/package-lock.json index 99068278..d1d0020e 100644 --- a/source/lambda/websocket-connectors/package-lock.json +++ b/source/lambda/websocket-connectors/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/websocket-connectors", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@amzn/websocket-connectors", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "devDependencies": { "@types/jest": "^29.5.14", diff --git a/source/lambda/websocket-connectors/package.json b/source/lambda/websocket-connectors/package.json index 8021ed8c..e6ba9908 100644 --- a/source/lambda/websocket-connectors/package.json +++ b/source/lambda/websocket-connectors/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/websocket-connectors", - "version": "4.0.2", + "version": "4.0.3", "description": "This lambda function is used to handle connect and disconnect requests", "main": "connect-handler.js", "scripts": { diff --git a/source/scripts/v2_migration/pyproject.toml b/source/scripts/v2_migration/pyproject.toml index 89c32899..ef2e2767 100644 --- a/source/scripts/v2_migration/pyproject.toml +++ b/source/scripts/v2_migration/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "gaab-v2-migration" -version = "4.0.2" +version = "4.0.3" authors = [ "Amazon Web Services" ] description = "Migration script to convert v1.X use cases to v2.X" packages = [ diff --git a/source/ui-chat/package-lock.json b/source/ui-chat/package-lock.json index 7aa137e2..48a438b7 100644 --- a/source/ui-chat/package-lock.json +++ b/source/ui-chat/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/gen-ai-app-builder-on-aws-ui-chat", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@amzn/gen-ai-app-builder-on-aws-ui-chat", - "version": "4.0.2", + "version": "4.0.3", "dependencies": { "@aws-amplify/core": "^6.10.0", "@aws-amplify/ui-react": "^6.9.1", diff --git a/source/ui-chat/package.json b/source/ui-chat/package.json index 2eee71aa..eed24fd5 100644 --- a/source/ui-chat/package.json +++ b/source/ui-chat/package.json @@ -1,7 +1,7 @@ { "name": "@amzn/gen-ai-app-builder-on-aws-ui-chat", "private": true, - "version": "4.0.2", + "version": "4.0.3", "type": "module", "author": { "name": "Amazon Web Services", diff --git a/source/ui-chat/src/utils/extract-thinking-content.ts b/source/ui-chat/src/utils/extract-thinking-content.ts index b40b3749..23b375fc 100644 --- a/source/ui-chat/src/utils/extract-thinking-content.ts +++ b/source/ui-chat/src/utils/extract-thinking-content.ts @@ -1,3 +1,6 @@ +// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + import { ThinkingMetadata } from '../pages/chat/types'; /** diff --git a/source/ui-deployment/package-lock.json b/source/ui-deployment/package-lock.json index 612f37f6..8871c7cf 100644 --- a/source/ui-deployment/package-lock.json +++ b/source/ui-deployment/package-lock.json @@ -1,12 +1,12 @@ { "name": "@amzn/gen-ai-app-builder-on-aws-ui-deployment", - "version": "4.0.2", + "version": "4.0.3", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@amzn/gen-ai-app-builder-on-aws-ui-deployment", - "version": "4.0.2", + "version": "4.0.3", "license": "Apache-2.0", "dependencies": { "@aws-amplify/ui-react": "^5.3.3", @@ -12859,24 +12859,24 @@ } }, "node_modules/body-parser": { - "version": "1.20.3", - "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.3.tgz", - "integrity": "sha512-7rAxByjUMqQ3/bHJy7D6OGXvx/MMc4IqBn/X0fcM1QUcAItpZrBEYhWGem+tzXH90c+G01ypMcYJBO9Y30203g==", + "version": "1.20.4", + "resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.4.tgz", + "integrity": "sha512-ZTgYYLMOXY9qKU/57FAo8F+HA2dGX7bqGc71txDRC1rS4frdFI5R7NhluHxH6M0YItAP0sHB4uqAOcYKxO6uGA==", "license": "MIT", "peer": true, "dependencies": { - "bytes": "3.1.2", + "bytes": "~3.1.2", "content-type": "~1.0.5", "debug": "2.6.9", "depd": "2.0.0", - "destroy": "1.2.0", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "on-finished": "2.4.1", - "qs": "6.13.0", - "raw-body": "2.5.2", + "destroy": "~1.2.0", + "http-errors": "~2.0.1", + "iconv-lite": "~0.4.24", + "on-finished": "~2.4.1", + "qs": "~6.14.0", + "raw-body": "~2.5.3", "type-is": "~1.6.18", - "unpipe": "1.0.0" + "unpipe": "~1.0.0" }, "engines": { "node": ">= 0.8", @@ -12893,6 +12893,27 @@ "ms": "2.0.0" } }, + "node_modules/body-parser/node_modules/http-errors": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.1.tgz", + "integrity": "sha512-4FbRdAX+bSdmo4AUFuS0WNiPz8NgFt+r8ThgNWmlrjQjt1Q7ZR9+zTlce2859x4KSXrwIsaeTqDoKQmtP8pLmQ==", + "license": "MIT", + "peer": true, + "dependencies": { + "depd": "~2.0.0", + "inherits": "~2.0.4", + "setprototypeof": "~1.2.0", + "statuses": "~2.0.2", + "toidentifier": "~1.0.1" + }, + "engines": { + "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" + } + }, "node_modules/body-parser/node_modules/iconv-lite": { "version": "0.4.24", "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz", @@ -12926,6 +12947,16 @@ "node": ">= 0.8" } }, + "node_modules/body-parser/node_modules/statuses": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.2.tgz", + "integrity": "sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==", + "license": "MIT", + "peer": true, + "engines": { + "node": ">= 0.8" + } + }, "node_modules/bootstrap": { "version": "5.3.3", "resolved": "https://registry.npmjs.org/bootstrap/-/bootstrap-5.3.3.tgz", @@ -18561,13 +18592,13 @@ } }, "node_modules/qs": { - "version": "6.13.0", - "resolved": "https://registry.npmjs.org/qs/-/qs-6.13.0.tgz", - "integrity": "sha512-+38qI9SOr8tfZ4QmJNplMUxqjbe7LKvvZgWdExBOmd+egZTtjLB67Gu0HRX3u/XOq7UU2Nx6nsjvS16Z9uwfpg==", + "version": "6.14.1", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.14.1.tgz", + "integrity": "sha512-4EK3+xJl8Ts67nLYNwqw/dsFVnCf+qR7RgXSK9jEEm9unao3njwMDdmsdvoKBKHzxd7tCYz5e5M+SnMjdtXGQQ==", "license": "BSD-3-Clause", "peer": true, "dependencies": { - "side-channel": "^1.0.6" + "side-channel": "^1.1.0" }, "engines": { "node": ">=0.6" @@ -18650,19 +18681,40 @@ } }, "node_modules/raw-body": { - "version": "2.5.2", - "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz", - "integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==", + "version": "2.5.3", + "resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.3.tgz", + "integrity": "sha512-s4VSOf6yN0rvbRZGxs8Om5CWj6seneMwK3oDb4lWDH0UPhWcxwOWw5+qk24bxq87szX1ydrwylIOp2uG1ojUpA==", "license": "MIT", "peer": true, "dependencies": { - "bytes": "3.1.2", - "http-errors": "2.0.0", - "iconv-lite": "0.4.24", - "unpipe": "1.0.0" + "bytes": "~3.1.2", + "http-errors": "~2.0.1", + "iconv-lite": "~0.4.24", + "unpipe": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/raw-body/node_modules/http-errors": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/http-errors/-/http-errors-2.0.1.tgz", + "integrity": "sha512-4FbRdAX+bSdmo4AUFuS0WNiPz8NgFt+r8ThgNWmlrjQjt1Q7ZR9+zTlce2859x4KSXrwIsaeTqDoKQmtP8pLmQ==", + "license": "MIT", + "peer": true, + "dependencies": { + "depd": "~2.0.0", + "inherits": "~2.0.4", + "setprototypeof": "~1.2.0", + "statuses": "~2.0.2", + "toidentifier": "~1.0.1" }, "engines": { "node": ">= 0.8" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/express" } }, "node_modules/raw-body/node_modules/iconv-lite": { @@ -18678,6 +18730,16 @@ "node": ">=0.10.0" } }, + "node_modules/raw-body/node_modules/statuses": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/statuses/-/statuses-2.0.2.tgz", + "integrity": "sha512-DvEy55V3DB7uknRo+4iOGT5fP1slR8wQohVdknigZPMpMstaKJQWhwiYBACJE3Ul2pTnATihhBYnRhZQHGBiRw==", + "license": "MIT", + "peer": true, + "engines": { + "node": ">= 0.8" + } + }, "node_modules/react": { "version": "18.3.1", "resolved": "https://registry.npmjs.org/react/-/react-18.3.1.tgz", diff --git a/source/ui-deployment/package.json b/source/ui-deployment/package.json index d83f0f35..83e04c53 100644 --- a/source/ui-deployment/package.json +++ b/source/ui-deployment/package.json @@ -1,6 +1,6 @@ { "name": "@amzn/gen-ai-app-builder-on-aws-ui-deployment", - "version": "4.0.2", + "version": "4.0.3", "dependencies": { "@aws-amplify/ui-react": "^5.3.3", "@aws-sdk/util-arn-parser": "^3.893.0",