You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Due for payment 2026-08-25] [$250] [Exploratory] Chat-In text plus attachment chat , edit comment option is not shown. #94878
Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.ExternalAdded to denote the issue can be worked on by a contributorNot a priorityWeeklyKSv2
📣 @teasikon15-afk! 📣
Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork.
Please follow these steps:
Get the email address used to login to your Expensify account. If you don't already have an Expensify account, create one here. If you have multiple accounts (e.g. one for testing), please use your main account email.
Get the link to your Upwork profile. It's necessary because we only pay via Upwork. You can access it by logging in, and then clicking on your name. It'll look like this. If you don't already have an account, sign up for one here.
Copy the format below and paste it in a comment on this issue. Replace the placeholder text with your actual details.
Format:
Contributor details
Your Expensify account email: <REPLACE EMAIL HERE>
Upwork Profile Link: <REPLACE LINK HERE>
ℹ️ Medium confidence — the gate and mechanism below are verified against the code; the exact trigger (see the note at the end) should be confirmed with a repro on the current build.
What is the root cause of that problem?
Whether the Edit comment option appears is decided entirely by canEditReportAction (the editAction entry's shouldShow at ContextMenuActions.tsx:605-609).
That function blocks editing whenever a message is an "optimistic attachment" (ReportUtils.ts:5357):
A text-plus-attachment message is built with isAttachmentWithText: true and isOptimisticAction: true (ReportUtils.ts:6597-6598). So while its optimistic upload is in flight — or any time that optimistic flag isn't cleared for the action — isOptimisticAttachment is true and Edit is hidden, even though the message contains freely-editable text. Including isAttachmentWithText in this block is the flaw: the text portion is always editable, so a text+attachment message should never be treated as un-editable the way a pure attachment is.
What changes do you think we should make in order to solve the problem?
Remove isAttachmentWithText from the block condition in canEditReportAction (ReportUtils.ts:5357). Only a pure attachment (isAttachmentOnly) should be blocked while it is still optimistic/uploading. A message that has text should always offer Edit — matching the issue's Expected Result ("In text plus attachment chat, edit comment option must be shown").
What alternative solutions did you explore? (Optional)
If the trigger turns out to be a lingering optimistic flag rather than the upload window (i.e. isOptimisticAction isn't being reset to null on the synced text+attachment action), the alternative is to ensure the success/refresh path clears it — the AddComment success handler already does this at Report/index.ts:1058, so the ADD_TEXT_AND_ATTACHMENT path would need the same guarantee. The primary fix above is still recommended because it makes Edit correct regardless of the optimistic state.
Investigation details & open question
Long-pressing anywhere on the combined bubble (text or image) fires the same CONTEXT_MENU_TYPES.REPORT_ACTION menu (ShowContextMenuContext/index.tsx), so this is not an "image vs. text portion" issue — there is a single gate: canEditReportAction.
Text+attachment is sent as one action via ADD_TEXT_AND_ATTACHMENT (Report/index.ts:914-920).
Open question / what to verify: the current guard is keyed on isOptimisticAction, so a fully-synced message should already be editable. The repro on V9.4.22-2 (staging + production) suggests the block is being hit either during the upload window or because the optimistic flag persists for this action. Worth confirming on the latest build whether Edit is missing only briefly (upload window) or permanently (lingering flag) — that determines whether the primary fix alone is sufficient.
Next Steps for Contributor+ team: To accept:@MelvinBot implement [this](https://github.com/Expensify/App/issues/94878) to create a draft PR. To refine:@MelvinBot <your feedback> To reject: Explain why you are rejecting Melvin's proposal.
I'm working with Claude to build a rubric for analyzing regressions. The current framework is
Not a regression from the linked PR
Bug was already on production. The PR exposed it, didn't create it. Test: build from the commit before the merge and repro. Precedent: 99143 on 98809, paid in full.
The original issue never asked for the behavior. Test: if the new work is never done, is the original issue still correctly closed? Yes = followup, and the new issue carries its own price. Precedent: 96390 / 98488. Covers scope creep.
The PR delivered what was specified and the spec was wrong. Behavior matches the issue body or design, we changed our mind after the merge. New work, full price.
The behavior was known and accepted before the merge. Precedent: 99155 on 98809. The comment has to exist from that time, not first appear when payment is disputed.
A different PR caused it, or the interaction of two did. Claimant names the other PR. "Something else may have done it" isn't a reason.
The regression window closed. Merge to 168 hours after production. After that it's an ordinary bug and pays like any issue.
A regression, but this payee isn't liable
They didn't write or review the offending PR. Anyone else assigned to fix it earns the job price.
The assigned internal engineer waived the C+ penalty for a large PR introducing new functionality. Already in the C+ doc, only the employee grants it.
and Claude's response from reviewing this issue was
$125 each to mukhrr and brunovjk. One confirmed regression, 50%. Separately, 98692 should be $0 with Skip Payment.
Running the framework against 98692:
Already on production - fails. Melvin verified getUploadingAttachmentHtmlFromComment and the editReportComment optimistic-HTML build did not exist before 97935. The fault is in code that PR added.
Original issue never asked for it - fails. 94878 asked for Edit comment to work on text plus attachment. An edit that destroys the attachment does not close it correctly. Regression under the test.
Spec was wrong / known and accepted before the merge - no comment exists from that time.
A different PR - no. Melvin named 97935 at high confidence and recommended a revert.
Window closed - no. Blocker filed 2026-08-14, the same day 97935 merged.
Payee not liable - fails for both. mukhrr authored 97935, brunovjk approved it. Melvin assigned both on that basis.
C+ waiver - the only route open, and it is weak. 97935 is 212 additions across 5 files, but it is a bug fix, not new functionality. Only youssef-lr can grant it, and he also approved the PR.
brunovjk's staging argument you already answered. His second half, that the original bug hid this in production, is also not a defence: the video path had no round-trip test in 97935, which is exactly what review should have caught.
cc @youssef-lr in case you find it helpful (if not and/or you have any feedback, let me know here or in NewDot
@MelvinBot will you review the above as a sanity check? I have a Claude project for contributor improvements and am want to continually sanity check it while building out the process
The conclusion holds — $125 each to mukhrr and brunovjk, and $0 on #98692. Every factual claim in Claude's analysis checked out against the PRs, the diff, and CONTRIBUTING.md. Five things to add.
1. Claude found one regression; there were three candidates. PR #97935 was also named as the offending PR on #98696 and #98743. Both are correctly excluded — 98696 was demoted after mukhrr and Beamanator agreed the underlying bug repros on production, and 98743 reports "Reproducible in production?: Yes" and is now a Monthly / Not a priority follow-up. So the count of one stands. But the analysis should have surfaced and cleared them, not omitted them: the policy applies the penalty "for each regression on an issue," so a missed second regression is the difference between $125 and $0.
2. The $0 on 98692 is right, but it doesn't come from your rubric. It comes from contributingGuides/CONTRIBUTING.md:75 — "work to fix regressions caused by the PR is unpaid by default." Your framework has no rule for how the fix issue pays, and no rule for penalties stacking across multiple regressions. Both are worth adding.
3. The C+ waiver only covers the C+. Even if youssef-lr granted it, it touches brunovjk only — mukhrr stays at $125 as the Contributor. Claude framed it as the one route open for both.
4. The Payment Summary role labels are wrong. It lists both as "Reviewer." mukhrr is the Contributor — they wrote the accepted proposal and authored #97935. Same $250 base either way, but your checklist item is "confirm assignees, roles."
5. No Payment Summary was ever generated on 98692, so there is nothing to actively skip — just don't create one.
"Already on production" test fails:getUploadingAttachmentHtmlFromComment and replaceLocalAttachmentReferences are added lines in the 97935 diff — they did not exist before it. The fault is in code that PR introduced.
Window open: 98692 was filed 2026-08-14T21:27:25Z, the same day 97935 merged. CONTRIBUTING.md:74 starts the window at merge, which also settles the staging-only argument the way you already answered it.
Timing: 98702 hit production 2026-08-18, so the 7-day post-fix payment date of 2026-08-25 was correct and payment is now overdue.
On the rubric itself: the structure is good — it's falsifiable, each branch has a test, and the precedents give it teeth. Two gaps beyond the ones above. First, add an explicit "enumerate every issue naming this PR as the offending PR" step before running the branches, or the framework silently assumes the regression count it was handed. Second, the "already on production" branch was the one that did real work here (it cleared two of three candidates), and in both cases the evidence was a human's repro, not the "build from the commit before the merge" test as written. Worth broadening that test to accept a QA "reproducible in production: yes" or a documented repro from someone on the issue.
Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.ExternalAdded to denote the issue can be worked on by a contributorNot a priorityWeeklyKSv2
Activity
applause-bot commentedon Jun 29, 2026
While Applause doesn't embed attachments for this bug, here are the links for quick view:
https://platform.applause.com/services/links/v1/external/4b1b346000aa55a008ffd3b0c49fd4f0dde1320ed951383c296c11a5cde4f2a3
melvin-bot commentedon Jul 6, 2026
📣 @teasikon15-afk! 📣
Hey, it seems we don’t have your contributor details yet! You'll only have to do this once, and this is how we'll hire you on Upwork.
Please follow these steps:
Format:
melvin-bot commentedon Jul 9, 2026
Whoops! This issue is 2 days overdue. Let's get this updated quick!
melvin-bot commentedon Jul 9, 2026
Whoops! This issue is 2 days overdue. Let's get this updated quick!
melvin-bot commentedon Jul 13, 2026
6 days overdue. This is scarier than being forced to listen to Vogon poetry!
melvin-bot commentedon Jul 15, 2026
8 days overdue is a lot. Should this be a Weekly issue? If so, feel free to change it!
MelvinBot commentedon Jul 17, 2026
Proposal
What is the root cause of that problem?
Whether the Edit comment option appears is decided entirely by
canEditReportAction(theeditActionentry'sshouldShowatContextMenuActions.tsx:605-609).That function blocks editing whenever a message is an "optimistic attachment" (
ReportUtils.ts:5357):A text-plus-attachment message is built with
isAttachmentWithText: trueandisOptimisticAction: true(ReportUtils.ts:6597-6598). So while its optimistic upload is in flight — or any time that optimistic flag isn't cleared for the action —isOptimisticAttachmentistrueand Edit is hidden, even though the message contains freely-editable text. IncludingisAttachmentWithTextin this block is the flaw: the text portion is always editable, so a text+attachment message should never be treated as un-editable the way a pure attachment is.What changes do you think we should make in order to solve the problem?
Remove
isAttachmentWithTextfrom the block condition incanEditReportAction(ReportUtils.ts:5357). Only a pure attachment (isAttachmentOnly) should be blocked while it is still optimistic/uploading. A message that has text should always offer Edit — matching the issue's Expected Result ("In text plus attachment chat, edit comment option must be shown").What alternative solutions did you explore? (Optional)
If the trigger turns out to be a lingering optimistic flag rather than the upload window (i.e.
isOptimisticActionisn't being reset tonullon the synced text+attachment action), the alternative is to ensure the success/refresh path clears it — theAddCommentsuccess handler already does this atReport/index.ts:1058, so theADD_TEXT_AND_ATTACHMENTpath would need the same guarantee. The primary fix above is still recommended because it makes Edit correct regardless of the optimistic state.Investigation details & open question
CONTEXT_MENU_TYPES.REPORT_ACTIONmenu (ShowContextMenuContext/index.tsx), so this is not an "image vs. text portion" issue — there is a single gate:canEditReportAction.ADD_TEXT_AND_ATTACHMENT(Report/index.ts:914-920).isOptimisticAction, so a fully-synced message should already be editable. The repro on V9.4.22-2 (staging + production) suggests the block is being hit either during the upload window or because the optimistic flag persists for this action. Worth confirming on the latest build whether Edit is missing only briefly (upload window) or permanently (lingering flag) — that determines whether the primary fix alone is sufficient.Possibly related
Next Steps for Contributor+ team:
To accept:
@MelvinBot implement [this](https://github.com/Expensify/App/issues/94878)to create a draft PR.To refine:
@MelvinBot <your feedback>To reject: Explain why you are rejecting Melvin's proposal.
68 remaining items
mallenexpensify commentedon Sep 2, 2026
I'm working with Claude to build a rubric for analyzing regressions. The current framework is
and Claude's response from reviewing this issue was
cc @youssef-lr in case you find it helpful (if not and/or you have any feedback, let me know here or in NewDot
mallenexpensify commentedon Sep 2, 2026
@MelvinBot will you review the above as a sanity check? I have a Claude project for contributor improvements and am want to continually sanity check it while building out the process
MelvinBot commentedon Sep 2, 2026
The conclusion holds — $125 each to
mukhrrandbrunovjk, and $0 on #98692. Every factual claim in Claude's analysis checked out against the PRs, the diff, and CONTRIBUTING.md. Five things to add.1. Claude found one regression; there were three candidates. PR #97935 was also named as the offending PR on #98696 and #98743. Both are correctly excluded — 98696 was demoted after
mukhrrandBeamanatoragreed the underlying bug repros on production, and 98743 reports "Reproducible in production?: Yes" and is now aMonthly/Not a priorityfollow-up. So the count of one stands. But the analysis should have surfaced and cleared them, not omitted them: the policy applies the penalty "for each regression on an issue," so a missed second regression is the difference between $125 and $0.2. The $0 on 98692 is right, but it doesn't come from your rubric. It comes from
contributingGuides/CONTRIBUTING.md:75— "work to fix regressions caused by the PR is unpaid by default." Your framework has no rule for how the fix issue pays, and no rule for penalties stacking across multiple regressions. Both are worth adding.3. The C+ waiver only covers the C+. Even if
youssef-lrgranted it, it touchesbrunovjkonly —mukhrrstays at $125 as the Contributor. Claude framed it as the one route open for both.4. The Payment Summary role labels are wrong. It lists both as "Reviewer."
mukhrris the Contributor — they wrote the accepted proposal and authored #97935. Same $250 base either way, but your checklist item is "confirm assignees, roles."5. No Payment Summary was ever generated on 98692, so there is nothing to actively skip — just don't create one.
Claims I verified
mukhrrauthored Show Edit comment for text and attachment messages while the attachment uploads #97935;brunovjkapproved 2026-08-12;youssef-lrapproved 2026-08-14. Merged 2026-08-14T00:13:33Z.getUploadingAttachmentHtmlFromCommentandreplaceLocalAttachmentReferencesare added lines in the 97935 diff — they did not exist before it. The fault is in code that PR introduced.CONTRIBUTING.md:74starts the window at merge, which also settles the staging-only argument the way you already answered it.CONTRIBUTING.md:76.blob:,file:, document anchors, andhttps— no video case.mukhrr, 53 additions) shipped in 9.4.54-4 on 2026-08-18. Doesn't change liability, but the record should be accurate.On the rubric itself: the structure is good — it's falsifiable, each branch has a test, and the precedents give it teeth. Two gaps beyond the ones above. First, add an explicit "enumerate every issue naming this PR as the offending PR" step before running the branches, or the framework silently assumes the regression count it was handed. Second, the "already on production" branch was the one that did real work here (it cleared two of three candidates), and in both cases the evidence was a human's repro, not the "build from the commit before the merge" test as written. Worth broadening that test to accept a QA "reproducible in production: yes" or a documented repro from someone on the issue.
view run
brunovjk commentedon Sep 2, 2026
Great, @mallenexpensify. I’m good with $125. Thank you!
melvin-bot commentedon Sep 2, 2026
@youssef-lr Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
mukhrr commentedon Sep 3, 2026
me too. thanks
youssef-lr commentedon Sep 3, 2026
Agreed with Melvin here.
mallenexpensify commentedon Sep 3, 2026
Payment Summary
Contributor: @mukhrr due $125 via NewDot
Contributor+: @brunovjk due $125 via NewDot
laurenreidexpensify commentedon Sep 4, 2026
$125 approved @brunovjk New Expensify
flaviadefaria commentedon Sep 11, 2026
Approved: @mukhrr owed $125 via NewDot