-
Notifications
You must be signed in to change notification settings - Fork 175
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
Hotfix: update the logic to get path of access tokens. #198
Conversation
1. Add logic to read path of access tokens through environment variable. 2. Add fallback logic to default one. Notice: this is short-term fix and require user to use latest version of provider in Cloud Shell.
I could not find any legacy unit test for AccessTokensPath method. Let me know if we need to add it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Couple of quick fixes, and as you mention, we would much appreciate it if you helped out and added a unit-test regardless of whether or not one previously existed.
Thanks!
autorest/azure/cli/token.go
Outdated
var err error | ||
|
||
// Fallback logic to default path on non-cloud-shell environment. | ||
// TODO(sushi): remove the dependency on hard-coding path. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of mentioning yourself, please open a new issue and mention it in this comment. :)
CHANGELOG.md
Outdated
|
||
### Bug Fixes | ||
|
||
- Update the logic to get path of access tokens through AZURE_ACCESS_TOKEN_FILE. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mind rephrasing this to make clear that the previous default still works?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes.
@marstr let me create an issue as TODO item for the unit test. |
@marstr the PR is updated, when it's merged, please let me know. I will work with Tom to update the dependency on provider repo. |
Notice: this is short-term fix and require user to use latest version of provider in Cloud Shell.
Thank you for your contribution to Go-AutoRest! We will triage and review it as soon as we can.
As part of submitting, please make sure you can make the following assertions:
dev
branch, except in the case of urgent bug fixes warranting their own release.master
, I've updated CHANGELOG.md to address the changes I'm making.