Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: sam build - AttributeError #6847

Closed
rkarthikr opened this issue Mar 16, 2024 · 2 comments
Closed

Bug: sam build - AttributeError #6847

rkarthikr opened this issue Mar 16, 2024 · 2 comments
Labels
stage/needs-triage Automatically applied to new issues and PRs, indicating they haven't been looked at.

Comments

@rkarthikr
Copy link

Description:

2024-03-16 12:31:43 Plugin 'ServerlessAppPlugin' raised an exception: 'NoneType' object has no attribute 'get'
This is an old project and i am trying to git clone and update the stack with new changes

Steps to reproduce:

Observed result:

2024-03-16 12:31:43 Plugin 'ServerlessAppPlugin' raised an exception: 'NoneType' object has no attribute 'get'
Traceback (most recent call last):
File "samtranslator/plugins/sam_plugins.py", line 130, in act
File "samtranslator/metrics/method_decorator.py", line 116, in wrapper_cw_timer
File "samtranslator/plugins/application/serverless_app_plugin.py", line 125, in on_before_transform_template
File "samtranslator/sdk/template.py", line 34, in iterate
File "samtranslator/sdk/resource.py", line 26, in init
AttributeError: 'NoneType' object has no attribute 'get'
Error: 'NoneType' object has no attribute 'get'
Traceback:
File "click/core.py", line 1078, in main
File "click/core.py", line 1688, in invoke
File "click/core.py", line 1434, in invoke
File "click/core.py", line 783, in invoke
File "samcli/cli/cli_config_file.py", line 347, in wrapper
File "click/decorators.py", line 92, in new_func
File "click/core.py", line 783, in invoke
File "samcli/lib/telemetry/metric.py", line 185, in wrapped
File "samcli/lib/telemetry/metric.py", line 150, in wrapped
File "samcli/lib/utils/version_checker.py", line 43, in wrapped
File "samcli/cli/main.py", line 95, in wrapper
File "samcli/commands/build/command.py", line 175, in cli
File "samcli/commands/build/command.py", line 240, in do_cli
File "samcli/commands/build/build_context.py", line 185, in enter
File "samcli/commands/build/build_context.py", line 191, in set_up
File "samcli/lib/providers/sam_stack_provider.py", line 270, in get_stacks
File "samcli/lib/providers/sam_stack_provider.py", line 62, in init
File "samcli/lib/providers/sam_base_provider.py", line 193, in get_template
File "samcli/lib/samlib/wrapper.py", line 73, in run_plugins
File "samcli/lib/samlib/wrapper.py", line 130, in parse
File "samtranslator/plugins/sam_plugins.py", line 136, in act
File "samtranslator/plugins/sam_plugins.py", line 130, in act
File "samtranslator/metrics/method_decorator.py", line 116, in wrapper_cw_timer
File "samtranslator/plugins/application/serverless_app_plugin.py", line 125, in on_before_transform_template
File "samtranslator/sdk/template.py", line 34, in iterate
File "samtranslator/sdk/resource.py", line 26, in init

Expected result:

Build to complete successfully

Additional environment details (Ex: Windows, Mac, Amazon Linux etc)

  1. OS: MacOS Sonoma 14.3.1 (23D60)
  2. sam --version: SAM CLI, version 1.112.0
  3. AWS region: us-east-1
# Paste the output of `sam --info` here

{
"version": "1.112.0",
"system": {
"python": "3.8.13",
"os": "macOS-14.3.1-arm64-arm-64bit"
},
"additional_dependencies": {
"docker_engine": "Not available",
"aws_cdk": "2.132.1 (build 9df7dd3)",
"terraform": "Not available"
},
"available_beta_feature_env_vars": [
"SAM_CLI_BETA_FEATURES",
"SAM_CLI_BETA_BUILD_PERFORMANCE",
"SAM_CLI_BETA_TERRAFORM_SUPPORT",
"SAM_CLI_BETA_RUST_CARGO_LAMBDA"
]
}

Add --debug flag to command you are running

@rkarthikr rkarthikr added the stage/needs-triage Automatically applied to new issues and PRs, indicating they haven't been looked at. label Mar 16, 2024
@rkarthikr
Copy link
Author

Fixed it - Code Issue

Copy link
Contributor

⚠️COMMENT VISIBILITY WARNING⚠️

Comments on closed issues are hard for our team to see.
If you need more assistance, please either tag a team member or open a new issue that references this one.
If you wish to keep having a conversation with other community members under this issue feel free to do so.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stage/needs-triage Automatically applied to new issues and PRs, indicating they haven't been looked at.
Projects
None yet
Development

No branches or pull requests

2 participants