Skip to content

docs: [No QA] Document MelvinBot workflow for contributors and C+#93066

Open
neil-marcellini wants to merge 7 commits into
mainfrom
melvinbot-contributor-docs
Open

docs: [No QA] Document MelvinBot workflow for contributors and C+#93066
neil-marcellini wants to merge 7 commits into
mainfrom
melvinbot-contributor-docs

Conversation

@neil-marcellini

@neil-marcellini neil-marcellini commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Explanation of Change

(Neil's AI agent)

Adds contributingGuides/HOW_TO_WORK_WITH_MELVINBOT.md documenting how contributors, C+, and CMEs work with MelvinBot on App issues: proposal review before implementation, C+ PR ownership after Melvin implements, and CME review/merge. Links the guide prominently from CONTRIBUTING.md and HOW_TO_BECOME_A_CONTRIBUTOR_PLUS.md.

Fixed Issues

$ #93064
PROPOSAL:

Tests

N/A

  • Verify that no errors appear in the JS console

Offline tests

N/A — documentation only

QA Steps

N/A — documentation only

PR Author Checklist

  • I linked the correct issue in the ### Fixed Issues section above
  • I wrote clear testing steps that cover the changes made in this PR
    • I added steps for local testing in the Tests section
    • I added steps for the expected offline behavior in the Offline steps section
    • I added steps for Staging and/or Production testing in the QA steps section
    • I added steps to cover failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
    • I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
    • I tested this PR with a High Traffic account against the staging or production API to ensure there are no regressions (e.g. long loading states that impact usability).
  • I included screenshots or videos for tests on all platforms
  • I ran the tests on all platforms & verified they passed on:
    • Android: Native
    • Android: mWeb Chrome
    • iOS: Native
    • iOS: mWeb Safari
    • MacOS: Chrome / Safari
  • I verified there are no console errors (if there's a console error not related to the PR, report it or open an issue for it to be fixed)
  • I followed proper code patterns (see Reviewing the code)
    • I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick)
    • I verified that comments were added to code that is not self explanatory
    • I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
    • I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method
    • I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
    • I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is either coming verbatim from figma or has been approved by marketing (in order to get marketing approval, ask the Bug Zero team member to add the Waiting for copy label to the issue)
    • I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
    • I verified the JSDocs style guidelines (in STYLE.md) were followed
  • If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
  • I followed the guidelines as stated in the Review Guidelines
  • I tested other components that can be impacted by my changes (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar are working as expected)
  • I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
  • I verified any variables that can be defined as constants (ie. in CONST.ts or at the top of the file that uses the constant) are defined as such
  • I verified that if a function's arguments changed that all usages have also been updated correctly
  • If any new file was added I verified that:
    • The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory
  • If a new CSS style is added I verified that:
    • A similar style doesn't already exist
    • The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))
  • If new assets were added or existing ones were modified, I verified that:
    • The assets are optimized and compressed (for SVG files, run npm run compress-svg)
    • The assets load correctly across all supported platforms.
  • If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
  • If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
  • If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
  • If the PR modifies a component or page that can be accessed by a direct deeplink, I verified that the code functions as expected when the deeplink is used - from a logged in and logged out account.
  • If the PR modifies the UI (e.g. new buttons, new UI components, changing the padding/spacing/sizing, moving components, etc) or modifies the form input styles:
    • I verified that all the inputs inside a form are aligned with each other.
    • I added Design label and/or tagged @Expensify/design so the design team can review the changes.
  • If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
  • I added unit tests for any new feature or bug fix in this PR to help automatically prevent regressions in this user flow.
  • If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.

Screenshots/Videos

N/A

Android: Native

N/A — documentation only

Android: mWeb Chrome

N/A — documentation only

iOS: Native

N/A — documentation only

iOS: mWeb Safari

N/A — documentation only

MacOS: Chrome / Safari

N/A — documentation only

Adds a dedicated guide for proposal review, C+ PR ownership, and CME merge
on MelvinBot issues, and links it prominently from CONTRIBUTING.md.

Co-authored-by: Cursor <cursoragent@cursor.com>
@neil-marcellini neil-marcellini requested a review from a team as a code owner June 9, 2026 13:02
@melvin-bot melvin-bot Bot requested review from ShridharGoel and removed request for a team June 9, 2026 13:02
@melvin-bot

melvin-bot Bot commented Jun 9, 2026

Copy link
Copy Markdown

@ShridharGoel 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]

Comment thread contributingGuides/HOW_TO_WORK_WITH_MELVINBOT.md Outdated
neil-marcellini and others added 6 commits June 9, 2026 09:09
Co-authored-by: Cursor <cursoragent@cursor.com>
Fixes spellcheck failure on the Melv acronym in CONTRIBUTING.md.

Co-authored-by: Cursor <cursoragent@cursor.com>
C+ who cannot edit Melvin-authored PR descriptions should post the full
body or checklist in a details block and ask Melvin to apply it; CMEs
may review that comment directly.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Reorder Phase 1 so C+ recommends via 🎀👀🎀, CME approves, then C+ asks
Melvin to implement—not immediately after C+ review.

Co-authored-by: Cursor <cursoragent@cursor.com>
@@ -153,7 +156,8 @@ This helps future investigators understand the history and current status of err

### Propose a solution for the job
4. Proposals must only be posted after the `Help Wanted` label is added. Any proposals submitted beforehand will be ignored and not reviewed. Do not post proposals in Slack.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we clarify "Proposals by contributors...." ? Because Melvin will post before Help Wanted label is applied.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's okay that Melvin follows different rules. This guide is aimed at contributors.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got it, I was just thinking what if some contributor cites this and asks why a proposal (Melvin's) posted before the "Help Wanted" label is being considered.

→ C+ recommends acceptance (🎀👀🎀) → CME approves proposal
→ C+ asks Melvin to implement (only after CME approval)
→ Not accepted: C+ or CME explains why
→ Melvin opens draft PR → C+ tweaks, tests, posts PR body/checklist in a PR comment, asks Melvin to apply it, self-reviews (including Reviewer checklist)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is C+ now expected to add the videos in both the author and reviewer checklists? Earlier we were adding only in the reviewer checklist

Once the assigned CME has approved Melvin's proposal (the same acceptance step as for any contributor proposal), the C+ comments on the issue asking Melvin to implement, for example:

```
@MelvinBot please implement your proposal

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we also add the link of the proposal, to ensure that Melvin only uses it's own proposal (and the latest one - since sometimes it posts a new proposal when asked to update) ?


Before requesting final review, the assigned C+ must:

1. **Manually tweak the PR** if Melvin's implementation needs corrections.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Worth mentioning that we'll need to ask by tagging @MelvinBot and explaining the needed changes.

Comment on lines +7 to +9
## Why this process exists

Melvin can open pull requests before a human has validated the approach. Without a clear process, contributors waste time on unapproved work, and internal engineers may review PRs that should not have been started. Proposal review must happen **before** implementation.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems unnecessary bloating the guide IMO, the first paragraph coves a lot of this

C+ members who cannot edit the PR body directly should use this workaround:

1. On the **pull request**, post a comment with the exact content you want in the PR description. Put the full body inside a `<details>` block so the PR thread stays readable. Include the complete [PR template](https://github.com/Expensify/App/blob/main/.github/PULL_REQUEST_TEMPLATE.md) when possible: Explanation of Change, Fixed Issues, Tests, Offline tests, QA Steps, a fully checked PR Author Checklist, and Screenshots/Videos sections as needed.
2. In the same comment, ask Melvin to copy that content into the pull request body, for example:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No we don't want contributors to workaround Melvin's permissions like this. Leaving the comment is fine

Comment on lines +101 to +110
## Quick reference: what not to do

| Do not | Why |
|--------|-----|
| Open a PR before a proposal is accepted | Wastes contributor and reviewer time if the approach is wrong |
| Ask `@MelvinBot` to implement before the CME approves the proposal | Implementation must wait for CME approval, not just C+ recommendation |
| Skip C+ proposal review because Melvin wrote it | Melvin proposals need the same validation as human proposals |
| Send Melvin's draft PR for CME review without testing and checklist completion | The C+ is the human author and owns quality |
| Assume you can edit Melvin's PR description in the GitHub UI | Post the body in a PR comment and ask `@MelvinBot` to apply it |
| Expect a second C+ or contributor review after C+ submission | Only the CME reviews before merge |

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary bloating the guide IMO

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants