Reset completedTaskReportActionID to undefined so it's not passed to the backend when not used#51992
Conversation
… to the backend when not used
completedTaskReportActionID to undefined so it's not passed…completedTaskReportActionID to undefined so it's not passed to the backend when not used
|
@ 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/VideosAndroid: NativeAndroid: mWeb ChromeiOS: NativeiOS: mWeb SafariMacOS: Chrome / SafariMacOS: Desktop |
| assigneeChatReportID: '', | ||
| createdTaskReportActionID: taskCreatedAction.reportActionID, | ||
| completedTaskReportActionID: completedTaskReportAction?.reportActionID ?? '-1', | ||
| completedTaskReportActionID: completedTaskReportAction?.reportActionID ?? undefined, |
There was a problem hiding this comment.
Hi @francoisl This change is causing "402 Invalid task data, missing completedTaskReportActionID" error on the latest main while selecting the "Chat and split expenses with friends" onboarding option and completing the flow. Reverting the change back to '-1' does fix it.
There was a problem hiding this comment.
Here is a video
onboarding-error.mp4
There was a problem hiding this comment.
Yep, that's why the PR description says:
Note that this requires the backend change https://github.com/Expensify/Auth/pull/13028 in order not to reintroduce the same issue from #51395
That first internal PR hasn't been deployed yet. The issue will resolve itself once we deploy it.
There was a problem hiding this comment.
Oh, I see. I didn't fully read the description. Thanks for the explanation.
There was a problem hiding this comment.
No worries haha. If it's blocking you from testing something, feel free to temporarily revert that change back to -1 locally, but please don't commit it.
I expect that the backend changes should be deployed in the next 12 hours.
completedTaskReportActionID to undefined so it's not passed to the backend when not usedcompletedTaskReportActionID to undefined so it's not passed to the backend when not used
|
Taking CP Staging out of title b/c these changes already got to staging in #51983 somehow, which has the exact same change 🤷 |
|
🚀 Deployed to staging by https://github.com/danieldoglas in version: 9.0.58-0 🚀
|
|
🚀 Deployed to production by https://github.com/Julesssss in version: 9.0.58-2 🚀
|
Explanation of Change
Don't pass a
completedTaskReportActionIDin the payload to the commandCompleteGuidedSetupfor tasks that should not be created completed. This will prevent the backend from attempting to auto-complete tasks with the ID-1(or'0'or whatever value we would use)Note that this requires the backend change https://github.com/Expensify/Auth/pull/13028 in order not to reintroduce the same issue from #51395
Fixed Issues
Needed for https://github.com/Expensify/Expensify/issues/441575
Needed for #51969
Needed for #51980
Tests
CompleteGuidedSetupdoesn't include anycompletedTaskReportActionID200QA steps
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)src/languages/*files and using the translation methodSTYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)Designlabel and/or tagged@Expensify/designso the design team can review the changes.ScrollViewcomponent to make it scrollable when more elements are added to the page.mainbranch was merged into this PR after a review, I tested again and verified the outcome was still expected according to theTeststeps.Screenshots/Videos
Android: Native
Android: mWeb Chrome
iOS: Native
iOS: mWeb Safari
MacOS: Chrome / Safari
MacOS: Desktop