App
App copied to clipboard
[$500] :pencil2: icon is shown for archived chats - reported by @thesahindia
If you haven’t already, check out our contributing guidelines for onboarding and email [email protected] to request to join our Slack channel!
Action Performed:
- Create a workspace
- Navigate to the announce room for that workspace
- Type something in the composer
- Delete the workspace
Expected Result:
The draft should get cleared and :pencil2: icon shouldn't be shown
Actual Result:
You will see :pencil2: icon
Workaround:
unknown
Platform:
Where is this issue occurring?
- Web
- iOS
- Android
- Desktop App
- Mobile Web
Version Number: 1.1.75-0 Reproducible in staging?: Y Reproducible in production?: Y Email or phone of affected tester (no customers): Logs: https://stackoverflow.com/c/expensify/questions/4856 Notes/Photos/Videos: Any additional supporting documentation
https://user-images.githubusercontent.com/43995119/173274359-c5355328-7f33-4947-a58e-d8c87cee5a10.mov
Expensify/Expensify Issue URL: Issue reported by: @thesahindia Slack conversation: https://expensify.slack.com/archives/C01GTK53T8Q/p1652951524576589 Reported again here: https://expensify.slack.com/archives/C01GTK53T8Q/p1666204335556309
Triggered auto assignment to @sonialiap (AutoAssignerTriage), see https://stackoverflow.com/c/expensify/questions/4749 for more details.
Good one.
Triggered auto assignment to @srikarparsi (Engineering), see https://stackoverflow.com/c/expensify/questions/4319 for more details.
changed to weekly, need to use the new API refactoring doc instead of just changing the front end.
commented on N7 doc to include this change, on hold until it's finished
^^
^^
^^
^
^
^
^
^
^
Issue got fixed with the API refactor, closing it out.
@srikarparsi, it's still reproducible. It was just reported here cc: @adeel0202
interesting, thanks for the heads up, reopening
Proposal
- Reason why the pencil icon doesn't go away because we never add any validation to check if the room is archived or not
- Based on the status we can show/hide the pencil icon
- Here we need to add one more validation like below
https://github.com/Expensify/App/blob/0c5642ff79fa174bdefb8033625882be71792596/src/components/LHNOptionsList/OptionRowLHN.js#L197-L201
{optionItem.hasDraftComment && !optionItem.isArchivedRoom && (
<View style={styles.ml2}>
<Icon src={Expensicons.Pencil} height={16} width={16} />
</View>
)}
Result

Current Code

looks good, marking the issue as external and assigning you to the issue so you can get compensated.
Triggered auto assignment to @tjferriss (External), see https://stackoverflow.com/c/expensify/questions/8582 for more details.
Triggered auto assignment to Contributor-plus team member for initial proposal review - @parasharrajat (External)
Current assignee @srikarparsi is eligible for the External assigner, not assigning anyone new.
@parasharrajat, @dhairyasenjaliya's solution looks good to me.
This ticket was closed because the bug was supposed to be fixed. Yesterday, I encountered this bug and reported it on slack. Its ticket was also created but then it was closed because this one has been reopened. So I think along with @thesahindia, I'm eligible for the reporting bonus too. Thanks. cc: @srikarparsi @tjferriss
Generally, only one person is eligible for reporting. I am not sure how come two persons can contribute to the same bug report.
@parasharrajat had I not reported this bug, this ticket would still have been closed and the bug would still be there. Also, I'm sure you must've seen other similar cases where two persons were credited for the same bug. However, if others think I should not be compensated, I'm fine with it.
That's why I said Generally. if you are saying that last time this was fixed, then you should be eligible for new reporting only. my 2 :coin:
I believe @adeel0202 is eligible for the compensation in this case. Asking internally to get some eyes on it.
Thanks @thesahindia
I don't like the proposal.
Reason why the pencil icon doesn't go away because we never add any validation to check if the room is archived or not
The reason is simply that no one can add drafts to achieved chats. Adding validations/check for cases that are not possible in the business logic is just not the correct approach.
What will happen to the stored draft of that report?