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

Add paypal installation as private repo #467

Closed
wants to merge 7 commits into from

Conversation

HungNgien
Copy link
Contributor

@HungNgien HungNgien commented Nov 29, 2024

Summary by Sourcery

Add support for installing the eventyay-paypal dependency as a private repository using a GitHub token, and remove the pretix.plugins.paypal plugin from the settings.

New Features:

  • Introduce the ability to install the eventyay-paypal dependency as a private repository using a GitHub token.

Enhancements:

  • Remove the pretix.plugins.paypal plugin from the settings, indicating a shift to using the eventyay-paypal dependency.

Copy link

sourcery-ai bot commented Nov 29, 2024

Reviewer's Guide by Sourcery

This PR implements changes to replace the built-in PayPal plugin with a private eventyay-paypal dependency. The implementation involves modifying the dependency management system to handle GitHub tokens for private repository access and removing the existing PayPal plugin code.

Class diagram for dependency management changes

classDiagram
    class DependencyManager {
        +loadPyproject()
        +writePyproject()
        +updateDependencies(github_token)
    }

    class Pyproject {
        +dependencies: List<String>
    }

    DependencyManager --> Pyproject
    note for DependencyManager "Handles loading, updating, and writing pyproject.toml"
    note for Pyproject "Represents the pyproject.toml structure"
Loading

File-Level Changes

Change Details Files
Add GitHub token-based installation support for eventyay-paypal dependency
  • Add conditional logic to handle GitHub token presence
  • Update dependency string to include GitHub token in the repository URL
  • Add placeholder for eventyay-paypal dependency in project dependencies
src/set_github_token.py
pyproject.toml
Remove the built-in PayPal plugin
  • Remove PayPal plugin from installed apps
  • Delete all PayPal plugin source files including models, views, and templates
src/pretix/settings.py
src/pretix/plugins/paypal/apps.py
src/pretix/plugins/paypal/migrations/0001_initial.py
src/pretix/plugins/paypal/migrations/0002_initial.py
src/pretix/plugins/paypal/models.py
src/pretix/plugins/paypal/payment.py
src/pretix/plugins/paypal/signals.py
src/pretix/plugins/paypal/urls.py
src/pretix/plugins/paypal/views.py
src/pretix/plugins/paypal/templates/pretixplugins/paypal/action_double.html
src/pretix/plugins/paypal/templates/pretixplugins/paypal/action_overpaid.html
src/pretix/plugins/paypal/templates/pretixplugins/paypal/action_refund.html
src/pretix/plugins/paypal/templates/pretixplugins/paypal/checkout_payment_confirm.html
src/pretix/plugins/paypal/templates/pretixplugins/paypal/checkout_payment_form.html
src/pretix/plugins/paypal/templates/pretixplugins/paypal/control.html
src/pretix/plugins/paypal/templates/pretixplugins/paypal/pending.html
src/pretix/plugins/paypal/templates/pretixplugins/paypal/redirect.html

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time. You can also use
    this command to specify where the summary should be inserted.

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@HungNgien HungNgien marked this pull request as ready for review November 29, 2024 03:06
Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

Hey @HungNgien - I've reviewed your changes - here's some feedback:

Overall Comments:

  • Please remove the GitHub token placeholder from pyproject.toml to avoid potential security issues. Token handling should be done entirely through environment variables or configuration.
  • The PR would benefit from more detailed documentation explaining the rationale for replacing the built-in PayPal plugin with the private repository version, along with any necessary migration steps for existing users.
Here's what I looked at during the review
  • 🟢 General issues: all looks good
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

lcduong and others added 3 commits December 4, 2024 11:37
* Standardize menu items

* update label for my event in common

* remove duplicated translate messages
Updates the requirements on [stripe](https://github.com/stripe/stripe-python) to permit the latest version.
- [Release notes](https://github.com/stripe/stripe-python/releases)
- [Changelog](https://github.com/stripe/stripe-python/blob/master/CHANGELOG.md)
- [Commits](stripe/stripe-python@v5.4.0b1...v11.3.0)

---
updated-dependencies:
- dependency-name: stripe
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
@HungNgien HungNgien closed this Dec 4, 2024
@HungNgien HungNgien deleted the eventyay-paypal branch December 4, 2024 04:52
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.

2 participants