https://serverless-stack.com/ logo
#help
Title
# help
p

Patrik Ståhl

06/03/2022, 6:50 PM
Copy code
Using stage: dev
Preparing your SST app

=======================
 Deploying debug stack
=======================

/Users/foo/Development/app/node_modules/@serverless-stack/cli/node_modules/aws-sdk/lib/shared-ini/ini-loader.js:8
    Object.keys(content).forEach(function(profileName) {
                         ^
TypeError: Cannot redefine property: foobar-prod
    at Function.defineProperty (<anonymous>)
    at /Users/foo/Development/app/node_modules/@serverless-stack/cli/node_modules/aws-sdk/lib/shared-ini/ini-loader.js:11:14
    at Array.forEach (<anonymous>)
    at IniLoader2.parseFile (/Users/foo/Development/app/node_modules/@serverless-stack/cli/node_modules/aws-sdk/lib/shared-ini/ini-loader.js:8:26)
    at IniLoader2.loadFrom (/Users/foo/Development/app/node_modules/@serverless-stack/cli/node_modules/aws-sdk/lib/shared-ini/ini-loader.js:56:30)
    at getRegion (/Users/foo/Development/app/node_modules/@serverless-stack/cli/node_modules/aws-sdk/lib/node_loader.js:118:32)
    at Config.region (/Users/foo/Development/app/node_modules/@serverless-stack/cli/node_modules/aws-sdk/lib/node_loader.js:173:18)
    at Config.set (/Users/foo/Development/app/node_modules/@serverless-stack/cli/node_modules/aws-sdk/lib/config.js:524:39)
    at Config.<anonymous> (/Users/foo/Development/app/node_modules/@serverless-stack/cli/node_modules/aws-sdk/lib/config.js:359:12)
    at Config.each (/Users/foo/Development/app/node_modules/@serverless-stack/cli/node_modules/aws-sdk/lib/util.js:512:32)
This app worked like a charm before I updated from aws-cli v1 to v2- Can’t think of anything else that would have changed.
staring at the problem for too long you become blind 🙂 broken .aws/config file was the root cause of this issue
f

Frank

06/03/2022, 7:25 PM
lol glad u figured it out
2 Views