Skip to content

Commit 942fad7

Browse files
authored
chore: pip update (#384)
1 parent cff4dcf commit 942fad7

File tree

8 files changed

+89
-72
lines changed

8 files changed

+89
-72
lines changed

.vscode/settings.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
"cSpell.words": [
33
"appconfig",
44
"Codecov",
5+
"getuid",
6+
"mkdocs",
57
"ranisenberg",
68
"runtimes"
79
]

Pipfile.lock

Lines changed: 47 additions & 47 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,25 @@
1+
import os
2+
import pwd
3+
from pathlib import Path
4+
15
from aws_cdk import Stack
26
from constructs import Construct
7+
from git import Repo
38
from my_service.service_stack.configuration.configuration_construct import ConfigurationStore
49
from my_service.service_stack.constants import CONFIGURATION_NAME, ENVIRONMENT, SERVICE_NAME
510
from my_service.service_stack.service_construct import ApiConstruct
611

712

13+
def _get_stack_prefix() -> str:
14+
repo = Repo(Path.cwd())
15+
username = pwd.getpwuid(os.getuid()).pw_name
16+
print(f'username={username}')
17+
try:
18+
return f'{username}{repo.active_branch}'
19+
except TypeError:
20+
return username
21+
22+
823
class ServiceStack(Stack):
924

1025
def __init__(self, scope: Construct, id: str, **kwargs) -> None:
@@ -13,6 +28,6 @@ def __init__(self, scope: Construct, id: str, **kwargs) -> None:
1328
# This construct should be deployed in a different repo and have its own pipeline so updates can be decoupled
1429
# from running the service pipeline and without redeploying the service lambdas. For the sake of this template
1530
# example, it is deployed as part of the service stack
16-
self.dynamic_configuration = ConfigurationStore(self, 'dynamic_conf', ENVIRONMENT, SERVICE_NAME, CONFIGURATION_NAME)
17-
18-
self.lambdas = ApiConstruct(self, 'Service')
31+
prefix = _get_stack_prefix()
32+
self.dynamic_configuration = ConfigurationStore(self, f'{prefix}dynamic_conf'[0:64], ENVIRONMENT, SERVICE_NAME, CONFIGURATION_NAME)
33+
self.lambdas = ApiConstruct(self, f'{prefix}Service'[0:64])

cdk/setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,6 @@
2525
'aws-cdk-lib>=2.0.0',
2626
'constructs>=10.0.0',
2727
'cdk-nag>2.0.0',
28-
'aws-cdk.aws-lambda-python-alpha==2.47.0-alpha.0',
28+
'aws-cdk.aws-lambda-python-alpha==2.50.0-alpha.0',
2929
],
3030
)

dev_requirements.txt

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11
-i https://pypi.org/simple
22
attrs==22.1.0; python_version >= '3.5'
33
aws-cdk-lib==2.50.0; python_version ~= '3.7'
4-
aws-cdk.aws-lambda-python-alpha==2.47.0a0; python_version ~= '3.7'
5-
boto3==1.26.0
6-
botocore==1.29.0; python_version >= '3.7'
4+
aws-cdk.aws-lambda-python-alpha==2.50.0a0; python_version ~= '3.7'
5+
boto3==1.26.9
6+
botocore==1.29.9; python_version >= '3.7'
77
cattrs==22.2.0; python_version >= '3.7'
88
-e ./cdk
9-
cdk-nag==2.19.10; python_version ~= '3.7'
9+
cdk-nag==2.20.11; python_version ~= '3.7'
1010
certifi==2022.9.24; python_version >= '3.6'
1111
cfgv==3.3.1; python_full_version >= '3.6.1'
1212
charset-normalizer==2.1.1; python_version >= '3.6'
1313
click==8.1.3; python_version >= '3.7'
1414
colorama==0.4.6; python_version >= '3.5'
15-
constructs==10.1.147; python_version ~= '3.7'
15+
constructs==10.1.160; python_version ~= '3.7'
1616
coverage[toml]==6.5.0; python_version >= '3.7'
1717
distlib==0.3.6
18-
exceptiongroup==1.0.0; python_version < '3.11'
18+
exceptiongroup==1.0.3; python_version < '3.11'
1919
filelock==3.8.0; python_version >= '3.7'
2020
flake8==5.0.4
2121
future==0.18.2; python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3'
@@ -29,27 +29,27 @@ iniconfig==1.1.1
2929
isort==5.10.1
3030
jinja2==3.1.2; python_version >= '3.7'
3131
jmespath==1.0.1; python_version >= '3.7'
32-
jsii==1.70.0; python_version ~= '3.7'
32+
jsii==1.71.0; python_version ~= '3.7'
3333
mando==0.6.4
3434
markdown==3.3.7; python_version >= '3.6'
3535
markupsafe==2.1.1; python_version >= '3.7'
3636
mccabe==0.7.0; python_version >= '3.6'
3737
mergedeep==1.3.4; python_version >= '3.6'
3838
mkdocs==1.4.2; python_version >= '3.7'
3939
mkdocs-git-revision-date-plugin==0.3.2
40-
mkdocs-material==8.5.7
40+
mkdocs-material==8.5.10
4141
mkdocs-material-extensions==1.1; python_version >= '3.7'
4242
nodeenv==1.7.0; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5, 3.6'
4343
packaging==21.3; python_version >= '3.6'
44-
platformdirs==2.5.2; python_version >= '3.7'
44+
platformdirs==2.5.4; python_version >= '3.7'
4545
pluggy==1.0.0; python_version >= '3.6'
4646
pre-commit==2.20.0
4747
publication==0.0.3
4848
py==1.11.0; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4'
4949
pycodestyle==2.9.1
5050
pyflakes==2.5.0; python_version >= '3.6'
5151
pygments==2.13.0; python_version >= '3.6'
52-
pymdown-extensions==9.7; python_version >= '3.7'
52+
pymdown-extensions==9.8; python_version >= '3.7'
5353
pyparsing==3.0.9; python_full_version >= '3.6.8'
5454
pytest==7.2.0
5555
pytest-cov==4.0.0
@@ -64,21 +64,21 @@ radon==5.1.0
6464
requests==2.28.1; python_version >= '3.7' and python_version < '4.0'
6565
s3transfer==0.6.0; python_version >= '3.7'
6666
-e ./cdk
67-
setuptools==65.5.0; python_version >= '3.7'
67+
setuptools==65.5.1; python_version >= '3.7'
6868
six==1.16.0; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'
6969
smmap==5.0.0; python_version >= '3.6'
7070
toml==0.10.2; python_version >= '2.6' and python_version not in '3.0, 3.1, 3.2, 3.3'
7171
tomli==2.0.1; python_version < '3.11'
7272
typeguard==2.13.3; python_full_version >= '3.5.3'
7373
typing-extensions==4.4.0; python_version >= '3.7'
74-
urllib3==1.26.12; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5' and python_full_version < '4.0.0'
75-
virtualenv==20.16.6; python_version >= '3.6'
74+
urllib3==1.26.12; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5' and python_version < '4'
75+
virtualenv==20.16.7; python_version >= '3.6'
7676
watchdog==2.1.9; python_version >= '3.6'
7777
xenon==0.9.0
7878
yapf==0.32.0
7979
zipp==3.10.0; python_version >= '3.7'
80-
aws-lambda-powertools[all]==2.1.0
81-
aws-xray-sdk==2.10.0
80+
aws-lambda-powertools[all]==2.2.0
81+
aws-xray-sdk==2.11.0
8282
fastjsonschema==2.16.2
8383
pydantic==1.10.2
8484
wrapt==1.14.1; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4'

docs/examples/best_practices/metrics/my_handler.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
from http import HTTPStatus
33
from typing import Any, Dict
44

5-
from aws_lambda_powertools.metrics.metrics import Metrics, MetricUnit
5+
from aws_lambda_powertools.metrics import Metrics, MetricUnit
66
from aws_lambda_powertools.utilities.typing import LambdaContext
77

88
SERVICE_NAME = 'my_service'

lambda_requirements.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
-i https://pypi.org/simple
2-
aws-lambda-powertools[all]==2.1.0
3-
aws-xray-sdk==2.10.0
4-
botocore==1.29.0; python_version >= '3.7'
2+
aws-lambda-powertools[all]==2.2.0
3+
aws-xray-sdk==2.11.0
4+
botocore==1.29.9; python_version >= '3.7'
55
fastjsonschema==2.16.2
66
jmespath==1.0.1; python_version >= '3.7'
77
pydantic==1.10.2
88
python-dateutil==2.8.2; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'
99
six==1.16.0; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3'
1010
typing-extensions==4.4.0; python_version >= '3.7'
11-
urllib3==1.26.12; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5' and python_full_version < '4.0.0'
11+
urllib3==1.26.12; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5' and python_version < '4'
1212
wrapt==1.14.1; python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4'

service/handlers/my_handler.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
from http import HTTPStatus
22
from typing import Any, Dict
33

4-
from aws_lambda_powertools.metrics.metrics import MetricUnit
4+
from aws_lambda_powertools.metrics import MetricUnit
55
from aws_lambda_powertools.utilities.feature_flags.exceptions import ConfigurationStoreError, SchemaValidationError
66
from aws_lambda_powertools.utilities.parser import ValidationError, parse
77
from aws_lambda_powertools.utilities.parser.envelopes import ApiGatewayEnvelope

0 commit comments

Comments
 (0)