Closed alexsomesan closed 3 years ago
I like it 🥇
Thanks for the fix!
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 hashibot-feedback@hashicorp.com. Thanks!
Description
This change introduces a check for valid credentials at the beginning of plan. This is to ensure that users get a clear meaningful error message rather than a raw error from the API. If credentials are invalid but the API is otherwise accessible the users will get this message:
The check is performed by doing a simple GET call on the API endpoint using the path
/apis
which only responds to authenticated calls but otherwise doesn't require specific permissions like resource paths do.This also avoids the problem reported in #159 where the cached RESTMapper will get stuck in retry loop when credentials are invalid.
Release Note
Release note for CHANGELOG:
References
Fixes #159
Community Note