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

Integrate Gravatar SDK #22921

Merged
merged 61 commits into from
Apr 2, 2024
Merged

Integrate Gravatar SDK #22921

merged 61 commits into from
Apr 2, 2024

Conversation

pinarol
Copy link
Contributor

@pinarol pinarol commented Mar 29, 2024

Fixes #22543

WordPressUI PR: wordpress-mobile/WordPressUI-iOS#156

  • Adds a new dependency: Gravatar
  • Replaces WordPressUI.Gravatar usage with Gravatar.AvatarURL
  • Starts using Gravatar.AvatarService.upload(...) to upload an avatar
  • WordpressUICacheAdapter now also conforms to Gravatar.ImageCaching.
  • Adds extension UIImageView to add new alternatives of what’s deprecated in WordPressUI. (All related with downloading an Avatar.)
  • Updates GravatarServiceTests

No new functionality is added. This is just to replace code & refactor.


I'll add some screenshots with avatars to make dangermattic happy.


To test:

Regression Notes

  1. Potential unintended areas of impact

  2. What I did to test those areas of impact (or what existing automated tests I relied on)

  3. What automated tests I added (or what prevented me from doing so)

PR submission checklist:

  • I have completed the Regression Notes.
  • I have considered adding unit tests for my changes.
  • I have considered adding accessibility improvements for my changes.
  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

Testing checklist:

  • WordPress.com sites and self-hosted Jetpack sites.
  • Portrait and landscape orientations.
  • Light and dark modes.
  • Fonts: Larger, smaller and bold text.
  • High contrast.
  • VoiceOver.
  • Languages with large words or with letters/accents not frequently used in English.
  • Right-to-left languages. (Even if translation isn’t complete, formatting should still respect the right-to-left layout)
  • iPhone and iPad.
  • Multi-tasking: Split view and Slide over. (iPad)

pinarol and others added 30 commits January 23, 2024 12:57
* Use GravatarURL instead of Gravatar

* Use GravatarURL in ListTableViewCell

---------

Co-authored-by: Pinar Olguc <[email protected]>
* Update podfile Gravatar testspecs

* bundle exec pod install

---------

Co-authored-by: Pinar Olguc <[email protected]>
We won't use the SDK until we have an open api-based endpoint for it
@wpmobilebot
Copy link
Contributor

wpmobilebot commented Mar 29, 2024

WordPress Alpha📲 You can test the changes from this Pull Request in WordPress Alpha by scanning the QR code below to install the corresponding build.
App NameWordPress Alpha WordPress Alpha
ConfigurationRelease-Alpha
Build Numberpr22921-50e5dbb
Version24.6
Bundle IDorg.wordpress.alpha
Commit50e5dbb
App Center BuildWPiOS - One-Offs #9347
Automatticians: You can use our internal self-serve MC tool to give yourself access to App Center if needed.

@wpmobilebot
Copy link
Contributor

wpmobilebot commented Mar 29, 2024

Jetpack Alpha📲 You can test the changes from this Pull Request in Jetpack Alpha by scanning the QR code below to install the corresponding build.
App NameJetpack Alpha Jetpack Alpha
ConfigurationRelease-Alpha
Build Numberpr22921-50e5dbb
Version24.6
Bundle IDcom.jetpack.alpha
Commit50e5dbb
App Center Buildjetpack-installable-builds #8391
Automatticians: You can use our internal self-serve MC tool to give yourself access to App Center if needed.

@pinarol pinarol self-assigned this Mar 29, 2024
@pinarol pinarol requested a review from etoledom March 29, 2024 12:17
@pinarol pinarol added this to the 24.6 milestone Mar 29, 2024
@pinarol
Copy link
Contributor Author

pinarol commented Mar 29, 2024

cc: @alpavanoglu @kean Could you take a look as well? Not sure who else to tag so please feel free to tag others who might be interested. We don't expect you to run the tests(although you are highly welcome if you want to). Just let us know if you have any concerns & comments. Thank you!

@pinarol pinarol marked this pull request as ready for review March 29, 2024 12:40
@pinarol
Copy link
Contributor Author

pinarol commented Mar 29, 2024

Also, here's the alternative change set that imports Gravatar from WordPressUI:

https://github.com/wordpress-mobile/WordPress-iOS/compare/task/gravatar-integration?expand=1
https://github.com/wordpress-mobile/WordPressUI-iOS/compare/task/gravatar-integration?expand=1

The reason why we didn't pursue that is because WordPressUI has deployment target set to iOS 11 and this is too low for our SDK. Gravatar SDK’s is iOS 15. For us, it’s better not to be bound by WPUI’s target version as we go down the road. Because we’ll add more features in the SDK and we would like to make the most of modern Apple APIs. So it would be easier for us to move fwd with this PR.

But let us know if you think this one is better.

Copy link
Contributor

@etoledom etoledom left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All looks good to me!

Smoke-tested using the test cases from #22543

@pinarol pinarol enabled auto-merge (squash) April 2, 2024 06:50
@pinarol
Copy link
Contributor Author

pinarol commented Apr 2, 2024

But let us know if you think this one is better.

We talked in Slack. We decided to move fwd with this solution.

@pinarol pinarol merged commit c2d4a35 into trunk Apr 2, 2024
24 of 27 checks passed
@pinarol pinarol deleted the wppinar/move-gravatar branch April 2, 2024 07:45
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

Successfully merging this pull request may close these issues.

[Gravatar] Gravatar SDK integration umbrella task
4 participants