-
Notifications
You must be signed in to change notification settings - Fork 66
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
Update appeals_api rake tasks for new OAuth scopes #12368
Update appeals_api rake tasks for new OAuth scopes #12368
Conversation
@@ -284,14 +284,22 @@ modules_appeals_api: | |||
api_key: '' | |||
# The token generation values below are only used for development rake tasks. | |||
token_generation: |
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.
These settings values are only used in local development workflows, so there's nothing related to update in the deployed environments
cc57b66
to
040dd81
Compare
040dd81
to
c0c749a
Compare
c0c749a
to
90a41ec
Compare
auth: | ||
config_uri: 'https://dev-api.va.gov/oauth2/appeals/v1/.well-known/openid-configuration' | ||
# Get a client ID/secret by submitting this form - make sure to check the boxes for the APIs under | ||
# "Authorization Code Flow APIs": https://developer.va.gov/onboarding/request-sandbox-access |
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.
N.B. for now, you can use https://dev-developer.va.gov/onboarding/request-sandbox-access to get tokens instead, since these APIs are only live in dev
rakelib/appeals_api_oauth.rake
Outdated
API_NAMES.each do |api_name| | ||
namespace abbreviate_snake_case_name(api_name).to_sym do | ||
AppealsRakeHelpers::API_NAMES.each do |api_name| | ||
namespace api_name.scan(/(?<=^|_)(\S)/).join.to_sym do |
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.
Consider keeping a wrapper for this regex. This seems more difficult to parse at a glance than the existing method name.
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.
Gold star 🌟 My comment on the regex is not a blocker.
e957f09
e957f09
to
3f827ac
Compare
|
||
def abbreviate_snake_case_name(name) | ||
name.scan(/(?<=^|_)(\S)/).join | ||
def abbreviate_snake_case_name(name) = name.scan(/(?<=^|_)(\S)/).join |
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.
Noice! Endless def!
3f827ac
to
3ec2573
Compare
Summary
- This PR is separate from API-25677 - New appeals scopes #12364 because of the PR check on changed lines, but it depends on those changes - this should not be merged (and won't work correctly) until API-25677 - New appeals scopes #12364 is merged and I've rebased this PR.DoneRelated issue(s)
Testing done
What areas of the site does it impact?
Acceptance criteria