Summary:
bypass-github-export-checks
OSS release infrastructure for the (experimental) React Native DevTools standalone shell.
Currently, binaries are built continuously on Meta infra and served from the Meta CDN using fbcdn.net URLs checked into a DotSlash file in the repo, e.g.:
https://github.com/facebook/react-native/blob/15373218ec572c0e43325845b80a849ad5174cc3/packages/debugger-shell/bin/react-native-devtools#L9-L18
For open source releases we want to primarily distribute the binaries as GitHub release assets, while keeping the Meta CDN URLs as a secondary option. This PR makes the necessary changes to the release workflows to support this:
* `workflows/create-release.yml` (modified): As part of the release commit, rewrite the DotSlash file to include the release asset URLs.
* **NOTE:** After this commit, **the new URLs don't work yet**, because they refer to a release that hasn't been published. Despite this, the DotSlash file remains valid and usable (because DotSlash will happily fall back to the Meta CDN URLs, which are still in the file).
* `workflows/create-draft-release.yml` (modified): After creating a draft release, fetch the binaries from the Meta CDN and reupload them to GitHub as release assets. This is based on the contents of the DotSlash file rewritten by `create-release.yml`.
* `workflows/validate-dotslash-artifacts.yml` (new): After the release is published, all URLs referenced by the DotSlash (both Meta CDN URL and GH release asset URLs) should be valid and refer to the same artifacts. This workflow checks that this is the case.
* If this workflow fails on a published release, the release may need to be burned or a hotfix release may be necessary - as the release will stop working correctly once the Meta CDN stops serving the assets.
* This workflow will also be running continuously on `main`. If it fails on a commit in `main`, there might be a connectivity issue between the GHA runner and the Meta CDN, or there might be an issue on the Meta side.
NOTE: These changes to the release pipeline are generic and reusable; if we later add another DotSlash-based tool whose binaries need to be mirrored as GitHub release assets, we just need to add it to the `FIRST_PARTY_DOTSLASH_FILES` array.
## Changelog:
[Internal] Mirror React Native DevTools binaries in GitHub Releases
Pull Request resolved: https://github.com/facebook/react-native/pull/52930
Test Plan:
### Step 0: Unit tests
I've added unit tests for `dotslash-utils`, `curl-utils`, and for the majority of the logic that makes up the new release scripts (`write-dotslash-release-assets-urls`, `upload-release-assets-for-dotslash`, `validate-dotslash-artifacts`).
### Step 1: Test release commit
Created a test branch and draft PR: https://github.com/facebook/react-native/pull/53147.
Locally created a release commit, simulating the create-release GH workflow:
```
node scripts/releases/create-release-commit.js --reactNativeVersion 0.82.0-20250903-0830 --no-dry-run
```
This updated the DotSlash file in the branch: https://github.com/facebook/react-native/pull/53147/commits/2deeb7e70376ee80b99f27bea4825789f22a89a3#diff-205a9ff6005e30be061eaa64b9cb50b15b0e909dd188e0866189e952655a3483
NOTE: I've also ensured that the `create-release-commit` script correctly updates the DotSlash file when running from a branch that already has a release commit - see screenshot:
<img width="1483" height="587" alt="image" src="https://github.com/user-attachments/assets/1ffd859b-e02b-483d-8067-9cc9116829a4" />
### Step 2: Test draft release
Enabled testing the create-draft-release GH workflow in the test branch using these temporary hacks:
* https://github.com/facebook/react-native/pull/53147/commits/81f334eac5147d4dbf5f6d7d627ddfa52cd197be
* https://github.com/facebook/react-native/pull/53147/commits/6d8851657629de7e0b710ed8f5dd7d0f7b9847cc
* https://github.com/facebook/react-native/pull/53147/commits/1428a8da8b9fb29c45fc33d79f311dd1fe273433
Workflow run: https://github.com/facebook/react-native/actions/runs/17426711373/job/49475327346
Draft release: https://github.com/facebook/react-native/releases/tag/untagged-c6a62a58e5baa37936e1
Draft release screenshot for posterity (since we'll likely delete the draft release after landing this):
<img width="1024" height="814" alt="image" src="https://github.com/user-attachments/assets/1900da15-48f6-4274-b29c-0ac2019d92c0" />
### Step 3: Test post-release validation script
For obvious reasons, I've avoided actually publishing the above draft release. But I have run the `validate-dotslash-artifacts` workflow on the *current* branch to ensure that the logic is correct: https://github.com/motiz88/react-native/actions/runs/17426885205/job/49475888486
Running `node scripts/releases/validate-dotslash-artifacts.js` in the release branch (without publishing the release first) fails, as expected:
<img width="1105" height="748" alt="image" src="https://github.com/user-attachments/assets/ed23a2e2-7a31-42eb-a324-f1d50eafe2fb" />
## Next steps
This PR is all the infra needed ahead of the 0.82 ~~branch cut~~ infra freeze to support the React Native DevTools standalone shell, at least on the GitHub side. ~~Some minor infra work remains on the Meta side, plus some product/logic changes to the React Native DevTools standalone shell that I'm intending to finish in time for 0.82 (for an experimental rollout).~~ EDIT: All the planned work has landed; the feature is code-complete on `main` as well as in `0.82-stable` (apart from this infra change).
As a one-off, once we've actually published 0.82.0-rc.1, we'll want to have a human look at the published artifacts and CI workflow logs to ensure everything is in order. (I'll make sure to communicate this to the 0.82 release crew.) Afterwards, the automation added in this PR should be sufficient.
Reviewed By: huntie
Differential Revision: D81578704
Pulled By: motiz88
fbshipit-source-id: 6a4a48c3713221a89dd5fc88851674c1ddc6bb10
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53558
Changelog: [Internal]
Got confused regarding why "reconnect" does not actually trigger a reconnect. It turns out, it only triggers a reconnect if the URL has changed.
Reviewed By: cipolleschi, huntie
Differential Revision: D80629308
fbshipit-source-id: 098ef5e91f3748deb9bc707b79bc0395d2442ca4
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53600
# Changelog:
[Internal] -
Adds the corresponding feature flag, similarly as it's done for other component types.
The flag is used in the next diff.
Reviewed By: mdvacca
Differential Revision: D81681404
fbshipit-source-id: f9f155379034695f5df6cc4f0d3787ff4c69df7f
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53578
Changelog: [Internal]
Adds a new preprocessor directive which should be set when the new Hermes is being used. This directive will disable the legacy debugger which isn't supported by it.
Reviewed By: cipolleschi, cortinico
Differential Revision: D81035112
fbshipit-source-id: b30ae348b3419ec2d064dfe7f91c9d664a66f5cf
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53410
Changelog: [Internal]
Adding babel-istanbul-plugin to instrument bundle code with coverage reporting.
Metro will transform source code only when coverage flag is set up globally in jest.
Coverage map is then provided by runner as part of test result.
Reviewed By: sammy-SC
Differential Revision: D80716433
fbshipit-source-id: 3831f227f8793f874f0d2366759bb6916e747c72
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53475
This is cleanup of IHermesExtra. Move the last method in IHermesExtra,
dumpOpcodeStats(), to jsi::Instrumentation, since other profile stats
dumping methods live in that interface as well.
Changelog: [Internal]
Reviewed By: tsaichien
Differential Revision: D81087047
fbshipit-source-id: e145aafea7459a161fca04ffc30f0838ee6c03c6
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53473
This is a cleanup of IHermesExtra:
1. Move dumpSampledTraceToProfile() and debugJavasScript() to IHermes.
I'm still keeping the empty DebugFlags, since changing that requires
more changes. It's also possible that we may need it in the future.
2. Remove `dumpBasicBlockProfileTrace`. Use
writeBasicBlockProfileTraceToFile` if users need to dump the profile.
Changelog: [Internal]
Reviewed By: tsaichien
Differential Revision: D81075460
fbshipit-source-id: b81005e531809cfd870fd9bdb5c0e17864ed92fb
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53419
By default, this function returns nullptr. User can pass a preprocessor
definition "-DHERMES_SH_UNIT_FN=sh_export_<unit_name>" (where
<unit_name> is the name passed to shermesc when compiling the JS
input), so that this function returns the function pointer, which can
be passed to `evaluateSHUnit` for evaluation.
Changelog: [Internal]
Reviewed By: avp
Differential Revision: D80747463
fbshipit-source-id: a798a7a572679444fca111c34674fd7ced9311f3
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53418
Expose these methods so that we can access from RN code. To minimize
the change, a few methods that depend on other headers or preprocessor
flags are wrapped into IHermesExtra in hermes/API/hermes.h.
Changelog: [Internal]
Reviewed By: tsaichien
Differential Revision: D80740969
fbshipit-source-id: 79565d851bc1b0833931f4fe7fb62d89d3d669ef
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53577
Simplify the API to keep all formatting inside of ReactHostStateTracker and remove the `bridgeless` part of the name. Bit more efficient binary-size wise.
Changelog: [Internal]
Reviewed By: alanleedev
Differential Revision: D81445833
fbshipit-source-id: 5bc8bc9e3de326f23e95e01e889b4e2806438c06
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53588
# Changelog: [Internal]
Since the `name` was already moved for the begin event, there is nothing to be moved for `end` event. Instead, we will be creating a copy for the `begin` event.
This was actually affecting some entries on a timeline, like component triggers (yellow ones).
Reviewed By: vzaidman
Differential Revision: D81589847
fbshipit-source-id: 3b7d801d3429217ce279ed7de41c40c3838a5f37
Summary:
This PR fixes swipe dismissal to work each time the modal is shown. Previously modalInPresentation was set on the view controller which gets destroyed every time user dismisses the modal. This makes sure that modal in presentation is correctly preserved when showing multiple modals.
https://github.com/user-attachments/assets/c7f140e5-1c4f-4809-8453-148d4becc9eb
## Changelog:
[IOS] [FIXED] - modal swipe dismissal works only for the first time
Pull Request resolved: https://github.com/facebook/react-native/pull/53499
Test Plan:
1. Open RN Tester
2. Check allow swipe dismissal
3. Check closing it multiple times
Reviewed By: javache
Differential Revision: D81312918
Pulled By: cipolleschi
fbshipit-source-id: 4f7cc60762660e5d5310f4973fe8df340c1ba52b
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53367
We are missing a dependency in the React-jsinspector podspec that prevents React Native from building with dynamic frameworks.
## Changelog:
[Internal] -
Reviewed By: cortinico
Differential Revision: D80619664
fbshipit-source-id: 1c87ef4d3614ceea3a23196831479ecae0a5acc8
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53570
Idle callbacks are implemented as a C++ module in the new architecture, this code should not be used.
Changelog: [Internal]
Reviewed By: cortinico
Differential Revision: D81485912
fbshipit-source-id: 18103bb96441880ff3de423aa6c03a176f6ff5de
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53569
Simplify construction to save a JNI call, slightly more efficient on binary size too (1KiB hah)
Changelog: [Internal]
Reviewed By: rshest
Differential Revision: D81445834
fbshipit-source-id: b0ec84d5e04d364e34eef4c3b712c62f878325cf
Summary:
Resolves https://github.com/facebook/react-native/issues/53501
This is a pretty major oversight of (presumably) the old autolinking refactor. The iOS autolinking's second stage, invoked in `use_react_native!` does not accept the `react-native-config` sub-command's `react-native-config` output. This is only invoked and used in the prior step, `use_native_modules`.
The second step instead invokes old code that does something _similar_ to the new autolinking in `scripts/generate-artifacts-executor`, and happens to align in most cases. (But it does "autolinking" from scratch). tl;dr: When the results don't match up, things go wrong.
Instead, we now write the autolinking (react native config) results to a file, then read the output back in the second step.
This doesn't affect Android/Gradle, which are implemented correctly.
## Changelog:
[IOS] [FIXED] - Use autolinking-generated react-native-config output in second step of cocoapods linking that generates artifacts and generated source
Pull Request resolved: https://github.com/facebook/react-native/pull/53503
Test Plan:
- See https://github.com/facebook/react-native/issues/53501 for failing repro
- Clone for working repro: https://github.com/byCedric/react-native-codegen-ios-autolinking/tree/fix-54503
- Note: Contains this PR's changes as a patch
- `bun install`
- `bun expo run:ios`
Reviewed By: cortinico
Differential Revision: D81490755
Pulled By: cipolleschi
fbshipit-source-id: eefe786a116404f4ed24bd7125dfb108a811f71e
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53560
Since Gradle 9.0, all the projects in the path must have an existing folder.
As we build :packages:react-native:ReactAndroid, we need to declare the folders
for :packages and :packages:react-native as well as otherwise the build from
source will fail with a missing folder exception.
Changelog:
[Android] [Fixed] - Fix build from source due to missing folder error on Gradle 9.0
Reviewed By: fabriziocucci
Differential Revision: D81482789
fbshipit-source-id: 609b503755486e10060a0f321bd0a38bd71864a1
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53566
TLDR; we never advertised this and it's not in use. We have an updated incoming plan for exposing internal private code to Expo / other frameworks.
Changelog: [Internal]
Reviewed By: christophpurrer
Differential Revision: D81490655
fbshipit-source-id: f3d64582f5e6092e4928865d868ea26867ee7e47
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53571
Changes `VirtualView` so that its layout when hidden can be configured by call sites.
Previously, it was hardcoded to only retain the last known height. However, this logic only works for `VirtualView` children oriented in a column layout.
This change enables the use of `VirtualView` in more flexible abstractions that require different hidden styles (e.g. row or grid orientations).
Also, this changes the default behavior to set `minWidth` and `minHeight`, so that the default behavior is more general and more likely to work in a reasonable manner in more use cases.
NOTE: Ideally, we would be able to default to using `flexBasis` instead. However, the `hiddenStyle` function receives a `Rect` and does not know whether the parent's flex direction is row or column to influence whether to use `targetRect.width` or `targetRect.height`. This is an opportunity for future improvement.
Changelog:
[Internal]
Reviewed By: lunaleaps
Differential Revision: D81344126
fbshipit-source-id: 33d9e81601b671059f97b4590816243cbd24734a
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53533
Creates a new `enableVirtualViewExperimental` feature flag that determines whether `VirtualView` uses the old or new implementation.
Changelog:
[Internal]
Reviewed By: lunaleaps
Differential Revision: D81340963
fbshipit-source-id: f550fe4e4573e080eb8668077d0ad3ca53cd4d33
Summary:
This PR falls back to UIScreen when windowScene is not available.
<img width="500" alt="CleanShot 2025-08-28 at 14 30 59@2x" src="https://github.com/user-attachments/assets/9dda3153-dfe7-48a5-9d0e-5416c2e34c64" />
## Changelog:
[IOS] [FIXED] - Simplify RCTAlertController, don't create additional UIWindow
Pull Request resolved: https://github.com/facebook/react-native/pull/53500
Test Plan:
Open the alert multiple times to check if everything works as expected.
Rollback Plan:
Reviewed By: javache
Differential Revision: D81410450
Pulled By: cipolleschi
fbshipit-source-id: c27ea98d9e811c2f259f0ff3c6689482d116c418
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/53534
BackgroundDrawable and BorderDrawable have already substituted CSSBackgroundDrawable en every Android surface.
- Deleting CSSBackgroundDrawable.java and its callsites
- Deleting enableNewBackgroundAndDrawable featureflag
Just cleaning up what at this point is just dead code.
Changelog: [Internal]
Reviewed By: javache
Differential Revision: D81330969
fbshipit-source-id: bcf66ec8d3225802432ae1d93a2b26ea65cfcda0