Skip to content

[ci] Add ghstack /land bot #32829

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

[ci] Add ghstack /land bot #32829

wants to merge 1 commit into from

Conversation

poteto
Copy link
Member

@poteto poteto commented Apr 8, 2025

Adds a new /land command that can be written as a comment on a pull request. The command must be the very first line of the comment, like so:

/land

<additional context etc>

The workflow will first check if the commenter is a collaborator or member, and additionally also check if the commenter is a maintainer via the MAINTAINERS file.

The workflow will then attempt to validate the pull request, checking that CI has completed successfully and that it has received at least one approval before landing. The land is performed via ghstack land, which does mean that the PR itself isn't merged directly via github but it is pushed to main by a synthetic user (@facebook-github-bot for now). This means PRs landed with /land will have an additional co-author @facebook-github-bot, but the original committer will not be lost.

@github-actions github-actions bot added the React Core Team Opened by a member of the React Core Team label Apr 8, 2025
@react-sizebot
Copy link

react-sizebot commented Apr 8, 2025

Comparing: bb74190...71c4b32

Critical size changes

Includes critical production bundles, as well as any change greater than 2%:

Name +/- Base Current +/- gzip Base gzip Current gzip
oss-stable/react-dom/cjs/react-dom.production.js = 6.68 kB 6.68 kB = 1.83 kB 1.83 kB
oss-stable/react-dom/cjs/react-dom-client.production.js = 527.72 kB 527.72 kB = 93.07 kB 93.07 kB
oss-experimental/react-dom/cjs/react-dom.production.js = 6.69 kB 6.69 kB +0.05% 1.83 kB 1.83 kB
oss-experimental/react-dom/cjs/react-dom-client.production.js = 633.34 kB 633.34 kB = 111.25 kB 111.25 kB
facebook-www/ReactDOM-prod.classic.js = 671.16 kB 671.16 kB = 117.72 kB 117.72 kB
facebook-www/ReactDOM-prod.modern.js = 661.44 kB 661.44 kB = 116.16 kB 116.16 kB

Significant size changes

Includes any change greater than 0.2%:

(No significant changes)

Generated by 🚫 dangerJS against 71c4b32

- name: Land It!
run: |
git config --global user.email "facebook-github-bot@users.noreply.github.com"
git config --global user.name "Facebook Community Bot"
Copy link
Member

Choose a reason for hiding this comment

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

Does this break the commit verification?

Ideally this would be set this to the user that does the /land command, I believe that's what a merge would do. But that would break the verification too.

Adds a new `/land` command that can be written as a comment on a pull request. The command must be the very first line of the comment, like so:

```
/land

<additional context etc>
```

The workflow will first check if the commenter is a collaborator or member, and additionally also check if the commenter is a maintainer via the MAINTAINERS file.

The workflow will then attempt to validate the pull request, checking that CI has completed successfully and that it has received at least one approval before landing. The land is performed via `ghstack land`, which does mean that the PR itself isn't merged directly via github but it is pushed to main by a synthetic user (@facebook-github-bot for now). This means PRs landed with `/land` will have an additional co-author @facebook-github-bot, but the original committer will not be lost.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed React Core Team Opened by a member of the React Core Team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants