feat(core): implement services for issue #8 #26
Reference in New Issue
Block a user
Delete Branch "fix/issue-8"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Implement pure business logic services in
core/services.py.Services
BountyService
Handles bounty operations in a room (group or DM via room_id):
add_bounty()- Add new bounty to roomlist_bounties()- List all bounties in roomget_bounty()- Get specific bounty by IDupdate_bounty()- Update bounty (creator only, raises PermissionError)delete_bounty()- Delete bounty (creator only, raises PermissionError)TrackingService
Handles tracking bounty operations:
track_bounty()- Start tracking (raises ValueError if bounty not found)untrack_bounty()- Stop trackingget_tracked_bounties()- Get all tracked bounties by user in roomKey Design
Fixes #8
lgtm
don't we need unit tests for this services? in a way to make sure that everything we defined in this service are working as expected even if with faulty input
lgtm