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

Azure errors are not wrapped correctly #14

Open
ShimShtein opened this issue Dec 27, 2018 · 0 comments
Open

Azure errors are not wrapped correctly #14

ShimShtein opened this issue Dec 27, 2018 · 0 comments

Comments

@ShimShtein
Copy link
Member

In cases when Azure throws an error, for example if credentials are wrong on while testing a connection, instead of the original error, NoMethodError (undefined method []' for nil:NilClass)` error is thrown.

This comes from fog-azure-rm-downgraded-0.3.1/lib/fog/azurerm/utilities/general.rb @ line 51 Object#raise_azure_exception. The original exception looks like this:

[6] pry(#<Fog::Resources::AzureRM::Real>)> exception
=> #<MsRestAzure::AzureOperationError: {
  "message": "Couldn't login to Azure, please verify your tenant id, client id and client secret",
  "request": null,
  "response": null
}>

But body property is nil.

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

No branches or pull requests

1 participant