Availability treats cancelled sessions as booked
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 74/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- next.js, postgresql, typescript
Research direction
Start at the GET /api/availability/[userId] handler and trace how it builds bookedTimes and subtracts sessions from available slots. Add a pure interval-overlap helper under src/lib, with tests for overlapping sessions and status filtering. Done means only requested and confirmed sessions block every slot they overlap, while cancelled sessions do not.
Written by the indexing model from the issue text.
Description
GET /api/availability/[userId] builds bookedTimes from every session for the mentor regardless of status, so a cancelled session keeps blocking its slot. It also matches exact start times only, so a session that doesn't start on a slot boundary doesn't block overlapping slots.
Fix. Filter to requested + confirmed; move the subtraction into a pure, tested interval-overlap helper in src/lib (also needed later for calendar free/busy, RFC-0012 Direction).
- Dominant language
- TypeScript
- Stars
- 3
- Forks
- 6
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 23
Getting set up
Starts the project's dev container in your browser, under your own GitHub account.
- Ships a Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from grasshopper-protocol/grsshppr
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
grasshopper-protocol/grsshppr#172 ·
Maintainers usually reply within 1 day
-
documentation
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
grasshopper-protocol/grsshppr#164 ·
Maintainers usually reply within 1 day
-
code quality security
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
grasshopper-protocol/grsshppr#141 ·
Maintainers usually reply within 1 day
-
Add tests for utils.ts cn() functionPossibly taken @yogesh201sits claimed this 5 days ago. Opengood first issue testing
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
grasshopper-protocol/grsshppr#81 · 1 comment · 1 assignee ·
Maintainers usually reply within 1 day
-
code quality documentation good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
grasshopper-protocol/grsshppr#78 ·
Maintainers usually reply within 1 day
All issues in grasshopper-protocol/grsshppr
Similar issues
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 73/100
ajv-validator/ajv#2689 ·
-
[Bug]: IME confirmation Enter can submit the SSH port-forward dialogPossibly taken @seijikohara claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
home-assistant/frontend#55323 ·
Maintainers usually reply within 1 day
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
Difficulty 1/5 Under an hour Newbie friendliness 72/100
lingdojo/kana-dojo#33188 · 1 comment · 5 reactions ·
Maintainers usually reply within 1 day
-
self-driving
Difficulty 1/5 1-3 hours Newbie friendliness 86/100
Maintainers usually reply within 1 day