Comment Filters - Unable to View Results
- Dominant language
- Python
- Stars
- 8
- Forks
- 2
- Avg merge
- 14h 34m
- Merged PRs (30d)
- 46
Description
**Describe the bug in current situation**
Filtered comments on a request are not consistently shown and hidden with each subsequent click of a comment filter. A user should be able to flip between the comments showing, and being hidden, each time they select the same comment filter.
When a user is on the 'Comments' tab, if they click a comment filter once, it shows the comments that correspond to that filter. If users click that same comment filter a second time, the filtered comments disappear. If a user clicks the same comment filter a third time (and beyond), nothing happens, and they still aren't able to view the filtered comments.
This applies to any record with comments, in every environment.
**Link bug to the User Story**
#2433
**Impact of this bug**
Impacts all users, but low impact when it occurs, as it can be resolved by clicking another comment filter, and then clicking back on the original filter.
**Chance of Occurring (high/medium/low/very low)**
Low
**Pre Conditions: which Env, any pre-requesites or assumptions to execute steps?**
Test environment
Request # EDU-2023-12666
**Steps to Reproduce**
Steps to reproduce the behavior:
1. Go to any EDU-2023-12666 as a Ministry or IAO user
2. Click on the 'Comments' tab
3. Click on the 'Request History Comments' filter
4. All filtered comments will show
5. Click the 'Request History Comments' filter a second time
6. All filtered results will disappear
7. Click the 'Request History Comments' filter a third time
8. Nothing happens, and the filtered results continue to not be displayed
9. Perform steps 1 - 7 for 'User Comments', 'Divisional Tracking', and 'All' comment filters, and step 8 will occur.
**Actual/ observed behaviour/ results**
Filtered comments are not able to to be shown and hidden in perpetuity by clicking the same comment filter.
**Expected behaviour**
A clear and concise description of what you expected to happen. Use the gherking language.
* GIVEN an IAO or Ministry User is on the 'Comments' tab of a request
* AND there are comments on the request
* When a user clicks the same comment filter multiple times
* Then the comment filter should alternate between showing and hiding the filter comment results
**Screenshots/ Visual Reference/ Source**
Filtered Results Shown

Comment Filter Clicked a Second Time (Results are Hidden)

Comment Filter Clicked a Third Time (Comments Do Not Reappear)

Contributor guide
Research direction
No source files, tests, or entry points are named. Start by reproducing the issue on a request's Comments tab with each filter, then locate the comment-filter implementation and its existing tests; done means repeatedly selecting the same filter alternates between showing and hiding its results.
Written by the indexing model from the issue text.
Assessment
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100