-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Fix adding unreported expense when expense is created in offline mode #62097
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix adding unreported expense when expense is created in offline mode #62097
Conversation
26675ba
to
4c6f800
Compare
b11f3a3
to
e31e605
Compare
Regarding I think we shouldn’t worry about it because we are in utility functions here, so: Firstly, it's better to avoid unnecessary changes. Secondly, we can't use useOnyx here anyway — we would have to implement it the same way as it's currently done using onyxConnect.
So we wouldn't really gain anything from making this change. |
This still reproduces for transactions that were created and added offline, and I don't think it's part of this task. |
@DylanDylann Please copy/paste the Reviewer Checklist from here into a new comment on this PR and complete it. If you have the K2 extension, you can simply click: [this button] |
Reviewer Checklist
Screenshots/VideosScreen.Recording.2025-05-16.at.15.56.38.mp4 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Note that getTransaction deprecation warning is being handled #61910
Thanks, I didn’t notice that. |
Deprecated note but we did not touch that function so moving ahead |
@mountiny looks like this was merged without a test passing. Please add a note explaining why this was done and remove the |
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
Performance Comparison Report 📊 (1/3)Significant Changes To Duration
Show details
|
Performance Comparison Report 📊 (2/3)Meaningless Changes To Duration (1/2)Show entries
Show details
|
Performance Comparison Report 📊 (3/3)Meaningless Changes To Duration (2/2)Show entries
Show details
|
@Expensify/mobile-deployers 📣 Please look into this performance regression as it's a deploy blocker. |
Explanation of Change
A newly created expense without an associated report has no report ID at all, rather than being set to 0.
Fixed Issues
$ #61999
$ #62001
PROPOSAL:
Tests
Offline tests
Same as test
QA Steps
Same as test
// TODO: These must be filled out, or the issue title must include "[No QA]."
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectioncanBeMissing
param foruseOnyx
toggleReport
and notonIconClick
)src/languages/*
files and using the translation methodSTYLE.md
) were followedAvatar
, I verified the components usingAvatar
are working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)
)Avatar
is modified, I verified thatAvatar
is working as expected in all cases)Design
label and/or tagged@Expensify/design
so the design team can review the changes.ScrollView
component to make it scrollable when more elements are added to the page.main
branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTest
steps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
Screen.Recording.2025-05-15.at.17.00.56.2.mov
MacOS: Desktop
Screen.Recording.2025-05-16.at.11.22.29.mov