rubyforgood / rubyforgood/human-essentials

Distribution emails -- on change, if you add items, they do not show up in the email, and if you *only* add items, no email is generated (i.e. if you don't change levels of existing items)

Open
#5,666 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Difficulty—Intermediate Ruby for Good 2026 DC
Dominant language
Ruby
Stars
593
Forks
593
Avg merge
4d 22h
Merged PRs (30d)
41

Description

Summary

The email sent out on distribution changes is not handling some changes correctly. Fix it.

Why?

Could be misleading

Details

To see the problems:

Using your local copy of the application:
sign in as org_Admin1@example.com
click on Distributions
choose an editable distribution (it's possible you may need to enter a new one) Note the partner for that distribution
Next, Confirm that that partner receives distribution notices:

  • click on Partner Agencies, then All Partners
  • Click on the partner name
  • Click on "Edit Partner Information"
  • Ensure that the "Do you want this partner to receive emails..." checkbox is checked, and then click "Update Partner".
    Go back to the distribution
    click Edit

Problem 1/
Change the level of one of the items, and add an item
Click Save

You will see that the email that comes out includes the updated item but not the added item.

The email should include a line detailing the added item.

Problem 2/
Same thing, but add an item without changing any items.

No email is sent. An email should be sent regarding the added item.

Criteria for completion

  • behaviour changes as detailed above
  • tests that confirm those behaviour changes
  • no user guide update is required

Please note:

  • there is a separate issue regarding the awkward wording of the text in the email

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Distributions edit and Save flow described in the issue, then trace how distribution-change emails are generated. Reproduce both cases locally using the listed partner and distribution steps, and locate the existing tests covering distribution notices. Done means added items appear in emails and adding items alone sends an email, with tests confirming both behaviors.

Written by the indexing model from the issue text.

Assessment

Tech stack
rails, ruby
Domain
backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.