Commit Graph

210 Commits

Author SHA1 Message Date
lauren
5a78dd7cfe [ci] Also notify compiler ready for review PRs (#32371)
Similar to #32344
2025-02-12 15:13:47 -05:00
Hendrik Liebau
93b58361d9 Trigger Discord notification when draft PR is set to "ready for review" (#32344)
Follow-up for #32332. The Discord webhook seems to ignore draft PRs,
which is a good thing. But when a draft PR is then later set to "ready
for review" we do want to send another notification that should not be
filtered out.
2025-02-09 17:55:50 -05:00
lauren
062fb31155 [ci] Fix typo (#32337)
Oops.
2025-02-07 18:01:53 -05:00
lauren
7588b6b291 [ci] Disallow PRs against builds branch (#32335)
Our internal build infra relies on a 1:1 mapping between `main` and the
2 build branches. Directly committing changes to those branches breaks
that infra.

Adds a simple workflow to leave a comment and decline the PR.
2025-02-07 17:49:09 -05:00
lauren
569c3b28ee [ci] Combine sizebot jobs (#32333)
There's no real reason to have 2 jobs for sizebot. It's more of a
historical artifact from before the GH migration. Merging them should
require one less worker needing to be provisioned and some of the extra
overhead
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/32333).
* __->__ #32333
* #32332
2025-02-07 16:39:37 -05:00
lauren
bc78de3a52 [ci] Use 'opened' event for discord notifications (#32332)
We don't need to wait for it to be labeled now that we have the shared
maintainer check workflow.
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/32332).
* #32333
* __->__ #32332
2025-02-07 16:34:26 -05:00
lauren
0a82580bfc [ci] Only notify discord on core team label (#32303)
Rather than notify on every label event on a PR by a core team member,
only do so for the specific core team label event.
2025-02-03 12:57:51 -05:00
lauren
55b54b0d63 [ci] Only install chromium for flight fixtures (#32275)
I noticed we only use chromium in fixtures/flight, so let's specifically
only install that browser in ci.
2025-01-30 14:13:45 -05:00
lauren
f02ba2fcc5 [ci] Remove build_devtools_and_process_artifacts as a dependency to run_devtools_e2e_tests (#32267)
I just noticed that we don't actually need to let the devtools build
finish first because the e2e tests don't use those built files. We can
decouple them to allow them to run in paralllel.
2025-01-30 11:55:28 -05:00
lauren
14f7c07271 [ci] Try to parallelize devtools builds (#32266)
Building DevTools is currently the long pole for the runtime CI job.
Let's see if we can get the overall runtime for runtime build and test
down by speeding this one step up.
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/32266).
* #32267
* __->__ #32266
2025-01-30 11:49:04 -05:00
Joe Savona
9eabb37338 [compiler][be] Remove unused experimental Rust port
I wrote this a couple summers back as an experiment to see how easily we could translate the compiler to Rust. We make extensive use of in-place mutation of the IR, and the experiment proved that this we can get reasonable ergonomics for this in Rust which was cool. We've since ended up using some of the code here for Relay, allowing Relay Compiler to parse JS files to do more fine-grained extraction of data. For React Compiler though, we plan to continue using JavaScript and explore lightweight native wrappers for things like OXC and SWC plugins. We're also working with the Hermes team to eventually compile the compiler with Static Hermes.

As Tomo always says: always bet on JavaScript.

ghstack-source-id: c5770a2efc
Pull Request resolved: https://github.com/facebook/react/pull/32219
2025-01-24 12:23:31 -08:00
lauren
a6ce56d9a9 [ci] Fix typo (#32217)
yml was a mistake
2025-01-24 15:06:15 -05:00
lauren
5269823927 [ci] Parse inputs for maintainer check workflow (#32216)
I forgot that workflow calls stringify their inputs
2025-01-24 14:56:37 -05:00
lauren
0f8a1e02ff [ci] Make maintainer check workflow usable from other repositories (#32215)
For use in reactjs/react.dev
2025-01-24 14:41:25 -05:00
lauren
77656c557a [ci] Use correct actor when checking if maintainer (#32112) 2025-01-17 12:42:07 -05:00
lauren
d46b04a27d [ci] Fix maintainer output condition check (#32111)
It appears GH actions treats outputs from workflow_calls to [always be
strings](https://github.com/orgs/community/discussions/9343) so we need
to do an explicit comparison.
2025-01-17 10:35:25 -05:00
Damian Stasik
5f38ef6719 Fix maintainer check condition (#32110)
<!--
  Thanks for submitting a pull request!
We appreciate you spending the time to work on these changes. Please
provide enough information so that others can review your pull request.
The three fields below are mandatory.

Before submitting a pull request, please make sure the following is
done:

1. Fork [the repository](https://github.com/facebook/react) and create
your branch from `main`.
  2. Run `yarn` in the repository root.
3. If you've fixed a bug or added code that should be tested, add tests!
4. Ensure the test suite passes (`yarn test`). Tip: `yarn test --watch
TestName` is helpful in development.
5. Run `yarn test --prod` to test in the production environment. It
supports the same options as `yarn test`.
6. If you need a debugger, run `yarn test --debug --watch TestName`,
open `chrome://inspect`, and press "Inspect".
7. Format your code with
[prettier](https://github.com/prettier/prettier) (`yarn prettier`).
8. Make sure your code lints (`yarn lint`). Tip: `yarn linc` to only
check changed files.
  9. Run the [Flow](https://flowtype.org/) type checks (`yarn flow`).
  10. If you haven't already, complete the CLA.

Learn more about contributing:
https://reactjs.org/docs/how-to-contribute.html
-->

## Summary

I've noticed that the value stored under `is_core_team` gets
stringified, so some PRs may be mislabelled as coming from the core
team.

I've checked this on my fork and saw stringified `null` returned by the
`is_core_team`, and this PR explicitly checks for the correct value.
Feel free to close this PR if you want to go with another approach.

## How did you test this change?

Checked this change on my fork with and without listing myself in the
maintainers file.
2025-01-17 10:22:34 -05:00
lauren
1185f88d35 [ci] Only notify after labeling (#32103)
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/32103).
* __->__ #32103
* #32102
2025-01-16 15:12:11 -05:00
lauren
60c797e744 [ci] Use shared maintainer check for discord notifications (#32101)
Uses the shared maintainer check workflow across the various workflows
that need it
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/32101).
* __->__ #32101
* #32100
2025-01-16 14:21:55 -05:00
lauren
af4987e19f [ci] Automatically label PRs from core team (#32100)
Adds a new `MAINTAINERS` file which contains github usernames of core
team members. This file serves as documentation for core team membership
and is also used to automatically label PRs from core.
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/32100).
* #32101
* __->__ #32100
2025-01-16 14:16:21 -05:00
lauren
e5fdd994bf [ci] Better filtering for discord notifications (#32092)
We don't always consistently use "tags" in commit messages, so let's use
the filepaths modified in the PR instead to determine which channel to
send notifications to.
2025-01-16 12:09:58 -05:00
Jack Pope
6093f1862a Fix local react usage in DOM fixture (#32080)
The DOM fixture hasn't worked on local builds since the UMD support was
removed in https://github.com/facebook/react/pull/28735

Here we update the fixture to set the local experimental builds to
window. Some of the pages are still broken, such as hydration. But these
bugs exist on other versions as well and can be cleaned up separately.
2025-01-16 10:33:24 -05:00
Ricky
87276ef1ef [actions] split out compiler notify (#32079) 2025-01-15 17:41:31 -05:00
lauren
f892dabd8c [ci] Make gh workflow names consistent (#32010)
Super minor change to keep our naming scheme consistent for gh workflows
2025-01-07 12:09:10 -05:00
Ricky
7b402084af Fix notify target, add lines (#32006) 2025-01-07 09:34:18 -05:00
Ricky
3314162535 bot for pr notifications (#31985)
Going to take some testing to get this right
2025-01-06 17:57:19 -05:00
lauren
3ce77d55a2 [playground:ci] Don't install compiler deps twice (#31995)
The compiler playground already installs the compiler's dependencies in
a preinstall step. No need to repeat it in CI.

---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/31995).
* __->__ #31995
* #31994
2025-01-06 11:02:23 -05:00
Andrew Clark
9463d51e51 Update runtime workflow to use HEAD commit (#31850)
This updates the CI workflow for the runtime build and tests to use the
HEAD commit of the PR branch rather than the Fake News merge commit that
the `@actions/checkout` action bafflingly defaults to.

Testing against the merge commit never made sense to me as a behavior
because as soon as someone updates upstream, it's out of date anyway.

It should just match the exact commit that the developer pushed, and the
once that appears in the GitHub UI.
2024-12-19 10:18:06 -05:00
lauren
7de040ccfa [ci] Don't cancel runs if more than one branch triggers CI (#31848)
This might primarily only affect those using Sapling for React
development, but pushing the same commit to multiple branches shouldn't
cancel the run

---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/31848).
* __->__ #31848
* #31847
* #31846
2024-12-18 20:10:03 -05:00
lauren
ee10c74824 [playground] Fix incorrect ci path and change reporter (#31572)
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/31572).
* #31573
* __->__ #31572
2024-11-18 19:17:58 -05:00
lauren
2a4f2507a0 [playground] Always upload test results in ci (#31571)
Small change to always upload test results from CI even if the test
failed.
2024-11-18 16:34:10 -05:00
Andrew Clark
e1ef8c9515 Don't dist-tag canaries with rc (#31546) 2024-11-15 10:05:36 +01:00
lauren
380f5d675d Fix sizebot (#31535)
Our CI workflows generally cache `**/node_modules` (note the glob, it
caches all transitive node_module directories) to speed up startup for
new jobs that don't change any dependencies. However it seems like one
of our caches got into a weird state (not sure how it happened) where
the `build` directory (used in various other scripts as the directory
for compiled React packages) would contain a `node_modules` directory as
well. This made sizebot size change messages very big since it would try
to compare every single file in `build/node_modules`.

The fix is to ensure we always clean the `build` directory before doing
anything with it. We can also delete that one problematic cache but this
PR is a little more resilient to other weird behavior with that
directory.
2024-11-13 15:13:46 -05:00
Jan Kassens
314968561b Back out "[bundles] stop building legacy Paper renderer (#31429)" (#31437)
Backs out the 2 related commits:
-
f8f6e1a21a
-
6c0f37f94b

Since I only realized when syncing that we need the version of `react`
and the legacy renderer to match.

While I investigate if there's anything we can do to work around that
while preserving the legacy renderer, this unblocks the sync.
2024-11-06 09:41:18 -05:00
Jan Kassens
f8f6e1a21a [bundles] update GitHub actions for commit build branch (#31432)
This is a followup to
6c0f37f94b
to unblock the job.
2024-11-05 16:04:02 -05:00
lauren
1839e1437f [ez] Update compiler issue template (#31297)
Add a field to specify which version of React Compiler is being used.

---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/31297).
* __->__ #31297
* #31296
2024-10-18 15:02:26 -04:00
lauren
54c0edc019 [ci] Don't use branch name for concurrency (#31296)
I happened to notice some jobs on main get canceled if another PR landed
before the prior commit on main had finished running CI. This is not
great for difftrain because the commit artifacts job relies on the CI
jobs on main finishing before it triggers. This would lead to commits
being skipped on DiffTrain which is not great for provenance since we
want it to be a 1:1 sync.

---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/31296).
* #31297
* __->__ #31296
2024-10-18 15:02:14 -04:00
lauren
9deb36748d [ci] Publish compiler weekly prereleases (#31294)
Adds a new weekly job for the compiler
2024-10-18 14:43:43 -04:00
lauren
915be0ef78 [playground] Upgrade various packages (#31293)
Just some housekeeping
2024-10-18 14:25:36 -04:00
lauren
25cac220d6 [ci] Allow passing various params to compiler publish script (#31283)
Allow passing in a few more inputs when manually publishing.
2024-10-17 18:12:58 -04:00
lauren
9c60cbe3d1 [compiler] Clean up publish script (#31278)
Few small tweaks to make it easier to run adhoc publishes
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/31278).
* #31283
* __->__ #31278
2024-10-17 18:02:41 -04:00
Ruslan Lesiutin
bf7e210cb5 tests[react-devtools]: added tests for Compiler integration (#31241)
Adds tests for Compiler integration.

This includes:
- Tests against Compiler from source.
- Versioned (18.2 - <19) tests against Compiler from npm.

For tests against React 18.2, I had to download `react-compiler-runtime`
from npm and put it to `react/compiler-runtime.js`.
2024-10-17 09:02:41 +01:00
lauren
6cf8518505 [ci] Specify limited concurrency for PR jobs (#31240)
There was a concurrency setting we hadn't enabled on jobs that are
primarily triggered for PRs. This meant that every update to the PR
would trigger new CI jobs without canceling any ones already in flight,
which can greatly slow down CI due to the number of jobs that need to
run.

This PR adds concurrency [based on the workflow name and PR number or
head
ref.](https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/control-the-concurrency-of-workflows-and-jobs)
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/31240).
* __->__ #31240
* #31239
2024-10-14 12:07:24 -04:00
lauren
cbcc1d2027 [ci] Consistent cache names (#31239)
Makes cache names more descriptive and consistent for CI, so it's easier
to tell which cache is used for what purpose.
---
[//]: # (BEGIN SAPLING FOOTER)
Stack created with [Sapling](https://sapling-scm.com). Best reviewed
with [ReviewStack](https://reviewstack.dev/facebook/react/pull/31239).
* #31240
* __->__ #31239
2024-10-14 12:07:08 -04:00
Lauren Tan
db240980a3 [playground] Decouple playground from compiler
Currently the playground is setup as a linked workspace for the
compiler which complicates our yarn workspace setup and means that snap
can sometimes pull in a different version of react than was otherwise
specified.

There's no real reason to have these workspaces combined so let's split
them up.

ghstack-source-id: 56ab064b2f
Pull Request resolved: https://github.com/facebook/react/pull/31081
2024-09-27 15:25:07 -04:00
Lauren Tan
d34da5cdb9 [ci] Fix incorrect sha / commit messages in manual Meta builds
ghstack-source-id: 0790b32d29
Pull Request resolved: https://github.com/facebook/react/pull/31083
2024-09-26 17:43:07 -04:00
Lauren Tan
b90e440231 [dependabot] Ignore all fixture directories
Seems like we can specify a wildcard dependency name to ignore all
dependencies from being updated. As I understand it dependabot will
still run monthly but no PRs will be generated.

ghstack-source-id: 64b76bd532663cdc4db10ba6299e791b5908d5b1
Pull Request resolved: https://github.com/facebook/react/pull/31074
2024-09-26 10:34:35 -04:00
Lauren Tan
0e9ccde185 [dependabot] Remove stale directories from config
ghstack-source-id: 570399bc77529bf9fb005149cfd20ba59405b2bc
Pull Request resolved: https://github.com/facebook/react/pull/31073
2024-09-26 10:34:35 -04:00
Lauren Tan
b7f74f39d8 [ez] Update deprecated action
ghstack-source-id: 991b314fd610bcbca68df52149866b2c6d8e6799
Pull Request resolved: https://github.com/facebook/react/pull/31047
2024-09-26 10:20:10 -04:00
Lauren Tan
c900ee0cce [ez] Make commit sha clickable for fbsource
ghstack-source-id: 1307b9a83a8613c08f11be5397ab45719df00992
Pull Request resolved: https://github.com/facebook/react/pull/31046
2024-09-26 10:20:10 -04:00