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

InvalidClientTokenId during DescribeStacks #988

Closed
alex-harvey-z3q opened this issue Mar 31, 2021 · 5 comments
Closed

InvalidClientTokenId during DescribeStacks #988

alex-harvey-z3q opened this issue Mar 31, 2021 · 5 comments

Comments

@alex-harvey-z3q
Copy link
Contributor

Hi there, I am receiving this failure that I cannot debug due to insufficient feedback from Sceptre:

[2021-04-01 04:29:25] - iam-cseo - termination protection set to 'enabled'
"An error occurred (InvalidClientTokenId) when calling the DescribeStacks operation: The security token included in the request is invalid."
**********************************************************************************************************************************************************************************                                                       launch on foundations/config/foundations.yaml returned exit status 1
**********************************************************************************************************************************************************************************

Outside of Sceptre, I am unable to reproduce any such issue about InvalidClientTokenId.

I have spent a couple of hours placing print statements variously through the Sceptre code but I just can't find where or what is emitting that error.

Can anyone give me any clues on where it might be coming from?

@craighurley
Copy link
Contributor

craighurley commented Apr 2, 2021

Looks like a boto error. Are you using a particular IAM role when running sceptre? Does that role have perms to DescribeStacks?

@alex-harvey-z3q
Copy link
Contributor Author

@craighurley Yes and yes. aws cloudformation describe-stacks runs fine for instance.

alex-harvey-z3q added a commit to alex-harvey-z3q/sceptre that referenced this issue Apr 6, 2021
Before this, the catch_exceptions function in cli/helpers would catch a
range of exceptions and then hide all but the error message from the
caller.

Over the years, this has caused myself and others quite a lot of lost
time, as it is now often quite unclear what caused Sceptre to fail.

Simply re-raising the original exception provides valuable information
to allow users of Sceptre to debug their failing code.
alex-harvey-z3q added a commit to alex-harvey-z3q/sceptre that referenced this issue Apr 6, 2021
Before this, the catch_exceptions function in cli/helpers would catch a
range of exceptions and then hide all but the error message from the
caller.

Over the years, this has caused myself and others quite a lot of lost
time, as it is now often quite unclear what caused Sceptre to fail.

Simply re-raising the original exception provides valuable information
to allow users of Sceptre to debug their failing code.
alex-harvey-z3q added a commit to alex-harvey-z3q/sceptre that referenced this issue Apr 6, 2021
Before this, the catch_exceptions function in cli/helpers would catch a
range of exceptions and then hide all but the error message from the
caller.

Over the years, this has caused myself and others quite a lot of lost
time, as it is now often quite unclear what caused Sceptre to fail.

Simply re-raising the original exception provides valuable information
to allow users of Sceptre to debug their failing code.
@craighurley
Copy link
Contributor

Did you figure out the cause in the end?

alex-harvey-z3q added a commit to alex-harvey-z3q/sceptre that referenced this issue Apr 7, 2021
Before this, the catch_exceptions function in cli/helpers would catch a
range of exceptions and then hide all but the error message from the
caller.

Over the years, this has caused myself and others quite a lot of lost
time, as it is now often quite unclear what caused Sceptre to fail.

Simply re-raising the original exception provides valuable information
to allow users of Sceptre to debug their failing code.
alex-harvey-z3q added a commit to alex-harvey-z3q/sceptre that referenced this issue Apr 7, 2021
Before this, the catch_exceptions function in cli/helpers would catch a
range of exceptions and then hide all but the error message from the
caller.

Over the years, this has caused myself and others quite a lot of lost
time, as it is now often quite unclear what caused Sceptre to fail.

Simply re-raising the original exception provides valuable information
to allow users of Sceptre to debug their failing code.
@craighurley
Copy link
Contributor

Relates to #897

alex-harvey-z3q added a commit to alex-harvey-z3q/sceptre that referenced this issue Oct 3, 2021
Before this, the catch_exceptions function in cli/helpers would catch a
range of exceptions and then hide all but the error message from the
caller.

Over the years, this has caused myself and others quite a lot of lost
time, as it is now often quite unclear what caused Sceptre to fail.

Simply re-raising the original exception provides valuable information
to allow users of Sceptre to debug their failing code.
alex-harvey-z3q added a commit to alex-harvey-z3q/sceptre that referenced this issue Oct 15, 2021
Before this, the catch_exceptions function in cli/helpers would catch a
range of exceptions and then hide all but the error message from the
caller.

Over the years, this has caused myself and others quite a lot of lost
time, as it is now often quite unclear what caused Sceptre to fail.

Simply re-raising the original exception provides valuable information
to allow users of Sceptre to debug their failing code.
@zaro0508
Copy link
Contributor

no reponse from reporter so closing

craighurley pushed a commit that referenced this issue Oct 18, 2021
* [Resolve #988] Stop hiding debug info in helpers

Before this, the catch_exceptions function in cli/helpers would catch a
range of exceptions and then hide all but the error message from the
caller.

Over the years, this has caused myself and others quite a lot of lost
time, as it is now often quite unclear what caused Sceptre to fail.

Simply re-raising the original exception provides valuable information
to allow users of Sceptre to debug their failing code.

* Refactor according to Jon's suggestion

* Refactor to implement Craig Hurley's suggestion

* Restore master version of tests

* Add unit tests
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants