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
Feature/daily not weekly #80
Merged
paulproteus
merged 7 commits into
openhatch:master
from
becdot:feature/daily-not-weekly
Oct 26, 2012
Merged
Feature/daily not weekly #80
paulproteus
merged 7 commits into
openhatch:master
from
becdot:feature/daily-not-weekly
Oct 26, 2012
Conversation
This file contains 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
Renames weekly_email__list_of_people.html and weekly_email_re_projects.html to email__list_of_people.html and email_re_projects.html, respectively
send_weekly_emails -> send_emails email_me_weekly_re_projects -> email_me_re_projects get_context__for_weekly_email_to -> get_context_for_email_to 'weekly' (in comments) -> 'periodically' test_weekly_email_re_projects -> test_email_re_projects
Updates profile/tests.py to test that emails are sent within the correct timeframe (i.e. 24 hours) Renames send_weekly_emails.py to send_emails.py Updates send_emails.py to send emails every 24 hours; also renames a few relevant variable names.
Adds back old email_me_weekly_re_projects column in models.py (so that data doesn't get deleted in migration!) Adds new email_me_re_projects column in models.py Minor wording change in tests.py
Adds three migrations: - 0093 to add a new email_me_re_projects column - 0094 to set user email_me_weekly_re_projects == email_me_re_projects - 0095 to delete old email_me_weekly_re_projects column Updates profile/models.py accordingly
Renames email_me_weekly_re_projects -> email_me_re_projects variables in static files (snapshot1.json, snapshot2.json, front-page-demo.html) Deletes old weekly email files (that have been replaced by email__list_of_people.html, email_re_projects.html, send_emails.py) Removes the word 'weekly' in a models.py comment and replaces it with 'periodically'
Update 0095 migration to only call person.save() if person.email_me_weekly_re_projects is different than person.email_me_re_projects Fix spacing issue in profile/models.py
Thanks for all these changes! As discussed on IRC, this changeset as a whole does the job, and does it very well. Things you've improved since the start:
And the tests all pass. Herculean effort, especially for your first patch! Thank you! Find someone near you and ask them to give you a high five! |
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.
Changes the weekly user emails to daily emails.
This patch touches a lot of files because a large number of variable and function names need to be changed (e.g. from email_me_weekly_re_projects to email_me_re_projects). I also updated the tests to reflect the changed timeframe (i.e. making sure that emails get sent every 24 hours instead of every 7 days) and completed three South migrations to add a new column, switch over the data, and then delete the old column.
All tests pass, and everything looked good to me on the local version of the website.
Please let me know whether any other changes need to be made.
Thanks!
Becca