fix: repair broken call-to-action link on Volunteer page (#2983)#3058
Open
hanu-14 wants to merge 1 commit into
Open
fix: repair broken call-to-action link on Volunteer page (#2983)#3058hanu-14 wants to merge 1 commit into
hanu-14 wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
Pull request overview
This PR fixes issue #2983 by removing an outdated call-to-action on the PSF Volunteer page that points to a non-existent psf-volunteers Mailman 2.1 list, updating the site’s CMS page content via a data migration.
Changes:
- Adds a Django data migration to locate the
psf/volunteerCMSPagerecord. - Removes the section of the page content referencing
psf-volunteersand its “Sign up” CTA.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+11
to
+35
| content = page.content | ||
| if "psf-volunteers" not in content: | ||
| return | ||
|
|
||
| # Remove the broken CTA section about the psf-volunteers mailing list, | ||
| # which was archived during the Mailman 2.1 -> Mailman 3 migration in | ||
| # May 2025 and no longer exists. | ||
| lines = content.split("\n") | ||
| new_lines = [] | ||
| drop = False | ||
| for line in lines: | ||
| if "psf-volunteers" in line: | ||
| drop = True | ||
| if not drop: | ||
| new_lines.append(line) | ||
| elif "Sign up" in line or "sign up" in line: | ||
| continue | ||
| elif line.strip() == "": | ||
| drop = False | ||
| new_lines.append(line) | ||
|
|
||
| new_content = "\n".join(new_lines).strip() | ||
| if new_content != content: | ||
| page.content = new_content | ||
| page.save() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #2983
Removes the broken psf-volunteers mailing list call-to-action
from the Volunteer page, as this list was archived during the
Mailman 2.1 to Mailman 3 migration in May 2025 and no longer
exists.