Repository navigation
Gate close account for copilots - #99400
Conversation
…ount-for-copilots
Codecov Report✅ Changes either increased or maintained existing code coverage, great job!
|
Reviewer Checklist
Screenshots/VideosAndroid: HybridAppAndroid: mWeb ChromeiOS: HybridAppiOS: mWeb SafariMacOS: Chrome / Safarichrome.mp4 |
|
@Beamanator 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] |
|
Assigning @Valforte since he reviewed the related backend PRs for it |
joekaufmanexpensify
left a comment
There was a problem hiding this comment.
Good for product
|
Internal approvals are complete and all tests pass. Going ahead with merging. |
|
🚧 joekaufmanexpensify has triggered a test Expensify/App build. You can view the workflow run here. |
|
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
|
🧪🧪 Use the links below to test this adhoc build on Android, iOS, and Web. Happy testing! 🧪🧪
|
|
🚀 Deployed to staging by https://github.com/joekaufmanexpensify in version: 9.4.62-1 🚀
|
Help site review — changes required ✅This PR gates the Close account action for Copilots: a Copilot acting on the account owner's behalf now sees a no-access message (and a full-page not-allowed view via direct link) instead of the close form, regardless of access level. The Act as a Copilot help article listed what Copilots can/can't do but only attributed restrictions to Limited Access — it didn't reflect that closing the account owner's account is blocked for all Copilots. I updated it to match this new behavior. I did not change Close Your Expensify Account, since its audience is the account owner closing their own account and the Copilot restriction is better documented in the Copilot article. Draft docs PR: #99604 (labeled @lakchote, please review the linked help site PR and confirm it reflects the current behavior. Then mark the linked help site PR |
|
🚀 Deployed to production by https://github.com/AndrewGable in version: 9.4.62-4 🚀
Bundle Size Analysis (Sentry): |
Explanation of Change
A copilot could still open Settings > Security > Close account while acting on another person’s behalf and submit the form. Backend doesn't allow that. Leaving the form visible would only lead copilots to an action they cannot complete.
This PR prevents that by:
CloseAccountPageinDelegateNoAccessWrapper, so direct links show the full-page not-allowed view instead of the form.Fixed Issues
$ #99518
PROPOSAL:
Tests
Screen.Recording.2026-08-26.at.08.59.54.mov
Offline tests
NA
QA Steps
Same as tests.
PR Author Checklist
### Fixed Issuessection aboveTestssectionOffline stepssectionQA stepssectiontoggleReportand notonIconClick)myBool && <MyComponent />.src/languages/*files and using the translation methodWaiting for Copylabel for a copy review on the original GH to get the correct copy.STYLE.md) were followedAvatar, I verified the components usingAvatarare working as expected)/** comment above it */thisproperly so there are no scoping issues (i.e. foronClick={this.submit}the methodthis.submitshould be bound tothisin the constructor)thisare necessary to be bound (i.e. avoidthis.submit = this.submit.bind(this);ifthis.submitis never passed to a component event handler likeonClick)StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG))Avataris modified, I verified thatAvataris working as expected in all cases)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