Skip to content

Commit

Permalink
Update cli.py (zappa#1314)
Browse files Browse the repository at this point in the history
Expected Behavior
The CLI should output that the current AWS user does not have permission to call lambda:GetFunction.

Actual Behavior
The CLI outputs: Warning! Couldn't get function {{function_name}} in {{AWS Region}} - have you deployed yet?.

Co-authored-by: monkut <[email protected]>
  • Loading branch information
2 people authored and FlorentGeode committed Jul 12, 2024
1 parent daddb5b commit ac2e7cd
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions zappa/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -942,6 +942,10 @@ def update(self, source_zip=None, no_upload=False, docker_image_uri=None):
except botocore.exceptions.BotoCoreError as e:
click.echo(click.style(type(e).__name__, fg="red") + ": " + e.args[0])
sys.exit(-1)
# https://github.com/zappa/Zappa/issues/1313
except botocore.exceptions.ClientError as e:
click.echo(click.style(type(e).__name__, fg="red") + ": " + e.args[0])
sys.exit(-1)
except Exception:
click.echo(
click.style("Warning!", fg="red")
Expand Down

0 comments on commit ac2e7cd

Please sign in to comment.