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

Update the BulkEmailFlag __str__ function to avoid infinite recursion #33901

Merged

Conversation

Anas12091101
Copy link
Contributor

@Anas12091101 Anas12091101 commented Dec 8, 2023

Description

This PR changes the str method of BulkEmailFlag to avoid the infinite recursion to occur due to a Network Request via BulkEmailFlag.current() method. For more information see the relevant Github Issue in the Supporting Information.

Supporting information

Github Issue: #32300

Testing instructions

  • Create an LMS shell and write the following code:
    >>> from lms.djangoapps.bulk_email.models import BulkEmailFlag
    >>> b = BulkEmailFlag.objects.create()
    >>> str(b)
  • You will get this output without any errors
    'BulkEmailFlag: enabled False, require_course_email_auth: True'

@openedx-webhooks openedx-webhooks added the open-source-contribution PR author is not from Axim or 2U label Dec 8, 2023
@openedx-webhooks
Copy link

openedx-webhooks commented Dec 8, 2023

Thanks for the pull request, @Anas12091101! Please note that it may take us up to several weeks or months to complete a review and merge your PR.

Feel free to add as much of the following information to the ticket as you can:

  • supporting documentation
  • Open edX discussion forum threads
  • timeline information ("this must be merged by XX date", and why that is)
  • partner information ("this is a course on edx.org")
  • any other information that can help Product understand the context for the PR

All technical communication about the code itself will be done via the GitHub pull request interface. As a reminder, our process documentation is here.

Please let us know once your PR is ready for our review and all tests are green.

@mphilbrick211 mphilbrick211 added the needs test run Author's first PR to this repository, awaiting test authorization from Axim label Dec 8, 2023
@mphilbrick211
Copy link

Hi @Anas12091101! Thank you for this contribution! Please let me know if you have any questions regarding submitting a CLA form.

@e0d
Copy link
Contributor

e0d commented Dec 14, 2023

@Anas12091101 I notice there are some commit-lint failures. Please note that we use conventional commits across Open edX projects. You can read about the details here. Can you please amend your commit messages to follow our standard?

@e0d e0d removed the needs test run Author's first PR to this repository, awaiting test authorization from Axim label Dec 14, 2023
@mphilbrick211
Copy link

HI @Anas12091101! I'm just following up to see if you plan to pursue this pull request?

@pdpinch
Copy link
Contributor

pdpinch commented Feb 13, 2024

@Anas12091101 can you fix the commit messages on this?

@Anas12091101
Copy link
Contributor Author

@Anas12091101 can you fix the commit messages on this?

@pdpinch thanks for reminding. I will update the commit messages today.

@Anas12091101
Copy link
Contributor Author

@Anas12091101 I notice there are some commit-lint failures. Please note that we use conventional commits across Open edX projects. You can read about the details here. Can you please amend your commit messages to follow our standard?

Hi @e0d, sorry I missed your comment. Will update the commit messages today

@Anas12091101 Anas12091101 force-pushed the update-BulkEmailFlag-str-method branch from 4c07b3f to 57f914a Compare February 15, 2024 16:09
@pdpinch
Copy link
Contributor

pdpinch commented Mar 4, 2024

@Anas12091101 there was a failed test, but it didn't seem related to your change. I re-ran it.

@pdpinch
Copy link
Contributor

pdpinch commented Mar 4, 2024

Oh, and you need to rebase.

@Anas12091101 Anas12091101 force-pushed the update-BulkEmailFlag-str-method branch from 57f914a to 91cef23 Compare March 4, 2024 17:14
@pdpinch
Copy link
Contributor

pdpinch commented Mar 5, 2024

Sorry @Anas12091101 it looks like it needs another rebase.

@Anas12091101 Anas12091101 force-pushed the update-BulkEmailFlag-str-method branch from 91cef23 to 1e760a7 Compare March 5, 2024 06:41
@Anas12091101
Copy link
Contributor Author

Sorry @Anas12091101 it looks like it needs another rebase.

Done

@pdpinch pdpinch self-assigned this Mar 18, 2024
@pdpinch pdpinch merged commit 09a8cfc into openedx:master Mar 21, 2024
47 checks passed
@openedx-webhooks
Copy link

@Anas12091101 🎉 Your pull request was merged! Please take a moment to answer a two question survey so we can improve your experience in the future.

@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX staging environment in preparation for a release to production.

@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX production environment.

1 similar comment
@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX production environment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
open-source-contribution PR author is not from Axim or 2U
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

6 participants