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

fix: include required messagingpush dependency for no push configuration #187

Merged
merged 1 commit into from
Aug 28, 2023

Conversation

levibostian
Copy link
Contributor

@levibostian levibostian commented Aug 18, 2023

The RN SDK today does require the messagingpush SDK module but the podspec that we ask customers to install does not include this module. This could mean compile-time errors.

Yes, we do expect that customers setup rich push in their app and so we do not expect customers to encounter this problem. However, the idea that this PR also adds a comment to the podspec files specifying required dependencies is a good value add to the codebase.

PR in draft mode and asks for review by team to get feedback if this is something we want to do or not.

Note: Conversation that sparked this idea: https://github.com/customerio/docs/pull/1446#discussion_r1298239891

@github-actions
Copy link

github-actions bot commented Aug 18, 2023

Pull request title looks good 👍!

If this pull request gets merged, it will cause a new release of the software. Example: If this project's latest release version is 1.0.0. If this pull request gets merged in, the next release of this project will be 1.0.1. This pull request is not a breaking change.

All merged pull requests will eventually get deployed. But some types of pull requests will trigger a deployment (such as features and bug fixes) while some pull requests will wait to get deployed until a later time.

This project uses a special format for pull requests titles. Expand this section to learn more (expand by clicking the ᐅ symbol on the left side of this sentence)...

This project uses a special format for pull requests titles. Don't worry, it's easy!

This pull request title should be in this format:

<type>: short description of change being made

If your pull request introduces breaking changes to the code, use this format:

<type>!: short description of breaking change

where <type> is one of the following:

  • feat: - A feature is being added or modified by this pull request. Use this if you made any changes to any of the features of the project.

  • fix: - A bug is being fixed by this pull request. Use this if you made any fixes to bugs in the project.

  • docs: - This pull request is making documentation changes, only.

  • refactor: - A change was made that doesn't fix a bug or add a feature.

  • test: - Adds missing tests or fixes broken tests.

  • style: - Changes that do not effect the code (whitespace, linting, formatting, semi-colons, etc)

  • perf: - Changes improve performance of the code.

  • build: - Changes to the build system (maven, npm, gulp, etc)

  • ci: - Changes to the CI build system (Travis, GitHub Actions, Circle, etc)

  • chore: - Other changes to project that don't modify source code or test files.

  • revert: - Reverts a previous commit that was made.

Examples:

feat: edit profile photo
refactor!: remove deprecated v1 endpoints
build: update npm dependencies
style: run formatter 

Need more examples? Want to learn more about this format? Check out the official docs.

Note: If your pull request does multiple things such as adding a feature and makes changes to the CI server and fixes some bugs then you might want to consider splitting this pull request up into multiple smaller pull requests.

@levibostian levibostian requested a review from a team August 18, 2023 18:40
# no dependencies. This is the default subspec designed to not install any push dependencies.
# This is the default subspec designed to not install any push dependencies. Customer should choose APN or FCM.
# The SDK at runtime currently requires the MessagingPush module so we do include it here.
ss.dependency "CustomerIO/MessagingPush", package["cioNativeiOSSdkVersion"]
Copy link
Collaborator

Choose a reason for hiding this comment

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

Looking at the comment, I'm not clear on what the customer needs to do. What about adding both APN and FCM options as comments and directing the customer to uncomment the one they need and deleting the other?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm not clear on what the customer needs to do.

The customer needs to follow our SDK docs to setup APN or FCM push.

This PR is trying to handle the scenario where a customer has not yet setup APN or FCM push. Some customers have sent us support tickets saying that they are experiencing issues with our SDK while following our SDK docs. They must be doing 1 step at a time, continuously compiling their app and testing along the way. If a customer does that, they could encounter issues. This PR is to try and fix those issues.

This PR does not effect our docs today. No work on customers part besides what they already do.

Copy link
Contributor

@Shahroz16 Shahroz16 left a comment

Choose a reason for hiding this comment

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

I like the idea but added some thoughts

@@ -28,7 +28,9 @@ Pod::Spec.new do |s|
s.default_subspec = "nopush"

s.subspec 'nopush' do |ss|
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe we need to move away from wording nopush because otherwise, it can get confusing. how about base/common ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This name would be for internal purposes, only which is why I included docs into this file explaining it. However, I do understand what you mean by nopush being confusing.

I wouldn't mind a word generic-push or base-push which implies that the RN SDK does require some sort of push setup, but it's not specific to the service yet.

Copy link
Contributor

Choose a reason for hiding this comment

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

Sweet, I am approving it as this isn't a blocker, feel free to update it to a more generic name now or later.

@levibostian levibostian marked this pull request as ready for review August 21, 2023 20:02
@@ -28,7 +28,9 @@ Pod::Spec.new do |s|
s.default_subspec = "nopush"

s.subspec 'nopush' do |ss|
Copy link
Contributor

Choose a reason for hiding this comment

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

Sweet, I am approving it as this isn't a blocker, feel free to update it to a more generic name now or later.

@levibostian levibostian changed the title build: include required messagingpush dependency fix: include required messagingpush dependency Aug 22, 2023
@levibostian levibostian changed the title fix: include required messagingpush dependency fix: include required messagingpush dependency for no push configuration Aug 22, 2023
@gerjunior-groundswell
Copy link

Hey guys!
Any updates on when this is going to be merged?

@levibostian levibostian merged commit 78bbc63 into main Aug 28, 2023
@levibostian levibostian deleted the levibostian-patch-1 branch August 28, 2023 17:07
github-actions bot pushed a commit that referenced this pull request Aug 28, 2023
### [3.1.8](3.1.7...3.1.8) (2023-08-28)

### Bug Fixes

* include required messagingpush dependency for no push configuration ([#187](#187)) ([78bbc63](78bbc63))
@levibostian
Copy link
Contributor Author

@gerjunior-groundswell, this has been deployed in 3.1.8. Thank you for your patience while we test the change before merging. Enjoy!

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.

5 participants