Repository: aws/serverless-application-model (branch: layer-version-fix)
Commit date: 2023-11-01T00:25:29Z

Workflow file: .github/workflows/build.yml (Tests)
name: Tests

on:
  push:
    branches:
      - develop
      - "feat-*"
  pull_request:
  workflow_dispatch:
  merge_group:
    types: [checks_requested]

jobs:
  build:
    name: ${{ matrix.os }} / ${{ matrix.python }}
    runs-on: ${{ matrix.os }}
    services:
      pypi_wayback:
        image: ghcr.io/waleko/pypi-wayback
        ports:
          - 8629:8080
    strategy:
      fail-fast: false
      matrix:
        os:
          - ubuntu-latest
        python:
          - "3.7"
          - "3.8"
          - "3.9"
          - "3.10"
          - "3.11"
    steps:
    - uses: actions/checkout@v3
    - uses: actions/setup-python@v4
      with:
        python-version: ${{ matrix.python }}
    - run: make init
    - run: make pr

env:
  PIP_INDEX_URL: http://localhost:8629/2023-11-01
  UV_INDEX_URL: http://localhost:8629/2023-11-01


Failed build logs:
step_name: ubuntu-latest  3.7/5_Run make pr.txt
log: ##[group]Run make pr
[36;1mmake pr[0m
shell: /usr/bin/bash -e {0}
env:
  pythonLocation: /opt/hostedtoolcache/Python/3.7.17/x64
  PKG_CONFIG_PATH: /opt/hostedtoolcache/Python/3.7.17/x64/lib/pkgconfig
  Python_ROOT_DIR: /opt/hostedtoolcache/Python/3.7.17/x64
  Python2_ROOT_DIR: /opt/hostedtoolcache/Python/3.7.17/x64
  Python3_ROOT_DIR: /opt/hostedtoolcache/Python/3.7.17/x64
  LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.7.17/x64/lib
##[endgroup]
# Checking latest schema was generated (run `make schema` if this fails)
mkdir -p .tmp
python -m samtranslator.internal.schema_source.schema --sam-schema .tmp/sam.schema.json --cfn-schema schema_source/cloudformation.schema.json --unified-schema .tmp/schema.json
diff -u schema_source/sam.schema.json .tmp/sam.schema.json
diff -u samtranslator/schema/schema.json .tmp/schema.json
black --check setup.py samtranslator tests integration bin schema_source
would reformat /home/runner/work/serverless-application-model/serverless-application-model/samtranslator/utils/actions.py
would reformat /home/runner/work/serverless-application-model/serverless-application-model/samtranslator/utils/traverse.py

Oh no! 💥 💔 💥
2 files would be reformatted, 363 files would be left unchanged.
make: *** [Makefile:40: format-check] Error 1
##[error]Process completed with exit code 2.

step_name: ubuntu-latest  3.8/5_Run make pr.txt
log: ##[group]Run make pr
[36;1mmake pr[0m
shell: /usr/bin/bash -e {0}
env:
  pythonLocation: /opt/hostedtoolcache/Python/3.8.18/x64
  PKG_CONFIG_PATH: /opt/hostedtoolcache/Python/3.8.18/x64/lib/pkgconfig
  Python_ROOT_DIR: /opt/hostedtoolcache/Python/3.8.18/x64
  Python2_ROOT_DIR: /opt/hostedtoolcache/Python/3.8.18/x64
  Python3_ROOT_DIR: /opt/hostedtoolcache/Python/3.8.18/x64
  LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.8.18/x64/lib
##[endgroup]
# Checking latest schema was generated (run `make schema` if this fails)
mkdir -p .tmp
python -m samtranslator.internal.schema_source.schema --sam-schema .tmp/sam.schema.json --cfn-schema schema_source/cloudformation.schema.json --unified-schema .tmp/schema.json
diff -u schema_source/sam.schema.json .tmp/sam.schema.json
diff -u samtranslator/schema/schema.json .tmp/schema.json
black --check setup.py samtranslator tests integration bin schema_source
would reformat /home/runner/work/serverless-application-model/serverless-application-model/samtranslator/utils/actions.py
would reformat /home/runner/work/serverless-application-model/serverless-application-model/samtranslator/utils/traverse.py

Oh no! 💥 💔 💥
2 files would be reformatted, 363 files would be left unchanged.
make: *** [Makefile:40: format-check] Error 1
##[error]Process completed with exit code 2.

step_name: ubuntu-latest  3.9/5_Run make pr.txt
log: ##[group]Run make pr
[36;1mmake pr[0m
shell: /usr/bin/bash -e {0}
env:
  pythonLocation: /opt/hostedtoolcache/Python/3.9.18/x64
  PKG_CONFIG_PATH: /opt/hostedtoolcache/Python/3.9.18/x64/lib/pkgconfig
  Python_ROOT_DIR: /opt/hostedtoolcache/Python/3.9.18/x64
  Python2_ROOT_DIR: /opt/hostedtoolcache/Python/3.9.18/x64
  Python3_ROOT_DIR: /opt/hostedtoolcache/Python/3.9.18/x64
  LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.9.18/x64/lib
##[endgroup]
# Checking latest schema was generated (run `make schema` if this fails)
mkdir -p .tmp
python -m samtranslator.internal.schema_source.schema --sam-schema .tmp/sam.schema.json --cfn-schema schema_source/cloudformation.schema.json --unified-schema .tmp/schema.json
diff -u schema_source/sam.schema.json .tmp/sam.schema.json
diff -u samtranslator/schema/schema.json .tmp/schema.json
black --check setup.py samtranslator tests integration bin schema_source
would reformat /home/runner/work/serverless-application-model/serverless-application-model/samtranslator/utils/actions.py
would reformat /home/runner/work/serverless-application-model/serverless-application-model/samtranslator/utils/traverse.py

Oh no! 💥 💔 💥
2 files would be reformatted, 363 files would be left unchanged.
make: *** [Makefile:40: format-check] Error 1
##[error]Process completed with exit code 2.

step_name: ubuntu-latest  3.10/5_Run make pr.txt
log: ##[group]Run make pr
[36;1mmake pr[0m
shell: /usr/bin/bash -e {0}
env:
  pythonLocation: /opt/hostedtoolcache/Python/3.10.13/x64
  PKG_CONFIG_PATH: /opt/hostedtoolcache/Python/3.10.13/x64/lib/pkgconfig
  Python_ROOT_DIR: /opt/hostedtoolcache/Python/3.10.13/x64
  Python2_ROOT_DIR: /opt/hostedtoolcache/Python/3.10.13/x64
  Python3_ROOT_DIR: /opt/hostedtoolcache/Python/3.10.13/x64
  LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.10.13/x64/lib
##[endgroup]
# Checking latest schema was generated (run `make schema` if this fails)
mkdir -p .tmp
python -m samtranslator.internal.schema_source.schema --sam-schema .tmp/sam.schema.json --cfn-schema schema_source/cloudformation.schema.json --unified-schema .tmp/schema.json
diff -u schema_source/sam.schema.json .tmp/sam.schema.json
diff -u samtranslator/schema/schema.json .tmp/schema.json
black --check setup.py samtranslator tests integration bin schema_source
would reformat /home/runner/work/serverless-application-model/serverless-application-model/samtranslator/utils/actions.py
would reformat /home/runner/work/serverless-application-model/serverless-application-model/samtranslator/utils/traverse.py

Oh no! 💥 💔 💥
2 files would be reformatted, 363 files would be left unchanged.
make: *** [Makefile:40: format-check] Error 1
##[error]Process completed with exit code 2.

step_name: ubuntu-latest  3.11/5_Run make pr.txt
log: ##[group]Run make pr
[36;1mmake pr[0m
shell: /usr/bin/bash -e {0}
env:
  pythonLocation: /opt/hostedtoolcache/Python/3.11.6/x64
  PKG_CONFIG_PATH: /opt/hostedtoolcache/Python/3.11.6/x64/lib/pkgconfig
  Python_ROOT_DIR: /opt/hostedtoolcache/Python/3.11.6/x64
  Python2_ROOT_DIR: /opt/hostedtoolcache/Python/3.11.6/x64
  Python3_ROOT_DIR: /opt/hostedtoolcache/Python/3.11.6/x64
  LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.11.6/x64/lib
##[endgroup]
# Checking latest schema was generated (run `make schema` if this fails)
mkdir -p .tmp
python -m samtranslator.internal.schema_source.schema --sam-schema .tmp/sam.schema.json --cfn-schema schema_source/cloudformation.schema.json --unified-schema .tmp/schema.json
diff -u schema_source/sam.schema.json .tmp/sam.schema.json
diff -u samtranslator/schema/schema.json .tmp/schema.json
black --check setup.py samtranslator tests integration bin schema_source
would reformat /home/runner/work/serverless-application-model/serverless-application-model/samtranslator/utils/actions.py
would reformat /home/runner/work/serverless-application-model/serverless-application-model/samtranslator/utils/traverse.py

Oh no! 💥 💔 💥
2 files would be reformatted, 363 files would be left unchanged.
make: *** [Makefile:40: format-check] Error 1
##[error]Process completed with exit code 2.


Changed files:
samtranslator/utils/actions.py
samtranslator/utils/traverse.py

Fix diff:
diff --git a/samtranslator/utils/actions.py b/samtranslator/utils/actions.py
index 10c1fd7b..921914a0 100644
--- a/samtranslator/utils/actions.py
+++ b/samtranslator/utils/actions.py
@@ -15,7 +15,7 @@ class Action(ABC):
 
 class ResolveDependsOn(Action):
     DependsOn = "DependsOn"
-    
+
     def __init__(self, resolution_data: Dict[str, str]):
         """
         Initializes ResolveDependsOn. Where data necessary to resolve execute can be provided.
diff --git a/samtranslator/utils/traverse.py b/samtranslator/utils/traverse.py
index 3ab9e1c5..ea5ec5e7 100644
--- a/samtranslator/utils/traverse.py
+++ b/samtranslator/utils/traverse.py
@@ -19,7 +19,7 @@ def traverse(
 
     :param input_value: Any primitive type  (dict, array, string etc) whose value might contain a changed value
     :param actions: Method that will be called to actually resolve the function.
-    :return: Modified `input` with values resolved    
+    :return: Modified `input` with values resolved
     """
 
     for action in actions: