-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
[spaceship] Add retrieve-create of iap shared secret to Spaceship::Tunes #16326
Conversation
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed (or fixed any issues), please reply here with What to do if you already signed the CLAIndividual signers
Corporate signers
ℹ️ Googlers: Go here for more info. |
@googlebot I signed it! |
CLAs look good, thanks! ℹ️ Googlers: Go here for more info. |
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.
I had no idea this was a thing 🙃 Thanks for the PR for this! I requested one little change to split the tunes client method into two methods. Would you also be able to add some tests for this as well?
def handle_shared_secret(method: nil, app_id: nil) | ||
r = request(method, "ra/apps/#{app_id}/iaps/appSharedSecret") | ||
data = parse_response(r, 'data') | ||
data['sharedSecret'] | ||
end |
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.
Can we actually split this into two methods? One for the :get
and one for the :post
. I’d just like this to follow the rest of the conventions in this class and keep the :get
and :post
encapsulated into this 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.
Thanks for review, totally agree. Have done this! 👍
@max-ott Can you take a look at these changes too? 😊 |
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.
Looks great to me! Thanks for making those changes ❤️ I’ll wait for @max-ott’s review before merging 😊
Works like a charm! Thanks for the addition. |
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.
Tested and everything is working as intended!
@max-ott thank you for review! |
Hey @piechart 👋 Thank you for your contribution to fastlane and congrats on getting this pull request merged 🎉 Please let us know if this change requires an immediate release by adding a comment here 👍 |
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.
Congratulations! 🎉 This was released as part of fastlane 2.147.0 🚀
Checklist
bundle exec rspec
from the root directory to see all new and existing tests passbundle exec rubocop -a
to ensure the code style is validMotivation and Context
I was working on iOS project in a remote team. Once someone was implementing in-app purchases functionality and regenerated shared secret key. Unluckily, at the same time I was testing other iaps in the app. Having fastlane as a helping tool which lanes prevent a lot of other cases of such scenarios in the project, I thought being able to retrieve actual shared secret via Spaceship and set in the project somehow would be a useful feature.
Description
Retrieve currently existing shared secret (or create if does not exist)
Generate (or regenerate if exists) new app-specific shared secret