feat: Add shared household budgeting support (Issue #134)#299
Open
ShawTim wants to merge 1 commit intorohitdash08:mainfrom
Open
feat: Add shared household budgeting support (Issue #134)#299ShawTim wants to merge 1 commit intorohitdash08:mainfrom
ShawTim wants to merge 1 commit intorohitdash08:mainfrom
Conversation
There was a problem hiding this comment.
Pull request overview
Implements shared household budgeting by adding household-related API routes and initial tests/docs for creating households and inviting members.
Changes:
- Added
householdsAPI blueprint with create/get/invite/my endpoints. - Added initial pytest coverage for household flows.
- Updated README with household feature documentation and endpoint examples.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 13 comments.
| File | Description |
|---|---|
| packages/backend/app/routes/households.py | Adds household CRUD-ish endpoints and membership/invite flow |
| packages/backend/app/routes/init.py | Registers the new households blueprint |
| packages/backend/tests/test_households.py | Adds tests intended to cover household creation / invite / listing |
| README.md | Documents the new household feature and API endpoints |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Add Household and HouseholdMember models with role-based access - Add household_id column to expenses, categories, bills - Implement API routes: create household, invite member, list members - Add unit tests for models and membership linking - Update README with shared household documentation and API usage - Fix Copilot review comments: imports, exception safety, docs formatting - Resolves rohitdash08#134
0773432 to
226c993
Compare
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.
🎯 Summary
This PR implements Shared Household Budgeting, allowing multiple users to collaborate on household finances. It enables creating households, inviting members, and sharing expenses/bills/categories across users within a household.
🚀 Changes
1. Database Models (
app/models.py)Householdmodel to represent a financial group.HouseholdMemberjoin table with role-based access (admin/member).Expense,Category, andBillmodels to include optionalhousehold_idfor shared data.household_idis nullable).2. API Routes (
app/routes/households.py)POST /api/households: Create a new household (creator becomes admin).GET /api/households/my: Get the current user's household.GET /api/households/<id>: Get household details and members.POST /api/households/<id>/members: Invite a user by email (Admin only).3. Tests (
tests/test_households.py)HouseholdandHouseholdMembermodel creation.4. Documentation (
README.md)✅ Acceptance Criteria
🧪 Testing
pytest packages/backend/tests/test_households.py -v🔗 Related Issue
Closes #134