Skip to content

Commit

Permalink
Update cli.py (#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 <shane.cousins@gmail.com>
  • Loading branch information
lmuther8 and monkut committed Apr 25, 2024
1 parent a38058b commit 39f75e7
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 @@ -936,6 +936,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 39f75e7

Please sign in to comment.