-
Notifications
You must be signed in to change notification settings - Fork 3k
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 ReportUtils Lint #49325
Fix ReportUtils Lint #49325
Conversation
@nkdengineer @thienlnam do you know if we migrated to start using reportAction.message instead of reportAction.originalMessage here? PR for context where we deprecated originalMessage |
Yeah, the goal is to stop using originalMessage and just use message instead |
Hi @nkdengineer, do you know if there was a reason this instance of originalMessage was not changed in this PR? Do we still need it? |
@srikarparsi Because BE change doesn't change this then we still keep the |
Got it, I'm going to disable this lint error for now since it's setting originalMessage, not getting it and we still use it in the backend. |
@youssef-lr 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] |
Hi @tgolen, I saw that you deprecated getParentReportAction in this PR so I just wanted to check if I'm going about this the right way. I also saw that we were using getReportAction in some places to get the parentReportAction but I felt like that has the same problem you described in this issue body? |
I wasn’t aware that a separate PR here is being worked on to remove I think it would be better to use a type predicate for Please check if any of the changes in #49324 for lint fixes are useful for this PR. I completed the changes as far as I felt are ideal in that PR and we might also consider reviewing that PR and merging it instead of this PR. |
Definitely agree with this thank you.
Yup! Taking a look. I do think it would be better to do it in this PR so we can identify regressions easier. If you want to put your PR on hold for this one, we probably should be able to get this merged today or tomorrow. |
src/libs/ReportUtils.ts
Outdated
@@ -4248,6 +4260,7 @@ function buildOptimisticTaskCommentReportAction( | |||
|
|||
// These parameters are not saved on the reportAction, but are used to display the task in the UI | |||
// Added when we fetch the reportActions on a report | |||
// eslint-disable-next-line deprecation/deprecation |
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.
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.
Hm so it's actually interesting. Locally, it says that the error is deprecation/deprecation when I run npm run lint-changed
I'm going to switch it to eslint-disable-next-line
for now to suppress the error? What do you think? The other thing we can do is what was done here with a spread operator but I'm not sure if it's worth it.
Thanks for assigning. I'll start my testing shortly |
Reviewer Checklist
Screenshots/VideosAndroid: NativeUploading Screen Recording 2024-09-20 at 08.56.55.mov… Android: mWeb ChromeScreen.Recording.2024-09-20.at.09.07.10.moviOS: NativeiOS: mWeb SafariMacOS: Chrome / SafariScreen.Recording.2024-09-20.at.08.44.18.movMacOS: Desktop |
Found this during testing but it also happened on main. Screen.Recording.2024-09-20.at.08.35.07.mov |
🎯 @hungvu193, thanks for reviewing and testing this PR! 🎉 An E/App issue has been created to issue payment here: #49508. |
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging by https://github.com/robertjchen in version: 9.0.40-0 🚀
|
🚀 Deployed to production by https://github.com/AndrewGable in version: 9.0.40-6 🚀
|
Details
Follow up from https://github.com/Expensify/App/pull/46934/files to fix lint errors (The PR did not cause them, just edited the same file)
Fixed Issues
$ #46934 (comment)
PROPOSAL:
Tests
Create a task
Reply in the task
Ensure that it renders correctly
Send an IOU to another user
Click inside the IOU
Ensure that it renders correctly
Offline tests
QA Steps
PR Author Checklist
### Fixed Issues
section aboveTests
sectionOffline steps
sectionQA steps
sectiontoggleReport
and notonIconClick
)myBool && <MyComponent />
.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
MacOS: Desktop