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

Add error message when provider does not exist #5964

Merged

Conversation

@Xenonym
Copy link
Contributor

commented Mar 27, 2019

What did you implement:

Closes #5876.

How did you implement it:

I added a check in the before:deploy:deploy hook to check if the specified provider in serverless.yml exists, and to throw an error if it does not.

How can we verify it:

  1. Specify a non-existent provider in serverless.yml:
provider:
  name: nonExistentProvider
  1. serverless deploy should throw an error:
  Serverless Error ---------------------------------------

  The specified provider "nonExistentProvider" does not exist.

Todos:

  • Write tests
  • Write documentation
  • Fix linting errors
  • Make sure code coverage hasn't dropped
  • Provide verification config / commands / resources
  • Enable "Allow edits from maintainers" for this PR
  • Update the messages below

Is this ready for review?: YES
Is it a breaking change?: NO

@Xenonym Xenonym force-pushed the Xenonym:enhancement/non-existent-provider-error branch 3 times, most recently from 9c5b87b to 76eaf78 Mar 27, 2019
@Xenonym Xenonym force-pushed the Xenonym:enhancement/non-existent-provider-error branch from 76eaf78 to 177a0ad Mar 27, 2019
@pmuens pmuens self-assigned this Mar 28, 2019
@pmuens pmuens added the pr/in-review label Mar 28, 2019
@pmuens pmuens added this to the 1.41.0 milestone Mar 28, 2019
@pmuens pmuens added this to In progress in Serverless via automation Mar 28, 2019
@pmuens
pmuens approved these changes Mar 28, 2019
Copy link
Member

left a comment

Thanks for submitting this PR @Xenonym 👍

Just tested it and it works fine! LGTM :shipit:

Serverless automation moved this from In progress to Reviewer approved Mar 28, 2019
@exoego
exoego approved these changes Mar 28, 2019
Copy link
Contributor

left a comment

LGTM 👍

@pmuens pmuens merged commit 467cdf8 into serverless:master Mar 29, 2019
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
Serverless automation moved this from Reviewer approved to Done Mar 29, 2019
@Xenonym Xenonym deleted the Xenonym:enhancement/non-existent-provider-error branch Mar 29, 2019
@dschep dschep added the enhancement label Apr 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Serverless
  
Done
4 participants
You can’t perform that action at this time.