Skip to content

Add PayPal Payments package - skeleton code only #43315

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

Merged
merged 9 commits into from
May 8, 2025

Conversation

allie500
Copy link
Contributor

Proposed changes:

  • This PR adds the skeleton code for the Simple Payments package. This is a bare bones PR to make sure I've got the basics set correctly for the package.

Other information:

  • Have you written new tests for your changes, if applicable?
  • Have you checked the E2E test CI results, and verified that your changes do not break them?
  • Have you tested your changes on WordPress.com, if applicable (if so, you'll see a generated comment below with a script to run)?

Jetpack product discussion

No discussions with Jetpack Product at this time. Discussions have been with Jetpack Engineering in regards to a similar project. Additional details can be found in this project thread update: pcqRLn-2xw-p2#comment-3584

Does this pull request change what data or activity we track or use?

No.

Testing instructions:

  • Please review the package files that were generated using the jetpack generate command.
  • Below you will find the command and output from generating the package.
jetpack generate package --name simple-payments

✔ Succinctly describe your project: · Add PayPal, credit, and debit card payment buttons with minimal setup. Good for collecting donations or payments for products and services.
✔ Select production and/or development build steps to generate: · production, development
✔ Do you plan to use WordPress core functions in your PHPUnit tests? (y/N) · false
✔ Does this project need to be deployed publicly? (Create a mirror repo?) (Y/n) · true
✔ What is your GitHub Personal Token? · ****************************************
GET /repos/Automattic/jetpack-simple-payments - 404 with id 4E28:2C0120:130E999:25FCEFB:681266F3 in 309ms
✔ Configure mirror repo to create new tags automatically (based on CHANGELOG.md)? (Y/n) · true
Project created successfully! Happy coding!
  • Let me know if any changes need to be made before I move in the existing code.

@allie500 allie500 added the [Status] Needs Review This PR is ready for review. label Apr 30, 2025
@allie500 allie500 self-assigned this Apr 30, 2025
@allie500 allie500 requested a review from jeherve April 30, 2025 18:25
Copy link
Contributor

github-actions bot commented Apr 30, 2025

Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.

  • To test on WoA, go to the Plugins menu on a WoA dev site. Click on the "Upload" button and follow the upgrade flow to be able to upload, install, and activate the Jetpack Beta plugin. Once the plugin is active, go to Jetpack > Jetpack Beta, select your plugin (Jetpack or WordPress.com Site Helper), and enable the add/simple-payments-pkg branch.
  • To test on Simple, run the following command on your sandbox:
bin/jetpack-downloader test jetpack add/simple-payments-pkg
bin/jetpack-downloader test jetpack-mu-wpcom-plugin add/simple-payments-pkg

Interested in more tips and information?

  • In your local development environment, use the jetpack rsync command to sync your changes to a WoA dev blog.
  • Read more about our development workflow here: PCYsg-eg0-p2
  • Figure out when your changes will be shipped to customers here: PCYsg-eg5-p2

Copy link
Contributor

github-actions bot commented Apr 30, 2025

Thank you for your PR!

When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:

  • ✅ Include a description of your PR changes.
  • ✅ Add a "[Status]" label (In Progress, Needs Review, ...).
  • ✅ Add a "[Type]" label (Bug, Enhancement, Janitorial, Task).
  • ✅ Add testing instructions.
  • ✅ Specify whether this PR includes any changes to data or privacy.
  • ✅ Add changelog entries to affected projects

This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖


Follow this PR Review Process:

  1. Ensure all required checks appearing at the bottom of this PR are passing.
  2. Make sure to test your changes on all platforms that it applies to. You're responsible for the quality of the code you ship.
  3. You can use GitHub's Reviewers functionality to request a review.
  4. When it's reviewed and merged, you will be pinged in Slack to deploy the changes to WordPress.com simple once the build is done.

If you have questions about anything, reach out in #jetpack-developers for guidance!

@github-actions github-actions bot added [Status] Needs Author Reply We need more details from you. This label will be auto-added until the PR meets all requirements. and removed [Status] Needs Review This PR is ready for review. labels Apr 30, 2025
Copy link

jp-launch-control bot commented Apr 30, 2025

Code Coverage Summary

1 file is newly checked for coverage.

File Coverage
projects/packages/paypal-payments/src/class-paypal-payments.php 0/0 (—%) 🤷

Full summary · PHP report · JS report

Copy link
Member

@jeherve jeherve left a comment

Choose a reason for hiding this comment

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

I think this may be an opportunity to move away from the "simple payments" name, and have a package that really tells what this is about, i.e. PayPal. What do you think?

@jeherve jeherve added [Type] Enhancement Changes to an existing feature — removing, adding, or changing parts of it [Block] Pay With Paypal aka Simple Payments [Feature] Pay with PayPal aka Simple Payments [Status] In Progress and removed [Status] Needs Author Reply We need more details from you. This label will be auto-added until the PR meets all requirements. labels May 2, 2025
@allie500
Copy link
Contributor Author

allie500 commented May 2, 2025

I think this may be an opportunity to move away from the "simple payments" name, and have a package that really tells what this is about, i.e. PayPal. What do you think?

Thanks for taking a look at this PR! I agree that this is a good opportunity to move away from "Simple Payments". "PayPal" could work but I think it also may be a bit too vague.

Other possible names:

  • PayPal Payments
  • PayPal Payments Block

Of those three which one do you like best? I could also bring this question to the project update today to get some wider input. If you have any other name suggestions, please let me know.

Lastly, what did you think of the options I selected when I walked through the interactive generate command? Did I make the correct choices or should I delete and re-run with different selections (other than the name)?

jetpack generate package --name simple-payments

✔ Succinctly describe your project: · Add PayPal, credit, and debit card payment buttons with minimal setup. Good for collecting donations or payments for products and services.
✔ Select production and/or development build steps to generate: · production, development
✔ Do you plan to use WordPress core functions in your PHPUnit tests? (y/N) · false
✔ Does this project need to be deployed publicly? (Create a mirror repo?) (Y/n) · true
✔ What is your GitHub Personal Token? · ****************************************
GET /repos/Automattic/jetpack-simple-payments - 404 with id 4E28:2C0120:130E999:25FCEFB:681266F3 in 309ms
✔ Configure mirror repo to create new tags automatically (based on CHANGELOG.md)? (Y/n) · true
Project created successfully! Happy coding!

@jeherve
Copy link
Member

jeherve commented May 2, 2025

I like PayPal Payments. 👍

what did you think of the options I selected when I walked through the interactive generate command?

This should work.

Did I make the correct choices or should I delete and re-run with different selections (other than the name)?

We'll need to make sure the tests pass, or we won't be able to merge. I believe that means you'll need to add a simple test in the package so it's not empty.

@allie500
Copy link
Contributor Author

allie500 commented May 2, 2025

I like PayPal Payments. 👍

Sounds good. I like it as well. I'll suggest it as our preferred name in the project update thread and give the stakeholders an opportunity to provide feedback on the name.

what did you think of the options I selected when I walked through the interactive generate command?

This should work.

Thanks for checking!

Did I make the correct choices or should I delete and re-run with different selections (other than the name)?

We'll need to make sure the tests pass, or we won't be able to merge. I believe that means you'll need to add a simple test in the package so it's not empty.

Yep, that was my next step. I can work on adding a simple test for the package.

@allie500 allie500 changed the title Add Simple Payments package - skeleton code only Add PayPal Payments package - skeleton code only May 2, 2025
@allie500
Copy link
Contributor Author

allie500 commented May 7, 2025

@jeherve I've added a test and made some minor changes to get a green check on CI. Can you review it once more?

@allie500 allie500 requested a review from jeherve May 7, 2025 19:06
@jeherve jeherve added [Status] Ready to Merge Go ahead, you can push that green button! and removed [Status] In Progress labels May 7, 2025
@allie500 allie500 merged commit bab55cc into trunk May 8, 2025
86 checks passed
@allie500 allie500 deleted the add/simple-payments-pkg branch May 8, 2025 12:50
@github-actions github-actions bot removed the [Status] Ready to Merge Go ahead, you can push that green button! label May 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Pay With Paypal aka Simple Payments Docs [Feature] Pay with PayPal aka Simple Payments [Package] Pay With Paypal [Package] Paypal Payments [Tests] Includes Tests [Type] Enhancement Changes to an existing feature — removing, adding, or changing parts of it
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants